Monday, February 19th 2018, 2:54am UTC+1

You are not logged in.

  • Login
  • Register

Venkat_15

Beginner

Date of registration: Jul 17th 2012

Posts: 47

1

Wednesday, July 10th 2013, 11:43am

Controlling backlight on touch

How to control LCD backlight on and off on touch.I observed, on touching the screen in screensaver mode it wakes up the system but also executes the GUI widgets.
On touch,backlight should on but should not execute widgets in GUI.

Date of registration: May 26th 2009

Posts: 1,022

2

Wednesday, July 10th 2013, 4:52pm

Hello,

The touch input needs to be stored in the emWin PID buffer,
so it can be processed automatically by the Window Manager. I
would recommend not to store touch events in the PID buffer as
long as the backlight of the display is off.


Best regards,
Adrian

Venkat_15

Beginner

Date of registration: Jul 17th 2012

Posts: 47

3

Tuesday, July 16th 2013, 12:30pm

Backlight control

I am working on single layer ,layer 0.
When user touches the LCD when back light is off that time i am making pState->Pressed = 0.
Then also it receive touch (Notify parent is get called).
Do you any sample example for making controling backlight.

case WM_TOUCH:
case WM_TOUCH_CHILD:

//on touch backlight will be on //
if( backLight == 0 )
{
deviceAction.Device.Type = CLASS_LOGICAL_OUTPUT;
deviceAction.Device.Address = DEVICE_BACKLIGHT;
deviceAction.ActionId = TurnUp;
BacklightConfig.ClassId = CONFIG_IO; /* Some necessary initialisations for the structure*/
BacklightConfig.ConfigId = CONFIG_ID_IO_CHANGE_OUTPUT_STATE;
BacklightConfig.configStruct = &deviceAction;
SendReceiveDataService(BacklightConfig);
backLight = 1; /* backlight off is reset*/
/* used to restart */
pState = (GUI_PID_STATE *)pMsg->Data.p;
pState->Pressed = 0;
//return;
}
else
{
backLight = 1; /* backlight off is reset*/
}

Date of registration: May 26th 2009

Posts: 1,022

4

Wednesday, July 17th 2013, 9:14am

Hello,

emWin does not control the backlight. This has to be done by your application.

Best regards,
Adrian