473,385 Members | 1,661 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,385 software developers and data experts.

Problem with writing and reading from serial device ttyS0

Hi folks ,
Can anyone help me out the problem regarding writing and reading data to/from a serial device like ttyS0 in linux . Writing is being done but unable to read from it . could u plea help me out with good stuff or brief explation what i need to do . Remember i need asynchronous read/write opeartion where i m using aio_read and aio_write.
May 5 '07 #1
1 2991
AdrianH
1,251 Expert 1GB
Hi folks ,
Can anyone help me out the problem regarding writing and reading data to/from a serial device like ttyS0 in linux . Writing is being done but unable to read from it . could u plea help me out with good stuff or brief explation what i need to do . Remember i need asynchronous read/write opeartion where i m using aio_read and aio_write.
Can you write out an example of how you are currently manipulating ttyS0 for writing, and then how you are actually doing the writing?

What errors are you experencing? I'm assuming runtime errors, but I could be wrong.

If you have a test app which is small (no more than 20 lines) and shows the problem you are experencing, post it to the forum. Please use [code][/code] tags to surround your code.

Thanks


Adrian
May 5 '07 #2

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

Similar topics

1
by: lec | last post by:
Hi, I'm trying to write a program to read from the serial port & write whatever that is read to the X console (/dev/tty7). For X to recognize the characters sent, I believe you have to send...
1
by: Andrew Rich | last post by:
Is there a better way than opening the serial port like this ? open (TNC, "/dev/ttyS0");
3
by: Martin Woolley | last post by:
Hi I have some code which reads from a serial port. When I use it on one of my Linux boxes I see 0x0D0A terminating lines read from the device. This is what I expect to see. But if I run the...
3
by: Gregory Graham | last post by:
I have a temperature sensor device we use to shutdown our servers. It relys on fopen() blocking when the serial port device isn't ready. Unfortunately that's not what's happening. The fopen()...
2
by: findyasir | last post by:
Hi all, I am having problem comunication with serial port in linux. I have tested the serial port with attaching a serial modem and dialing the numbers with wvdial. it works okie but when i...
5
by: lucky001 | last post by:
Hi I need to write a file using ANSI C:- From a computer having unix To a computer attached on a serial port (this computer has Window CE) I am able to make a connection with computer...
9
by: Hal Vaughan | last post by:
I've done a fair amount of Googling for information on reading the serial port in C++ (and in Linux). Unfortunately, out of every 4 hits, 1 seems to be an unanswered question, 1 is someone saying,...
5
by: kkadrese | last post by:
hello group, how to get ttyS0 serial port for exclusive access? I have a python script that uses this device with AT commands. I need that two instances can call simultaneosuly this python...
6
by: anu29dolly | last post by:
Hello everyone... I have written a program to write and read data from serial port.... I am able to write 80(in binary)..and is expecting 1B but i am uable to read it... My code goes as...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
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: 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: 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
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
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...

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.