Note that Strato Pi CM will reset the Raspberry Pi Compute Module even if GPIO18 is not
set high. In this case the power cycles occurs 120 seconds after the heartbeat timeout.
The Strato Pi utility can be used to control the watchdog from your own application.
Enable the watchdog:
$
sudo strato watchdog enable
Disable the watchdog:
$
sudo strato watchdog disable
Send the heartbeat:
$
sudo strato watchdog heartbeat
Print “1” if the watchdog timeout is expired, “0” if not:
$
sudo strato watchdog timeout; echo $?
Reset cycle
You can start a delayed reset cycle by rising Raspberry Pi’s GPIO18 pin.
When GPIO18 is set to high, Strato Pi CM will wait 60 seconds and then reset the
Raspberry Pi Compute Module.
To initiate a delayed reset cycle:
$
sudo strato reset
Advanced configuration
The Strato Pi CM logic controller can be configured from the Raspberry Pi to change the
default behavior and timing of the hardware watchdog and reset features. The RX/TX
switching mode (TX-Enable control) of the RS-485 serial port is also configurable.
These configuration parameters can be accessed using the Strato Pi kernel module or
implementing the underlying ASCII-based serial protocol described in the "Strato Pi Logic
Controller Advanced Configuration Guide" document.
23
Strato Pi CM User Guide