Hello,
Simply placing a subVI in a state machine should not affect it's execution; I would recommend executing that subVI inside the state machine just as you do outside the state machine to verify this, even if it means using a trivial state machine (cycling through states like a sequence structure). Can you verify, perhaps using the VISA Interactive control (in MAX see Tools -> NI-VISA -> Interactive Control) or the NI-488.2 Communicator (in MAX see right click on your device after scanning for instruments and select "Communicate with Instrument")? If you can open and run NI-Spy in the background and post the capture, I'll have a better idea of what's going on (see step 0. below for a link to instructions)!
I would use the following sequence of troubleshooting steps:
0. Open and run NI-Spy; here are directions for obtaining a capture:
1. Use one of the above utilities to verify proper communication, as you plan to do in your application.
2. Write a simply program using either the GPIB or VISA API to mimic the sequence of events you used in 1. above.
3. Integrate the simple program from 2. above into your larger application, placing the relevant code within your state machine if necessary.
Ok, I hope this helps!
Best Regards,
JLS