Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   Java (http://www.chiefdelphi.com/forums/forumdisplay.php?f=184)
-   -   Talon Programming (http://www.chiefdelphi.com/forums/showthread.php?t=111526)

SBrosious 18-01-2013 11:43

Talon Programming
 
Unfortunately, we (Programmers) were asked to program the new Talons, we are new to java so we have no clue what we should manually program into our robot to work. Its been giving us issues so if you could teach me how to create a tank drive program. id be SUPER thankful :)

F22Rapture 18-01-2013 11:57

Re: Talon Programming
 
Quote:

Originally Posted by SBrosious (Post 1217950)
Unfortunately, we (Programmers) were asked to program the new Talons, we are new to java so we have no clue what we should manually program into our robot to work. Its been giving us issues so if you could teach me how to create a tank drive program. id be SUPER thankful :)

It's no different than using Victors or PWM Jaguars in code, just a different keyword.

Code:

     

        Talon frontLeftMotor = new Talon(1);
        Talon rearLeftMotor = new Talon(2);
        Talon frontRightMotor = new Talon(3);
        Talon rearRightMotor = new Talon(4);

        drive = new RobotDrive(frontLeftMotor, rearLeftMotor,
                frontRightMotor, rearRightMotor);


SBrosious 18-01-2013 13:13

Re: Talon Programming
 
Thanks you so much but for some reason it still wont move the robot, it gives recongition that its being called but no movement is there a way to set up how the axis of each joystick vary is what the speed controller should be set for. or something along the lines.?

Team3266Spencer 18-01-2013 17:04

Re: Talon Programming
 
You have to call the drive() method with a Joystick object as the parameter in the operatorControl() method.


All times are GMT -5. The time now is 09:49.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi