[Bdi4emc-help] xfce and axis

Matt Timmermans matt at timmermans.org
Fri Feb 17 05:25:17 CET 2006

----- Original Message ----- 
From: <jepler at unpythonic.net>
> If you start emc from a terminal, then hit control-c after AXIS has
> started, do you get a Python traceback?

Hey, that's a useful feature!  The trace I got is included below.

It looks like the problem is a call in line 640-something in axis, in the 
update method.  It tells something to call the same method again in 20ms and 
then does the update.  If it takes more than 20ms to do the update, bad 
things ensue, including deadlocks on some semaphores.  You might be able to 
replicate the problem by setting the delay to 1ms or so.

When I moved the enqueing call to the end of the update method, axis started 
to work just fine.  I don't know whether or not even that is completely 
safe, however.  Are "TkIntr" callbacks single-threaded?

In any case, that's a lovely UI you have there.


Here's the trace.  ALL this stuff came out when I hit Ctrl-C -- even the two 
lines before "Exception in Tkinter".
_sem.c 72: semctl(1409026,0,0) failed: (errno = 1) Operation not permitted
_sem.c 72: semctl(1376257,0,0) failed: (errno = 1) Operation not permitted
Exception in Tkinter callback
Traceback (most recent call last):
  File "/usr/lib/python2.3/lib-tk/Tkinter.py", line 1345, in __call__
    return self.func(*args)
  File "/usr/lib/python2.3/lib-tk/Tkinter.py", line 456, in callit
  File "plat/nonrealtime/bin/axis", line 646, in update
  File "plat/nonrealtime/bin/axis", line 251, in set_current_line
    vupdate(vars.running_line, -1)
  File "plat/nonrealtime/bin/axis", line 571, in vupdate
    if var.get() == val: return
  File "/usr/lib/python2.3/lib-tk/Tkinter.py", line 254, in get
    return getint(self._tk.globalgetvar(self._name))

MT> Ctrl-C didn't actually bring the UI down, so I killed it here.

./generic.run: line 605:  7681 Terminated 
plat/nonrealtime/bin/$display -ini $INIFILE
quickstep.ini was not changed.
generic.var was not changed.
Removing shared memory  2490383
resource(s) deleted
Removing semaphore 1507333
resource(s) deleted
Removing shared memory  2523153
resource(s) deleted
Removing semaphore 1540102
resource(s) deleted
Removing shared memory  2326535
resource(s) deleted
Removing semaphore 1343488
resource(s) deleted
Removing shared memory  2359304
resource(s) deleted
Removing semaphore 1376257
resource(s) deleted
Removing shared memory  2392073
resource(s) deleted
Removing semaphore 1409026
resource(s) deleted

More information about the Bdi4emc-help mailing list