|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
|
|
Thread Tools | Rate Thread | Display Modes |
|
|
|
#1
|
|||
|
|||
|
Pnuematics Programming Issues
Our team has never used pnuematics and we started this year, and we hooked up and wired up everything right according to the manuals, BUT when i try to add the compressor to the program and deploy the code my robot WILL NOT DO ANYTHING,.. does anyone know a solution to this?
|
|
#2
|
||||
|
||||
|
Re: Pnuematics Programming Issues
It would help if you can include what language you are using, and post the code you are using.
|
|
#3
|
|||
|
|||
|
Re: Pnuematics Programming Issues
i'm using Java and when i deploy this code and my compressor will pulse on when i first enable it then it will just cut off.
public class RobotTemplate extends IterativeRobot { Compressor compressor = new Compressor(1, 1); public void robotInit() { compressor.start(); } |
|
#4
|
||||
|
||||
|
Re: Pnuematics Programming Issues
Looks like that portion of your code is without errors.
When the compressor stops running, do you see any error messages printed out to the DriverStation or, if you are connected to your coding computer, in the console? Are other functions of your robot still operating when the compressor stops running? for example, can you still drive the robot around? Can you post the rest of the code from your project? Note, use the [ code ] and [ / code ] tags (without spaces) around a block of code, and it will be easier for people to read. example: Code:
public class RobotTemplate extends IterativeRobot {
Compressor compressor = new Compressor(1, 1);
public void robotInit() {
compressor.start();
}
}
|
|
#5
|
|||
|
|||
|
Re: Pnuematics Programming Issues
Hi, my team is encountering similar problems. We're also using Java, but our code is a little different.
Code:
//this is all within our main robot class
Compressor compress;
public void robotInit(){
compress=new Compressor(1,1);
}
public void operatorControl() {
while(isOperatorControl()&&isEnabled()){
if(!compress.enabled())
{
compress.start();
}
}
}
Last edited by captianjroot : 16-01-2014 at 15:37. |
|
#6
|
||||
|
||||
|
Re: Pnuematics Programming Issues
Quote:
This will only start the compressor in teleop. |
|
#7
|
|||
|
|||
|
Re: Pnuematics Programming Issues
We are having similar problems but the compressor will not turn on at all. We have the same code as the very first presented sample code. Could it be that something is wrong with our sidecar or relay?
|
|
#8
|
||||||
|
||||||
|
Re: Pnuematics Programming Issues
There are several things related to the pressure switch that could keep the compressor from turning on that are not related to the Digital Sidecar or Relay. Is the pressure switch plugged into the port defined in your code? Is the pressure switch wired between signal and ground? Is the Digital Sidecar properly powered (are all 3 power LEDs brightly lit) if you remove the DB-37 cable?
|
|
#9
|
|||
|
|||
|
Re: Pnuematics Programming Issues
The led's for power to the sidecar do turn on and I believe that the pressure switch ports are correctly assigned in the code. How exactly is the pressure switch supposed to be wired?
|
|
#10
|
||||
|
||||
|
Re: Pnuematics Programming Issues
Quote:
http://www.chiefdelphi.com/forums/sh...44&postcount=7 |
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|