View Single Post
  #8   Spotlight this post!  
Unread 13-01-2009, 21:17
wt200999's Avatar
wt200999 wt200999 is offline
Texas Instruments
AKA: Will Toth
FRC #3005 (Robochargers)
Team Role: Mentor
 
Join Date: Mar 2006
Rookie Year: 2004
Location: Dallas, Texas
Posts: 323
wt200999 has much to be proud ofwt200999 has much to be proud ofwt200999 has much to be proud ofwt200999 has much to be proud ofwt200999 has much to be proud ofwt200999 has much to be proud ofwt200999 has much to be proud ofwt200999 has much to be proud ofwt200999 has much to be proud of
Send a message via MSN to wt200999
Re: need help understanding c code in robotdrive

Quote:
Originally Posted by mahmosh View Post

i want to understand what is float sensitivity?? what could i put on it?
and other question: can i replace speedcontroller *...... with a number of the pwm in the digital sidecar? i mean if i am using a victor and have a connection for pwm number 1 so could i write for example :
Code:
myrobot.robotdrive(1,2,3,4,float sensitivity)
the sensitivity parameter you can leave out.

As far as replacing speedcontroller if you look at the class the constructor is overloaded and one of the possible variations is:

Code:
	RobotDrive(UINT32 frontLeftMotorChannel, UINT32 rearLeftMotorChannel,
				UINT32 frontRightMotorChannel, UINT32 rearRightMotorChannel, float sensitivity = 0.5);
so you could do
Code:
myrobot.robotdrive(1,2,3,4);
then for arcade
Code:
myrobot.ArcadeDrive(stick);
for 1 joystick control
__________________
Programming in LabVIEW? Try VI Snippets!

FIRST LEGO League 2004 - 2005
FRC Team 870 Student 2006 - 2009
FRC Team 3005 Mentor 2013 -
Reply With Quote