Go to Post Remind me to wear my kevlar vest to any event you're at. - Andrew Schreiber [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

 
 
 
Thread Tools Rate Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Spotlight this post!  
Unread 15-01-2003, 20:34
Adam Collet Adam Collet is offline
Registered User
#0159 (Alpine Robotics)
 
Join Date: Nov 2002
Location: Ft. Collins, Colorado
Posts: 25
Adam Collet is an unknown quantity at this point
Question Translational Drive Code

How can we code translational drive off of one joystick? Right now all I can think of is to use and inverse tangent, which obviously isn't possible. Using inverse tanget it would be (for the first quadrant):

tan-1 (p1_y/p1_x) 'then code torotate it using timing or rotation sensor
pwm1=p1_y
pwm2=p1_y
pwm2=p1_y
pwm4=p1_y 'all the motors go forward/backward now that the angle is set, based on how far the drive moved p1_y


Any ideas?
__________________
"Without the wind, the grass does not move. Without software, hardware is useless.''

Thus spake the Master Programmer

The Tao of Programming
Translated by: Geoffrey James
 


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
What is your most prefered programming language? Hailfire Programming 156 19-01-2005 21:42
1 stick drive to 2 stick drive wayne 05 Programming 18 01-04-2004 16:41
Direct drive or Chain? Suneet Technical Discussion 32 27-03-2003 23:00
TechnoKats Automated Test Drive Code Greg McCoy Programming 1 16-01-2003 17:45
"Motors and Drive train edition" of Fresh From the Forum Ken Leung CD Forum Support 6 29-01-2002 12:32


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

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