Solved

reading and writing to a serial port thru C or C++

Posted on 2003-12-06
2
21,838 Views
Last Modified: 2011-08-18
i'm currently trying to read and write a stream of either integers or chars into a device plugged in a serial port.
i know that linux has a device for it under /dev

i tried using the standard open() to open that device but it doesn't seem to be doing anything.
my question is, how do you communicate with a serial port?

any snippet will be of great help,

thanks in advance, i really appreciate any help
0
Comment
Question by:urif
2 Comments
 
LVL 44

Accepted Solution

by:
Karl Heinz Kremer earned 50 total points
Comment Utility
The best source of information is the "Serial Programming HOWTO" (e.g. at http://en.tldp.org/HOWTO/Serial-Programming-HOWTO/)

The serial port test program you can find at http://www.comptechdoc.org/os/linux/programming/c/linux_pgcserial.html demonstrates how to use the serial port.

0
 

Author Comment

by:urif
Comment Utility
great, thanks!
0

Featured Post

Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
script that sorts the lines in file according to integer in line 7 25
script 11 136
Problem to telnet 23 162
Identify Linux loader 67 157
The purpose of this article is to fix the unknown display problem in Linux Mint operating system. After installing the OS if you see Display monitor is not recognized then we can install "MESA" utilities to fix this problem or we can install additio…
The purpose of this article is to demonstrate how we can upgrade Python from version 2.7.6 to Python 2.7.10 on the Linux Mint operating system. I am using an Oracle Virtual Box where I have installed Linux Mint operating system version 17.2. Once yo…
This video discusses moving either the default database or any database to a new volume.
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.

763 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

7 Experts available now in Live!

Get 1:1 Help Now