Arduino-Pro-Mini-LoRa-Sensor-Node
Arduino-Pro-Mini-LoRa-Sensor-Node copied to clipboard
How is the sleep time defined and where is the wake up call
trafficstars
Hi,
I'm quite new at using interrupts with arduino hence i am having difficulties understanding your code.
Could you enlighten me on when in the powerdown functions the sleeping time is defined? I understand it's related to LORA_TX_INTERVAL and that the number of sleep cycles is compared. But I don't understand why there a division by 8 and where the arduino is waken up
thanks
The WDTCSR register is set to 8 seconds, therefore the micro controller wake up every 8 seconds to check if the sleep time from LORA_TX_INTERVAL has reached.