If it isnt already, try to put your camera handling code in a separate function with its own wait loop.
Even if this ISNT managable, put "proc_mode=PROC_LATE;"(lite-c) or "proc_late();"(c-script) just before the wait in the code that contains the camera code.
"There is no fate but what WE make." - CEO Cyberdyne Systems Corp. A8.30.5 Commercial