[ace-users] Trying to adding an ACE_TTY_IO handler to the reactor.

Steve Huston shuston at riverace.com
Fri Jun 15 09:42:26 CDT 2007


You might want to look at using the ACE_Proactor with tty I/O on
Windows.
 
Or, do overlapped I/O on your own and use the overlapped event handle
with the reactor framework.
 
-Steve

--
Steve Huston, Riverace Corporation
Would you like ACE to run great on your platform?
See http://www.riverace.com/sponsor.htm


-----Original Message-----
From: ace-users-bounces at cse.wustl.edu
[mailto:ace-users-bounces at cse.wustl.edu] On Behalf Of Kim J. Schmock
Sent: Friday, June 15, 2007 10:39 AM
To: ace-users at cs.wustl.edu
Subject: [ace-users] Trying to adding an ACE_TTY_IO handler to the
reactor.


1) It enters into my Rs232Handler::Handle_signal() without any
characters to available. (you can see the code in previous mail. I
just exchanged the Handel_input() with Handle_signal() as suggested).
 
2) Yes; the reactor should enter sleep infinite or timed until an
event happens. I ends up on WaitForMultipleObejcts();
 
3) Do you refer to "Windows documentation on programming Serial ports"
or some other documentation?
 
So, ACE_TTY_IO is not able to be used as is with the reactor object
without polling?
 
I have tried to look around for some solutions/examples without luck.
Maybe someone have that knowledge? or seen a solution?
 
Best regards
/Kim

  _____  

Fra: Douglas C. Schmidt [mailto:schmidt at dre.vanderbilt.edu]
Sendt: fr 15-06-2007 14:34
Til: Kim J. Schmock
Cc: ace-users at cs.wustl.edu
Emne: Re: [ace-users] FW: Trying to adding an ACE_TTY_IO handler to
the reactor. 




Hi Kim,

> That solved the issue.

Great!

> I was just wondering why handle_signal() are called rapidly.

1) Can you please provide more info on this, i.e., when the calls are
occurring is there any data available?

> Shouldn't it preempt the application until a character arrives at
the
> COM1?

2) What do you mean by "it" (i.e., the Reactor) and "preempt" (i.e.,
the
reactor should sleep)?

> It seems like it is polling, or maybe reacting on an event related
to
> the handle for the COM1 port.

3) I recommend you read the documentation on programming with Windows
serial ports.  I seem to recall the way of getting I/O from them is to
create an event that's associated with the serial port handle and
register *that* event with the reactor, rather than the handle itself.

Take care,

     Doug


-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://list.isis.vanderbilt.edu/pipermail/ace-users/attachments/20070615/fae10375/attachment.htm


More information about the Ace-users mailing list