From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jonathan Larmour To: "Natarajan, Mekala (CTS)" Cc: "'ecos-discuss@sources.redhat.com'" Subject: Re: [ECOS] Reg::input from keyboard Date: Fri, 20 Apr 2001 07:11:00 -0000 Message-id: <3AE04385.CC73F249@redhat.com> References: X-SW-Source: 2001-04/msg00265.html "Natarajan, Mekala (CTS)" wrote: > > Hi, > i am using MBX starter kit with MPC860 50MHZ processor. This kit > has two serial ports and keyboard interface too. I am using ecos latest cvs > version. > How do i use the serial port 2 for getting input or for diagnostic output. Diagnostic output can go there by using the options in the MBX platform HAL such as "Diagnostic serial port" (CYGNUM_HAL_VIRTUAL_VECTOR_CONSOLE_CHANNEL) and switching it from 0 to 1. Input is something best done with a proper interrupt-driven serial driver. If they are included in your configuration the port 2 driver is enabled by going into the I/O serial configuration and enabling "HArdware serial device drivers" (CYGPKG_IO_SERIAL_DEVICES) and selecting it under there. You could then do I/O using the more native cyg_io_read/cyg_io_write commands described in the documentation, or by using /dev/tty2 (probably) with stdio for tty-like access. Jifl -- Red Hat, Rustat House, Clifton Road, Cambridge, UK. Tel: +44 (1223) 271062 Maybe this world is another planet's Hell -Aldous Huxley || Opinions==mine