From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
08-02-2012 01:56 AM
Hi VitEm,
"I'm not sure, if my parser is optimal."
- Surely not, that FOR loop can be optimized - maybe it isn't needed at all.
- Instead of the formula node I would use a case structure.
- Attach real VIs when you want optimizations by others.
- Give a good description of how that string should be parsed...
08-02-2012 04:16 AM
Hi Gerd,
"- Surely not, that FOR loop can be optimized - maybe it isn't needed at all."
yes-yes-yes and yes! I'm also trying to avoid the "for loops", but in this case a small loop was my conscious compromise.
"- Instead of the formula node I would use a case structure."
I did it, while in next step it was desired to manage more than 25 cases! But in the my new variant I realized all based on the "case machine pattern". I must denote: the new parsing paradigm is a help of one professional LabView expert.
"- Attach real VIs when you want optimizations by others."
No problem! I would gladly do it, cause now I have big trouble to manage the huge number of cases.
"- Give a good description of how that string should be parsed..."
I could'nt do it better, than own Data Format Description from DMM manufacturer.
Please take a look on attachments.
08-02-2012 04:27 AM
Hi VitEm,
why don't you use the parser that you already have in the VI attached to your last message? It looks much better than your try...
I would replace the case structure in the VI by a string array constant holding all measurement descriptors and a simple IndexArray to index the corresponding descriptor...
08-02-2012 04:54 AM
Dear Gerd,
I've had VISA troubles with it today morning. Surely, there is only another variant to interpret the DMMs answer well.
I thought about it, more then one it could be replaced with a small config file, witch have to be loaded at the VI start. But I wrote: today morning I tried the new paradigm to test these advantages. It's dynamical, flexible and works more stable, then mine.