Go to Post Maybe we should have some safety training before and during build instead of just having flyers at our pit. Hm... - JaneYoung [more]
Home
Go Back   Chief Delphi > Technical > Programming > NI LabVIEW
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 21-12-2015, 19:20
Caboose's Avatar
Caboose Caboose is offline
Programmer - LabVIEW, C++, C#, Java
AKA: James Parks
FRC #0900 (Zebracorns)
Team Role: Alumni
 
Join Date: Jan 2009
Rookie Year: 2008
Location: Seattle, WA
Posts: 72
Caboose has a spectacular aura aboutCaboose has a spectacular aura about
Exclamation navX Library v2 - From Team 900 - The Zebracorns

Together with KauaiLabs, Inc., Team 900 has updated the LabVIEW library for the navX-MXP and navX-Micro.
Check it out. https://github.com/FRC900/navX-MXP-LabVIEW/
__________________
navX Labview Library

"Robots are aluminum shavings, held together by zip-ties."

myManga
Reply With Quote
  #2   Spotlight this post!  
Unread 21-12-2015, 19:42
Ari423's Avatar
Ari423 Ari423 is offline
LabVIEW aficionado and robot addict
AKA: The guy with the yellow hat
FRC #5987 (Galaxia)
Team Role: Mentor
 
Join Date: Mar 2015
Rookie Year: 2012
Location: Haifa, Israel
Posts: 540
Ari423 has a brilliant futureAri423 has a brilliant futureAri423 has a brilliant futureAri423 has a brilliant futureAri423 has a brilliant futureAri423 has a brilliant futureAri423 has a brilliant futureAri423 has a brilliant futureAri423 has a brilliant futureAri423 has a brilliant futureAri423 has a brilliant future
Re: navX Library v2 - From Team 900 - The Zebracorns

What are the major changes with v2 from v1?

Also what kind of luck have you had using LabVIEW with GitHub. My team has tried it a number of times but it never seemed to work out how we wanted.
__________________
2017-present: Mentor FRC 5987
2017-present: CSA for FIRST in Israel
2012-2016: Member FRC 423
2013: Programmer
2014: Head Programmer, Wiring
2015: Head Programmer, Wiring
2016: Captain, Head Programmer, Wiring, Manipulator, Chassis, CAD, Business, Outreach (basically everything)


Reply With Quote
  #3   Spotlight this post!  
Unread 21-12-2015, 20:05
Caboose's Avatar
Caboose Caboose is offline
Programmer - LabVIEW, C++, C#, Java
AKA: James Parks
FRC #0900 (Zebracorns)
Team Role: Alumni
 
Join Date: Jan 2009
Rookie Year: 2008
Location: Seattle, WA
Posts: 72
Caboose has a spectacular aura aboutCaboose has a spectacular aura about
Re: navX Library v2 - From Team 900 - The Zebracorns

Quote:
Originally Posted by Ari423 View Post
What are the major changes with v2 from v1?

Also what kind of luck have you had using LabVIEW with GitHub. My team has tried it a number of times but it never seemed to work out how we wanted.
The biggest change is how the navX is read from, better support for Serial, and better recovery support for power issues.
In v1 SPI/I2C were read and cached if needed when ever the user would make the read request. Where as the Serial had a background loop VI running to handle the serial buffer that would dump data into global variables.
In v2 all interfaces run in a background loop VI that handles and navX reading and writing for the navX, stores the navX registry cache, handles any brownouts/disconnects to the navX, and makes sure that the latest data is always available to the user. This also allows for using a common set of VIs for reading and updating the navX and switching interfaces without the need to rewrite code. The Serial protocol can now also be switched during runtime.
The biggest thing for myself is a better organization of the files. In v1 I started with I2C and SPI as my team didn't see the need for serial. I was later asked to add Serial by Scott from KauaiLabs so that was sort of just shoehorned in. In the new version all interfaces are handled the same.

On LabVIEW and GitHub:
LabVIEW and Git are not the best of friends, but can be made to work together. Here is an NI Community Doc after a quick Google search about LabVIEW and Git.
__________________
navX Labview Library

"Robots are aluminum shavings, held together by zip-ties."

myManga

Last edited by Caboose : 22-12-2015 at 14:25.
Reply With Quote
  #4   Spotlight this post!  
Unread 17-01-2016, 18:03
Caboose's Avatar
Caboose Caboose is offline
Programmer - LabVIEW, C++, C#, Java
AKA: James Parks
FRC #0900 (Zebracorns)
Team Role: Alumni
 
Join Date: Jan 2009
Rookie Year: 2008
Location: Seattle, WA
Posts: 72
Caboose has a spectacular aura aboutCaboose has a spectacular aura about
Exclamation Re: navX Library v2 - From Team 900 - The Zebracorns

Latest Release
Fixes #9 - Missing NAVX_INTEGRATION_CTL functions
__________________
navX Labview Library

"Robots are aluminum shavings, held together by zip-ties."

myManga
Reply With Quote
  #5   Spotlight this post!  
Unread 12-02-2016, 18:03
Caboose's Avatar
Caboose Caboose is offline
Programmer - LabVIEW, C++, C#, Java
AKA: James Parks
FRC #0900 (Zebracorns)
Team Role: Alumni
 
Join Date: Jan 2009
Rookie Year: 2008
Location: Seattle, WA
Posts: 72
Caboose has a spectacular aura aboutCaboose has a spectacular aura about
Re: navX Library v2 - From Team 900 - The Zebracorns

Build v2.0.5.0
Fixes:
  • #10 - Device not open for immediate ZeroYaw.vi
  • #11 - Async processing loop not closing on robot code abort
__________________
navX Labview Library

"Robots are aluminum shavings, held together by zip-ties."

myManga
Reply With Quote
  #6   Spotlight this post!  
Unread 26-04-2016, 14:01
aeastet aeastet is offline
Programming Mentor
AKA: Tim Easterling
FRC #6043 (Allegan Tigers Robotics)
Team Role: Coach
 
Join Date: Jan 2015
Rookie Year: 2011
Location: Holland, MI
Posts: 116
aeastet is an unknown quantity at this point
Re: navX Library v2 - From Team 900 - The Zebracorns

What do you think about these upgrades?

I added a state machine to the code.
I simplified the communication.
I changed it so you only make one call to get the registry values vs calling for every vi.
I added action engines (functional globals) so that the data is easy to get into the robot code. If you drop the example two code into the periodic tasks all you have to do is open the vi and get the action engines that you what data from. Drop them in your code and it works that easy.


I wanted to get your opinion of what I did before I went any further. I would be happy to help contribute to the development of this library. I have used the NavX board for the last two years. I took the code that you developed the first year and simplified it to do only want I wanted it to do. This time I made it do everything still.

Thanks,

Tim
Attached Files
File Type: zip navX-MXP-LabVIEW-master.zip (4.33 MB, 2 views)
Reply With Quote
  #7   Spotlight this post!  
Unread 26-04-2016, 16:46
Caboose's Avatar
Caboose Caboose is offline
Programmer - LabVIEW, C++, C#, Java
AKA: James Parks
FRC #0900 (Zebracorns)
Team Role: Alumni
 
Join Date: Jan 2009
Rookie Year: 2008
Location: Seattle, WA
Posts: 72
Caboose has a spectacular aura aboutCaboose has a spectacular aura about
Re: navX Library v2 - From Team 900 - The Zebracorns

Quote:
Originally Posted by aeastet View Post
What do you think about these upgrades?

I added a state machine to the code.
I simplified the communication.
I changed it so you only make one call to get the registry values vs calling for every vi.
I added action engines (functional globals) so that the data is easy to get into the robot code. If you drop the example two code into the periodic tasks all you have to do is open the vi and get the action engines that you what data from. Drop them in your code and it works that easy.


I wanted to get your opinion of what I did before I went any further. I would be happy to help contribute to the development of this library. I have used the NavX board for the last two years. I took the code that you developed the first year and simplified it to do only want I wanted it to do. This time I made it do everything still.

Thanks,

Tim
Hey Tim,
I'm always open to feedback and/or if I'm doing something backasswards. I've tried to keep the navX library for LabVIEW as easy to use as possible. The user just needs to open the device and use the get/set VIs similar to the default FRC NI sensor VIs. Originally there was a loop VI that needed to be placed in the Periodic Tasks.vi and a Global var for the registry but when I rewrote the code I decided against that as it was an extra hoop the user would need to jump through to get started.
Looking over your code from your ChiefDelphi post, I assume this is the latest, I have a few comments. First, placing the DrvrStn Start Comm.vi loop inside your state machine will cause you to never exit the 'INI' state, never ending loops in loops. Unless you will be rewriting how the data processing is handled and the Open*** VIs, how you are currently writing the 'Action Engines' you are going to be caching a cache, and there is a small possibility where you could read across two updates with how they are decoding the data. In addition caching all of the values inside of the VIs will inflate the memory footprint of the library.
I would like to hear what your definition of easier to use is when it comes to the current library. To me it is currently on par with the native FRC NI sensors, Open -> Get/Set -> Close, the processing happens 'magically' in the background.
__________________
navX Labview Library

"Robots are aluminum shavings, held together by zip-ties."

myManga
Reply With Quote
  #8   Spotlight this post!  
Unread 26-04-2016, 16:48
Caboose's Avatar
Caboose Caboose is offline
Programmer - LabVIEW, C++, C#, Java
AKA: James Parks
FRC #0900 (Zebracorns)
Team Role: Alumni
 
Join Date: Jan 2009
Rookie Year: 2008
Location: Seattle, WA
Posts: 72
Caboose has a spectacular aura aboutCaboose has a spectacular aura about
Re: navX Library v2 - From Team 900 - The Zebracorns

Build v2.3.254
Update to match the new navX firmware 2.3.254 from Kauai Labs
  • Modified VIs which were previously limiting update rate to 60Hz (now 100Hz)
  • Modified the processing loop wait time to (1/update_rate) - 4. Empirical testing on a RoboRIO indicated that this update rate allows all 100 samples/second to be received successfully on a RoboRIO. The previous update rate was not quite sufficient, and would lead to missed updates.
__________________
navX Labview Library

"Robots are aluminum shavings, held together by zip-ties."

myManga
Reply With Quote
  #9   Spotlight this post!  
Unread 02-05-2016, 11:46
Bpk9p4's Avatar
Bpk9p4 Bpk9p4 is offline
Registered User
FRC #1756
Team Role: Mentor
 
Join Date: Jan 2013
Rookie Year: 2010
Location: Illinios
Posts: 271
Bpk9p4 is on a distinguished road
Re: navX Library v2 - From Team 900 - The Zebracorns

is there any difference between the navx-Micro and the navx-MXP
__________________
2015 Midwest Regional Finalist
2015 Central Illinois Regional Winner
2015 Newton Division Finalist
2015 Newton Quality Award
Reply With Quote
  #10   Spotlight this post!  
Unread 02-05-2016, 17:15
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: 343
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: navX Library v2 - From Team 900 - The Zebracorns

Quote:
Originally Posted by Bpk9p4 View Post
is there any difference between the navx-Micro and the navx-MXP
navX-MXP has expansion IO and mounts directly into the RoboRIO MXP port; it has SPI, I2C, TTL UART and USB interfaces. Specifically designed for plug-n-play use in FRC. Great for use as a FRC Chassis Orientation sensor. $99.

navX-Micro is smaller (2x2" square), and only has I2C and USB interfaces. Great for FTC robots, and also placing on arms and cameras on FRC robots if you want to measure their orientation separately from the Robot Chassis. $79.

Other than those differences, the sensor and motion processing firmware is the same.

The RoboRIO libraries (C++, Java, LabVIEW, Python, C#) will work with either, no code change required except to specify which interface to connect to it with.

We are aware of teams who are using both simultaneously on a FRC robot, which is also supported.

- scott

Also, please note that there's currently an issue w/reconnecting to the RoboRIO if communicating over USB if the navX-device gets reset. Kauai Labs is currently working with National Instruments to resolve this issue, but until it is resolved, we are not actively encouraging using the USB interface in competition settings. We'll notify the FIRST community once this issue has been resolved.

Last edited by slibert : 02-05-2016 at 19:26.
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


All times are GMT -5. The time now is 00:48.

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