Go to Post Back in the old days, we didn't have clues, and we liked it! - Joe Ross [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 02-09-2005, 09:46
Greg Needel's Avatar Unsung FIRST Hero
Greg Needel Greg Needel is offline
REVving up for a new season
FRC #2848 (All-sparks)
Team Role: Engineer
 
Join Date: Jan 2002
Rookie Year: 2002
Location: Dallas, TX
Posts: 3,110
Greg Needel has a reputation beyond reputeGreg Needel has a reputation beyond reputeGreg Needel has a reputation beyond reputeGreg Needel has a reputation beyond reputeGreg Needel has a reputation beyond reputeGreg Needel has a reputation beyond reputeGreg Needel has a reputation beyond reputeGreg Needel has a reputation beyond reputeGreg Needel has a reputation beyond reputeGreg Needel has a reputation beyond reputeGreg Needel has a reputation beyond repute
looking for 1 joystick Pbasic drive code

for my battle bot i am using one of the older pbasic controllers w/ 1 joystick. We have tried for some time to play with the default 1 stick code but we can;t get it to work. So i figured i would ask and see if anyone has any successful code.
__________________
Greg Needel│www.robogreg.com
Co-founder REV Robotics LLC www.REVrobotics.com
2014 FRC World Champions with 254, 469, & 74
  #2   Spotlight this post!  
Unread 02-09-2005, 09:55
sciguy125 sciguy125 is offline
Electrical Engineer
AKA: Phil Baltar
FRC #1351
Team Role: College Student
 
Join Date: Jan 2005
Rookie Year: 2004
Location: Sunnyvale, CA
Posts: 519
sciguy125 has a reputation beyond reputesciguy125 has a reputation beyond reputesciguy125 has a reputation beyond reputesciguy125 has a reputation beyond reputesciguy125 has a reputation beyond reputesciguy125 has a reputation beyond reputesciguy125 has a reputation beyond reputesciguy125 has a reputation beyond reputesciguy125 has a reputation beyond reputesciguy125 has a reputation beyond reputesciguy125 has a reputation beyond repute
Send a message via AIM to sciguy125 Send a message via MSN to sciguy125 Send a message via Yahoo to sciguy125
Re: looking for 1 joystick Pbasic drive code

Could you post some code?
__________________

-----BEGIN GEEK CODE BLOCK-----
Version: 3.12
GE/S/P a-- e y-- r-- s:++ d+ h! X+++
t++ C+ P+ L++ E W++ w M-- V? PS+ PE+
5- R-- tv+ b+ DI+++ D- G
------END GEEK CODE BLOCK------
  #3   Spotlight this post!  
Unread 02-09-2005, 11:01
Mark McLeod's Avatar
Mark McLeod Mark McLeod is online now
Just Itinerant
AKA: Hey dad...Father...MARK
FRC #0358 (Robotic Eagles)
Team Role: Engineer
 
Join Date: Mar 2003
Rookie Year: 2002
Location: Hauppauge, Long Island, NY
Posts: 8,862
Mark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond repute
Re: looking for 1 joystick Pbasic drive code

Here's the 1-joystick code we used for driver practice this year on a second robot using one of the older controllers. I don't remember if it's any different than the original default code other than minor changes though. It does a debug printout of the drive values being sent to the PWMs.

The right drive motors are on PWMs 1 & 2 & 13 & 14
The left motors are on PWMs 3 & 4 & 15 & 16

P.S. This second version was used on a third robot, but reverses the behavior of the joysticks due to motor wiring and mounting. It switches between 1 and 2-joystick operation based on the value of p4_sw_aux1 where we attached a switch on the OI.
__________________
"Rationality is our distinguishing characteristic - it's what sets us apart from the beasts." - Aristotle

Last edited by Mark McLeod : 02-09-2005 at 11:25.
  #4   Spotlight this post!  
Unread 02-09-2005, 12:25
John Gutmann John Gutmann is offline
I'm right here
AKA: sparksandtabs
FRC #0340 (GRR)
Team Role: Mechanical
 
Join Date: Feb 2005
Rookie Year: 2004
Location: rochester
Posts: 804
John Gutmann has a brilliant futureJohn Gutmann has a brilliant futureJohn Gutmann has a brilliant futureJohn Gutmann has a brilliant futureJohn Gutmann has a brilliant futureJohn Gutmann has a brilliant futureJohn Gutmann has a brilliant futureJohn Gutmann has a brilliant futureJohn Gutmann has a brilliant futureJohn Gutmann has a brilliant futureJohn Gutmann has a brilliant future
Send a message via AIM to John Gutmann Send a message via MSN to John Gutmann Send a message via Yahoo to John Gutmann
Re: looking for 1 joystick Pbasic drive code

greg this is what i used on my robot, just pick the code you need

http://www.ifirobotics.com/first-legacy.shtml

the "default" codes are for 2 joysticks and the "user" codes are for 1 joystick
  #5   Spotlight this post!  
Unread 02-09-2005, 14:47
Greg Needel's Avatar Unsung FIRST Hero
Greg Needel Greg Needel is offline
REVving up for a new season
FRC #2848 (All-sparks)
Team Role: Engineer
 
Join Date: Jan 2002
Rookie Year: 2002
Location: Dallas, TX
Posts: 3,110
Greg Needel has a reputation beyond reputeGreg Needel has a reputation beyond reputeGreg Needel has a reputation beyond reputeGreg Needel has a reputation beyond reputeGreg Needel has a reputation beyond reputeGreg Needel has a reputation beyond reputeGreg Needel has a reputation beyond reputeGreg Needel has a reputation beyond reputeGreg Needel has a reputation beyond reputeGreg Needel has a reputation beyond reputeGreg Needel has a reputation beyond repute
Re: looking for 1 joystick Pbasic drive code

Quote:
Originally Posted by sparksandtabs
greg this is what i used on my robot, just pick the code you need

http://www.ifirobotics.com/first-legacy.shtml

the "default" codes are for 2 joysticks and the "user" codes are for 1 joystick
that is the code we can;t get working....it says to put your Pwm in ports 11-12 and when you do the motor are just full on....I tried calibrating the speed controllers with no luck.

I was kinda hoping someone would have some custom code that was driven during the season during those years. Something that has been throughly tested and known to work well. IFI default codes sometimes work in theory but not in real life.
__________________
Greg Needel│www.robogreg.com
Co-founder REV Robotics LLC www.REVrobotics.com
2014 FRC World Champions with 254, 469, & 74
  #6   Spotlight this post!  
Unread 02-09-2005, 15:00
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: looking for 1 joystick Pbasic drive code

Quote:
Originally Posted by Greg Needel
that is the code we can;t get working....it says to put your Pwm in ports 11-12 and when you do the motor are just full on...
Read it again. The 2003 default code for 1-joystick drive that I'm looking at puts the right side outputs on pwms 13 and/or 14, and the left side on pwms 15 and/or 16. Pwms 11 and 12 are set from the p3 and p4 wheel inputs, respectively.
  #7   Spotlight this post!  
Unread 02-09-2005, 15:59
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,590
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: looking for 1 joystick Pbasic drive code

Quote:
Originally Posted by Greg Needel
that is the code we can;t get working....it says to put your Pwm in ports 11-12 and when you do the motor are just full on....I tried calibrating the speed controllers with no luck.
Be sure to remove your custom calibration after moving to the correct PWMs or else it still won't work.
  #8   Spotlight this post!  
Unread 02-09-2005, 17:24
John Gutmann John Gutmann is offline
I'm right here
AKA: sparksandtabs
FRC #0340 (GRR)
Team Role: Mechanical
 
Join Date: Feb 2005
Rookie Year: 2004
Location: rochester
Posts: 804
John Gutmann has a brilliant futureJohn Gutmann has a brilliant futureJohn Gutmann has a brilliant futureJohn Gutmann has a brilliant futureJohn Gutmann has a brilliant futureJohn Gutmann has a brilliant futureJohn Gutmann has a brilliant futureJohn Gutmann has a brilliant futureJohn Gutmann has a brilliant futureJohn Gutmann has a brilliant futureJohn Gutmann has a brilliant future
Send a message via AIM to John Gutmann Send a message via MSN to John Gutmann Send a message via Yahoo to John Gutmann
Re: looking for 1 joystick Pbasic drive code

Quote:
Originally Posted by Greg Needel
that is the code we can;t get working....it says to put your Pwm in ports 11-12 and when you do the motor are just full on....I tried calibrating the speed controllers with no luck.

I was kinda hoping someone would have some custom code that was driven during the season during those years. Something that has been throughly tested and known to work well. IFI default codes sometimes work in theory but not in real life.
i am using the default code on my robot, infact i was just playing with it not too long ago today and i didtn have any problems, I never even read the directions, i just pluged the pwm cables into pwm 1 and 2 and the joysticks into 1 and 2 and it works perfectly

did you try adjusting the trim pot on your joystick?
  #9   Spotlight this post!  
Unread 02-09-2005, 20:35
Greg Needel's Avatar Unsung FIRST Hero
Greg Needel Greg Needel is offline
REVving up for a new season
FRC #2848 (All-sparks)
Team Role: Engineer
 
Join Date: Jan 2002
Rookie Year: 2002
Location: Dallas, TX
Posts: 3,110
Greg Needel has a reputation beyond reputeGreg Needel has a reputation beyond reputeGreg Needel has a reputation beyond reputeGreg Needel has a reputation beyond reputeGreg Needel has a reputation beyond reputeGreg Needel has a reputation beyond reputeGreg Needel has a reputation beyond reputeGreg Needel has a reputation beyond reputeGreg Needel has a reputation beyond reputeGreg Needel has a reputation beyond reputeGreg Needel has a reputation beyond repute
Re: looking for 1 joystick Pbasic drive code

i mistyped the port numbers we were trying the correct ones.

We fixed it by trying a different controller....there was an internal problem with my joystick (but i guess that is what I get for 6 bux at goodwill )
__________________
Greg Needel│www.robogreg.com
Co-founder REV Robotics LLC www.REVrobotics.com
2014 FRC World Champions with 254, 469, & 74
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

Similar Threads
Thread Thread Starter Forum Replies Last Post
Change joystick to pwm mapping Joe Lewis Programming 3 30-03-2005 19:27
Drive Straight C Code using Encoders without PID? Chris_Elston Programming 17 15-02-2005 23:41
trentonDrive.c: our joystick/wheel drive code gnormhurst Programming 16 03-02-2005 14:40
Team THRUST - Kevin's Code and Camera Code Combine Chris_Elston Programming 3 31-01-2005 22:28
TechnoKats Automated Test Drive Code Greg McCoy Programming 1 16-01-2003 17:45


All times are GMT -5. The time now is 13: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