25.5.1.1 sleep
Set the sleep mode of the device and put the MCU to sleep.
int sleep(
const uint8_t mode
)
For an overview of which systems are disabled in sleep for the different sleep modes, see the data sheet.
Parameters
- mode
-
Type: const uint8_t
Sleep mode to use
Returns
Type: int
The status of a sleep request
- -1
-
The requested sleep mode was invalid or not available
- 0
-
The operation completed successfully, returned after leaving the sleep