|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
| Thread Tools | Rate Thread | Display Modes |
|
#1
|
||||
|
||||
|
Crio does not accept new programs
Instead, it just spins the motor on port 1 at ~5% speed, weve even tried reformatting.
Help pls. The code is just a dead simple make this motor go project |
|
#2
|
|||||
|
|||||
|
Re: Crio does not accept new programs
Last edited by Mark McLeod : 01-02-2010 at 23:23. |
|
#3
|
|||||
|
|||||
|
Re: Crio does not accept new programs
Can you double-check your wiring? Odd behavior on the PWM outputs is often explained by not having the Digital Sidecar powered properly from a 20 amp breaker.
|
|
#4
|
||||
|
||||
|
Re: Crio does not accept new programs
We did make sure everything was wired goodwise. We are using java. heres the code:
Code:
/*----------------------------------------------------------------------------*/
/* 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. */
/*----------------------------------------------------------------------------*/
package edu.wpi.first.wpilibj.templates;
import edu.wpi.first.wpilibj.*;
/**
* The VM is configured to automatically run this class, and to call the
* functions corresponding to each mode, as described in the SimpleRobot
* documentation. If you change the name of this class or the package after
* creating this project, you must also update the manifest file in the resource
* directory.
*/
public class EEARGH extends SimpleRobot
{
Joystick xbox = new Joystick(1);
Jaguar motor = new Jaguar(1);
Jaguar otherMotor = new Jaguar(2);
/**
* This function is called once each time the robot enters autonomous mode.
*/
public void autonomous() {
while(isEnabled()) {
motor.set(1);
Timer.delay(5);
motor.set(0);
Timer.delay(5);
}
}
/**
* This function is called once each time the robot enters operator control.
*/
public void operatorControl()
{
getWatchdog().setEnabled(true);
getWatchdog().feed();
//boolean isReversed = false;
double speed = xbox.getRawAxis(2);
//motor.set(0);
while(isOperatorControl())
{
otherMotor.set(-speed);
getWatchdog().feed();
}
}
}
|
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Code deploys but does not save to cRIO | Bill Taylor | NI LabVIEW | 11 | 15-02-2012 20:30 |
| Downloading code: Netbeans does not reset cRIO | ellisk | Java | 8 | 31-01-2010 19:02 |
| Imaging Tool does not find cRIO | aeasson | FRC Control System | 2 | 10-01-2010 20:39 |
| cRIO Does Not Communicate, Yet Can Be Pinged and Re-Imaged | 1951-44U | FRC Control System | 7 | 15-12-2009 21:25 |
| Crio network light does not light when camera plugged in | Bongle | Programming | 16 | 16-01-2009 11:00 |