Jump to content

Difficulty on explaining a program


Carman

Recommended Posts

In fact , I don't know my problems is falling into which category. ^^"""

Well Carman what is the problem?

What are you trying to do?

That said:

You don't need the sequence structure, the data-flow will force the VI's to execute from left to right.

Secondly if you get unexpected results, connect the error out of the first VI (DIG-Line) to the seconed one (group config)

Also read the error status from the VI in the while loop, invert this and OR it with the switch and connect that to the loop condition (the green arrow).

Now the loop will end when the VI produces an error AND the switch is false (note that you've selected continue if true, this makes the loop run if the switch is true)

Stop if true is better IMHO. In that case you can OR the error state and the switch

Ton

Link to comment

thank Ton! :D

In fact ...

I want to ask

Could u help me to explain what is the program doing (including the functions of VIs in details) step-by-step in words ??

This program was created at a laboratory following a guide sheet

but i don't really know what are the little icons mean and how are they function. :unsure:

Link to comment
thank Ton! :D

In fact ...

I want to ask

Could u help me to explain what is the program doing (including the functions of VIs in details) step-by-step in words ??

This program was created at a laboratory following a guide sheet

but i don't really know what are the little icons mean and how are they function. :unsure:

Actually, most of what I can say by looking at the code is already contained in the caption: Quadrature Encoder Program. It looks like the code is initializing some hardware that's used to read an encoder (quadrature encoders are frequently used on servo or stepper motors for position monitoring). Everything to the left of the While loop is involved in that.

Inside the While loop, the program reads the position of the encoder and outputs it to the screen continuously until the user clicks the "Switch" button. Then the program exits.

Since what you've posted is labeled as a Figure, is it fair to assume that you need to recreate the functionality of this code, but you don't have the original source VIs to work from?

If you have the original source VIs, you should be able to use LabVIEW's online help to dig through the code and see what's going on. If not, you'll need to find more documentation on how the encoder works and how it's connected to the DAQ hardware you're using (of course, having documentation of your hardware is always a good idea!).

Good luck!

Link to comment

thank you, Justin!

well ~ I don't have the original source VIs to work from......

Hhmmm...... what can I do.....Hmmm :headbang:

how about ......

I may ask..... :shifty:

what is the function of [dig. line], [group config.], [set attribute], [control],

[get attribute], [error] and counts?

and what do the pink line and box represent ?

Do the lines mean flow, input and output ?

What are the [up down], [source polarity], [hardware], [high to low],

[program]and [reset] used to do??

hahaha ~~~ thank you a lot for answering my questionssss!

I am really don't know how to deal with them.

The Question should be answered in my Laboratory Report::::

"""Explain the program including the functions of VIs at task 2 in details.

Hint: use the Help to assist you."""

However, I don't have the software at home. I can't get any assistance.

I hope you can teach me what to do. :yes:

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.