Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   General Forum (http://www.chiefdelphi.com/forums/forumdisplay.php?f=16)
-   -   ANNOUNCING: Kauai Labs navX-MXP Upgrade, navX-Micro & SF2 (http://www.chiefdelphi.com/forums/showthread.php?t=152956)

slibert 13-01-2017 15:22

Re: ANNOUNCING: Kauai Labs navX-MXP Upgrade, navX-Micro & SF2
 
Quote:

Originally Posted by kmrchiefdelphi (Post 1630189)
Hi, after installing the latest navx_mxp jar file we are getting the following errors during deploy. We followed the Java coding steps from the Kauai Labs website. Any suggestions would be welcomed.

Thanks in advance.

[javac] RobotMap.java:3: error: package com.kauailabs.navx.frc does not exist
[javac] import com.kauailabs.navx.frc.AHRS;
[javac] ^
[javac] RobotMap.java:23: error: cannot find symbol
[javac] AHRS x = new AHRS(SerialPort.Port.kMXP);
[javac] ^
[javac] symbol: class AHRS
[javac] location: class RobotMap
[javac] RobotMap.java:23: error: cannot find symbol
[javac] AHRS x = new AHRS(SerialPort.Port.kMXP);
[javac] ^
[javac] symbol: class AHRS
[javac] location: class RobotMap
[javac] 3 errors

The info you sent suggests that Eclipse can't locate the navx_frc.jar file (the navX-MXP RoboRIO Java Library).

For 2017, the location of the navX-MXP RoboRIO Java Library has changed, to match the new standard defined by the WPI Library for 3rd-party libraries.

This new location is:

C:\Users\<username>\wpilib\user\java\lib

This actually makes things simpler to configure in Eclipse than in previous years, but it involves a change to the Eclipse library paths.

Please review the RoboRIO Java Library instructions for Configuring Eclipse Library Paths, which have been recently updated to reflect this new location.

slibert 13-01-2017 16:14

Re: ANNOUNCING: Kauai Labs navX-MXP Upgrade, navX-Micro & SF2
 
Quote:

Originally Posted by madz (Post 1629052)
Are there any FRC Java examples for turning to or driving on a heading with a tank drive like there are for FTC? The FRC examples all seem to be for a mecanum drive. Thanks!

If Kauai Labs creates a Java tank drive "straight-line driving" example using the WPI Library RobotDrive class, would your team be able to spend some time testing it? I realize everyone's busy right now...

kmrchiefdelphi 14-01-2017 09:36

Re: ANNOUNCING: Kauai Labs navX-MXP Upgrade, navX-Micro & SF2
 
Quote:

Originally Posted by slibert (Post 1630675)
The info you sent suggests that Eclipse can't locate the navx_frc.jar file (the navX-MXP RoboRIO Java Library).

For 2017, the location of the navX-MXP RoboRIO Java Library has changed, to match the new standard defined by the WPI Library for 3rd-party libraries.

This new location is:

C:\Users\<username>\wpilib\user\java\lib

This actually makes things simpler to configure in Eclipse than in previous years, but it involves a change to the Eclipse library paths.

Please review the RoboRIO Java Library instructions for Configuring Eclipse Library Paths, which have been recently updated to reflect this new location.

Thanks a lot. That was the missing step.

madz 25-01-2017 00:24

Re: ANNOUNCING: Kauai Labs navX-MXP Upgrade, navX-Micro & SF2
 
Quote:

Originally Posted by slibert (Post 1630724)
If Kauai Labs creates a Java tank drive "straight-line driving" example using the WPI Library RobotDrive class, would your team be able to spend some time testing it? I realize everyone's busy right now...


Sorry for the slow reply. We'd be happy to.

We are trying to get this to work right now, but are running into build problems just trying to test out the DataMonitor example. We followed the steps at http://www.pdocs.kauailabs.com/navx-...ibraries/java/ (three sets of eyes checked this) and are still getting an error:


...navx-mxp\java\examples\DataMonitor\src\org\usfirst\frc\ team2465\robot\Robot.java:3: error: package com.kauailabs.navx.frc does not exist
[javac] import com.kauailabs.navx.frc.AHRS;


Is there anything else we should check? This seems like a really basic thing. We've now spent two full meetings trying to figure it out. The navx-mxp jar path is right there in our Java Build Path, but its like it's invisible and gets letf out during the build.

Code:

Buildfile: C:\Users\robotics\navx-mxp\java\examples\DataMonitor\build.xml
Trying to override old definition of task classloader
clean:
  [delete] Deleting directory C:\Users\robotics\navx-mxp\java\examples\DataMonitor\build
compile:
    [mkdir] Created dir: C:\Users\robotics\navx-mxp\java\examples\DataMonitor\build
    [echo] [athena-compile] Compiling src with classpath=C:\Users\robotics/wpilib/java/current/lib/WPILib.jar:C:\Users\robotics/wpilib/java/current/lib/NetworkTables.jar: to build
    [javac] Compiling 1 source file to C:\Users\robotics\navx-mxp\java\examples\DataMonitor\build
    [javac] C:\Users\robotics\navx-mxp\java\examples\DataMonitor\src\org\usfirst\frc\team2465\robot\Robot.java:3: error: package com.kauailabs.navx.frc does not exist
    [javac] import com.kauailabs.navx.frc.AHRS;
    [javac]                              ^
    [javac] C:\Users\robotics\navx-mxp\java\examples\DataMonitor\src\org\usfirst\frc\team2465\robot\Robot.java:34: error: cannot find symbol
    [javac]    AHRS ahrs;
    [javac]    ^
    [javac]  symbol:  class AHRS
    [javac]  location: class Robot
    [javac] C:\Users\robotics\navx-mxp\java\examples\DataMonitor\src\org\usfirst\frc\team2465\robot\Robot.java:51: error: cannot find symbol
    [javac]            ahrs = new AHRS(SPI.Port.kMXP);
    [javac]                        ^
    [javac]  symbol:  class AHRS
    [javac]  location: class Robot
    [javac] C:\Users\robotics\navx-mxp\java\examples\DataMonitor\src\org\usfirst\frc\team2465\robot\Robot.java:135: error: package AHRS does not exist
    [javac]            AHRS.BoardYawAxis yaw_axis = ahrs.getBoardYawAxis();
    [javac]                ^
    [javac] 4 errors

BUILD FAILED
C:\Users\robotics\wpilib\java\current\ant\build.xml:71: Compile failed; see the compiler error output for details.

Total time: 610 milliseconds


madz 25-01-2017 09:46

Re: ANNOUNCING: Kauai Labs navX-MXP Upgrade, navX-Micro & SF2
 
Quote:

Originally Posted by madz (Post 1635990)
We are trying to get this to work right now, but are running into build problems

OK, we think there is an issue on this particular computer's eclipse. We were able to get it to compile on another computer (after refresh/clean/rebuild) but not on our main computer. It's really weird.

We'd love to test the tank drive code, though. We have a test drivetrain wired and ready to go.

slibert 25-01-2017 10:45

Re: ANNOUNCING: Kauai Labs navX-MXP Upgrade, navX-Micro & SF2
 
Quote:

Originally Posted by madz (Post 1636074)
OK, we think there is an issue on this particular computer's eclipse. We were able to get it to compile on another computer (after refresh/clean/rebuild) but not on our main computer. It's really weird.

We'd love to test the tank drive code, though. We have a test drivetrain wired and ready to go.

Glad to hear you've worked around the configuration problem. Now, let's work together on the tank drive code, and discuss what it exactly you'd like to accomplish.

With your tank drive system, is it your goal to:

- when stopped, rotate the robot to point to a particular angle?

- or -

- when moving, continue driving in a straight line?

madz 25-01-2017 11:14

Re: ANNOUNCING: Kauai Labs navX-MXP Upgrade, navX-Micro & SF2
 
Quote:

Originally Posted by slibert (Post 1636104)
Glad to hear you've worked around the configuration problem. Now, let's work together on the tank drive code, and discuss what it exactly you'd like to accomplish.

With your tank drive system, is it your goal to:

- when stopped, rotate the robot to point to a particular angle?

- or -

- when moving, continue driving in a straight line?

Thanks for offering to help! It's actually both.

We're using a naxX micro for our FTC robot so are familiar with the FTC examples (we have a consistent 100 point autonomous in FTC). We are just trying to translate that into FRC where we have much less experience.

So, for instance, we may:

(1) drive on a heading for X encoder ticks
(2) stop, and turn in place
(3a) drive on a heading for X more encoder ticks AND/OR
(3b) drive using vision tracking for X more encoder ticks

inform880 27-01-2017 20:18

Re: ANNOUNCING: Kauai Labs navX-MXP Upgrade, navX-Micro & SF2
 
Hi,

I'm using Labview (updated), and have just installed the library, but it can't find this file:

Code:

FRIC_SF2_ProcessingLoopStatesTypeDef_I2C.ctl
Any ideas on what's wrong?

slibert 30-01-2017 00:07

Re: ANNOUNCING: Kauai Labs navX-MXP Upgrade, navX-Micro & SF2
 
Quote:

Originally Posted by madz (Post 1636120)
Thanks for offering to help! It's actually both.

We're using a naxX micro for our FTC robot so are familiar with the FTC examples (we have a consistent 100 point autonomous in FTC). We are just trying to translate that into FRC where we have much less experience.

So, for instance, we may:

(1) drive on a heading for X encoder ticks
(2) stop, and turn in place
(3a) drive on a heading for X more encoder ticks AND/OR
(3b) drive using vision tracking for X more encoder ticks

Ok, there's now a FRC RoboRIO Java Tank-drive example demonstrating Rotate-to-Angle and Drive-straight techniques using navX-MXP, as well as zeroing the yaw.

Let us know how the testing goes.

- scott

aeastet 30-01-2017 09:09

Re: ANNOUNCING: Kauai Labs navX-MXP Upgrade, navX-Micro & SF2
 
Quote:

Originally Posted by inform880 (Post 1637280)
Hi,

I'm using Labview (updated), and have just installed the library, but it can't find this file:

Code:

FRIC_SF2_ProcessingLoopStatesTypeDef_I2C.ctl
Any ideas on what's wrong?

I would try reinstalling the navX-AE library again. Something must have gone wrong with your install. Is that the only file that can not be found?

inform880 03-02-2017 10:45

Re: ANNOUNCING: Kauai Labs navX-MXP Upgrade, navX-Micro & SF2
 
Quote:

Originally Posted by aeastet (Post 1638049)
I would try reinstalling the navX-AE library again. Something must have gone wrong with your install. Is that the only file that can not be found?

Sorry for the long delay, the SF2 stuff was put on hold while we had to work something else out, but now I'm back and remembered about the post. Yes, that is the only file missing, I installed it twice to try and work it out but it didn't fix it.

aeastet 03-02-2017 11:03

Re: ANNOUNCING: Kauai Labs navX-MXP Upgrade, navX-Micro & SF2
 
Quote:

Originally Posted by inform880 (Post 1639840)
Sorry for the long delay, the SF2 stuff was put on hold while we had to work something else out, but now I'm back and remembered about the post. Yes, that is the only file missing, I installed it twice to try and work it out but it didn't fix it.

You should be able to download this file from here:

https://github.com/kauailabs/navxmxp...ewae/_TypeDefs

I would just check that you have your robot project file open when you place the navX into your robot code. As far as I know I have not heard of anyone else having this problem.

madz 06-02-2017 00:26

Re: ANNOUNCING: Kauai Labs navX-MXP Upgrade, navX-Micro & SF2
 
Quote:

Originally Posted by slibert (Post 1637984)
Ok, there's now a FRC RoboRIO Java Tank-drive example demonstrating Rotate-to-Angle and Drive-straight techniques using navX-MXP, as well as zeroing the yaw.

Let us know how the testing goes.

- scott

OK, thank you for the example. We were able to pull from that and get the turns to work. We're new to FRC Java, and after struggling with it for a while today we realized that this is more like an FTC opMode (same code is called every 20 ms) and not a LinearOpMode (everything executes once and then moves on) so we are going to have to readjust our thinking so that more than one command in the sequence gets executed. Hopefully we can learn it in the next couple of weeks.

blturner 09-02-2017 10:19

Re: ANNOUNCING: Kauai Labs navX-MXP Upgrade, navX-Micro & SF2
 
We tried to use the SF2 Labview samples yesterday for latency correction. The samples seem incomplete. The top level vision example does not seem to call to the lower level VIs. It makes reference to an Action Engine in the comments which I think is a replacement for global variables but I don't see where the needed stuff gets passed back and forth.

I was hoping to add shot while driving to our robot, but this all looks more complicated than we're going to be able to deal with in the next 2 weeks.

Sorry for being negative. But I am looking forward to SF2 in the future. I suspect that I have not found the right documentation.

aeastet 09-02-2017 12:50

Re: ANNOUNCING: Kauai Labs navX-MXP Upgrade, navX-Micro & SF2
 
Quote:

Originally Posted by blturner (Post 1642438)
We tried to use the SF2 Labview samples yesterday for latency correction. The samples seem incomplete. The top level vision example does not seem to call to the lower level VIs. It makes reference to an Action Engine in the comments which I think is a replacement for global variables but I don't see where the needed stuff gets passed back and forth.

I was hoping to add shot while driving to our robot, but this all looks more complicated than we're going to be able to deal with in the next 2 weeks.

Sorry for being negative. But I am looking forward to SF2 in the future. I suspect that I have not found the right documentation.

If you send me a private message I can tell you how to use this library. I might be able to talk you through what you need to do. We made this library a little more difficult for now so only more advanced teams would use it so we can get some feedback on how it is working. My plan would be to make it easier to integrate and have a video explaining how to use it in the future.

Tim


All times are GMT -5. The time now is 05:38.

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