Go to Post Man, FIRST is amazing :D - galewind [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
  #16   Spotlight this post!  
Unread 12-02-2012, 21:15
Tom Line's Avatar
Tom Line Tom Line is online now
Raptors can't turn doorknobs.
FRC #1718 (The Fighting Pi)
Team Role: Mentor
 
Join Date: Jan 2007
Rookie Year: 1999
Location: Armada, Michigan
Posts: 2,554
Tom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond repute
Re: Benefits of "Periodic Tasks VI"?

Ok, this brings up another question I've been thinking about.

Greg, if a speed has not changed from the last loop, is there any reason to call the set speed command? Will not calling it result in a watchdog?
  #17   Spotlight this post!  
Unread 12-02-2012, 21:17
ratdude747's Avatar
ratdude747 ratdude747 is offline
Official Scorekeeper
AKA: Larry Bolan
no team
 
Join Date: Feb 2009
Rookie Year: 2008
Location: Madison, IN
Posts: 1,064
ratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond repute
Re: Benefits of "Periodic Tasks VI"?

Quote:
Originally Posted by Tom Line View Post
Ok, this brings up another question I've been thinking about.

Greg, if a speed has not changed from the last loop, is there any reason to call the set speed command? Will not calling it result in a watchdog?
yes, it would if the delay was long enough. it used to be 100ms last I checked.

(safety measure to prevent runaway robots)
__________________
Dean's List Semi-finalist 2010
1747 Harrison Boiler Robotics 2008-2010, 2783 Engineers of Tomorrow 2011, Event Volunteer 2012-current

DISCLAIMER: Any opinions/comments posted are solely my personal opinion and does not reflect the views/opinions of FIRST, IndianaFIRST, or any other organization.

Last edited by ratdude747 : 12-02-2012 at 21:21. Reason: meant to say 100ms, not 10ms
  #18   Spotlight this post!  
Unread 12-02-2012, 21:18
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,600
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: Benefits of "Periodic Tasks VI"?

Quote:
Originally Posted by Tom Line View Post
Greg, if a speed has not changed from the last loop, is there any reason to call the set speed command? Will not calling it result in a watchdog?
The motor safety will trigger if it isn't updated every 100ms (assuming that you didn't disable the motor safety or change the timeout limit). It will not affect the watchdog.
  #19   Spotlight this post!  
Unread 12-02-2012, 21:19
Tom Line's Avatar
Tom Line Tom Line is online now
Raptors can't turn doorknobs.
FRC #1718 (The Fighting Pi)
Team Role: Mentor
 
Join Date: Jan 2007
Rookie Year: 1999
Location: Armada, Michigan
Posts: 2,554
Tom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond repute
Re: Benefits of "Periodic Tasks VI"?

Quote:
Originally Posted by ratdude747 View Post
yes, it would if the delay was long enough. it used to be 10ms last I checked.

(safety measure to prevent runaway robots)
Shouldn't be 10ms, since setspeed commands in teleop aren't called that often.
  #20   Spotlight this post!  
Unread 12-02-2012, 21:21
ratdude747's Avatar
ratdude747 ratdude747 is offline
Official Scorekeeper
AKA: Larry Bolan
no team
 
Join Date: Feb 2009
Rookie Year: 2008
Location: Madison, IN
Posts: 1,064
ratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond repute
Re: Benefits of "Periodic Tasks VI"?

Quote:
Originally Posted by Tom Line View Post
Shouldn't be 10ms, since setspeed commands in teleop aren't called that often.
yeah, it is 100ms. typo. fixing original
__________________
Dean's List Semi-finalist 2010
1747 Harrison Boiler Robotics 2008-2010, 2783 Engineers of Tomorrow 2011, Event Volunteer 2012-current

DISCLAIMER: Any opinions/comments posted are solely my personal opinion and does not reflect the views/opinions of FIRST, IndianaFIRST, or any other organization.
  #21   Spotlight this post!  
Unread 12-02-2012, 21:21
Tom Line's Avatar
Tom Line Tom Line is online now
Raptors can't turn doorknobs.
FRC #1718 (The Fighting Pi)
Team Role: Mentor
 
Join Date: Jan 2007
Rookie Year: 1999
Location: Armada, Michigan
Posts: 2,554
Tom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond repute
Re: Benefits of "Periodic Tasks VI"?

Thanks Joe. So - if you've disabled the motor safeties, what happens if set speed is not called for say, 2 or 3 seconds. Does the motor stay at the last set point?

I ask because some of the Beta teams saw a noticeable improvement in CPU usage by putting a simple if/then around their set speed and only calling it on a change.
  #22   Spotlight this post!  
Unread 12-02-2012, 21:25
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: Benefits of "Periodic Tasks VI"?

Quote:
Originally Posted by Tom Line View Post
Ok, this brings up another question I've been thinking about.

Greg, if a speed has not changed from the last loop, is there any reason to call the set speed command? Will not calling it result in a watchdog?
I'm not Greg, but I know the answer. If a motor has its Motor Safety watchpup enabled, you must continue to set it at least as often as the safety configuration requires. Drive motors have the safety period set at 100 milliseconds. Other motors have the safety disabled by default. If you let a motor's safety timeout elapse without setting its output, that motor will be shut off.

If a motor's safety feature is not enabled, it will keep its last commanded output value indefinitely. That includes switching from autonomous to teleoperated mode (or vice versa, which can happen during testing), so you should make sure your motors are initialized to something reasonable when such things happen.

Last edited by Alan Anderson : 12-02-2012 at 21:27.
  #23   Spotlight this post!  
Unread 12-02-2012, 21:26
Greg McKaskle Greg McKaskle is offline
Registered User
FRC #2468 (Team NI & Appreciate)
 
Join Date: Apr 2008
Rookie Year: 2008
Location: Austin, TX
Posts: 4,756
Greg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond repute
Re: Benefits of "Periodic Tasks VI"?

There are several watchdog and safety mechanisms in effect.

The system watchdog will shutdown the robot outputs when the DS communications is interrupted or an estop takes place. The 100ms timeout is controlled by the Robot Safety mechanism and it automatically zeroes configured robotDrive motors after 100ms. Not setting RobotDrive every 20ms will lower CPU usage, but I'm curious as to how much.

Greg McKaskle
  #24   Spotlight this post!  
Unread 13-02-2012, 17:01
Pirate programe's Avatar
Pirate programe Pirate programe is offline
Registered User
FRC #0354
 
Join Date: Jan 2012
Location: Queens,NY
Posts: 53
Pirate programe is an unknown quantity at this point
Re: Benefits of "Periodic Tasks VI"?

Quote:
The system watchdog will shutdown the robot outputs when the DS communications is interrupted or an estop takes place.
What could cause Driver Station communications to be interrupted?

our team is using UDP to transmit between the Dashboard and the cRIO, which appears to be delaying the watchdog being fed, and interrupting robot communications. the port we're using for the socket isn't being used anywhere else in the code, from what we can see, so what could it be?
  #25   Spotlight this post!  
Unread 13-02-2012, 17:58
ratdude747's Avatar
ratdude747 ratdude747 is offline
Official Scorekeeper
AKA: Larry Bolan
no team
 
Join Date: Feb 2009
Rookie Year: 2008
Location: Madison, IN
Posts: 1,064
ratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond reputeratdude747 has a reputation beyond repute
Re: Benefits of "Periodic Tasks VI"?

Quote:
Originally Posted by Pirate programe View Post
What could cause Driver Station communications to be interrupted?

our team is using UDP to transmit between the Dashboard and the cRIO, which appears to be delaying the watchdog being fed, and interrupting robot communications. the port we're using for the socket isn't being used anywhere else in the code, from what we can see, so what could it be?
wireless failure on the robot, wireless failure of the field, loose cable at the robot, loose able on the field, loose cable at the driver's station, software/hardware glitch on the robot/field/driver's station, random acts of god, solar flares , etc.
__________________
Dean's List Semi-finalist 2010
1747 Harrison Boiler Robotics 2008-2010, 2783 Engineers of Tomorrow 2011, Event Volunteer 2012-current

DISCLAIMER: Any opinions/comments posted are solely my personal opinion and does not reflect the views/opinions of FIRST, IndianaFIRST, or any other organization.
  #26   Spotlight this post!  
Unread 13-02-2012, 19:23
Greg McKaskle Greg McKaskle is offline
Registered User
FRC #2468 (Team NI & Appreciate)
 
Join Date: Apr 2008
Rookie Year: 2008
Location: Austin, TX
Posts: 4,756
Greg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond repute
Re: Benefits of "Periodic Tasks VI"?

Can you describe more? Perhaps post some code?

Greg Mckaskle
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 01:42.

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