This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
Re: Getting battery status on ipaq
- To: Cristiano Ligieri Pereira <cpereira at ics dot uci dot edu>
- Subject: Re: [ECOS] Getting battery status on ipaq
- From: Jonathan Larmour <jlarmour at redhat dot com>
- Date: Wed, 03 Oct 2001 23:58:36 +0100
- Cc: ecos-discuss at sourceware dot cygnus dot com
- References: <Pine.SOL.4.20.0110031535180.28554-100000@washoe.ics.uci.edu>
Cristiano Ligieri Pereira wrote:
>
> Hi folks,
>
> I'm attaching my code to get battery status from amtel controller in the
> compaq ipaq. The code seems to work fine when there is no
> cyg_thread_delay() called in thread code. When there is a function call to
> cyg_thread_delay() it only works once and I don't get any answer from the
> controller and the system seems to freeze after that.
>
> The code seems correct to me. Can anyone guess what's the problem if I
> call cyg_thread_delay()?
Sorry, where are you calling cyg_thread_delay()? Could it just be as simple
as the cyg_thread_delay causing another thread to be scheduled which
doesn't relinquish control? Or perhaps the deschedule causes another device
to talk to the Atmel and confuse it.
Just a suggestion anyway, even though I know little about the Atmel.
Jifl
--
Red Hat, Rustat House, Clifton Road, Cambridge, UK. Tel: +44 (1223) 271062
Maybe this world is another planet's Hell -Aldous Huxley || Opinions==mine