![](https://pdfstore-manualsonline.prod.a.ki/pdfasset/6/cd/6cdd8c80-ce60-48ad-81ee-c40b6d52dfda/6cdd8c80-ce60-48ad-81ee-c40b6d52dfda-bge4.png)
C-4 Power Management API
MX3-CE Reference Guide E-EQ-MX3CERG-A-ARC
Backlight Power On/Off
Backlight power is activated by directly toggling the GPIO pins. This has the limitation that the
system software does not know what the current state of the backlight is. In particular, if the
backlight is turned on in software, the power management driver still thinks it is off, and does not
control it.
See Also: WriteGPIO().
void WriteBacklight(int onoff)
{
DWORD val;
#define GPIO20 0x00100000L
if (onoff)
val = GPIO20;
else
val = 0;
WriteGPIO(val, GPIO20);
}
Forcing Computer Not To Go To Suspend
Software activity on the computer will not prevent the computer from going into suspend. You can
set the power management timers to zero and reboot, or you can periodically (off a timer event)
call the following Win32 API:
SystemIdleTimerReset();
Cold Boot
Cold boot is performed by making a KernelIOCtl call as follows:
DWORD rtn;
if (MessageBox(NULL, L"Are you REALLY REALLY sure?", L"Erasing
memory!",
MB_ICONWARNING|MB_YESNO|MB_DEFBUTTON2) == IDYES)
KernelIoControl(IOCTL_HAL_COLDBOOT, NULL, 0, NULL, 0,
&rtn);
Note that cold boot erases all RAM memory; any applications and data in RAM are erased, and
any registry changes from defaults will be destroyed.
Warm Boot
Warm boot is performed by making a KernelIOCtl call as follows:
DWORD rtn;
KernelIoControl(IOCTL_HAL_WARMBOOT, NULL, 0, NULL, 0, &rtn);
Note that warm boot preserves all RAM memory.