Go to Post And I think the poll needs another option: WILL be under weight ... eventually ... just get me a drill. :D - Franchesca [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

 
Reply
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 23-01-2010, 21:34
Robopanda6 Robopanda6 is offline
Registered User
FRC #2477
 
Join Date: Jan 2009
Location: Waipahu,HI
Posts: 18
Robopanda6 is an unknown quantity at this point
Running Java Program

I have done all the updates needed and downloaded the default code into the CRIO of our bench top test, but the joysticks still don't control the motor. We enable the teleoperator part of the Driver Station but even though it says there is a code on the CRIO the motors still don't move, we even tried doing thing autonomously. Does anyone know how to properly deploy the java code?
Reply With Quote
  #2   Spotlight this post!  
Unread 23-01-2010, 21:43
NerdGuy's Avatar
NerdGuy NerdGuy is offline
Registered User
FRC #2974
 
Join Date: Jan 2010
Location: Atlanta
Posts: 16
NerdGuy is an unknown quantity at this point
Re: Running Java Program

Did you create a project and Deploy that project via the green button?

if so and it looks and it seems to be deploying check if you created multiple projects in Netbeans

We had a problem that if you deploy one project and then try to redeploy another project it just acts like it is deploying the code whereas it keeps the old code as the startup code.

So this might occur if you deployed 2 robot main classes or deployed one project and then later tried to deploy another different project.

We had to reformat and redeploy code and then it called the correct robotMain class on startup.

Or I might be completely wrong, just my theory.
Reply With Quote
  #3   Spotlight this post!  
Unread 23-01-2010, 22:38
synth3tk's Avatar
synth3tk synth3tk is offline
Volunteer / The Blue Alliance
AKA: David Thomas
no team
Team Role: Alumni
 
Join Date: Jan 2007
Rookie Year: 2007
Location: Ohio
Posts: 2,005
synth3tk has a reputation beyond reputesynth3tk has a reputation beyond reputesynth3tk has a reputation beyond reputesynth3tk has a reputation beyond reputesynth3tk has a reputation beyond reputesynth3tk has a reputation beyond reputesynth3tk has a reputation beyond reputesynth3tk has a reputation beyond reputesynth3tk has a reputation beyond reputesynth3tk has a reputation beyond reputesynth3tk has a reputation beyond repute
Re: Running Java Program

Reboot the cRIO, deploy the code again, then check to see if it's deploying the code. You'll know when it echos a statement in the console that teleop has started, and/or the "Robot Code" light on the driver station lights up.

Are the joysticks changing the LED indicator on the Jaguar? (Red or green instead of orange when pushing the joysticks).

Can you post your teleop code?
__________________
Quote:
The difference between theory and application is that in theory, theory and application are the same; In application, they are not.
Reply With Quote
  #4   Spotlight this post!  
Unread 24-01-2010, 16:02
Delian Delian is offline
Registered User
FRC #3006
 
Join Date: Dec 2008
Location: Salt Lake City
Posts: 16
Delian is on a distinguished road
Re: Running Java Program

On your output on the Classmate, is anything showing up in terms of the PWM values (Located on the upper half of the dashboard). Perhaps your PWM/CAN wiring is incorrect, and the values are being sent out but the motor controllers are not seeing them.
Reply With Quote
  #5   Spotlight this post!  
Unread 27-01-2010, 19:16
Robopanda6 Robopanda6 is offline
Registered User
FRC #2477
 
Join Date: Jan 2009
Location: Waipahu,HI
Posts: 18
Robopanda6 is an unknown quantity at this point
Re: Running Java Program

Thank you for the advice we have tried some of your theories and it is still not working. We know that the program is being deployed because we are told it the program is built successfully but...

We are using a benchtop test so we only have Victors and no Jaguars. The Victors light up and blink orange, usually if the motors are working correctly the stop flashing.

I know that we're not deploying two projects at once because I make sure to stop the previous project before deploying or running a new one.

As for the classmate I have to get back to you on the PWM but the it knows there is a robot code in the CRIO and in know that the joysticks are there.

Thank you again for the suggestions. I am open to more advice.
Reply With Quote
  #6   Spotlight this post!  
Unread 28-01-2010, 16:03
scott.paul scott.paul is offline
Registered User
FRC #3011
 
Join Date: Jan 2010
Location: Wiesbaden, GE
Posts: 2
scott.paul is an unknown quantity at this point
Re: Running Java Program

Our programming team is also having a hard time with the initial example in the Java getting started document. Our first error was a version mismatch as we had an old cRIO image. The next step was to figure out how the RobotDrive works. The Javadoc does a good job explaining the classes and constructors.

Here are a few points of interest: public RobotDrive(int leftMotorChannel, int rightMotorChannel, double sensitivity)Constructor for RobotDrive with 2 motors specified with channel numbers. Set up parameters for a two wheel drive system where the left and right motor pwm channels are specified in the call. This call assumes Jaguars for controlling the motors."

"Specification of an IO Port consists of a slot number followed by a channel number. If the port is on the lowest numbered slot/module, the slot parameter can be left out."

For the Getting Started Example, I assume that the example will have to be modified for a Victor controller or if you a higher slot number than 4 on the cRIO. I am not sure how to modify the the RobotDrive for a Victor yet.

Finally, I believe our current issue is that our project was not selected as the main project and as a result, a println from another program displayed in the output.
Reply With Quote
  #7   Spotlight this post!  
Unread 28-01-2010, 16:55
synth3tk's Avatar
synth3tk synth3tk is offline
Volunteer / The Blue Alliance
AKA: David Thomas
no team
Team Role: Alumni
 
Join Date: Jan 2007
Rookie Year: 2007
Location: Ohio
Posts: 2,005
synth3tk has a reputation beyond reputesynth3tk has a reputation beyond reputesynth3tk has a reputation beyond reputesynth3tk has a reputation beyond reputesynth3tk has a reputation beyond reputesynth3tk has a reputation beyond reputesynth3tk has a reputation beyond reputesynth3tk has a reputation beyond reputesynth3tk has a reputation beyond reputesynth3tk has a reputation beyond reputesynth3tk has a reputation beyond repute
Re: Running Java Program

Quote:
Originally Posted by scott.paul View Post
Finally, I believe our current issue is that our project was not selected as the main project and as a result, a println from another program displayed in the output.
Interesting, I never thought about that. We've recently had some issues pop up, and I'm wondering if that'll solve some, if not, all, of our problems.
__________________
Quote:
The difference between theory and application is that in theory, theory and application are the same; In application, they are not.
Reply With Quote
Reply


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

Similar Threads
Thread Thread Starter Forum Replies Last Post
Learning to Program in Java Kingofl337 Java 15 10-10-2009 10:47
running program on startup windell747 FRC Control System 2 22-01-2009 14:21
cRIO Not Running Program railerobotics NI LabVIEW 5 18-01-2009 08:48
Running program without transmitter bear24rw VEX 3 15-11-2007 23:41
Canera Calibration- Java program itsme Programming 1 20-01-2007 16:14


All times are GMT -5. The time now is 11:15.

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