Go to Post Ineveitably what we do just might end up in the hands of millions of people. - JoeXIII'007 [more]
Home
Go Back   Chief Delphi > Technical > Programming > Java
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
 
 
Thread Tools Rating: Thread Rating: 5 votes, 5.00 average. Display Modes
Prev Previous Post   Next Post Next
  #1   Spotlight this post!  
Unread 01-14-2015, 09:10 PM
Mr.Roboto3335's Avatar
Mr.Roboto3335 Mr.Roboto3335 is offline
Wait, What?
AKA: Jimmy
FRC #3335 (Cy-Borgs)
Team Role: Programmer
 
Join Date: Nov 2011
Rookie Year: 2011
Location: Texas
Posts: 47
Mr.Roboto3335 is an unknown quantity at this point
How do deploy code with Eclipse?

I've been trying to deploy code to the roborio for a few days now. It's not connecting to the driver station either. It finds it in eclipse but it shows this
Code:
    [echo] [athena-deploy] Copying code over.
      [scp] Connecting to roboRIO-3335.local:22
      [scp] done.
      [scp] Connecting to roboRIO-3335.local:22
      [scp] done.
     [echo] [athena-deploy] Starting program.
  [sshexec] Connecting to roboRIO-3335.local:22
  [sshexec] cmd : . /etc/profile.d/natinst-path.sh; /usr/local/frc/bin/frcKillRobot.sh -t -r;
  [sshexec] start-stop-daemon: warning: killing process 3227: No such process
BUILD SUCCESSFUL
Total time: 8 seconds
and here's the code
Code:
package org.usfirst.frc.team3335.robot;

/*----------------------------------------------------------------------------*/
/* Copyright (c) FIRST 2008. All Rights Reserved.                             */
/* Open Source Software - may be modified and shared by FRC teams. The code   */
/* must be accompanied by the FIRST BSD license file in the root directory of */
/* the project.                                                               */
/*----------------------------------------------------------------------------*/

import edu.wpi.first.wpilibj.*;
import edu.wpi.first.wpilibj.vision.*;

public class Robot extends IterativeRobot {

    private Joystick controller;
    private RobotDrive drive;
    private SpeedController one, two, three, four, lift;
    private AxisCamera camera;
    private DigitalInput limit;

    public void robotInit() {
        joystickInit();
        sensorInit();
        robotDriveInit();
        speedControllerInit();
    }

    public void sensorInit() {
        limit = new DigitalInput(1);
    }

    public void joystickInit() {
        controller = new Joystick(1);
    }

    public void robotDriveInit() {
        drive = new RobotDrive(one, two, three, four);
    }

    public void speedControllerInit() {
        one = new Talon(1);
        two = new Talon(2);
        three = new Talon(3);
        four = new Talon(4);
        lift = new Talon(5);
    }

    public void autonomousPeriodic() {

    }

    public void teleopPeriodic() {
        double y = getDeadZone(controller.getY(), 0.1);
        double x = getDeadZone(controller.getThrottle(), 0.1);
        drive.arcadeDrive(y, x);
         if (controller.getAxis(Joystick.AxisType.kZ) > 0.8) {
                two.set(-1);
            } else if (controller.getAxis(Joystick.AxisType.kZ) < -0.8 && limit.get()) {
                two.set(1);
            } else {
                two.set(0);
            }
    }
    public void testPeriodic() {

    }

    public double getDeadZone(double axis, double zone) {

        return Math.abs(axis) > zone ? axis : 0;
    }
}
does this mean it was successful? I'm so confused. This is my first time using eclipse. And if anyone knows as to the roborio's:confused not wanting to show up on the driver station, it'd be a great help.
__________________
Wait, what?
Reply With Quote
 


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


All times are GMT -5. The time now is 08:17 AM.

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