3 #include <lunaix/lunaix.h>
11 int fd = open("/dev/ttyS0", FO_WRONLY);
13 printf("ttyS0 not accessable (%d)\n", errno);
20 printf("ttyS0 input: ");
22 if ((sz = read(fd, buf, 31)) < 0) {
23 printf("write to ttyS0 failed (%d)\n", errno);
34 main(int argc, char* argv[])
40 char* target = argv[1];
42 if (!strcmp(target, "serial")) {
45 printf("unknown test: %s\n", target);