[En-Nut-Discussion] Writting a new UART device -- I solved the problem , very weird
Avex
avexwu at yahoo.com.tw
Tue Oct 22 06:58:55 CEST 2002
>
> >if(idx > limit) idx = 0;
>
> >within interrupt routines degrades system performance.
>
> If you simply increment the index and then mask off the two high bits with
> an 'and', you will get a 64 byte rollover. Add the index to the base address
> & voila... works a treat, fast & easy to implement in asm in the interrupt
> driver.
Hi Don,
I didn't mask any ....bit , I rewrote uartspi & uartavr to a new file as my new
device driver. It's no reason ,why we could mask any ... bit whenever
developing a driver of NutOS. I cann't figure out.
Avex
-----------------------------------------------------------------
< ¨C¤Ñ³£ Yahoo!©_¼¯ > www.yahoo.com.tw
More information about the En-Nut-Discussion
mailing list