10-14-2008
Thanks for you replay
Thanks for you replay
I think I was not describing my problem properly,
I Run the READ process first, and then the WRITE process
I write the code following the Serial Programming guide:
http://www.faqs.org/docs/Linux-HOWTO/Serial-Programming-HOWTO.html
Because I open the device file /dev/ttyS0 with the flags then the read system call is blocked. mean that the read is blocked until there is data in the file descriptor (no need to poll, unless I need to poll between 2 files descriptors)
The problem might be partially solved (for the first time running the read process) by flushing the rx buffers by the code:
tcflush(fd , TCIOFLUSH ); //this code is supposed to flush out the content of write buffer of the file descriptor fd.
However, process READ still get (sometimes) only part of chars what process WRITE writing to the fd.
10 More Discussions You Might Find Interesting
1. Programming
Need help for RS232 communication with switches in order to optimise the data traffic. How to manipulate different flags in termios struct to do the same? (1 Reply)
Discussion started by: ManishSaxena
1 Replies
2. UNIX for Advanced & Expert Users
Hi !
Is there somebody who is able to connect a VNC session via serial cable ?
There is a hint on the VNC homepage that it is possible to configure that.
But how?
thanks joerg (2 Replies)
Discussion started by: joerg
2 Replies
3. Solaris
hello mates,
do you know a manufactor for rs232 serial pci cards for the sparc architecture? it seems that there is no original product from sun for that purpose. strange, isn't it?
problem is that i have a V250 with only one db9 rs232 serial port, and i need it for a modem connection, but i also... (1 Reply)
Discussion started by: pressy
1 Replies
4. Programming
Hi,
can somebody help me with this one?
I have to configure rs232 write/read inside a C program.
I'm using the termios.h (POSIX)
The problem is that the only baudrate that works for me is 28800 and
it is not supported any more from this driver. :(
So I can't write :
cfsetispeed(&options,... (4 Replies)
Discussion started by: palexo
4 Replies
5. AIX
Current setup:
Some old AIX standalone machine (F series)
My WinXP laptop
Null modem cable from laptop to AIX machine (console port).
On Hypterminal on WinXP I can connect to the AIX machine (serial connection), but when I try to transfer file, it will just sit there. I'm guessing the... (3 Replies)
Discussion started by: apra143
3 Replies
6. Programming
Hello to all Gurus out there,
Could you show me a source code in Unix platform using C language. I want to read the status or voltage level of the DSR and CTS.
Thanks a lot,
Swing5 (2 Replies)
Discussion started by: Swing5
2 Replies
7. Shell Programming and Scripting
i want to calculate power of 10 as follows:
coef=2.0588
ra1=$(awk 'BEGIN{print 10^$coef}')
it gives a result 1
when,
if i calculate
ra1=$(awk 'BEGIN{print 10^2.0588}')
it gives a result 114.499
what should i do? (2 Replies)
Discussion started by: SANGUINE
2 Replies
8. UNIX for Dummies Questions & Answers
We have a text/csv file (4mb) sitting on a Unix box. The PC belongs to a retail store and they're asking me to bring the file over to Windows so they can import the file.
Can a file be copied to an rs232 port? If so how? The idea is that I'll hook up a null modem cable to the Unix com port,... (2 Replies)
Discussion started by: alivebyscience
2 Replies
9. Programming
Hi Everybody.
I have an Ubuntu linux 10.04 os and want be able to use the website of intuit but it only runs on unix. Is there any way that I can put the needed drivers in this os since both linux/unix share some distinctive programs.
If this is not possible how can I save the information that I... (1 Reply)
Discussion started by: mk631219
1 Replies
10. UNIX for Dummies Questions & Answers
I searched the forums for RS232 issues, but all of the results don't help me solving my problem, so I had to open new thread.
This is the problem:
I have PIC16F877A micro-controller and I'm programming it with Easypic5(the PIC programming device(board) from MikroElektronika) and I want to... (1 Reply)
Discussion started by: ivan_vasileski
1 Replies
UARK(4) BSD Kernel Interfaces Manual UARK(4)
NAME
uark -- Arkmicro Technologies ARK3116 based USB serial adapter
SYNOPSIS
To compile this driver into the kernel, place the following lines in your kernel configuration file:
device uark
device ucom
Alternatively, to load the driver as a module at boot time, place the following line in loader.conf(5):
uark_load="YES"
DESCRIPTION
The uark driver supports Arkmicro Technologies ARK3116 based serial adapters.
HARDWARE
The uark driver supports the following adapters:
o HL USB-RS232
o HugePine USB-UART
o KQ-U8A Data Cable
o Skymaster USB to RS232
SEE ALSO
tty(4), ucom(4), usb(4)
HISTORY
The uark device driver first appeared in OpenBSD 4.0. The first FreeBSD release to include it was FreeBSD 7.0.
AUTHORS
The uark driver was written by Jonathan Gray <jsg@openbsd.org>.
CAVEATS
Setting hardware flow control is not currently supported. It is not yet known how to ask the hardware to send a break.
Arkmicro Technologies do not reply to requests of documentation for their products.
BSD
November 15, 2006 BSD