Hello to all labview users,
i am a beginner in using labview. I am currently writting a labview program to automatically control a digital control rotator HD201e and a network analyzer 8720a to work with the anechoic chamber. The program receives an initial position, amount of increment and # of steps. My program will then ask the controller to rotate to the initial position and at the meantime, the program will monitor the position of the rotator to ensure the requested position is reached. After that, at the position, the program will ask the NA to perform a reading of the measurement. Once the reading is done, the program will ask the controller to rotate to the next position and does a reading of the measurement and so on.
My program seems to be able to perform the tasks; however, the dig.controller part seems to get stuck around 50% of the time when running the program. Sometimes, even the controller receives the requested position (can be seen from the lcd screen of the controller), the rotator just simply would not rotate; also, sometimes, the controller just simply does not respond when sending the command of moving a position, as in the debug mode (the one with a lightbulb), i see that i got "ok" on all the blocks in the writing portion ofthe program, but the controller just doesnt seem to receive the position (as seen no new position received from the lcd screen) and the cursor on the lcd screen blinks weirdly, due to that problem, my program will then get stuck in an infinite loop.....
Usually, that problem occurs after few positions have been reached.....
so, when that happens, i have to stop my program and re-run it. that means the program will have to re-do the measurement that were read previously....
sometimes i have to stop and re-run my program several times to get all the measurement of all the positions done.....so...that bug renders that program to be an unefficient program.
I have been trying to resolve that bug for weeks...but no success....i have tried to put some wait time between each block....result is not much different...
I have also tried putting "clear" block before and after the "write" block.....same problem.....
I have heard that the serial GPIB "flush" block may help...but i tried..but it seems the controller doesnt recognize/accept flush....
i have also tried using the "Visa open" and "Visa close" block to see if ithat reduces the stucking thing....but seems that the controller can still get stuck....
i have also even tried using "lock asyn" and "unlock asyn" block...but didnt seem to work....
Has anyone experienced such problem.? Is it a known problem with some gpib instrument?
Is there any discrepancy or bugs in my program that i am unaware of that causes this problem?
Any advice and or opinion would be greatly appreciated....
PS: i attached the controller part of my program and the overall program
desperate happyguy......
*********************************************************************
Happy guy
~ currently final year undergraduate in Electrical Engr. Graduating soon! Yes!
~ currently looking for jobs : any position related to engineering, labview, programming, tech support would be great.
~ humber learner of LabVIEW lvl: beginner-intermediate