Page 1 of 1

Display not turning off

Posted: Sat Aug 03, 2024 6:21 pm
by javisaman
Hi,

I've noticed recently that the reef angel display on my plus unit is not turning off. I noticed that the joystick was stuck (kept scrolling down), so I cleaned the joystick with contact cleaner and added dielectric grease and it fixed that problem. However, the screen remains on. Is there something else I can try?

Re: Display not turning off

Posted: Mon Aug 05, 2024 12:16 pm
by brennyn21
It sounds like it still thinks the joy stick is being pressed or moved.

Here is the relevant code in the ReefAngel_1.5_LCD.h

Code: Select all

void ReefAngelClass::CheckScreenSaver()
{
	// process screensaver timeout
	if ( Timer[LCD_TIMER].IsTriggered() )
	{
		// Screensaver timeout expired
		LCD.BacklightOff();
	}

	if ( Joystick.IsButtonPressed() )
	{
		// turn the backlight on
		LCD.BacklightOn();

		// TODO check Timer[LCD_TIMER] code
		if ( Timer[LCD_TIMER].Trigger == 0 )
		{
			Timer[LCD_TIMER].Start();
			return;
		}
		PrepMenuScreen();
		// get out of this function and display the menu
		return;
	}
#ifdef MAIN_2014
	if ( Joystick.IsUp() || Joystick.IsDown() )
#else
	if ( Joystick.IsUp() || Joystick.IsDown() || Joystick.IsRight() || Joystick.IsLeft() )
#endif // MAIN_2014
	{
		// Turn backlight on
		LCD.BacklightOn();
		Timer[LCD_TIMER].Start();
	}
}