This is the mail archive of the ecos-discuss@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: cyg_io_read


"amassa@cts.com" wrote:
> 
> I am trying to get input from the /dev/tty1 device.  I have attached the
> code snippet I am using.  However, I am unable to get any input from the
> serial port.  I am running on an MBX board.  I can send output to the port
> using cyg_io_write for the /dev/tty1 device.  The device seems to get
> initialized properly from the cyg_io_lookup call - there is no error
> returned.  I never return from the call to cyg_io_read.
> 
> I have also tried this with GDB in the stubs disabled.
> 
> Can you give me some suggestions or reasons why this is not working?

cyg_io_write() works but cyg_io_read() doesn't? Since you are using a tty
device, perhaps it is the line endings - tty devices buffer things up until
they see end-of-line chars.

Jifl
-- 
Red Hat, 35 Cambridge Place, Cambridge, UK. CB2 1NS  Tel: +44 (1223) 728762
"Plan to be spontaneous tomorrow."  ||  These opinions are all my own fault

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]