ADLINK MXE-5300 Series User Manual

Page 80

Advertising
background image

70

WDT Function Reference

MXE-5300

SetWDT

Description

Set the timeout value of watchdog timer. There are two param-
eters for this function to indicate the timeout ticks and unit.
Users should call ResetWDT or StopWDT before the expiration
of watchdog timer, or the system will be reset.

Supported controllers

MXE-5300

Syntax

C/C++

BOOL SetWDT(BYTE tick, BYTE unit)

Parameters

tick

Specify the number of tick for watchdog timer. A valid value
is 1 - 255.

unit

Specify the timeout ticks of the watchdog timer.

Return codes

TRUE

if timeout value of watchdog timer is successfully set.

FALSE

if timeout value of watchdog timer is failed to set.

Value

Description

0

The unit of tick is second. For example, when you specify tick
as 100 and unit as 0, the timeout value is 100 seconds.

1

The unit of tick is minute. For example, when you specify tick
as 100 and unit as 1, the timeout value is 100 minutes.

Advertising