Re: reading a serial port, putting it in a EntryBox

On Mon, Aug 30, 2010 at 10:44 AM, Wolfman <wolfhack yahoo com> wrote:
At this moment, I'm want to do an application capable to read permanently from /dev/ttyS0 and the output 
put into an entry box

I can read from /dev/ttyS0 but I dont know how can I read continously from it and put the result in a entry 

The Gtk2-Perl FAQ has a question along these lines [1].

You use the add_watch method to watch a filehandle for changes, then
your anonymous subroutine gets called whenever some data appears on
that filehandle.  It would be up to you to have that anonymous
subroutine parse the data and make any changes to controls on your

I would start with the example listed in the FAQ, and search for
"Gtk2::Helper" or the actual class Gtk2::Helper calls, "Glib::IO",  in
the mailing list archives to find more examples of similar problems.




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]