Moxa Technologies UC-7420/7410 Input Int fd File handle from swtdopen return value Output

Models: UC-7420/7410

1 106
Download 106 pages 2.64 Kb
Page 82
Image 82

UC-7420/7410 User’s Manual

Programmer’s Guide

int swtd_disable(int fd)

Description:

Disable the application to ack sWatchDog. And the kernel will be auto ack it. User does not to do it at periodic.

Input :

 

int fd

- the file handle from swtd_open() return value.

Output:

 

OK will be zero. The other has some error, to get error code from errno.

int swtd_get(int fd, int *mode, unsigned long *time)

Description:

Get current setting values. mode –

1 for user application enable sWatchDog: need to do ack.

0 for user application disable sWatchdog: does not need to do ack. time – The time period to ack sWatchDog.

Input :

 

int fd

- the file handle from swtd_open() return value.

int *mode

- the function will be return the status enable or disable user application

need to do ack.

unsigned long *time – the function will return the current time period.

Output:

OK will be zero.

The other has some error, to get error code from errno().

int swtd_ack(int fd)

Description:

Acknowledge sWatchDog. When the user application enable sWatchDog. It need to call this function periodically with user predefined time in the application program.

Input :

 

int fd

- the file handle from swtd_open() return value.

Output:

 

OK will be zero.

The other has some error, to get error code from errno().

5-6

Page 82
Image 82
Moxa Technologies UC-7420/7410 user manual Input Int fd File handle from swtdopen return value Output