Share your knowledge at the LQ Wiki.
Go Back > Forums > Non-*NIX Forums > Programming
User Name
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.


  Search this Thread
Old 06-01-2010, 07:50 AM   #1
LQ Newbie
Registered: Nov 2008
Location: Milan
Distribution: Lucid Lynx
Posts: 2

Rep: Reputation: 0
How to transmit a file by source-code to USB drive

Hi guys,

I want to find a simple and quick way to permit my application to bring a file located in my file system and write it into an external USB device. I have to use Bulk Transfer Only mode that means to use stream of characters only. I looked through the LibUsb library using it in my IDE I can transmit a string.

To transfer a whole file I suppose I've to dodge the file system building a char sequence that permits to recognise a file in the file system and to put it into the usb device.

Suggestions? Cheers..

Note I'm working with Ubuntu 10.04
Old 06-02-2010, 06:00 AM   #2
LQ Newbie
Registered: Nov 2008
Location: Milan
Distribution: Lucid Lynx
Posts: 2

Original Poster
Rep: Reputation: 0

It works with system("/bin/cp -p /tmp/footbar /mnt/footbar")


driver, filesystem, linux, usb

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Need USB 2.0 Pendrive device driver source code sanket1512 Linux - Kernel 3 03-05-2010 12:06 AM
[SOLVED] make use of gcc source code to parse c++ source file famsinyi Programming 14 10-19-2009 06:47 PM
source code file 'Not a local file' error with anjuta 2.4.2 PrathuD Linux - Newbie 2 10-24-2008 10:36 AM
Source code file transfer shiv84_verma Linux - Networking 3 09-01-2006 03:14 PM
source code for file(1) dombrowsky Linux - Software 2 02-11-2006 02:38 PM

All times are GMT -5. The time now is 08:58 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration