From 7f83930ebb280971bdf28f441d954e4116b65cae Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20J=C3=A4ger?= Date: Thu, 22 Oct 2026 00:04:23 +0200 Subject: [PATCH] tests: drivers: half_bridge_loopback: detect floating outputs Use pull-ups instead of pull-downs at the capture inputs, so that the tests fail if the outputs are not actively driven low while the half bridge is stopped. Co-Authored-By: Claude Opus 5.5 --- .../boards/nucleo_g474re.overlay | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/tests/drivers/half_bridge_loopback/boards/nucleo_g474re.overlay b/tests/drivers/half_bridge_loopback/boards/nucleo_g474re.overlay index d7625c7..0278b51 100644 --- a/tests/drivers/half_bridge_loopback/boards/nucleo_g474re.overlay +++ b/tests/drivers/half_bridge_loopback/boards/nucleo_g474re.overlay @@ -39,23 +39,26 @@ status = "disabled"; }; -/* pull-downs, as some half bridges leave their outputs floating if disabled */ +/* + * Pull-ups to detect outputs which are not actively driven low when switched off. The outputs + * must never be left floating, as the gate drivers would switch on the MOSFETs. + */ &tim2_ch1_pa0 { - bias-pull-down; + bias-pull-up; }; &tim2_ch2_pa1 { - bias-pull-down; + bias-pull-up; }; &tim2_ch3_pb10 { - bias-pull-down; + bias-pull-up; }; &tim5_ch1_pb2 { - bias-pull-down; + bias-pull-up; }; &tim5_ch2_pc12 { - bias-pull-down; + bias-pull-up; };