I want to use ix.application.add_timer in Python. So far, I failed to reproduce the SWIG AppCallback type of the callback function. I tried to use ctypes.CFUNCTYPE and ctypes.cast to generate a void (*)(void*) signature, but the SWIG type check for that parameter failed regardless. Is there a way to solve this?
As a fallback I we used the ix.application.add_to_event_loop_single pattern, as shown in the pyqt_clarisse utility of Clarisse. It works very well, except it produces 100% CPU usage. Just for clarification: the 100% CPU usage results from the pattern itself, not from our routine we call. If we just use this pattern without calling our own routine, it generates 100% CPU too. I guess that installing an event loop callback results in a bypass of any wait operation in the main loop and it starts spinning. So my educated guess is that running any QT application within Clarisse results in 100% CPU usage too. Please correct me if I am wrong. Note: our routine just executes every X ms a cheap non-blocking socket select to check for new data (we call it only when X ms elapsed).
As another fallback we tried to implement EVT_ID_APPLICATION_IDLE using "ix.api.ClarisseApp.on_idle = on_idle" and "ix.application.connect(ix.application, ix.api.EVT_ID_APPLICATION_IDLE, ix.application.on_idle)" (just getting desperate

Well, I understand you do not want a crowded main loop. If I were able to use add_timer, it would not be a burden for Clarisse.
If there is no other way, we will fall back to what Bridge Livelink and Clarisse Survival Kit do and create a separate process which executes commands via the command port.
I am looking forward to your insights.
Kind regards
Niklas