Rockbox mail archiveSubject: Re: Use SLEEP instruction for longer (?) runtime
Re: Use SLEEP instruction for longer (?) runtime
From: Linus Nielsen Feltzing <linus_at_haxx.se>
Date: Thu, 23 Jan 2003 12:43:52 +0100
On Thu, 23 Jan 2003 02:27:02 +0000, Joaquim Carvalho wrote:
> Can it be because high frequency noise enters the remote pin (RXD1)
> and causes many consecutive interrupts and interrupt reentrancy?
No. Only one interrupt can be served at a time. The problem is that
the incoming garbage is interpreted as valid data.
Incoming data is only considered valid if the previous byte was
received without errors.
Since the SH1 has separate interrupts for data reception and errors,
it is not simple to handle this in a readable way. I chose to keep
the code simple.
Feel free to try to use the interrupts, but I prefer the robust way.
-- Linus Nielsen Feltzing, linus_at_haxx.se on 2003-01-23Received on 2003-01-23