#include #include #include #include #include #include int main(int argc, char *argv[]) { int fd; struct usbdevfs_ioctl command; if (argc != 2) exit(1); fd=open(argv[1],O_RDWR); if (fd < 0) { perror(argv[1]); exit(1); } command.ifno = 0; command.ioctl_code = USBDEVFS_CONNECT; command.data = NULL; if (ioctl(fd, USBDEVFS_IOCTL, &command)) perror("ioctl"); close(fd); return 0; }