11-06-2006 05:44 AM
11-06-2006 10:17 AM
11-06-2006 11:51 AM - edited 11-06-2006 11:51 AM
Thanks for the response Chris.
I'm afraid your suggestion doesn't work... I can set it via the property node, but the readout from 'DAQmx read' still is without unit. (see the broken wire in the attachment). I think the property node isn't different than the 'create channel' vi. I can also set the unit there. (Either to Volt, or to 'from custom scale')
Now... I could readout the scale with the property node, but that doesn't bring me much further. I would need to make a case statement with that information, and manually type-cast the unit on the data that I've read. That would be quite cumbersome with custom scales, as the unit is then set to 'from custom scale'. Then I'd need to nest another case statement inside the previous one, going through my custom scales. And the unit from the custome scale is hardcoded in that case...
That seems rather complicated, for something that would seem to have to be handled automatically... (While else put a unit inside the custom scale?)
Message Edited by Anthony de Vries on 11-06-2006 06:51 PM
11-06-2006 01:28 PM
You're right. That is most annoying. the property seems useless. I programatically change the caption text... Torque(Nm)... with property nodes. This method gets to be combersome as well because i cluster all of the unit values through the VI. I hope someone knows this because it would be simpler to write.
If you open up the create scale VI, the reason becomes clear. The prescaled and scaled values are appended to scale after the fact. it never gets updated, at least that is how i interpret it.
Chris
11-06-2006 03:16 PM
Never mind, it was a reference and not a property node. I'm not really sure how that reference works as far as data flow.
Maybe there is a way to programatically save a created scale into max, read scale from max, and when done delete from max. Just a thought.
Chris
11-10-2006 09:31 AM