LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

how to create a table with 3 inputs one of which is received from a sensor and the other 2 are constants

i want to create a table that has 2 angles (beta and theta) that could assume values from 0 to 180º and gamma that is given from a sensor to the table at every moment... all angles depend of each other and i want a table that demonstrates that. so i can pull a data to use it in a equation. can someone help with this mess?

0 Kudos
Message 1 of 10
(3,596 Views)

A table is just a way to depict an array on the front panel (control or indicator), so if you can work with arrays, you're 99% there.

 

But first work out your math, then you can start programming.

 

If you don't know how to work with arrays (or reading sensors, for that matter), you should at least work out some of the (free) online LabVIEW tutorials.

 

Cameron

 

To err is human, but to really foul it up requires a computer.
The optimist believes we are in the best of all possible worlds - the pessimist fears this is true.
Profanity is the one language all programmers know best.
An expert is someone who has made all the possible mistakes.

To learn something about LabVIEW at no extra cost, work the online LabVIEW tutorial(s):

LabVIEW Unit 1 - Getting Started</ a>
Learn to Use LabVIEW with MyDAQ</ a>
Message 2 of 10
(3,579 Views)

I could not have explained it better than Cameron.  🙂

 

Make sure you populate your array (table) properly and the rest should be simple.  Don't think of a table as some different entity from an array.

Try to minimize type conversions.  If your data is numeric, stick with a numeric array. 

0 Kudos
Message 3 of 10
(3,566 Views)

I really do not have much (any) experience with labview, i had a class but was not very deep, so we didn't talk about arrays or tables, so i am kinda on my own. so i will try to do what you said!.

thank you

0 Kudos
Message 4 of 10
(3,533 Views)

@alufe wrote:

I really do not have much (any) experience with labview, i had a class but was not very deep, so we didn't talk about arrays or tables, so i am kinda on my own. so i will try to do what you said!.

thank you


Do you have any experience with computer programming at all? LabVIEW arrays are no different from arrays in other high-level languages (of course, someone is going to pop in with an exception).The LabVIEW help screens have a wealth of information for you.

 

No experience with computers? Computer arrays are just like math arrays, except that they can contain stuff other than numbers or numeric variables as elements. Go to Wikipedia, then hit the LabVIEW help screens to explore more.

 

Cameron

 

To err is human, but to really foul it up requires a computer.
The optimist believes we are in the best of all possible worlds - the pessimist fears this is true.
Profanity is the one language all programmers know best.
An expert is someone who has made all the possible mistakes.

To learn something about LabVIEW at no extra cost, work the online LabVIEW tutorial(s):

LabVIEW Unit 1 - Getting Started</ a>
Learn to Use LabVIEW with MyDAQ</ a>
0 Kudos
Message 5 of 10
(3,521 Views)

I really dont like anything that has to do with  programming (at all), i only do it because i am "forced" to.

I need to make a "simple" table of angles, in which this vertically, eg, alpha, and horizontally is beta, the values on the table are the values of the relation between them. both angles are between 0 and 180 so i need a table with 32400 logs :S and there is a third angle that is gamma that is received from a sensor at every moment and they all depend of each other, so they have a relation like theta= gamma+ beta (eg).

I need to do that because i have an equation that doesn´t have solution so i need a table to pull this values in order to have numeric solution for my equation.

Somebody told me to do a lut in matlab but because i dont know how to do that either, my teacher advised me to dont waist time and do everything in labview because is the program i have been using all along in this project.

I dont understand how to fill arrays in order to do that.

(as you might have notice by now i´m clueless... :S)

0 Kudos
Message 6 of 10
(3,464 Views)

Well, you really don't sound very happy, being "clueless" about your project. So let's find out where you need your first clue.

 

First, do you understand arrays (1-D, 2-D, etc.) in Math? If not, you need to go immediately to your teacher for help, because without this, you're doomed.

 

Second, did you work the tutorials I suggested, or any of the other ones on the Web? You aren't going to get better without some broad-spectrum instruction, and they do cover arrays. (Any "class" on LabVIEW which didn't even cover the use of arrays [which you mention above] is absolutely useless.)

 

Third, after you do understand something about arrays, the LabVIEW help files are, coincidently, very helpful.

 

Have you done anything yet? Your last post pretty much just restates your first post without saying anything about what you have accomplished towards your goal.

 

Cameron

 

 

To err is human, but to really foul it up requires a computer.
The optimist believes we are in the best of all possible worlds - the pessimist fears this is true.
Profanity is the one language all programmers know best.
An expert is someone who has made all the possible mistakes.

To learn something about LabVIEW at no extra cost, work the online LabVIEW tutorial(s):

LabVIEW Unit 1 - Getting Started</ a>
Learn to Use LabVIEW with MyDAQ</ a>
0 Kudos
Message 7 of 10
(3,459 Views)

Not happy at all.. x)

 

I didn't talk about arrays in math either or if i did it was something very shallow..
what i learned about arrays was by my self, searching on the internet and labview help.
I didn´t do anything else, because when you said arrays i thought "ok i was searching by tables and i need to search by arrays" and when i went searching for arrays i thought "ok that is easy is just fill it up now". wasn´t easy :S
When i pulled the array module to the front panel and followed the tutorial instructions i didn´t understand why only has num ctrl vertically and anything horizontally, why is it a num ctrl if the values i want verticaly and horizontly are constants (0-180 degres) and i got stuck all over again.

 

Ana

0 Kudos
Message 8 of 10
(3,443 Views)

I have to make an array for each angle and connects them?

0 Kudos
Message 9 of 10
(3,416 Views)

@alufe wrote:

I have to make an array for each angle and connects them?


That's one way. You end up with multiple 2-D arrays. You also could make a 3-D array to iterate through all your beta/theta arrays, calculating a gamma for each pair, if you understand arrays of multiple dimensions. You seem to indicate a major shortfalling in your math skills here, so I'll repeat, work with your teacher until you can understand the math, and then work on the programming.

 

You have to know what you want to do before you can do it. In this case, you have to know what that array represents, and how (I'm talking math now) you are going to determine/represent the one set of numbers you need to work with for each experiment before you set something up in software.

 

Cameron

 

To err is human, but to really foul it up requires a computer.
The optimist believes we are in the best of all possible worlds - the pessimist fears this is true.
Profanity is the one language all programmers know best.
An expert is someone who has made all the possible mistakes.

To learn something about LabVIEW at no extra cost, work the online LabVIEW tutorial(s):

LabVIEW Unit 1 - Getting Started</ a>
Learn to Use LabVIEW with MyDAQ</ a>
0 Kudos
Message 10 of 10
(3,402 Views)