Go to Post Dwelling on the past does nothing for the future. - Cory [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
  #76   Spotlight this post!  
Unread 05-04-2011, 08:52
Robby Unruh's Avatar
Robby Unruh Robby Unruh is offline
*insert random dial-up tone here*
FRC #3266 (Robots R Us)
Team Role: Coach
 
Join Date: Feb 2010
Rookie Year: 2010
Location: Eaton, OH
Posts: 338
Robby Unruh will become famous soon enough
Re: The Hardest Drive System To Program:

Can someone give me some examples of how swerve drive is controlled via joysticks?
__________________
[Robots R Us #3266]
2015: Georgia Southern Classic (Winners / Thanks 1319 & 1648!), Queen City
2014: Crossroads, Queen City
2013: Buckeye, Queen City, Crossroads
2012: Buckeye, Queen City

2011: Buckeye
2010: Buckeye
  #77   Spotlight this post!  
Unread 05-04-2011, 09:01
bladetech932's Avatar
bladetech932 bladetech932 is offline
Programmer of awesome
AKA: Jon
FRC #0932 (Circuit Chargers)
Team Role: College Student
 
Join Date: May 2009
Rookie Year: 2009
Location: Tulsa
Posts: 242
bladetech932 is on a distinguished road
Re: The Hardest Drive System To Program:

There are many ways but two common ways among teams who do it for the first time are
-one joystick with the y axis being speed of the wheels the buttons being rotation of the whole robot and the x being the rotation of the wheels(the easiest)
-one joystick with the rotation based on where the stick is on the joystick and speed is the R vector of the x and y axis and rotation on buttons
but really there are A LOT of ways to control a swerve.
__________________
Expect the best, Prepare for the worst
  #78   Spotlight this post!  
Unread 06-04-2011, 01:01
Captaindan's Avatar
Captaindan Captaindan is offline
Registered User
AKA: Daniel
FRC #0364 (Team Fusion)
Team Role: Driver
 
Join Date: Jan 2011
Rookie Year: 2010
Location: Mississippi
Posts: 43
Captaindan is a jewel in the roughCaptaindan is a jewel in the roughCaptaindan is a jewel in the roughCaptaindan is a jewel in the rough
Re: The Hardest Drive System To Program:

hardest robot to program as far as drive goes is definitely an omni drive robot that can switch to akermon.... which is similar to a monster truck drive train where the front and back wheels turn all with encoders to exact positions we called it the crazy bot because the watchdogs would go crazy and the r0bot would go plum crazy and head for the nearest programmer for some reason
  #79   Spotlight this post!  
Unread 06-04-2011, 01:16
davidthefat davidthefat is offline
Alumni
AKA: David Yoon
FRC #0589 (Falkons)
Team Role: Alumni
 
Join Date: Jan 2011
Rookie Year: 2010
Location: California
Posts: 792
davidthefat has much to be proud ofdavidthefat has much to be proud ofdavidthefat has much to be proud ofdavidthefat has much to be proud ofdavidthefat has much to be proud ofdavidthefat has much to be proud ofdavidthefat has much to be proud ofdavidthefat has much to be proud ofdavidthefat has much to be proud of
Re: The Hardest Drive System To Program:

Quote:
Originally Posted by Captaindan View Post
hardest robot to program as far as drive goes is definitely an omni drive robot that can switch to akermon.... which is similar to a monster truck drive train where the front and back wheels turn all with encoders to exact positions we called it the crazy bot because the watchdogs would go crazy and the r0bot would go plum crazy and head for the nearest programmer for some reason
I never understood the watchdog, does it starve when a set of instructions took too long? I never had to explicitly feed it. Most of them usually were simple programming errors similar to index out of bounds or segment fragmentation.
__________________
Do not say what can or cannot be done, but, instead, say what must be done for the task at hand must be accomplished.
  #80   Spotlight this post!  
Unread 06-04-2011, 07:12
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: The Hardest Drive System To Program:

The watchdog monitors one thing and controls another.

In the case of the system watchdog, it monitors incoming control packets and controls the outputs of the robot. The deadline is 100ms, and this means that if the incoming packets take longer than 100ms to arrive, the watchdog shuts down the outputs. As an example, lets say that the driver sets the tethered robot to driving forward, and then the clumsy mentor steps on the enet cable, yanking out out of the laptop. Since this breaks comms, the watchdog notices and will shutdown the outputs. Same situation if your laptop runs out of power, you shut down the radio, you yank the enet from the dlink, you lose power to the dlink, etc. If the cRIO doesn't get incoming packets, you don't want the robot to keep driving, and the system watchdog does that.

For the User watchdog, it observes your code's ability to call the feed function. If your code doesn't call feed, it shuts down the outputs. As an example, lets say that the robot is driving forward, and the forgetful mentor sets a breakpoint in your teleop function. Without the watchdog, the robot will maintain its current course. With the watchdog, it will halt the motors.

The Safety Timers are similar to this, but are I/O specific. They observe the updates to a given output and will shutdown that output if the deadline is missed. Again, this could be due to a breakpoint, delay, infinite loop, dead thread, bad logic, etc.

Does that help?
Greg McKaskle
  #81   Spotlight this post!  
Unread 06-04-2011, 09:23
Ether's Avatar
Ether Ether is offline
systems engineer (retired)
no team
 
Join Date: Nov 2009
Rookie Year: 1969
Location: US
Posts: 8,125
Ether has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond repute
Re: The Hardest Drive System To Program:

Quote:
Originally Posted by Captaindan View Post
hardest robot to program as far as drive goes is definitely an omni drive robot that can switch to akermon
Once you've got omni programmed, adding Ackermann is very simple.


  #82   Spotlight this post!  
Unread 06-04-2011, 12:15
davidthefat davidthefat is offline
Alumni
AKA: David Yoon
FRC #0589 (Falkons)
Team Role: Alumni
 
Join Date: Jan 2011
Rookie Year: 2010
Location: California
Posts: 792
davidthefat has much to be proud ofdavidthefat has much to be proud ofdavidthefat has much to be proud ofdavidthefat has much to be proud ofdavidthefat has much to be proud ofdavidthefat has much to be proud ofdavidthefat has much to be proud ofdavidthefat has much to be proud ofdavidthefat has much to be proud of
Re: The Hardest Drive System To Program:

Quote:
Originally Posted by Greg McKaskle View Post
The watchdog monitors one thing and controls another.

In the case of the system watchdog, it monitors incoming control packets and controls the outputs of the robot. The deadline is 100ms, and this means that if the incoming packets take longer than 100ms to arrive, the watchdog shuts down the outputs. As an example, lets say that the driver sets the tethered robot to driving forward, and then the clumsy mentor steps on the enet cable, yanking out out of the laptop. Since this breaks comms, the watchdog notices and will shutdown the outputs. Same situation if your laptop runs out of power, you shut down the radio, you yank the enet from the dlink, you lose power to the dlink, etc. If the cRIO doesn't get incoming packets, you don't want the robot to keep driving, and the system watchdog does that.

For the User watchdog, it observes your code's ability to call the feed function. If your code doesn't call feed, it shuts down the outputs. As an example, lets say that the robot is driving forward, and the forgetful mentor sets a breakpoint in your teleop function. Without the watchdog, the robot will maintain its current course. With the watchdog, it will halt the motors.

The Safety Timers are similar to this, but are I/O specific. They observe the updates to a given output and will shutdown that output if the deadline is missed. Again, this could be due to a breakpoint, delay, infinite loop, dead thread, bad logic, etc.

Does that help?
Greg McKaskle
Yes, that helps and explains it.
__________________
Do not say what can or cannot be done, but, instead, say what must be done for the task at hand must be accomplished.
  #83   Spotlight this post!  
Unread 13-04-2011, 00:28
Jimmy the Kidd's Avatar
Jimmy the Kidd Jimmy the Kidd is offline
Programmer, Scouter, Tactician, etc
FRC #0364 (Team Fusion)
Team Role: Tactician
 
Join Date: May 2010
Rookie Year: 2010
Location: Gulfport MS
Posts: 71
Jimmy the Kidd is an unknown quantity at this point
Re: The Hardest Drive System To Program:

Quote:
Originally Posted by Ether View Post
Are you referring to an omni drive using omni wheels, or mecanum, or swerve?
Omni wheels.
__________________

The GDC needs to write the rules once and let the game be what the game is going to be. There's little that's fun about being told exactly how to play with your toys. - Madison
  #84   Spotlight this post!  
Unread 13-04-2011, 10:56
Ether's Avatar
Ether Ether is offline
systems engineer (retired)
no team
 
Join Date: Nov 2009
Rookie Year: 1969
Location: US
Posts: 8,125
Ether has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond repute
Re: The Hardest Drive System To Program:

Quote:
Originally Posted by Jimmy the Kidd View Post
Last year, the team thought it was a good idea to combine Ackerman and omnidrive. We never got the programming right. Ever. We were supposed to be able to switch back and forth, but the omni drive was too sensitive or sometimes wouldn't even work.
Quote:
Originally Posted by Ether View Post
Are you referring to an omni drive using omni wheels, or mecanum, or swerve?
Quote:
Originally Posted by Jimmy the Kidd View Post
Omni wheels.
I'm trying to understand what you mean by "Ackerman" in the context of an omniwheel vehicle.

Ackermann is a very specific type of front-wheel steering, used by automobiles, in which the vehicle turns around a point lying on the line which is colinear with the axles of the rear wheels.

Since an omni-wheel vehicle is holonomic, you certainly could mimic this behavior, but why would you want to? An omni-wheel vehicle can be given a "car-like" driver interface simple by disabling the strafe command - and using only rotate and fwd/rev commands.


  #85   Spotlight this post!  
Unread 13-04-2011, 13:09
Jimmy the Kidd's Avatar
Jimmy the Kidd Jimmy the Kidd is offline
Programmer, Scouter, Tactician, etc
FRC #0364 (Team Fusion)
Team Role: Tactician
 
Join Date: May 2010
Rookie Year: 2010
Location: Gulfport MS
Posts: 71
Jimmy the Kidd is an unknown quantity at this point
Re: The Hardest Drive System To Program:

Quote:
Originally Posted by Ether View Post
I'm trying to understand what you mean by "Ackerman" in the context of an omniwheel vehicle.

Ackermann is a very specific type of front-wheel steering, used by automobiles, in which the vehicle turns around a point lying on the line which is colinear with the axles of the rear wheels.

Since an omni-wheel vehicle is holonomic, you certainly could mimic this behavior, but why would you want to? An omni-wheel vehicle can be given a "car-like" driver interface simple by disabling the strafe command - and using only rotate and fwd/rev commands.

What we ended up trying to accomplish was a, I guess you'd say, mirrored Ackermann. AKA, the front wheels would turn 45 degrees to the left, and the back wheels would turn 45 degrees to the right. Then, when triggered, the drive sticks would toggle over to omnidrive, with each wheel receiving the same value from the joystick.
__________________

The GDC needs to write the rules once and let the game be what the game is going to be. There's little that's fun about being told exactly how to play with your toys. - Madison
  #86   Spotlight this post!  
Unread 13-04-2011, 13:47
Ether's Avatar
Ether Ether is offline
systems engineer (retired)
no team
 
Join Date: Nov 2009
Rookie Year: 1969
Location: US
Posts: 8,125
Ether has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond repute
Re: The Hardest Drive System To Program:

Quote:
Originally Posted by Jimmy the Kidd View Post
What we ended up trying to accomplish was a, I guess you'd say, mirrored Ackermann. AKA, the front wheels would turn 45 degrees to the left, and the back wheels would turn 45 degrees to the right. Then, when triggered, the drive sticks would toggle over to omnidrive, with each wheel receiving the same value from the joystick.
Several comments:

1) I thought you just said you were using omni wheels. Omni wheels aren't usually steered. Can you post a picture of your drivetrain?

2) I wouldn't suggest using the word "Ackermann" to describe what you stated. The whole idea of Ackermann is that the wheels are steered to different angles, not the same angle. The point of this is so that each wheel's axis will point to the center of rotation of the vehicle so that the wheels do not scrub.

3) Not sure I understand what you mean by "omnidrive, with each wheel receiving the same value from the joystick". Each wheel of an omnidirectional vehicle typically receives different commands, not the same commands.


  #87   Spotlight this post!  
Unread 13-04-2011, 13:55
Jimmy the Kidd's Avatar
Jimmy the Kidd Jimmy the Kidd is offline
Programmer, Scouter, Tactician, etc
FRC #0364 (Team Fusion)
Team Role: Tactician
 
Join Date: May 2010
Rookie Year: 2010
Location: Gulfport MS
Posts: 71
Jimmy the Kidd is an unknown quantity at this point
Re: The Hardest Drive System To Program:

Quote:
Originally Posted by Ether View Post
Several comments:

1) I thought you just said you were using omni wheels. Omni wheels aren't usually steered. Can you post a picture of your drivetrain?

2) I wouldn't suggest using the word "Ackermann" to describe what you stated. The whole idea of Ackermann is that the wheels are steered to different angles, not the same angle. The point of this is so that each wheel's axis will point to the center of rotation of the vehicle so that the wheels do not scrub.

3) Not sure I understand what you mean by "omnidrive, with each wheel receiving the same value from the joystick". Each wheel of an omnidirectional vehicle typically receives different commands, not the same commands.

I apologize. I was confused myself when I was talking. We had standard wheels. In "Ackermann" the wheels turned opposite of each other to make tighter turns. In "Omni", say you pushed the joystick to the left. Each of the four wheels would go left. Up-left, each would go up-left.
__________________

The GDC needs to write the rules once and let the game be what the game is going to be. There's little that's fun about being told exactly how to play with your toys. - Madison
  #88   Spotlight this post!  
Unread 13-04-2011, 14:08
Ether's Avatar
Ether Ether is offline
systems engineer (retired)
no team
 
Join Date: Nov 2009
Rookie Year: 1969
Location: US
Posts: 8,125
Ether has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond repute
Re: The Hardest Drive System To Program:

Quote:
Originally Posted by Jimmy the Kidd View Post
In "Ackermann" the wheels turned opposite of each other to make tighter turns. In "Omni", say you pushed the joystick to the left. Each of the four wheels would go left. Up-left, each would go up-left.
You mentioned in your earlier post that your team encountered a great deal of trouble trying to get this programmed properly.

Have you given up, or is your team going to try to tackle this as an off-season learning project?


  #89   Spotlight this post!  
Unread 13-04-2011, 14:11
Jimmy the Kidd's Avatar
Jimmy the Kidd Jimmy the Kidd is offline
Programmer, Scouter, Tactician, etc
FRC #0364 (Team Fusion)
Team Role: Tactician
 
Join Date: May 2010
Rookie Year: 2010
Location: Gulfport MS
Posts: 71
Jimmy the Kidd is an unknown quantity at this point
Re: The Hardest Drive System To Program:

Quote:
Originally Posted by Ether View Post
You mentioned in your earlier post that your team encountered a great deal of trouble trying to get this programmed properly.

Have you given up, or is your team going to try to tackle this as an off-season learning project?

We do still have the original drive train, and we've cycled programmers since then. That sounds like a good summer project, actually.
__________________

The GDC needs to write the rules once and let the game be what the game is going to be. There's little that's fun about being told exactly how to play with your toys. - Madison
  #90   Spotlight this post!  
Unread 13-04-2011, 14:21
Ether's Avatar
Ether Ether is offline
systems engineer (retired)
no team
 
Join Date: Nov 2009
Rookie Year: 1969
Location: US
Posts: 8,125
Ether has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond repute
Re: The Hardest Drive System To Program:

Quote:
Originally Posted by Jimmy the Kidd View Post
We do still have the original drive train, and we've cycled programmers since then. That sounds like a good summer project, actually.
Here's a resource that your new programmers might find useful. It discusses swerve and Ackermann programming.


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 03:54.

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