The previous setting of `1` meant that the bluetooth system couldn't be
used when the watchdog timer was enabled.
Signed-off-by: Sean Cross <sean@xobs.io>
As part of the reset process, save the current tick count to an
uninitialized memory location. That way, the current tick value will be
preserved across reboots.
A reboot will cause us to lose a certain number of ticks, depending on
how long a reboot takes, however if reboots are infrequent then this
will not be a large amount of time lost.
Signed-off-by: Sean Cross <sean@xobs.io>
For `microcontroller.reset()`, don't manually call NVIC_SystemReset().
Instead, call the `port_reset()` in case the port wants to do any
cleanup.
Signed-off-by: Sean Cross <sean@xobs.io>
This finishes the rework of the exception handler, which is once
again stored inside the watchdog timer module.
This also implements a `watchdog_reset()` that is used to disable the
RAISE watchdog, if one is enabled.
Signed-off-by: Sean Cross <sean@xobs.io>
Check to see if the current exception is a Watchdog exception, if it's
enabled. This ensures we break out of the current sleep() if a watchdog
timeout hits.
Signed-off-by: Sean Cross <sean@xobs.io>
This adds an exception to be raised when the WatchDogTimer times out.
Note that this currently causes a HardFault, and it's not clear why it's
not behaving properly.
Signed-off-by: Sean Cross <sean@xobs.io>
This enables WDT support for Simmel. Other platforms cannot yet use
WDT because it overflows their flash storage.
Enable CIRCUITPY_WDT support for the nrf target.
Signed-off-by: Sean Cross <sean@xobs.io>
With the WDT changes, building Circuit Python results in the following error:
/opt/gcc-arm-none-eabi-9-2019-q4-major/bin/../lib/gcc/arm-none-eabi/9.2.1/../../../../arm-none-eabi/bin/ld: section .ARM.exidx LMA [00000000000621c8,00000000000621cf] overlaps section .data LMA [00000000000621c8,0000000000062383]
This is because unwinding data is getting generated, but has nowhere to go.
Re-enable this data in the linker script so it is saved.
Signed-off-by: Sean Cross <sean@xobs.io>
Sommersoft noticed that without submodules (as RTD currently does),
the "make -qp" failed due to trying to find files within submodules.
The "print-VAR" target doesn't have any dependencies, so it sidesteps
the problem.
If we move ulab's pyi files into the submodule, though, we'll need to
fetch submodules anyway during doc building.
Revisiting this because I noticed the support matrix said that pyruler
had several modules it obviously didn't, such as the recently added
vectorio.
It is less error-prone because we can use the final values instead
of re-coding the Makefile logic in python. The only things we need
to do are invoke make in "print-database" mode, then chase any
indirect references like CIRCUITPY_VECTORIO = $(CIRCUITPY_DISPLAYIO)
It does take longer, about 45s on my laptop.