This is the mail archive of the ecos-discuss@sourceware.org mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: MPC555 serial receive drops bytes


> With the exception fixed, I was still getting overruns so I moved the
> code out of the DSR code into the ISR to improve latency. Since its only
> moving a byte out of a register, I thought it doesn't really need a DSR.

You have to be very careful here. You cannot call the 

(chan->callbacks->rcv_char)(chan, (cyg_uint8)scdr);

from ISR context. It has to be in DSR context. It will play around
with threads, unblocking readers etc, which can only be done safely in
DSR context.

    Andrew


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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]