The function and scpiCmds all work, the problem is enabling the function using a scpiCmd, independent of the scpiCmd calling the function. I made the addFuncGlobal a #pgm# command:
#scpiCmd EnablegetMeasUnit #pgm#
addFuncGlobal("getMeasUnit","""
If I manually enable that, it works fine. The problem is, I don't know how to enable the global function automatically.
For example, initCmd does not work:
#initCmd MeasDefault;EnablegetMeasUnit
It shows the command execution in the log, but the global function doesn't work until I manually run the EnablegetMeasUnit cmd. After I manually execute that, everything works as it should.
I will have to do some testing on that.
Have you had a chance to check on this? If it won't work, I will need to revert to the larger driver file.
On the other hand, this gave me an idea for another feature request.

Here's the idea: like the #initCmd, but for when you open the #cmdSetup, you could have something like
#cmdSetupInit to run commands either before or after the #cmdSetup popup is synchronized. Ideally, before or after could be a tag like :loadbefore: or :loadafter:.
Thanks,
Josh