You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
ExternalWakeup: LowPowerMode parameter SLEEP_MODE should be used
Last parameter of attachInterruptWakeup(), aka "LowPowerMode",
should match lowpower state used (in this case LowPower.sleep())
Fixes#54
Signed-off-by: Alexandre Bourdiol <[email protected]>
Copy file name to clipboardExpand all lines: README.md
+4-3
Original file line number
Diff line number
Diff line change
@@ -12,7 +12,7 @@ Arduino library to support STM32 Low Power.
12
12
**param** ms (optional): number of milliseconds before to exit the mode. The RTC is used in alarm mode to wakeup the chip in ms milliseconds.
13
13
14
14
***`void sleep(uint32_t ms)`**: enter in sleep mode
15
-
**param** ms (optional): number of milliseconds before to exit the mode. he RTC is used in alarm mode to wakeup the chip in ms milliseconds.
15
+
**param** ms (optional): number of milliseconds before to exit the mode. The RTC is used in alarm mode to wakeup the chip in ms milliseconds.
16
16
17
17
***`void deepSleep(uint32_t ms)`**: enter in deepSleep mode
18
18
**param** ms (optional): number of milliseconds before to exit the mode. The RTC is used in alarm mode to wakeup the chip in ms milliseconds.
@@ -22,10 +22,11 @@ Arduino library to support STM32 Low Power.
22
22
23
23
**Note: With [STM32RTC](https://github.com/stm32duino/STM32RTC) version lower than 1.1.0, the minimum number of milliseconds is 1000 ms.**
24
24
25
-
***`void attachInterruptWakeup(uint32_t pin, voidFuncPtrVoid callback, uint32_t mode)`**: Enable GPIO pin in interrupt mode. If the pin is a wakeup pin, it is configured as wakeup source (see board documentation).
25
+
***`void attachInterruptWakeup(uint32_t pin, voidFuncPtrVoid callback, uint32_t mode, LP_Mode LowPowerMode)`**: Enable GPIO pin in interrupt mode. If the pin is a wakeup pin, it is configured as wakeup source (see board documentation).
26
26
**param** pin: pin number
27
27
**param** callback: pointer to callback
28
-
**param** mode: interrupt mode (HIGH, LOW, RISING, FALLING or CHANGE)
28
+
**param** mode: interrupt mode (HIGH, LOW, RISING, FALLING or CHANGE)
29
+
**param** LowPowerMode: Low power mode which will be used (IDLE_MODE, SLEEP_MODE, DEEP_SLEEP_MODE or SHUTDOWN_MODE). In case of SHUTDOWN_MODE only, Wakeup pin capability is activated.
29
30
30
31
***`void enableWakeupFrom(HardwareSerial *serial, voidFuncPtrVoid callback)`**: enable a UART peripheral in low power mode. See board documentation for low power mode compatibility.
0 commit comments