LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Store Scale Properties

Hello,

 

Is there a way to store additional properties in DAQmx scales? Specifically, once a measurement is done, would like to collect the relevant scale properties to create an equipment list. I see there is a description property that can be accessed through a property node but I don't think that description is saved and it does not appear in NI MAX.

 

Thanks,

Denis

0 Kudos
Message 1 of 7
(2,555 Views)

@Denis.Vashuk wrote:

Hello,

 

Is there a way to store additional properties in DAQmx scales? Specifically, once a measurement is done, would like to collect the relevant scale properties to create an equipment list. I see there is a description property that can be accessed through a property node but I don't think that description is saved and it does not appear in NI MAX.

 


I don't understand what you want to do.  You mention "additional properties" -- like what?  The purpose (I think) of a Scale is to get DAQmx to output values as "units", i.e. Volts, °C, g's (acceleration due to gravity), etc., rather than as an I16 (for an A/D converter), so as long as the Scale is accurate, what does it mean to "know" it?  [And if it isn't accurate, of what value are the scaled data].

 

If you set the Scale using DAQmx, then you can write out the Scales as you set them.  Otherwise, as you note, you can obtain the Scale for a particular Channel from a Property Node.  Hmm, on further looking, it doesn't look like you can (easily, if at all) retrieve the Scale assigned to a Channel, except by "trapping" the wire going into DAQmx Create Channel (or otherwise saving the Scale wire) -- there's a Scale Property Node, but it needs a Scale I/O constant ...

 

Bob Schor

0 Kudos
Message 2 of 7
(2,511 Views)

I would like to be able to store additional data with the scale or virtual channel at run time. For example, transducer S/N and Cal Due date. There is a description property for both scales and channels that I can read and write into. However, I am unable to store that into NI MAX. Is there a Save Scale or Save Channel VI that I don't know about?

0 Kudos
Message 3 of 7
(2,507 Views)

@Denis.Vashuk wrote:

I would like to be able to store additional data with the scale or virtual channel at run time. For example, transducer S/N and Cal Due date. There is a description property for both scales and channels that I can read and write into. However, I am unable to store that into NI MAX. Is there a Save Scale or Save Channel VI that I don't know about?


Sure.  Open MAX.  Create a new Scale.  Give it a name.  Configure it.  Add a Description (tab at the bottom of the right pane).  Click "Save" at top of pane.  Done.

 

Bob Schor

0 Kudos
Message 4 of 7
(2,504 Views)

I need to be able to do it from within a VI.

0 Kudos
Message 5 of 7
(2,502 Views)

As you probably know, MAX is a stand-alone program that maintains its own database of things you create in it.  I'm not sure how it does this, but when you drop, say, a Scale I/O constant, and right-click it, it will show you the Scales that MAX knows about.  This probably also works for Scales that you create in a Project -- in fact, it wouldn't surprise me if the Project "talked" to MAX to get the information.

 

Anyway, I (myself) don't know how, if you change the properties of a Scale, you can "push" it back to MAX and have MAX update its database (i.e. push its Save button) -- I suspect you cannot do this, in fact.  You might have better luck if you use a Project-defined Scale, but it might take scripting to get that written back into Project.  So your best/safest/most-certain-to-work method is to create your own Scale Configuration utility to read and write Scale Properties for yourself.

 

I'd be pleased to be shown to be wrong about this ...

 

Bob Schor

0 Kudos
Message 6 of 7
(2,500 Views)

scale.png

"If you weren't supposed to push it, it wouldn't be a button."
Message 7 of 7
(2,475 Views)