LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
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.

Notices


Reply
  Search this Thread
Old 06-12-2007, 05:08 AM   #1
amit_pansuria
Member
 
Registered: Sep 2006
Posts: 73

Rep: Reputation: 15
how to transfer and receive file using serial port from my application


helo i m using fedoara 6 .
i want to transmit and receive the file using serial port programatically
plz tell me is there any sample program available for tranfering and receiving the file
regards,
Amit
 
Old 06-12-2007, 05:53 AM   #2
nc3b
Member
 
Registered: Aug 2005
Posts: 330

Rep: Reputation: 32
Maybe minicom? I am not sure
 
Old 06-12-2007, 10:37 AM   #3
theNbomr
LQ 5k Club
 
Registered: Aug 2005
Distribution: OpenSuse, Fedora, Redhat, Debian
Posts: 5,398
Blog Entries: 2

Rep: Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908
Minicom, C-Kermit and Seyon are the three most common serial interface applications for Linux. All are open-source. Does your program need to communicate with an existing remote host? If so, you need to know about the nature of that remote host's file transfer capabilities. Using straight serial protocols, the four most common file transfer protocols are Kermit, Xmodem, Ymodem, and Zmodem. There may be others.
--- rod.
 
Old 06-12-2007, 05:39 PM   #4
xhi
Senior Member
 
Registered: Mar 2005
Location: USA::Pennsylvania
Distribution: Slackware
Posts: 1,065

Rep: Reputation: 45
the java communications API (also known as javax.comm) may be something to look at
 
Old 06-14-2007, 03:07 PM   #5
schneidz
LQ Guru
 
Registered: May 2005
Location: boston, usa
Distribution: fc-15/ fc-20-live-usb/ aix
Posts: 5,235

Rep: Reputation: 914Reputation: 914Reputation: 914Reputation: 914Reputation: 914Reputation: 914Reputation: 914Reputation: 914
i never tried this, but would 'cat $file > /dev/ttys0' then 'cat /dev/ttys0 > $file' on the receiver work ?
 
Old 06-14-2007, 06:27 PM   #6
theNbomr
LQ 5k Club
 
Registered: Aug 2005
Distribution: OpenSuse, Fedora, Redhat, Debian
Posts: 5,398
Blog Entries: 2

Rep: Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908
It should, as long as you have sufficient privilege on the device, and as long as the transmission parameters (bit rate, parity, stop bits, handshake, etc) and 'processing' of the stream have be properly configured a priori. The receiving situation may have problems determining EOF, since the device is a character device, and just sees the channel as a conduit through which to ship bytes.
--- rod.
 
  


Reply


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
Source code for file transfer over serial port. nethunter Linux - Networking 2 09-01-2006 03:35 PM
File transfer over parallel port. nethunter Linux - Networking 1 03-18-2006 02:46 PM
file transfer over serial port. nethunter Linux - Networking 2 02-26-2006 07:54 AM
Serial port transfer tklima Programming 1 01-12-2005 03:13 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 10:29 AM.

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