12-01-2010 03:12 PM
Can I change the scale of an IO Variable on my crio at runtime. The exact scale of my ai and ao change over time, I would like to use the inate scales in the io variables mapped to the channels on my modules but can not figure out how to change this at runtime only through the project. I know I can write my own scaling code but this extra work and uses the limited space on the crio. Is there an API to change the scales?
Solved! Go to Solution.
12-03-2010 09:34 AM
Paul,
After some searching I was unable to find a way to programmatically change a scale of a shared variable at runtime. If you find an alternative solution or if I somehow skipped the way of doing it I would be very interested in learning about it.
12-03-2010 10:06 AM
Low and behold it took me a few more minutes and I found it:
Regards from Austin,
12-03-2010 12:30 PM
I am able to do this with a call to the shared variable engine api. I access the io shared variable using a constant, then set the properties using scales ptopertied of the sharedVariableIO type. I will play with this and make sure it is working correctly, there is no help files linked to this.
12-03-2010 12:31 PM
Thanks looks like we found the same API, I used the class browser, this in one of the best hiddent gems in labview for finding what you are looking for.