timing an event

timing an event

Post by Leslie F. Donalds » Fri, 07 Jan 1994 07:58:59



I am looking for a way to time events to 1/60 of second accurcy
in unix using gcc. This is for a data acquireing project. my idea
is do something like..

start an (alarm)

     process
     sleep

alarm handler

   see if were done if not finish
else start next one.

There is also a static boolean that tells if the processing is done yet.

Does anyone have any portable way of doing this in unix.
Please respond by e-mail.

Thank You
Lesie Donaldson

 
 
 

1. Time-based events screwed up in X (not reliable)

I'm running RH6.0 w/2.2.10, tested both with and without rtc compiled in.
All on a Thinkpad 755c notebook.

Console-based realtime programs (top, etc) update correctly and reliably,
and seem to work great.

However, in XFree86, programs such as gpppkill and gstripchart run for a
couple of seconds and/or update iterations, then simply stop. If I move the
mouse over their windows and right-click a context menu or something, they
will tend to update their displays once in response to the mouse event, but
then become idle again.

The behaviour is consistent with them no longer receiving timer-based events
(their code has generic event handlers that respond to mouse and timer
events and update via either, so it's understandable that the mouse event
would trigger an update).

I've also had related issues, such as the screen blanking/screensaver
initializing every couple of seconds, only held at bay with continuous mouse
movement (finally had to turn off blanking/saving altogether), and focus
switching windows extremely slowly (like 30 seconds or so) on an unloaded
CPU.

Any ideas? Right now my X windows environment is pretty screwed up without
reliable timer events...

Eric

2. silo overflows?

3. Determine Elapsed Time Between Events

4. Smail Problems

5. Console Graphics and Timing Events and Real Time programming

6. NFS between RH Linux 6.2 and Solaris 2.6

7. Time Events: How to handle multiple pending time events within a single thread on UNIX type systems?

8. pppd cbcp 2.4.0 + kernel 2.4.32

9. setting mouse button event to key press event

10. XtAppAddTimeOut and Expose Event - Not Getting event

11. Joystick -->Create an event --> Handle this event

12. How get the time of ANY keyboard-event?

13. ssh problem - bad time limit in the event loop