samples: task_wdt: add scenario without hw fallback
Add new sample scenario without using a hardware watchdog as fallback. This is used for the moment only for the mr_canhubk3 board, but a generic configuration is introduced that can be used by other boards if needed. Signed-off-by: Manuel Argüelles <manuel.arguelles@nxp.com>
This commit is contained in:
parent
cb54a31b28
commit
42e8678d2a
3 changed files with 45 additions and 17 deletions
15
samples/subsys/task_wdt/boards/mr_canhubk3.overlay
Normal file
15
samples/subsys/task_wdt/boards/mr_canhubk3.overlay
Normal file
|
@ -0,0 +1,15 @@
|
|||
/*
|
||||
* Copyright 2023 NXP
|
||||
*
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
/*
|
||||
* FS26 watchdog cannot be used as hardware watchdog fallback on this SoC, since
|
||||
* the SPI driver being used to communicate with the device, cannot transceive
|
||||
* from interrupt context. In order to run this sample, FS26 must be started in
|
||||
* DEBUG mode (see board documentation).
|
||||
*/
|
||||
&fs26_wdt {
|
||||
status = "disabled";
|
||||
};
|
8
samples/subsys/task_wdt/prj_no_hw_fallback.conf
Normal file
8
samples/subsys/task_wdt/prj_no_hw_fallback.conf
Normal file
|
@ -0,0 +1,8 @@
|
|||
CONFIG_LOG=y
|
||||
CONFIG_LOG_MODE_IMMEDIATE=y
|
||||
|
||||
CONFIG_WATCHDOG=n
|
||||
|
||||
CONFIG_TASK_WDT=y
|
||||
|
||||
CONFIG_THREAD_NAME=y
|
|
@ -1,23 +1,28 @@
|
|||
sample:
|
||||
name: Task Watchdog Subsytem Sample
|
||||
common:
|
||||
tags: subsys
|
||||
harness: console
|
||||
harness_config:
|
||||
type: multi_line
|
||||
ordered: true
|
||||
regex:
|
||||
- "Task watchdog sample application."
|
||||
- "Control thread started."
|
||||
- "Main thread still alive..."
|
||||
- "Control thread getting stuck..."
|
||||
- "Task watchdog channel 1 callback, thread: control"
|
||||
- "Resetting device...(.*)"
|
||||
- "Task watchdog sample application."
|
||||
depends_on: watchdog
|
||||
platform_exclude:
|
||||
- s32z270dc2_rtu0_r52
|
||||
- s32z270dc2_rtu1_r52
|
||||
tests:
|
||||
sample.subsys.task_wdt:
|
||||
tags: subsys
|
||||
harness: console
|
||||
harness_config:
|
||||
type: multi_line
|
||||
ordered: true
|
||||
regex:
|
||||
- "Task watchdog sample application."
|
||||
- "Control thread started."
|
||||
- "Main thread still alive..."
|
||||
- "Control thread getting stuck..."
|
||||
- "Task watchdog channel 1 callback, thread: control"
|
||||
- "Resetting device...(.*)"
|
||||
- "Task watchdog sample application."
|
||||
depends_on: watchdog
|
||||
integration_platforms:
|
||||
- nucleo_g474re
|
||||
platform_exclude:
|
||||
- s32z270dc2_rtu0_r52
|
||||
- s32z270dc2_rtu1_r52
|
||||
sample.subsys.task_wdt.no_hw_fallback:
|
||||
extra_args: CONF_FILE="prj_no_hw_fallback.conf"
|
||||
platform_allow:
|
||||
- mr_canhubk3
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue