Merge branch 'bugfix/twai_utils_down' into 'master'

fix(twai): fix the twai_utils's pytest to turn canbus down

Closes IDFCI-3079

See merge request espressif/esp-idf!41238
This commit is contained in:
Yuan Yu
2025-08-14 14:48:04 +08:00

View File

@@ -421,6 +421,7 @@ class CanBusManager:
if self.bus:
try:
self.bus.shutdown()
subprocess.run(['sudo', '-n', 'ip', 'link', 'set', self.interface, 'down'], check=True)
except Exception:
pass