LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
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 07-16-2012, 01:11 PM   #1
abd_bela
Member
 
Registered: Dec 2002
Location: algeria
Distribution: redhat 7.3, debian lenny
Posts: 627

Rep: Reputation: 31
a small C program to read from serial port


Hi,
I haven't solved my problem !! sorry I just need a small program which write a character ( or several) then read it from that serial port.
I used a null modem ( since I have just on serial port device).

I want a simple serial connection. I consulted Howto on tdlp and other ?? Now I can write on the port but not read !!


Thanks a lot
regards
 
Old 07-17-2012, 05:52 AM   #2
NevemTeve
Senior Member
 
Registered: Oct 2011
Location: Budapest
Distribution: Debian/GNU/Linux, AIX
Posts: 4,856
Blog Entries: 1

Rep: Reputation: 1869Reputation: 1869Reputation: 1869Reputation: 1869Reputation: 1869Reputation: 1869Reputation: 1869Reputation: 1869Reputation: 1869Reputation: 1869Reputation: 1869
What error message you got when tried read(2)? Did you use termios(3)?
 
  


Reply



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
how to read from serial port abd_bela Programming 5 04-29-2012 05:16 PM
read serial port problem kievari Linux - Newbie 1 03-02-2010 08:31 AM
When to read from the serial port? kad_79 Programming 3 06-15-2006 02:39 PM
Serial port Read Write SeanatIL Programming 2 07-14-2004 03:42 PM
how to create ppp server in RH 7.2 as small ISP thro serial port pentium5 Linux - General 5 07-06-2002 06:35 AM

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

All times are GMT -5. The time now is 05:11 PM.

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
Open Source Consulting | Domain Registration