Go to Post IRI: Where the Egos Go to Tie. :ahh: - Ian Curtis [more]
Home
Go Back   Chief Delphi > Technical > Programming > NI LabVIEW
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
 
 
Thread Tools Rate Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Spotlight this post!  
Unread 18-01-2011, 06:53
Itamar's Avatar
Itamar Itamar is offline
Registered User
FRC #1943 (NeatTeam) & FRC #4590 (GreenBlitz)
Team Role: Mentor
 
Join Date: Jan 2010
Rookie Year: 2010
Location: Israel
Posts: 83
Itamar is an unknown quantity at this point
How come endless loops don't stop the code?

Hello.
I have been programming in LabVIEW for about a year, and until now I programmed everything with the same structure, like the one shown in the default code. Say I wanted to run a motor with a constant 50% speed, I'd do it like this: open the motor at Begin.vi and set it with a curtain reference name.
At the Teleop.vi I'd call the get motor vi and the set speed vi to give it 0.5 speed, and finally I'd go to the Finish.vi and close the motor.

Today I read the Basic Motor Control Tutorial at NI.com and saw this code example:



Now... If I called this motor control vi file from inside Teleop.vi, would it work? is it better than what I usually do? and wouldn't the endless loop (say I won't press the stop button, or replace it with a False constant like I've seen in several other code examples) freeze the code and prevent the other vi files in Teleop.vi from working?

Thanks.
Reply With Quote
 


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 10:10.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi