ISO Example for reading/writing uart/rs-232
Marc Lehmann
schmorp at schmorp.de
Sat Feb 6 06:38:02 CET 2016
On Fri, Feb 05, 2016 at 04:45:45PM +0000, Chris Galas <ChrisG at nytec.com> wrote:
> I'm still having trouble with getting the read callback to fire. I've verified (via Realterm) that when I write my values to the file descriptor, byes are received on the port. So I know traffic is going back and forth, but I can't seem to get libev to detect a read on the file descriptor. Thanks.
When you write to the fd, you send bytes out to the serial port, you wouldn't
receive anything. How do you know traffic goes back and forth?
Otherwise, I don't see anything obviously bad about your libev usage, but
your example is quite confusing, for example you print "write" both for
reading and writing. Are you sure you are not confusing yourself with these
messages? How do you know you the read callback isn't actually invoked?
--
The choice of a Deliantra, the free code+content MORPG
-----==- _GNU_ http://www.deliantra.net
----==-- _ generation
---==---(_)__ __ ____ __ Marc Lehmann
--==---/ / _ \/ // /\ \/ / schmorp at schmorp.de
-=====/_/_//_/\_,_/ /_/\_\
More information about the libev
mailing list