Go to Post 50% of the time that 330 used mcmaster 2717T51, we went to Einstein. Your mileage may vary. - 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 13-02-2004, 20:46
Xufer's Avatar
Xufer Xufer is offline
8 Seasons and as stable as ever
AKA: Working, 2/4 degrees complete still schooling...
FRC #1740 (The Cyber Colonels)
Team Role: Engineer
 
Join Date: Jan 2003
Rookie Year: 1999
Location: Waterford, CT
Posts: 231
Xufer is a splendid one to beholdXufer is a splendid one to beholdXufer is a splendid one to beholdXufer is a splendid one to beholdXufer is a splendid one to beholdXufer is a splendid one to behold
Send a message via AIM to Xufer Send a message via MSN to Xufer Send a message via Yahoo to Xufer
null zone

where in the code is 127 defined as the null zone?

im trying to set a null zone for the joystick so i can apply a "parabola" to decrese the sensitivity for fine driving. but first off i need to set this null zone so its not a true parabola, because more than 2 points would be touching the x-axis in one spot.

nonetheless, Where is the 127 nullzone defined ?
__________________


If saftey is first and i put FIRST ahead of everything, then i must be the safest guy in the world.

Team 521 Alumni -- Team 1740 Mentor-- Go Go 1740!
Sometimes I think I've been doing this too long and other times I think I haven't done this enough... but all the times I'm sure I'm crazy
Photonics, It's Your Future
  #2   Spotlight this post!  
Unread 13-02-2004, 20:58
Richomundo's Avatar
Richomundo Richomundo is offline
Mascot
AKA: Richie Knight
#1115 (Deus Ex Machina)
Team Role: Programmer
 
Join Date: Feb 2004
Rookie Year: 2004
Location: Santa Monica, California
Posts: 19
Richomundo is on a distinguished road
Send a message via AIM to Richomundo Send a message via Yahoo to Richomundo
Re: null zone

Quote:
Originally Posted by Xufer
where in the code is 127 defined as the null zone?

im trying to set a null zone for the joystick so i can apply a "parabola" to decrese the sensitivity for fine driving. but first off i need to set this null zone so its not a true parabola, because more than 2 points would be touching the x-axis in one spot.

nonetheless, Where is the 127 nullzone defined ?

its in the reference guide, however today i adjusted the sensitivity by making a very simple program code:

here is what i used.
the only problem is its a single speed code for the window motor.

you can change the values to make it more or less sensitive.
****************************
/* you can also change sensitivity here*/
/* if statements to raise and lower the arm */
if (p2_y > 180)
{relay1_fwd=1;
relay1_rev=0;}
else if (p2_y < 74)
{relay1_fwd=0;
relay1_rev=1;}
else
{relay1_fwd=0;
relay1_rev=0;}
/* ********************** */
the 1st if statement says if the joystick is above 180, then send a signal to relay 1 to make the window motor go. since iats a relay it only goes one speed.
sorry if i didnt answer your question
but thats how we did it.
__________________
I got the mic and you got the moshpit
  #3   Spotlight this post!  
Unread 13-02-2004, 21:16
The Lucas's Avatar
The Lucas The Lucas is offline
CaMOElot, it is a silly place
AKA: My First Name is really "The" (or Brian)
FRC #0365 (The Miracle Workerz); FRC#1495 (AGR); FRC#4342 (Demon)
Team Role: Mentor
 
Join Date: Mar 2002
Rookie Year: 2001
Location: Dela-Where?
Posts: 1,564
The Lucas has a reputation beyond reputeThe Lucas has a reputation beyond reputeThe Lucas has a reputation beyond reputeThe Lucas has a reputation beyond reputeThe Lucas has a reputation beyond reputeThe Lucas has a reputation beyond reputeThe Lucas has a reputation beyond reputeThe Lucas has a reputation beyond reputeThe Lucas has a reputation beyond reputeThe Lucas has a reputation beyond reputeThe Lucas has a reputation beyond repute
Send a message via AIM to The Lucas
Re: null zone

Quote from Innovation First website:
"The Victor 884 has a deadband with respect to the PWM signal, which is approximately 117 to 137 (127 center). "

So the null zone is in the Speed Controller, you can't change the 127 center. However you can make the deadband bigger in code. I recommend calibrating your speed controllers to adjust them to your joysticks. Instructions are on the website
__________________
Electrical & Programming Mentor ---Team #365 "The Miracle Workerz"
Programming Mentor ---Team #4342 "Demon Robotics"
Founding Mentor --- Team #1495 Avon Grove High School
2007 CMP Chairman's Award - Thanks to all MOE members (and others) past and present who made it a reality.
Robot Inspector
"I don't think I'm ever more ''aware'' than I am right after I burn my thumb with a soldering iron"
  #4   Spotlight this post!  
Unread 14-02-2004, 01:50
Xufer's Avatar
Xufer Xufer is offline
8 Seasons and as stable as ever
AKA: Working, 2/4 degrees complete still schooling...
FRC #1740 (The Cyber Colonels)
Team Role: Engineer
 
Join Date: Jan 2003
Rookie Year: 1999
Location: Waterford, CT
Posts: 231
Xufer is a splendid one to beholdXufer is a splendid one to beholdXufer is a splendid one to beholdXufer is a splendid one to beholdXufer is a splendid one to beholdXufer is a splendid one to behold
Send a message via AIM to Xufer Send a message via MSN to Xufer Send a message via Yahoo to Xufer
Re: null zone

Yea, see the fun thing is as soon as i posted my little problem where my head wouldnt work, the problem was solved, ill post the code tomarrow for the nullzone aand when i finish the parabola for the joystick ill post that aswell it should be funny to see working heh

--thanks for the help.
__________________


If saftey is first and i put FIRST ahead of everything, then i must be the safest guy in the world.

Team 521 Alumni -- Team 1740 Mentor-- Go Go 1740!
Sometimes I think I've been doing this too long and other times I think I haven't done this enough... but all the times I'm sure I'm crazy
Photonics, It's Your Future
  #5   Spotlight this post!  
Unread 14-02-2004, 07:58
Ryan M. Ryan M. is offline
Programming User
FRC #1317 (Digital Fusion)
Team Role: Programmer
 
Join Date: Jan 2004
Rookie Year: 2004
Location: Ohio
Posts: 1,508
Ryan M. has much to be proud ofRyan M. has much to be proud ofRyan M. has much to be proud ofRyan M. has much to be proud ofRyan M. has much to be proud ofRyan M. has much to be proud ofRyan M. has much to be proud ofRyan M. has much to be proud ofRyan M. has much to be proud of
Re: null zone

Quote:
Originally Posted by Xufer
Yea, see the fun thing is as soon as i posted my little problem where my head wouldnt work, the problem was solved,...
Confessional debugging. Works every time.
__________________

  #6   Spotlight this post!  
Unread 14-02-2004, 10:02
Xufer's Avatar
Xufer Xufer is offline
8 Seasons and as stable as ever
AKA: Working, 2/4 degrees complete still schooling...
FRC #1740 (The Cyber Colonels)
Team Role: Engineer
 
Join Date: Jan 2003
Rookie Year: 1999
Location: Waterford, CT
Posts: 231
Xufer is a splendid one to beholdXufer is a splendid one to beholdXufer is a splendid one to beholdXufer is a splendid one to beholdXufer is a splendid one to beholdXufer is a splendid one to behold
Send a message via AIM to Xufer Send a message via MSN to Xufer Send a message via Yahoo to Xufer
Re: null zone

As promised I said id post it in the morning and its morning... Im not exactly sure if it works yet i cant tels the speed untill i can use it on the "real" robot which is getting some "fine" tuning. Im going to go "program" things...

COFFEE POT... oh its too early.

Code:
pwm01 = p1_y;
if (p1_y >= 120 && p1_y <= 133)
     {pwm01 = 127;}
else if (p1_y < 120 && p1_y  > 133)
     {pwm01 = 1/1635.6 * p1_y * p1_y - 0.16149181 * p1_y * p1_y + 9.10002;}

/******************/

          pwm02 = p2_y;
if (p2_y >= 120 && p2_y <= 133)
     {pwm02 = 127;}
else if (p2_y < 120 && p2_y  > 133)
     {pwm02 = 1/1635.6 * p2_y * p2_y - 0.16149181 * p2_y * p2_y + 9.10002;}
__________________


If saftey is first and i put FIRST ahead of everything, then i must be the safest guy in the world.

Team 521 Alumni -- Team 1740 Mentor-- Go Go 1740!
Sometimes I think I've been doing this too long and other times I think I haven't done this enough... but all the times I'm sure I'm crazy
Photonics, It's Your Future

Last edited by Xufer : 14-02-2004 at 10:36.
  #7   Spotlight this post!  
Unread 14-02-2004, 10:35
Xufer's Avatar
Xufer Xufer is offline
8 Seasons and as stable as ever
AKA: Working, 2/4 degrees complete still schooling...
FRC #1740 (The Cyber Colonels)
Team Role: Engineer
 
Join Date: Jan 2003
Rookie Year: 1999
Location: Waterford, CT
Posts: 231
Xufer is a splendid one to beholdXufer is a splendid one to beholdXufer is a splendid one to beholdXufer is a splendid one to beholdXufer is a splendid one to beholdXufer is a splendid one to behold
Send a message via AIM to Xufer Send a message via MSN to Xufer Send a message via Yahoo to Xufer
Re: null zone

Ok. it works ! yea, anyway thanks again guys. Any questions about it id be glad to answer.

-Xufer
__________________


If saftey is first and i put FIRST ahead of everything, then i must be the safest guy in the world.

Team 521 Alumni -- Team 1740 Mentor-- Go Go 1740!
Sometimes I think I've been doing this too long and other times I think I haven't done this enough... but all the times I'm sure I'm crazy
Photonics, It's Your Future
  #8   Spotlight this post!  
Unread 15-02-2004, 09:55
Xufer's Avatar
Xufer Xufer is offline
8 Seasons and as stable as ever
AKA: Working, 2/4 degrees complete still schooling...
FRC #1740 (The Cyber Colonels)
Team Role: Engineer
 
Join Date: Jan 2003
Rookie Year: 1999
Location: Waterford, CT
Posts: 231
Xufer is a splendid one to beholdXufer is a splendid one to beholdXufer is a splendid one to beholdXufer is a splendid one to beholdXufer is a splendid one to beholdXufer is a splendid one to behold
Send a message via AIM to Xufer Send a message via MSN to Xufer Send a message via Yahoo to Xufer
Re: null zone

Sorry wasnt paying attention when i posted that it was off the backup file. heres the working version.


Code:
pwm01 = p1_y;
if (p1_y >= 120 && p1_y <= 133)
     {pwm01 = 127;}
else if (p1_y < 120 && p1_y  > 133)
     {pwm01 = (1/1635.6 * (p1_y * p1_y) - 0.16149181 * (p1_y * p1_y) + 9.10002);}

/******************/

          pwm02 = p2_y;
if (p2_y >= 120 && p2_y <= 133)
     {pwm02 = 127;}
else if (p2_y < 120 && p2_y  > 133)
     {pwm02 = (1/1635.6 * (p2_y * p2_y) - 0.16149181 * (p2_y * p2_y) + 9.10002);}
Sometimes numbers are fun... not today.
__________________


If saftey is first and i put FIRST ahead of everything, then i must be the safest guy in the world.

Team 521 Alumni -- Team 1740 Mentor-- Go Go 1740!
Sometimes I think I've been doing this too long and other times I think I haven't done this enough... but all the times I'm sure I'm crazy
Photonics, It's Your Future

Last edited by Xufer : 15-02-2004 at 21:58.
  #9   Spotlight this post!  
Unread 15-02-2004, 12:33
Ryan M. Ryan M. is offline
Programming User
FRC #1317 (Digital Fusion)
Team Role: Programmer
 
Join Date: Jan 2004
Rookie Year: 2004
Location: Ohio
Posts: 1,508
Ryan M. has much to be proud ofRyan M. has much to be proud ofRyan M. has much to be proud ofRyan M. has much to be proud ofRyan M. has much to be proud ofRyan M. has much to be proud ofRyan M. has much to be proud ofRyan M. has much to be proud ofRyan M. has much to be proud of
Re: null zone

Quote:
Originally Posted by Xufer
Sorry wasnt paying attention when i posted that it was off the backup file. heres the working version.


Code:
pwm01 = p1_y;
if (p1_y >= 120 && p1_y <= 133)
{pwm01 = 127;}
else if (p1_y < 120 && p1_y > 133)
{pwm01 = (1/1635.6 * (p1_y * p1_y) - 0.16149181 * (p1_y * p1_y) + 9.10002);}
 
/******************/
 
pwm02 = p2_y;
if (p2_y >= 120 && p2_y <= 133)
{pwm02 = 127;}
else if (p2_y < 120 && p2_y > 133)
{pwm02 = (1/1635.6 * (p2_y * p2_y) - 0.16149181 * (p2_y * p2_y) + 9.10002);}
Sometimes suqre numbers are fun... not today.
A warning about this code. You use floating points in the equations. The way C works, temporary results in an equation are subject to the same limitations that the final result will be. (I.E. if you are going to ended storing the result in an unsigned char, then none of the stuff that occurs in the equation should pass 0 or 255 either, because it will wrap around.) So, your results will probably be fairly inaccurate.

Also, it may be right, but just in case, the equation is complex, make sure that it is being evaluated the way you think it is.

Somebody correct me if I'm wrong.

--EDIT--
Well, not all compilers work this way. I don't konow about this compiler.
__________________


Last edited by Ryan M. : 15-02-2004 at 14:09.
  #10   Spotlight this post!  
Unread 15-02-2004, 12:54
Tom Bottiglieri Tom Bottiglieri is offline
Registered User
FRC #0254 (The Cheesy Poofs)
Team Role: Engineer
 
Join Date: Jan 2004
Rookie Year: 2003
Location: San Francisco, CA
Posts: 3,187
Tom Bottiglieri has a reputation beyond reputeTom Bottiglieri has a reputation beyond reputeTom Bottiglieri has a reputation beyond reputeTom Bottiglieri has a reputation beyond reputeTom Bottiglieri has a reputation beyond reputeTom Bottiglieri has a reputation beyond reputeTom Bottiglieri has a reputation beyond reputeTom Bottiglieri has a reputation beyond reputeTom Bottiglieri has a reputation beyond reputeTom Bottiglieri has a reputation beyond reputeTom Bottiglieri has a reputation beyond repute
Re: null zone

check out this thread. I havent actually used this tool yet, but it seems to be what you are looking for...

lookup table
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
Robot/Goal scoring: Official Answer Mike Martus Mike Martus OCCRA 6 21-10-2003 23:51
Picture of robot starting zone? Jeff Rodriguez General Forum 2 06-01-2003 22:37
Zone Zeal Pool Joe Johnson Championship Event 31 26-09-2002 22:27
Zone Zeal Pool "Entry Fee" Joe Johnson Championship Event 21 26-04-2002 02:56
need help with time zone! Ken Leung General Forum 6 25-06-2001 12:44


All times are GMT -5. The time now is 00:04.

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