All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Pages
find_port.c

Find Serial ports

Author
Satofumi KAMIMURA

$Id$

#include <stdio.h>
int main(void)
{
int found_port_size = urg_serial_find_port();
int i;
if (found_port_size == 0) {
printf("could not found ports.\n");
return 1;
}
for (i = 0; i < found_port_size; ++i) {
printf("%s", urg_serial_port_name(i));
printf(" [URG]");
}
printf("\n");
}
return 0;
}