I apologize, this is very basic, but I can’t seem to find a tutorial on the web.
If I want a Digi XBee3 to report the temperature of the chip every x seconds/minutes/hours, what command would I use for the timing? If I put it to sleep on a cycle, will it know to run the code when it wakes up? I’m starting with the basic AT command example:
import xbee
print(" ±------------------------------------+“)
print(” | XBee MicroPython AT Commands Sample |“)
print(” ±------------------------------------+
")
Read the module’s temperature.
temperature = xbee.atcmd(“TP”)
convert unsigned 16-bit value to signed temperature
if temperature > 0x7FFF:
temperature = temperature - 0x10000
print(“The XBee is %.1F C (%.1F F)” % (temperature, temperature * 9.0 / 5.0 + 32.0))
Thank you for your help!