[ECOS] problems with small CYGNUM_HAL_RTC_PERIOD

David N. Welton davidw@dedasys.com
Wed Jan 22 09:52:00 GMT 2003


I have an experimental app that drives the PC speaker.

CYGNUM_HAL_RTC_PERIOD is, on the i386 platform, normally defined as
11932, making for 100 ticks per second.  That's not very fine grained
for what I want to do.

1) Is there any way to do some sort of sleep/alarm/whatever in less
   than a tick? I don't think so, but just checking...

2) I drop that number down to 1193, and things work ok, but I try and
   drop it further to 119, and the system no longer seems to respond
   to events (keyboard interrupts, to be specific).  Same problem with
   alarms.  Any idea what could be going on?

What's the best way to do something every few microseconds?  A thread
that pauses X time?  An alarm?

BTW, on a completely unrelated note,

#ifdef KEYBOARD_EN_US
#include <cyg/hal/pcmb_keyboard_en_us.h>
#else if ....
#include <cyg/hal/pcmb_keyboard_en_gb.h>
...

with an accompanying bit of CDL would be convenient in pcmb_screen.c
in order to pick whichever keyboard is the most convenient.
Unfortunately, I couldn't quite get the CDL right to make this work
well enough to submit a patch.

Thanks,
-- 
David N. Welton
   Consulting: http://www.dedasys.com/
     Personal: http://www.dedasys.com/davidw/
Free Software: http://www.dedasys.com/freesoftware/
   Apache Tcl: http://tcl.apache.org/

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



More information about the Ecos-discuss mailing list