Filip Jagodzinski
7ab0a35fdf
Test: WatchdogManager: Remove tests
...
This component no longer exists in Mbed OS.
2019-07-02 12:46:23 +01:00
Filip Jagodzinski
a810ef807f
Watchdog: Fix timeout constraints
...
Update the start method to check 0 < timeout <= max_timeout.
2019-07-02 12:46:23 +01:00
Filip Jagodzinski
a5ad5e04ca
Test: Watchdog: Add new driver tests
2019-07-02 12:46:23 +01:00
Filip Jagodzinski
cc7a3dd677
Fix more unittest errors
2019-07-02 12:46:23 +01:00
Martin Kojtal
ff0652830a
Watchdog: fix space in code example
2019-07-02 12:46:23 +01:00
Filip Jagodzinski
1c12f9b2b0
Fix unittest errors
2019-07-02 12:46:23 +01:00
Martin Kojtal
188655f929
Watchdog: example code - add kick()
2019-07-02 12:46:23 +01:00
Martin Kojtal
6b26b23d7b
virtualWatchdog: fix alignment for tickers and one space
2019-07-02 12:46:23 +01:00
Martin Kojtal
72582b0622
virtualWatchdog: fix alignment for tickers
2019-07-02 12:46:23 +01:00
Martin Kojtal
2c6357b098
VirtualWatchdog: fix missing kick and init check in process
...
Also syntax error for ticker definitions.
2019-07-02 12:46:23 +01:00
Martin Kojtal
529f4a2a7e
unittest: add virtualwatchdog stub
2019-07-02 12:46:23 +01:00
Martin Kojtal
33f8b35917
watchdog unittest: fix naming after refactor
2019-07-02 12:46:23 +01:00
Martin Kojtal
8231efc41c
unittest: remove platform watchdog (moved to drivers)
2019-07-02 12:46:23 +01:00
Martin Kojtal
4549a22566
unittest: move watchdog files to drivers
...
Test VirtualWatchdog and Watchdog
2019-07-02 12:46:23 +01:00
Martin Kojtal
8bbba26842
unittest: rename watchdog to VirtualWatchdog
2019-07-02 12:46:23 +01:00
Martin Kojtal
2d77fccb09
Watchdog: update unittests
2019-07-02 12:46:23 +01:00
Martin Kojtal
bb473d916e
Watchdog: keep it simple - providing simple driver functionality
...
No callbacks or tickers. User is handling kick() method directly based on timeout set.
VirtualWatchdog manages ticker and callback.
2019-07-02 12:46:23 +01:00
Martin Kojtal
28398e6254
Watchdog: fix include paths - use module name
2019-07-02 12:46:23 +01:00
Martin Kojtal
a63a54680c
VirtualWatchdog: fix default timeout value (1ms is unreal)
2019-07-02 12:46:23 +01:00
Martin Kojtal
88a9548167
VirtualWatchdog: fix name for member timeout
2019-07-02 12:46:23 +01:00
Martin Kojtal
a18ba70c1b
VirtualWatchdog: fix is hw init definition
2019-07-02 12:46:23 +01:00
Martin Kojtal
61f859b514
VirtualWatchdog: add config option to ctor to clarify the hw timeout
2019-07-02 12:46:23 +01:00
Martin Kojtal
9f48f26876
Watchdog: fix timeout - use full range for watchdog
2019-07-02 12:46:23 +01:00
Martin Kojtal
b822c09b3b
Watchdog: fix callback - uses ms
2019-07-02 12:46:23 +01:00
Martin Kojtal
0519caebe1
VirtualWatchdog: fix doxygen docs errors
2019-07-02 12:46:23 +01:00
Martin Kojtal
581bf208ad
Watchdog: refactor timeout handling
...
Enable kicking directly by kick() and handle timeout by using private handler.
2019-07-02 12:46:23 +01:00
Martin Kojtal
0aa095b944
Watchdog: add missing docs doxygen
2019-07-02 12:46:23 +01:00
Martin Kojtal
f7ccd06685
Watchdog: remove dead reference file
2019-07-02 12:46:23 +01:00
Martin Kojtal
400a7e4b77
error: add watchdog driver error
2019-07-02 12:46:23 +01:00
Martin Kojtal
1c0f1880eb
VirtualWatchdog: fix error code and timeout
2019-07-02 12:46:23 +01:00
Martin Kojtal
02936376ae
Watchdog: fix const static
...
Fixing error "non-static data member initializers only available with -std=c++11 or -std=gnu++11"
2019-07-02 12:46:23 +01:00
Filip Jagodzinski
455015daf5
Watchdog & VirtualWatchdog process() update
...
Add uint32 argument - pass how much time already passed to the callback.
2019-07-02 12:46:23 +01:00
Martin Kojtal
701d8f7cef
VirtualWatchdog: make sure we are the only owner of watchdog
...
If virtual one is not the only owner we error - init error code in driver.
2019-07-02 12:46:23 +01:00
Martin Kojtal
a3599414e1
Watchdog: clean-up start
2019-07-02 12:46:23 +01:00
Martin Kojtal
b166acd1cb
watchdog: fix astyle errors
2019-07-02 12:46:23 +01:00
Martin Kojtal
f98c2fdbba
watchdog: remove manager
...
Watchdog can handle callbacks - VirtualManager can attach to the tick. This should simplify the logic.
Watchdog can tick on its own using tickers.
VirtualWatchdog uses attach to get a callback when Watchdog ticks - to process own
linked list of virtual watchdogs.
2019-07-02 12:46:23 +01:00
Martin Kojtal
698b0eda8a
watchdog: add WatchdogManager
...
Watchdog should be usable on it's own - kicking it via ticker. No Virtual involved.
VirtualWatchdog as well - services should use this one to have multiple one in the system.
There's WatchdogManager - basically internal class to manage ticker for Watchdog.
2019-07-02 12:46:23 +01:00
Martin Kojtal
a668454de4
Watchdog: fix dtor
2019-07-02 12:46:23 +01:00
Martin Kojtal
bb1cc32a25
Watchdog: kick method should not have any external dep
2019-07-02 12:46:23 +01:00
Martin Kojtal
91679d40d5
Watchdog: cleanup after singleton usage
2019-07-02 12:46:23 +01:00
Martin Kojtal
d9e12e4168
VirtualWatchdog: fix protection macro
2019-07-02 12:46:23 +01:00
Martin Kojtal
7da2c6dbb6
Watchdog: use get_instance to access watchdog hw
2019-07-02 12:46:23 +01:00
Martin Kojtal
962a3d3c4c
mbed: add Watchdog and VirtualWatchdog
2019-07-02 12:46:23 +01:00
Martin Kojtal
737335c357
Remove watchdog manager
...
Use VirtualWatchdog instead
2019-07-02 12:46:23 +01:00
Martin Kojtal
edd857ea9c
VirtualWatchdog: software watchdog
...
Refactor old Watchdog (it was not a driver) to become VirtualWatchdog.
This is software virtual watchdog. This it the primary used watchdog in user application.
VirtualWatchdog: has-a watchdog. Initializes hw watchdog - start it when first used, stops it when there is no more VirtualWatchdog in the system -
list is empty.
Adding also check to watchdog to make sure there is only one in the system - runtime error if multiple objects created to already
running hw watchdog.
2019-07-02 12:46:23 +01:00
Martin Kojtal
7b0915c7d4
Watchdog: refactor driver
...
Watchdog is hardware driver. It interacts with HAL - provides wrapper to interact with the peripheral.
Provides basic functionality: start/stop, get timeout/max timeout.
It is automatically kicked by a timer, according to the timeout set in ctor.
2019-07-02 12:46:23 +01:00
Martin Kojtal
8b49ffc0c3
Merge pull request #10920 from NXPmicro/Update_Kinetis_SDK_Clock_Driver
...
Kinetis MCUXpresso: Update the clock drivers
2019-07-02 12:44:09 +01:00
Martin Kojtal
dea8268689
Merge pull request #10928 from kjbracey-arm/us_ticker_optimise
...
STM: Correct macro test in us_ticker_defines.h
2019-07-02 12:40:56 +01:00
Martin Kojtal
23037b9d6b
Merge pull request #10921 from jeromecoutant/PR_STMOD
...
STMOD_CELLULAR: readme file additional information
2019-07-02 12:40:32 +01:00
Antti Kauppila
369e2d53ff
Fixed unittests
2019-07-02 10:17:06 +03:00