Table of Contents
quanser.hardware.hil.watchdog_start
Starts the watchdog timer.
err = board.watchdog_start(timeout)
Starts the watchdog timer, programming it with the given timeout interval. If the watchdog is allowed to expire, then it will set the board's outputs to the expiration states specified by the watchdog_set_expiration_xxxx_state functions. Furthermore, it will disable the outputs of the board until the "watchdog state" is clear using the watchdog_clear function.
To prevent the watchdog timer from expiring, call the watchdog_reload function.
The watchdog timer must be stopped using the watchdog_stop function prior to closing the board.
If no err output is provided then it throws an exception if an error occurs. In generated code it prints the error message. Use hil_get_error_message to get the message associated with an error code.
board
The board instance returned by the quanser.hardware.hil.open function.
timeout
The timeout interval for the watchdog timer, in seconds. The range of timeouts supported depends on the board. Some boards have a very limited set of timeout intervals available.
Select a board type from the list for board-specific details: .
err
A negative error code or zero on success.
% Configures the watchdog to expire every 0.1 seconds and starts it running
board.watchdog_start(0.1);
See Also
Copyright ©2024 Quanser Inc. This page was generated 2024-10-17. Submit feedback to Quanser about this page.
Link to this page.