Skip to content

Watchdog API update #10645

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions TESTS/mbed_drivers/reset_reason/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
#include "mbed.h"

#if DEVICE_WATCHDOG
#include "drivers/Watchdog.h"
#include "hal/watchdog_api.h"

#define MSG_VALUE_WATCHDOG_STATUS "wdg_present"
#define WDG_TIMEOUT_MS 50UL
Expand Down Expand Up @@ -101,9 +101,9 @@ static cmd_status_t handle_command(const char *key, const char *value)
if (strcmp(key, MSG_KEY_DEVICE_RESET) == 0 && strcmp(value, MSG_VALUE_DEVICE_RESET_WATCHDOG) == 0) {
greentea_send_kv(MSG_KEY_DEVICE_RESET, MSG_VALUE_DEVICE_RESET_ACK);
wait_ms(10); // Wait for the serial buffers to flush.
Watchdog watchdog;
if (watchdog.start(WDG_TIMEOUT_MS) != WATCHDOG_STATUS_OK) {
TEST_ASSERT_MESSAGE(0, "watchdog.start() error.");
watchdog_config_t config = { .timeout_ms = WDG_TIMEOUT_MS };
if (hal_watchdog_init(&config) != WATCHDOG_STATUS_OK) {
TEST_ASSERT_MESSAGE(0, "hal_watchdog_init() error.");
return CMD_STATUS_ERROR;
}
wait_ms(WDG_TIMEOUT_MS + WDG_TIMEOUT_DELTA_MS);
Expand Down
114 changes: 0 additions & 114 deletions TESTS/mbed_drivers/watchdog/Watchdog_tests.h

This file was deleted.

227 changes: 0 additions & 227 deletions TESTS/mbed_drivers/watchdog/main.cpp

This file was deleted.

Loading