trouble with application programe of serial port (use bsp of pc386)
zpeng563 at 126.com
Thu Feb 16 13:29:17 UTC 2012
I am a student. Now i have take part in a project which is based on x86 cpu. So i study BSP of PC386. Precently,i want to write a application program of serial port. Because,the BSP of PC386 is provide the serial port driver. So we can use the serial port driver directly.
The soruce code of this drive programe include tty_drv.c\ termios.c\ uart.c... Before i write the application programe , i made a analysis about this driver. Let's look some code whic is come out of these files.
return rtems_termios_read (arg);
} /* tty_read */
rtems_termios_read (void *arg)
rtems_libio_rw_args_t *args = arg;
struct rtems_termios_tty *tty = args->iop->data1;
uint32_t count = args->count;
char *buffer = args->buffer;
we can find a important arguements *arg , it's a pointer point to a struct .This struct have three member ,they are
args->iop->data1 \ args->count \ args->buffer
who know their funcations??? I believe in application programe ,we have to provide these arguements!
Can you provide a test programe of serial port with this drive in bsp of pc386.?
Thanks so much!
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the users