[ECOS] Interrupt Handler Routine

Andrew Lunn andrew.lunn@ascom.ch
Thu Dec 19 06:31:00 GMT 2002


On Thu, Dec 19, 2002 at 06:42:14PM +0800, Lin Ming wrote:
> Thank you Andrew for your reply!
> I have found some code I can use in dev/ about serial interrupt handler.
> 
> One thing I am wondering: If I have to write my own UART interrupt routines
> or there is some existed ecos api functions I can use?

Depends on the UART you are using. Is it one of the already supported
UARTs? If so, you should not have to do anything. Just include the
correct packages, and open /dev/ttyS0 or what every its called.

If its not supported then you need to write a serial driver. The
manual contains information about doing that.

> I am using cyg_hal_plf_serial_xxx() functions now. But they don't seem to be 
> interrupt handler routines. I have some troubles when using them to access a 
> GPS module.

cyg_hal_plf_* refer to functions called via the Virtual Vectors into
redboot. The serial functions in redboot use polled io. You want to
include the real serial driver package and the serial io package. You
can then open the device with open and use read/write etc. Or use
cyg_io_lookup() etc.

       Andrew

-- 
Before posting, please read the FAQ: http://sources.redhat.com/fom/ecos
and search the list archive: http://sources.redhat.com/ml/ecos-discuss



More information about the Ecos-discuss mailing list