Go to Post To quote Dylan, "When you aint got nothing, you got nothing to lose". - KenWittlief [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

 
Reply
 
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 22-03-2016, 13:18
C.Barry C.Barry is offline
Co-Captain
AKA: Courtney
FRC #2723 (Team Rocket)
 
Join Date: Feb 2016
Rookie Year: 2012
Location: Oklahoma City
Posts: 3
C.Barry is an unknown quantity at this point
Autonomous Help

Hello everyone!

I am Courtney, head programmer for my team. I am in need of some assistance with my team's autonomous code. I was able to get the drive wheels to work, yet our wedge arm motor is having difficulties. I am trying to get it to run for 1 second, yet everything I have tried has failed- it keeps running continuously. The way the code is supposed to be set up is: run wedge arm for 1 second then stop, next (after that 1 second) the drive motors should run forward for 5 seconds then stop.

Thank you for your time and help.

(Also, I am sorry in advance if the code is more complicated than necessary.)
Attached Thumbnails
Click image for larger version

Name:	IMG_0946 (1).JPG
Views:	45
Size:	1.59 MB
ID:	20416  
Reply With Quote
  #2   Spotlight this post!  
Unread 22-03-2016, 13:41
vhcook's Avatar
vhcook vhcook is offline
Reader of Things
AKA: Victoria
FRC #1939 (Kuh-nig-its)
Team Role: Mentor
 
Join Date: Feb 2007
Rookie Year: 2006
Location: Kansas City, MO
Posts: 546
vhcook has a reputation beyond reputevhcook has a reputation beyond reputevhcook has a reputation beyond reputevhcook has a reputation beyond reputevhcook has a reputation beyond reputevhcook has a reputation beyond reputevhcook has a reputation beyond reputevhcook has a reputation beyond reputevhcook has a reputation beyond reputevhcook has a reputation beyond reputevhcook has a reputation beyond repute
Re: Autonomous Help

In your second frame of your sequence, you don't actually tell the wedge arm motor to stop. You need to set output to 0 for that device for it to stop, otherwise it just keeps doing the last thing you told it.

Really, you should have three sequence frames here.
1. One second wait and the code you have for the wedge arm motor,
2. Five second wait, the wedge arm motor stop, and the drivetrain start
3. Stop the drivetrain.

Right now, your first frame ends as soon as you set the motor. If you put a wait block in that first sequence frame for 1 second, that will get it to last a full second. This doesn't have to be connected to any of the other items in that block -- Labview won't leave that frame of the sequence until everything in it has completed. What you're doing in your second frame would have worked without the sequence structure.
__________________



Last edited by vhcook : 22-03-2016 at 13:49. Reason: Noticed a second thing
Reply With Quote
Reply


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 08:08.

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