Turn the MCU to sleep mode

Description

  Turn the MCU to sleep mode to save few mA power consumption.

Wake up the MCU: any new data received on serial port will wake up the MCU, but the first few bytes of data could be received incorret, so use few bytes of dummy data before real commands.

Usage:

Direct:

"DNMCU"

Arduino:

void mcuOff(void)
void cpuOff(void)

C:

void Digole_cpuOff(void)

Parameters:

none

Return:

none

Example (Arduino):

mydisp.mcuOff(0); //turn MCU to sleep
mydisp.write(0); //wake up the MCU
mydisp.write(0);

Example(direct)

serial.writeString("DNMCU"); //turn MCU to sleep
serial.write(0); //wake up the MCU
serial.write(0);

Changelog

Version Description
   

See Also