Go to Post Here's some food for thought: Does your FRC program need the students, or do the students need your FRC program? - sanddrag [more]
Home
Go Back   Chief Delphi > Technical > Programming
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Closed Thread
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 04-02-2016, 21:09
ForeverAlon ForeverAlon is offline
Registered User
AKA: Alon Greyber
FRC #0900 (Zebracorns)
Team Role: Programmer
 
Join Date: May 2015
Rookie Year: 2013
Location: Durham NC
Posts: 10
ForeverAlon will become famous soon enoughForeverAlon will become famous soon enough
Need help using NavX Micro with Linux on Jetson TK1

Hi Everyone,

Our team is looking to mount the NavX Micro to our onboard vision processor (the Jetson TK1) which is a Linux ARM based machine. Currently the only drivers I have found for the NavX are for Windows. Does anyone have any experience using this device with Linux or any idea how to go about implementing this. Thanks in advance.
  #2   Spotlight this post!  
Unread 05-02-2016, 10:14
RyanN's Avatar
RyanN RyanN is offline
RyanN
AKA: Ryan Nazaretian
FRC #4901 (Garnet Squadron)
Team Role: Mentor
 
Join Date: Jun 2006
Rookie Year: 2005
Location: Columbia, SC
Posts: 1,126
RyanN has a reputation beyond reputeRyanN has a reputation beyond reputeRyanN has a reputation beyond reputeRyanN has a reputation beyond reputeRyanN has a reputation beyond reputeRyanN has a reputation beyond reputeRyanN has a reputation beyond reputeRyanN has a reputation beyond reputeRyanN has a reputation beyond reputeRyanN has a reputation beyond reputeRyanN has a reputation beyond repute
Re: Need help using NavX Micro with Linux on Jetson TK1

I may be wrong, but I think the NavX (no experience with it) uses a USB-UART interface. You may be lucky and have drivers installed on the Jetson.

You can do a ls /dev/ttyUSB* to see if it shows up. You may also try a ls /dev/tty*. In my experience, they show up as a ttyUSB# device, usually 0.
__________________
Garnet Squadron
FRC 4901
Controls Mentor
@rnazaretian

Previous mentor and student from Team Fusion, FRC 364
  #3   Spotlight this post!  
Unread 05-02-2016, 10:43
slibert slibert is offline
Software Mentor
AKA: Scott Libert
FRC #2465 (Kauaibots)
Team Role: Mentor
 
Join Date: Oct 2011
Rookie Year: 2005
Location: Kauai, Hawaii
Posts: 349
slibert has much to be proud ofslibert has much to be proud ofslibert has much to be proud ofslibert has much to be proud ofslibert has much to be proud ofslibert has much to be proud ofslibert has much to be proud ofslibert has much to be proud ofslibert has much to be proud of
Re: Need help using NavX Micro with Linux on Jetson TK1

Quote:
Originally Posted by ForeverAlon View Post
Hi Everyone,

Our team is looking to mount the NavX Micro to our onboard vision processor (the Jetson TK1) which is a Linux ARM based machine. Currently the only drivers I have found for the NavX are for Windows. Does anyone have any experience using this device with Linux or any idea how to go about implementing this. Thanks in advance.
The navX-Micro has I2C and USB interfaces; not sure which interface you'd select. USB is faster, and according to this article on the web, Linux has a built-in device driver that'd work with it:

"This sample code creates a USB connected virtual COM port, using the USB CDC class (Communications Device Class.) On Linux, this class does not require a driver: it is supported directly by the kernel. Simply put, it makes the STM32F4 function similar to a USB-serial adapter."

Next, are you wanting to interface to this from C++ or Java on the TK1?

I believe your vision code is all C++.

Based upon that, my thinking is you'd USB and C++.

A place to start would be the RoboRIO C++ class sources that work w/the WPI Library. [There are Java sources that are very similar, if you choose that language instead.]

You will need to modify the "IO" module (SerialIO.cpp or RegisterIOI2C.cpp) that corresponds to either I2C or the Serial Port. And you'll need to modify the AHRS class to remove the WPI Library code that inherits from PIDSource and LiveWindowSendable.

It'll be a bit of work, but I think it's doable. James Parks on your team is familiar w/the serial protocol. And you can contact me at scott@kauailabs.com if you have any questions.
  #4   Spotlight this post!  
Unread 05-02-2016, 12:09
Joe Ross's Avatar Unsung FIRST Hero
Joe Ross Joe Ross is offline
Registered User
FRC #0330 (Beachbots)
Team Role: Engineer
 
Join Date: Jun 2001
Rookie Year: 1997
Location: Los Angeles, CA
Posts: 8,567
Joe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond repute
Re: Need help using NavX Micro with Linux on Jetson TK1

I'm curious about your vision processing architecture that makes it better to have the IMU attached to the vision processor, rather then the roboRIO. In FRC, it's most common to use the gyro to close the loop, with setpoint updates from vision processing. In that case, it's much better to have the gyro connected to the roboRIO, as you need low latency when closing the loop, but can afford higher latency on setpoint updates.
  #5   Spotlight this post!  
Unread 05-02-2016, 13:16
marshall's Avatar
marshall marshall is offline
My pants are louder than yours.
FRC #0900 (The Zebracorns)
Team Role: Mentor
 
Join Date: Jan 2012
Rookie Year: 2003
Location: North Carolina
Posts: 1,282
marshall has a reputation beyond reputemarshall has a reputation beyond reputemarshall has a reputation beyond reputemarshall has a reputation beyond reputemarshall has a reputation beyond reputemarshall has a reputation beyond reputemarshall has a reputation beyond reputemarshall has a reputation beyond reputemarshall has a reputation beyond reputemarshall has a reputation beyond reputemarshall has a reputation beyond repute
Re: Need help using NavX Micro with Linux on Jetson TK1

Quote:
Originally Posted by Joe Ross View Post
I'm curious about your vision processing architecture that makes it better to have the IMU attached to the vision processor, rather then the roboRIO. In FRC, it's most common to use the gyro to close the loop, with setpoint updates from vision processing. In that case, it's much better to have the gyro connected to the roboRIO, as you need low latency when closing the loop, but can afford higher latency on setpoint updates.
Who says you can't have both?
__________________
"La mejor salsa del mundo es la hambre" - Miguel de Cervantes
"The future is unwritten" - Joe Strummer
"Simplify, then add lightness" - Colin Chapman
Closed Thread


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 00:42.

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