XForms: Fast timer?

Hugh Gibson (hugh@mrao.cam.ac.uk)
Fri, 1 Oct 1999 14:43:05 +0100 (BST)

# To subscribers of the xforms list from Hugh Gibson <hugh@mrao.cam.ac.uk> :

Hi,
I am using the timer object 'fl_set_timer' to generate
regular updates (10Hz). There seem to be large latencies in XForms
which means it is hard to go faster than this, which is a
shame. I don't want to use the idle callback, as I want a defined time
between calls.
I am also stuck with the unix usleep(x) which is supposed to
sleep for x ammount of microseconds. In reality, you will be lucky to
get better than 10ms.

I'm using Linux Slackware 2.0.34 with XForms V0.88.1 and Fdesign 0.53

Any advice would be useful.

p.s. Here is my Makefile (for those who were having fun with
modifying the complex DEMO one) (I did!)

----------------------- snip ---------------------

CANDIR=/usr/local/can4linux/Can
LIBS =-L/usr/X11R6/lib -L$(CANDIR)/lib -lCan -lforms -lX11 -lm
CFLAGS = -I$(CANDIR)/include -O3 -Wall

# N.B. we are using fdesign with -I myheader.h which
# points harp_coila.c include file to myheader.h, which includes
# both forms.h and myglobals.h files automatically, so we can
# make changes with fdesign without having to make tweaks.
# modified_main.c is harp_coila_main.c but with extra start-up
# bits
# modified_cb.c is harp_coila_cb.c template file, with the
# callbacks filled in.

OBJS = harp_coila.o modified_main.o modified_cb.o can.o

harp_coila: $(OBJS)
$(CC) $(CFLAGS) -o harp_coila $(OBJS) $(LIBS)

clean:
-rm harp_coila *.o ; make

_________________________________________________
To unsubscribe, send the message "unsubscribe" to
xforms-request@bob.usuhs.mil or see
http://bob.usuhs.mil/mailserv/xforms.html
XForms Home Page: http://bragg.phys.uwm.edu/xforms
List Archive: http://bob.usuhs.mil/mailserv/list-archives/