Table of Contents

USB Watchdog

Tags: Adapter Auto Restarter USB WatchDog do koparki BTC

Communication protocol

[238947.892900] usb 1-3.4: Product: USB2.0-Serial
[238947.899333] ch341 1-3.4:1.0: ch341-uart converter detected
[238947.906552] usb 1-3.4: ch341-uart converter now attached to ttyUSB0

Serial port parameters: 9600 8N1

stty -F /dev/ttyUSB0 raw speed 9600

Each command is 1 byte value. It set watchdog threshold in deciseconds. Example commands: Commands sent to watchdog (1 byte):

REMARK: Avoid low threshold. It is stored internally in watchdog, so after reset it is still low. In this case it is not possible to boot OS.

Default (after powerup) watchdog window is 170 sec (measured).

Daemon

https://github.com/niziak/usb-watchdog