This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
Re: Clarification
- To: "Veerraju, Yeluduti (CTS)" <VYeludut at CHN dot CTS-CORP dot COM>
- Subject: Re: [ECOS] Clarification
- From: Jonathan Larmour <jlarmour at cygnus dot co dot uk>
- Date: Wed, 06 Dec 2000 03:45:22 +0000
- CC: ecos-discuss at sourceware dot cygnus dot com
- Organization: Red Hat UK Ltd.
- References: <8F1D166D08ACD41196EE00B0D020944B0EA0EA@CTSINENTSXUB>
"Veerraju, Yeluduti (CTS)" wrote:
>
> Hi,
> I am veerraju,working as software engineer in Teelcom field.
> What is the system call or API in ecos to get a character from keyboard?
> I used getchar() function but it is not working.
> So could any body help in this?
getchar() should work in general. But on some platforms you should set the
device which stdio uses for stdin to a serial driver such as /dev/tty0.
Ensure you enable the serial drivers. The configuration option in stdio is
named CYGDAT_LIBC_STDIO_DEFAULT_CONSOLE
One other case in which it doesn't work is that you can't use it when using
the serial connection to talk to GDB. Mixing serial I/O and the debug
protocol just doesn't work well.
What target is this anyway?
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