Marc,
Thank you for the example! This will definitely allow me to run multiple threads to separate UI from audio processing.
I will try to dig a bit deeper to understand how the VMs work. One of the things I need to do is invoking a function on a specific VM (to generate audio I need to register a C callback that is invoked on a thread that is not controlled my me). My plan is having a standard VM running the main program and have another "idle" VM that will only be invoked by the C callback function. This way I should avoid corruption of the main VM stack. This idle VM would receive the information it needs from an in process message queue or a socket. If I can find the way of invoking the function on the right VM, I think my problem would be solved.
Thank you!
Regards,
Francisco