LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

increment HOW TO help

See my notes on the block diagram...

LabVIEW Pro Dev & Measurement Studio Pro (VS Pro) 2019 - Unfortunately now moving back to C#, .NET, Python due to forced change to subscription model by NI. 8^{
Message 41 of 52
(1,150 Views)

Can you please save for 8.5 version,

 

Many thanks

_________________________
Rookie; LV 2011 on WIN 7
0 Kudos
Message 42 of 52
(1,147 Views)

Here is a pic of the BD.  You need to put your Agilent code in.  What Agilent device are you using?

21531i4D7733A7838CF189

LabVIEW Pro Dev & Measurement Studio Pro (VS Pro) 2019 - Unfortunately now moving back to C#, .NET, Python due to forced change to subscription model by NI. 8^{
0 Kudos
Message 43 of 52
(1,136 Views)

Since the number of steps may change, you could either use a control to have the operator do the math and figure out how many steps to iterate the loop (will probably cause confusion) -OR- use a While Loop where you stop the loop once the value is equal to or greater than your upper threhold (value).

 

0 Kudos
Message 44 of 52
(1,127 Views)

Please delete !

_________________________
Rookie; LV 2011 on WIN 7
0 Kudos
Message 45 of 52
(1,122 Views)

If I do like this(see attachments for this .vi)

21533i3877A61C7D60F157

PROBLEMS:

-Start value if I define for example 6, on output will be first value 7(if I set step size 1)

-I cannot define end value(because I can only define numbers of "cyle" for "for loop"), for example, I need  from 6-16, step size 0,5, time 1000ms

 

 

THE SOLUTION from @ NIquist (LINK)

 

works great, I can choose start value, end value, time, but I don't how to "define" step size.

 

 

PS:

1. sorry for double post

2. Many thanks for some help and advices

 

_________________________
Rookie; LV 2011 on WIN 7
0 Kudos
Message 46 of 52
(1,108 Views)

@hlod wrote:

PROBLEMS:

-Start value if I define for example 6, on output will be first value 7(if I set step size 1)

-I cannot define end value(because I can only define numbers of "cyle" for "for loop"), for example, I need  from 6-16, step size 0,5, time 1000ms

 


This is child's play.  If you want the output to start at 6, make the Start Value 6 minus the step size.  Can't you see that the adding takes place before the data is sent to the meter?  So just set the start value to something that will result in 6 after the step size has been added.  If step size is 0.5, and you start at 5.5, your first value will be 6.  So start at 5.5, not 6.

 

To figure out the loop N, count how many steps from start to end using step size.  From 6 to 16 with step size of 1 takes 10 steps.  So with step size of 0.5, it will be 20 steps.  Wire 20 into N.  This is 3rd grade arithmetic.  (End - Start)/StepSize  DUH!!!!

 

 

 

 

- tbob

Inventor of the WORM Global
0 Kudos
Message 47 of 52
(1,096 Views)

Okej I try and try, and "explore" some tutorials also examples, but I don't get it...

 

This "circuit" is working OK, I only need to define step, I try with for loop and some advices which you give me, but with no success, can anyone just change anything, so I can set step size...

 

Just ignore .vi for HP Agilent 6654A.... If anyone want to help please save for 8.5 version of labview...

_________________________
Rookie; LV 2011 on WIN 7
0 Kudos
Message 48 of 52
(1,062 Views)

Use this .vi

_________________________
Rookie; LV 2011 on WIN 7
0 Kudos
Message 49 of 52
(1,052 Views)

I've been following this thread, and I'm sorry, but, this has simply gone beyond silly. This really is, as tbob, noted, 3rd grade arithmetic and trivial LabVIEW programming. You have a while loop. Great. You have a start value. Great. You have a step size. Great. You have an end value. Great. Then what's so difficult about this formula: new value = start value + (iteration * step size)? Can't figure it out? Write out a table, as I learned to do in school:

 

using start value = 10 and step size = 2:

 

i   i*step size    new value

----------------------------

0       0            10

1       2            12

2       4            14

3       6            16

4       8            18

 


P.S. LabVIEW code are not "circuits". They're programs.

0 Kudos
Message 50 of 52
(1,033 Views)