The problem with doing this in stage is that when you tell the CTRIO to do something it can take a few scans of the PLC to complete. Therefore if you set the Process Command bit, and then jump out of the Stage before that operation comes to completion (i.e. Command Complete bit comes ON), then this could cause problems depending on how you have programmed it.
If you are using DirectSOFT5, I would advise you to use the CTRIO IBoxes to accomplish this task; it is much easier. You would use:
- IB-1000 (CTRIO - CTRIO Config) at the top of your program.
- IB-1013 (CTRVELO - CTRIO Velocity Mode) in the stage. When this IBox is enabled, wait for the Success bit to come ON before disabling the Stage.
Of course, you could eliminate the problem by executing these outside the Stage.