0

MEMCX causes loop for some reason?

Hey all, 

i have a procedure that, for reasons i do not understand, is looping when i do not want it to loop!

The code looks something like this:

##########

LABEL section_name

ASK- N

CALL sub initialize /swpg

target -p

disp <connection instructions>

VISA (statements to set up DUT)

MATH (variables to send to upcoming sub)

CALL sub (read and level with power meter)

MATH (store power meter reading in variableA)

CALL sub take sweep with DUT

VISA (Get marker reading from DUT)

MATH (store DUT level reading in variableB)

MATH MEM = variableA - variableB - reference1

MEMCX     dBm             0.3U

#################

At the point of executing MEMCX, the procedure instead loops back to the first CALL statement, to initialize the SWPG. On the second run, it goes through and actuall evaluates the MEMCX and continues as expected.

So: Is there some default that makes it run thru twice? Do i need to set some sort of ASK parameter? I haven't seen this behaviour elsewhere (yet - i'm still very new at this!)

any thoughts are appreciated!

 

 

3 comments

Date Votes
0
Avatar
David Weir-Marshall

Hi Tick,

Do you have the VSET parameter NMEAS set to a number greater than 1?

This will cause the procedure to loop in order to get the correct number of measurements, and I've experienced procedures jumping to some odd places (usually CALL or IF blocks) if there's no TARGET -m set.

0
Avatar
Michael Johnston

This is probably the cause, but it might not be in a VSET FSC, it could also be in your mu.ini file

0
Avatar
Ticknor, Scott (IC)

Thank you for the suggestions, i will investigate those possiblities.

Please sign in to leave a comment.