XBee 3 watchdog

Discussion about programs, libraries and tools that work with MicroPython. Mostly these are provided by a third party.
Target audience: All users and developers of MicroPython.
Post Reply
Glenn
Posts: 2
Joined: Thu Feb 25, 2021 9:48 pm

XBee 3 watchdog

Post by Glenn » Thu Feb 25, 2021 9:58 pm

I would like to use the watchdog timer for my project. The only info I found contains a conflict.

Code: Select all

from machine import WDT
wdt = WDT(timeout=2000)  # enable it with a timeout of 2s
wdt.feed()
This implies the time out is in milliseconds. The text below it says;

classmachine.WDT(id=0, timeout=5000)
Create a WDT object and start it. The timeout must be given in seconds and the minimum value that is accepted is 1 second. Once it is running the timeout cannot be changed and the WDT cannot be stopped either.

Implying that the units are seconds. So only off by about 3 orders of magnitude.

Does anyone know which is correct?

User avatar
jimmo
Posts: 2754
Joined: Tue Aug 08, 2017 1:57 am
Location: Sydney, Australia
Contact:

Re: XBee 3 watchdog

Post by jimmo » Thu Feb 25, 2021 11:46 pm

Glenn wrote:
Thu Feb 25, 2021 9:58 pm
Does anyone know which is correct?
This was corrected since the version of the documentation that the XBee docs link to.

See http://docs.micropython.org/en/latest/l ... e.WDT.html

I would suspect that XBee copied the implementation from the WiPy, which definitely uses milliseconds.

Unfortunately very little is known about the XBee MicroPython port, they have provided no source code or information other than the "Programming Guide" PDF.

Glenn
Posts: 2
Joined: Thu Feb 25, 2021 9:48 pm

Re: XBee 3 watchdog

Post by Glenn » Thu Feb 25, 2021 11:53 pm

Thanks.

I guess I'll find out by trial and error.
The Digi docs on XBee 3 are definitely wanting when it comes to details.

Post Reply