DIAdem

cancel
Showing results for 
Search instead for 
Did you mean: 

Scaling of Datavalues in Data Plugin

Hi There,
 
I am trying to bring up a data plugin where the channels values needs an offset and an factor. The Factor information is obtained through a single value in the file, but the offset is the previous value of the channel.
 
For Example,
 
if 1,2,3,4 are the channel values and Factor is 0.1
 
Then the 1st chnnael value is 1*0.1   = 0.1
2nd Channel Value is = 2 * 0.1 + 0.1 = 0.3
3rd cahnnel value = 3 * 0.1 + 0.3       = 0.6
4th Channel value = 4 * 0.1 + 0.6      = 1
 
I am not quite sure How I can get this information on the offset. Can you please help me out with this.
Waiting for you earliest response.
 
 
Thanks,
Priya
 
 

 



Message Edited by pria on 06-30-2008 12:50 PM

Message Edited by pria on 06-30-2008 12:50 PM
0 Kudos
Message 1 of 3
(3,505 Views)
Hi pria,
 
There is no way to do this with DirectAccessChannels, you will need to parse each data value manually in VBScript in the DataPlugin code, then use the Channel.Values(i-1) property to return the previous value to use for Channel.Values(i).
 
Brad Turpin
DIAdem Product Support Engineer
National Instruments
0 Kudos
Message 2 of 3
(3,484 Views)

Hi Brad,

Thanks for letting me know this. I should be be to get all my future plugins correctly.

Thanks,

Priya

 

 

 

0 Kudos
Message 3 of 3
(3,465 Views)