473,386 Members | 1,786 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Linux USB programming in C

I'm working on a c project in Linux. This project contains two components, one transmitter and one receiver each one should be executed on a different PC. Hence, two PCs should be communicated. To do so, USB port have to be used. Hence, my question is how to use USB programming in Linux to send data from one PC and receive data in another one and vice versa. I read some examples about libusb and checked them. currently, I used my flash disk as a USB device and I tried to open it and send some bytes (in bulk mode). However, I think I should buy a USB data cable (bridge cable?) first to connect both PCs. Then, I should set configurations of both USB ports as desired (in both PCs, is it possible or I cannot to re-set them?) and after that I can use usblib functions to send and receive data. Am I right or I missed something? I tried to set my flash configuration previously and I encountered a problem, i.e., device is busy and so on. Please help. I appreciate your time and effort.

Mehdi
May 11 '10 #1
1 4051
newb16
687 512MB
Start with googling for 'pc as a slave usb' . Not every USB controller can serve as an USB slave, and it may require a special cable with electronics to connect them.
May 11 '10 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

383
by: John Bailo | last post by:
The war of the OSes was won a long time ago. Unix has always been, and will continue to be, the Server OS in the form of Linux. Microsoft struggled mightily to win that battle -- creating a...
2
by: Bo Huge | last post by:
Hey! I am making a server and a client like FTP, but my own design. want users to be able to login with usernames and pwords, which I have stored in a file. My problem is, that i can't read from...
4
by: Joćo Pires | last post by:
I have a program write in VB and I need to convert the code to C for Linux. Well, I began to do that but I have some problems ... - How can I write te code in C to comunicate with the serial...
26
by: Kanthi Kiran Narisetti | last post by:
Hi ALL, I am new to C and programming . I need suggestions for the IDE to be used as a begginer and should I start on Windows or Linux ?? I am also looking for resources for C programming on...
0
by: ruschein | last post by:
Hi, We're looking for an experienced C++ programmer for the Linux platform. Machine learning experience especially in the area of text processing/classification is considered a big plus. ...
10
by: stylecomputers | last post by:
Hey guys, I am absolutely new to Linux programming, with no w######s programming experience except a small amount of C++ console apps. Reasonably new to Linux, BSD etc, got good sound networking...
12
by: Magesh | last post by:
Can anyone suggest me a good book to learn C/C++ programming under Linux platform?
17
by: =?iso-8859-1?q?Tom=E1s_=D3_h=C9ilidhe?= | last post by:
I'm kind of new to Linux and I've started downloading applications and installing them. Applications are distributed as source code in a ".tar.gz" file. You unzip the file, navigate to the...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.