Check out our General Code Repository Files. Also, before posting here, check to see if your post doesn't fit into another subforum by category.
Tags |
(This content has not been tagged yet)
|
![]() |
Aug 20 2008, 05:33 PM
Post
#1
|
|||
|
2 more posts to go! Member Posts: 8 Joined: 9-July 08 Member No.: 11955 Using LabVIEW Since:2008 LV:8.5.1 ,. ,.
|
1)In the code below, I do not understand what is the function of V subvi?
2)Also in the second image what is the function of my global.vi and motion status , active status. I am sorry if this sounds silly, but I am kinda new to labview. Thanks
Attached File(s)
|
||
|
|
|||
| Ad |
Aug 20 2008, 05:33 PM
Post
#
|
||
|
|
|
||
|
|
|||
Aug 20 2008, 05:51 PM
Post
#2
|
|||
![]() Very Active Member Posts: 93 Joined: 11-October 07 From: Tarboro, NC Member No.: 9577 Using LabVIEW Since:2001 LV:7.1 ,. ,.
|
Eleetrika,
Please do not post .BMP files. Convert them to .PNG format (or jpg) and repost. Not many people are going to waste the time to download a 2.25MB file, much less two of them. -------------------- Jim
![]()
|
||
|
|
|||
Aug 20 2008, 06:34 PM
Post
#3
|
|||
![]() Extremely Active Premium Member ![]() Posts: 451 Joined: 19-June 07 From: Everett, WA Member No.: 8758 Using LabVIEW Since:2007 LV:8.6 ,8.5.1 ,8.2.1
|
1)In the code below, I do not understand what is the function of V subvi? 2)Also in the second image what is the function of my global.vi and motion status , active status. I am sorry if this sounds silly, but I am kinda new to labview. Thanks Do you know about the context help window? Press Ctrl-h to bring it up, then hover over the subvi you would like to know more about. If the original programmer documented anything, you'll see more information about it in the context help window. 1. Based on the extremely limited information available, I would guess that this subvi sets the velocity of a given axis in um/s 2. Your guess is better than mine because you can see all of the code, but they appear to be global variables that are storing status information
|
||
|
|
|||
Aug 20 2008, 09:43 PM
Post
#4
|
|||
![]() Very Active Premium Member ![]() Posts: 217 Joined: 31-January 03 From: Wilson NC USA Member No.: 48 Using LabVIEW Since:2001 LV:8.5 ,. ,.
|
1)In the code below, I do not understand what is the function of V subvi? 2)Also in the second image what is the function of my global.vi and motion status , active status. I am sorry if this sounds silly, but I am kinda new to labview. Thanks There is no way to tell what is inside a sub-VI by looking at its icon. You can find out for yourself by double clicking on the icon which will cause that sub-VI to open up for editing in LabVIEW, and any sub-VIs in there can also be opened up, and so on, until you have looked at all the under lying code. If the subVI has any output terminals you can add indicators to them to see what is produced by the subVI as it is run. The highlitghing button on the menu (a light bulb) of the Block diagram menu allows you to watch the progress of the program as it operates. These may help you understand what is happening. -------------------- Michael E. Ross
Senior Design Engineer Standard Motor Products, Inc. 2717 Commerce Road Wilson, NC 27893 mross@smpcorp.com 252.234.5821
|
||
|
|
|||
Aug 20 2008, 10:19 PM
Post
#5
|
|||
|
2 more posts to go! Member Posts: 8 Joined: 9-July 08 Member No.: 11955 Using LabVIEW Since:2008 LV:8.5.1 ,. ,.
|
Eleetrika, Please do not post .BMP files. Convert them to .PNG format (or jpg) and repost. Not many people are going to waste the time to download a 2.25MB file, much less two of them. OK jimm i'll remember that..thanks.... "Do you know about the context help window? Press Ctrl-h to bring it up, then hover over the subvi you would like to know more about. If the original programmer documented anything, you'll see more information about it in the context help window. 1. Based on the extremely limited information available, I would guess that this subvi sets the velocity of a given axis in um/s 2. Your guess is better than mine because you can see all of the code, but they appear to be global variables that are storing status information" Thanks tobyD ...I know about ctrl-h but the original programmer has not documented anything for this subvi so where is the value set by the subvi being used? There is no way to tell what is inside a sub-VI by looking at its icon. You can find out for yourself by double clicking on the icon which will cause that sub-VI to open up for editing in LabVIEW, and any sub-VIs in there can also be opened up, and so on, until you have looked at all the under lying code. If the subVI has any output terminals you can add indicators to them to see what is produced by the subVI as it is run. The highlitghing button on the menu (a light bulb) of the Block diagram menu allows you to watch the progress of the program as it operates. These may help you understand what is happening. Thanks for your suggestions mross,...I have uploaded all the codes within this code...thanks again..
|
||
|
|
|||
Aug 20 2008, 10:33 PM
Post
#6
|
|||
![]() Very Active Premium Member ![]() Posts: 217 Joined: 31-January 03 From: Wilson NC USA Member No.: 48 Using LabVIEW Since:2001 LV:8.5 ,. ,.
|
Now you see that there is depth to the "G" (Graphic) code in a LabVIEW VI. When you develop your own code you will regularly create subVIs that are functional blocks that can be run and tested on their own.
In this case there is the function, Pm500 Send.vi, which sends a command string with a carriage return on the end of it to a port. I can't begin to guess what a PM 500 will do with the command. But you could test this yourself: If everything is wired properly to the PM 500 and powered up, when you activate this VI it should send the command string and cause something to occur. Then the Status and Byte Count are passed to the PM 500 Send VI (from whatever instrument the PM 500 addresses) and should appear in those indicators when the VI finishes its work. If you get no action or no returned data then you know something is not working correctly. You can see this makes debugging the Send PM 500 operation very straight forward. This is how you want to approach your own creation of LabVIEW code. -------------------- Michael E. Ross
Senior Design Engineer Standard Motor Products, Inc. 2717 Commerce Road Wilson, NC 27893 mross@smpcorp.com 252.234.5821
|
||
|
|
|||
![]() ![]() |
| Time is now: 1st December 2008 - 09:47 PM |