RSB-4411 User Manual
58
count=0;
}
sleep(sleep_sec);
count+=sleep_sec;
}
return
0;
}
void
help_info(void)
{
printf("Usage:
wdt_driver_test
<timeout>
<sleep>
<trigger>\n");
printf("
timeout:
value
in
seconds
to
cause
wdt
timeout/reset\n");
printf("
sleep:
value
in
seconds
to
display
wdt
timeout\n");
printf("
trigger:
value
in
seconds
to
ping
the
wdt\n");
}
If you would like to change the WDT time, please modify:
ioctl(fd,
WDIOC_SETTIMEOUT,
&timeout).
3.7.3
GPIO Setting
Please see GPIO initial code listed below. Below code is to assign the starting value
to GPIO variable.
/*
Enable
GPIO
*/
gpio_request(SABRESD_GPIO0,
"gpio
‐
0");
gpio_request(SABRESD_GPIO1,
"gpio
‐
1");
gpio_request(SABRESD_GPIO2,
"gpio
‐
2");
gpio_request(SABRESD_GPIO3,
"gpio
‐
3");
gpio_request(SABRESD_GPIO4,
"gpio
‐
4");
gpio_request(SABRESD_GPIO5,
"gpio
‐
5");
gpio_request(SABRESD_GPIO6,
"gpio
‐
6");
gpio_request(SABRESD_GPIO7,
"gpio
‐
7");
3.7.4
RS232 Initial Code
The RS232 initial code as below. It shows you how to initial COM ports.
int
open_port(void)
{
int
fd;
fd=open("/dev/ttymxc1",O_RDWR|O_NOCTTY|O_NDELAY);
if(fd
==
‐
1){
perror("open
error");
}
return(fd);
}
Summary of Contents for RSB-4411
Page 2: ...User Manual RSB 4411 3 5 SBC with NXP i MX6 Processor ARM Cortex A9 Architecture ...
Page 11: ...RSB 4411 User Manual x ...
Page 12: ...Chapter 1 1 General Introduction ...
Page 15: ...RSB 4411 User Manual 4 ...
Page 16: ...Chapter 2 2 H W Installation ...
Page 33: ...RSB 4411 User Manual 22 Figure 2 25 M 2 Connector ...
Page 37: ...RSB 4411 User Manual 26 ...
Page 82: ...71 RSB 4411 User Manual Chapter 5 Advantech Services ...