Go to Post So please, think twice before you click that little button that says "reply". - Ken Leung [more]
Home
Go Back   Chief Delphi > Technical > Programming
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Closed Thread
 
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 24-01-2014, 15:47
katsauga's Avatar
katsauga katsauga is offline
Lead Programmer
AKA: Marshall Baskin
no team
Team Role: Programmer
 
Join Date: Jan 2013
Rookie Year: 2011
Location: Mora, MN
Posts: 86
katsauga has a little shameless behaviour in the past
TImed Sequence help

I am testing a timed sequence for our ball launcher, but it appears my code isn't working. Every time we press the button, motor clicks on for just a split second, then turns back off. Could someone review my code and tell me where I messed up?
__________________
If life gives you lemons,Make grape juice and sit back and watch the world wonder how you did it
  #2   Spotlight this post!  
Unread 24-01-2014, 15:52
notmattlythgoe's Avatar
notmattlythgoe notmattlythgoe is offline
Flywheel Police
AKA: Matthew Lythgoe
FRC #2363 (Triple Helix)
Team Role: Mentor
 
Join Date: Feb 2010
Rookie Year: 2009
Location: Newport News, VA
Posts: 1,717
notmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond repute
Re: TImed Sequence help

Quote:
Originally Posted by katsauga View Post
I am testing a timed sequence for our ball launcher, but it appears my code isn't working. Every time we press the button, motor clicks on for just a split second, then turns back off. Could someone review my code and tell me where I messed up?
What does the false part of the statement look like? If you hold the button down does the timed sequence complete?
  #3   Spotlight this post!  
Unread 24-01-2014, 15:53
katsauga's Avatar
katsauga katsauga is offline
Lead Programmer
AKA: Marshall Baskin
no team
Team Role: Programmer
 
Join Date: Jan 2013
Rookie Year: 2011
Location: Mora, MN
Posts: 86
katsauga has a little shameless behaviour in the past
Re: TImed Sequence help

I have not created a false statement yet. And no, it does not complete the timed sequence
__________________
If life gives you lemons,Make grape juice and sit back and watch the world wonder how you did it
  #4   Spotlight this post!  
Unread 24-01-2014, 15:55
notmattlythgoe's Avatar
notmattlythgoe notmattlythgoe is offline
Flywheel Police
AKA: Matthew Lythgoe
FRC #2363 (Triple Helix)
Team Role: Mentor
 
Join Date: Feb 2010
Rookie Year: 2009
Location: Newport News, VA
Posts: 1,717
notmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond repute
Re: TImed Sequence help

I haven't done any labview programming for a few years, but why not just take the output directly from the button into the case block?
  #5   Spotlight this post!  
Unread 24-01-2014, 16:03
katsauga's Avatar
katsauga katsauga is offline
Lead Programmer
AKA: Marshall Baskin
no team
Team Role: Programmer
 
Join Date: Jan 2013
Rookie Year: 2011
Location: Mora, MN
Posts: 86
katsauga has a little shameless behaviour in the past
Re: TImed Sequence help

It now completes the timed sequence, but, the timing is all off.
__________________
If life gives you lemons,Make grape juice and sit back and watch the world wonder how you did it
  #6   Spotlight this post!  
Unread 24-01-2014, 16:08
Alan Anderson's Avatar
Alan Anderson Alan Anderson is offline
Software Architect
FRC #0045 (TechnoKats)
Team Role: Mentor
 
Join Date: Feb 2004
Rookie Year: 2004
Location: Kokomo, Indiana
Posts: 9,113
Alan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond repute
Re: TImed Sequence help

Quote:
Originally Posted by katsauga View Post
Every time we press the button, motor clicks on for just a split second, then turns back off.
How is Motor1 being created? If it has the motor safety enabled, it will act as you describe because you're only setting it once. The motor safety will shut off a motor if it doesn't get an explicit command at least every 100 milliseconds.

Are you seeing any errors reported in the Driver Station diagnostics window?
  #7   Spotlight this post!  
Unread 24-01-2014, 16:09
katsauga's Avatar
katsauga katsauga is offline
Lead Programmer
AKA: Marshall Baskin
no team
Team Role: Programmer
 
Join Date: Jan 2013
Rookie Year: 2011
Location: Mora, MN
Posts: 86
katsauga has a little shameless behaviour in the past
Re: TImed Sequence help

So I should turn the MotorSafety off?
__________________
If life gives you lemons,Make grape juice and sit back and watch the world wonder how you did it
  #8   Spotlight this post!  
Unread 24-01-2014, 16:13
Alan Anderson's Avatar
Alan Anderson Alan Anderson is offline
Software Architect
FRC #0045 (TechnoKats)
Team Role: Mentor
 
Join Date: Feb 2004
Rookie Year: 2004
Location: Kokomo, Indiana
Posts: 9,113
Alan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond repute
Re: TImed Sequence help

Quote:
Originally Posted by katsauga View Post
So I should turn the MotorSafety off?
No, you should answer the question first. Show us the part of Begin.vi where you open Motor1. Then we can ask more questions to lead you to the most appropriate solution.

And RufflesRidge has a good point. Do you control Motor1 anywhere else in your program?
  #9   Spotlight this post!  
Unread 24-01-2014, 16:19
katsauga's Avatar
katsauga katsauga is offline
Lead Programmer
AKA: Marshall Baskin
no team
Team Role: Programmer
 
Join Date: Jan 2013
Rookie Year: 2011
Location: Mora, MN
Posts: 86
katsauga has a little shameless behaviour in the past
Re: TImed Sequence help

I have already removed it from the teleop.vi , before this. I suspected that might have been an issue. It is working now though. So you would like me to post a screen shot?
__________________
If life gives you lemons,Make grape juice and sit back and watch the world wonder how you did it
  #10   Spotlight this post!  
Unread 25-01-2014, 23:23
Alan Anderson's Avatar
Alan Anderson Alan Anderson is offline
Software Architect
FRC #0045 (TechnoKats)
Team Role: Mentor
 
Join Date: Feb 2004
Rookie Year: 2004
Location: Kokomo, Indiana
Posts: 9,113
Alan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond repute
Re: TImed Sequence help

If it's working, you probably don't need help getting it working. Unless you have more questions about something, there's no need to post your code now.
  #11   Spotlight this post!  
Unread 26-01-2014, 13:42
katsauga's Avatar
katsauga katsauga is offline
Lead Programmer
AKA: Marshall Baskin
no team
Team Role: Programmer
 
Join Date: Jan 2013
Rookie Year: 2011
Location: Mora, MN
Posts: 86
katsauga has a little shameless behaviour in the past
Talking Re: TImed Sequence help

Alright, Thank you for your help
__________________
If life gives you lemons,Make grape juice and sit back and watch the world wonder how you did it
  #12   Spotlight this post!  
Unread 24-01-2014, 16:09
RufflesRidge RufflesRidge is offline
Registered User
no team
 
Join Date: Jan 2012
Location: USA
Posts: 989
RufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant future
Re: TImed Sequence help

Also make sure you're not trying to control Motor 1 in your Teleop code.
  #13   Spotlight this post!  
Unread 24-01-2014, 16:12
katsauga's Avatar
katsauga katsauga is offline
Lead Programmer
AKA: Marshall Baskin
no team
Team Role: Programmer
 
Join Date: Jan 2013
Rookie Year: 2011
Location: Mora, MN
Posts: 86
katsauga has a little shameless behaviour in the past
Re: TImed Sequence help

It was the Motor safety, thanks! I did't realize that is what it did! Thank you for your help!
__________________
If life gives you lemons,Make grape juice and sit back and watch the world wonder how you did it
  #14   Spotlight this post!  
Unread 24-01-2014, 16:09
Joe Ross's Avatar Unsung FIRST Hero
Joe Ross Joe Ross is offline
Registered User
FRC #0330 (Beachbots)
Team Role: Engineer
 
Join Date: Jun 2001
Rookie Year: 1997
Location: Los Angeles, CA
Posts: 8,567
Joe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond repute
Re: TImed Sequence help

Is motor safety enabled for motor1?
Closed Thread


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 02:36.

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