LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

please tell me how

スクリーンショット (17).png

please tell me a program that puts 0,0.01,0.02,0.03,0.04,,,,,,4in t in order.(ignore the v)

for loop couldn't because of integer.

 

 

0 Kudos
Message 1 of 5
(1,174 Views)

You could

  1. divide the for loop iteration i by 100.
  2. add a array with autoindexing as for loop input
  3. use a while loop and count yourself with add and shift register

there are sure more options, but those came quickly in my mind.

 

0 Kudos
Message 2 of 5
(1,159 Views)

Hi Hiddg,

 


@Hiddg wrote:

please tell me a program that puts 0,0.01,0.02,0.03,0.04,,,,,,4in t in order.(ignore the v)

for loop couldn't because of integer.


Several options:

  • Use a FOR loop with 4/0.01+1 iterations. Let "i" autoindex at an output tunnel to get an array of integer values from 0…400. Then multiply that array by 0.01…
  • Use the Ramp function found in the Signal functions palette to generate your ramp values…
Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 3 of 5
(1,154 Views)

This shows what others have described (except I chose to use primitives instead of the formula node).

 

snippet.png

Message 4 of 5
(1,101 Views)

Why don't you look at the code I made for you three days ago??

 

 

 

(Unless you only have LabVIEW base, you should have ramp pattern.

 

\ramp.gif

 

 


@Hiddg wrote:

 

for loop couldn't because of integer.

 


You can do anything with integers including convert them to DBL. Just multiply [i] by 0.01, right?

 

You have now three different threads about the same problem. It would really help to keep it all in one place!

Message 5 of 5
(1,090 Views)