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


That's correct write works, read does not.

I do hit the enter key after I type in some characters, but this still does
not produce any response from cyg_io_read.  I read in the documentation that
cyg_io_read is supposed to echo the characters back to the terminal port,
however, this does not happen either.

--Anthony

Jonathan Larmour <jlarmour@redhat.co.uk> writes:
>"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]