Log in

View Full Version : NXT Labview Training with Mindstorm Kits


Brian Holford
20-09-2011, 09:27
Hello Everyone,

For teamPrion and Grimsley Robotics FRC3215/FTC3391 I am developing a Labview training curriculum working with the NXT Mindstorm Kits.

The slides are being posted to:
https://sites.google.com/site/0123icdesign/labview_mindstorm_training

So far we have covered:

A broad introduction to navigating the Labview environment
General movement with the NXT and mindstorm
Basic Math Functions
Unit conversion with Labview
While Loops with stop conditions
Touch Sensors
NXT button input
NXT sequence flow
Shift Registers
Boolean Logic (lightly)
IF-THEN-ELSE with Select blocks in Labview
Displaying Text to the NXT screen


Hopefully this will be helpful to other teams as well.

Any feedback/suggestions are greatly appreciated.

Regards,

Brian

James Critchley
20-09-2011, 23:18
Wow, I didn't know they released a free toolkit! A comment from this external observer is that it would be great to include a link on the first slide to the NI page or simply state "goto the NI Developer Zone to install the toolkit." I was lost and Google brought up several links, none of which look like the right place to go (i.e. an official page). But the first/top was actually correct so no big deal.

Thank you!

Brian Holford
21-09-2011, 06:28
Hi James,

Great point:

The NXT mindstorms addon can be downloaded from: https://lumen.ni.com/nicif/us/evallegotoolkit/content.xhtml

It's a free software package so just fill everything out and it will provide you with the ~40meg download.

The version in the link will install directly to the FRC version of Labview 8.6.1 there are also toolkit versions for the newer versions of Labview

I updated the 2nd lesson slides to include loop timing/bandwidth

Soon to come will be Case Statements and State Machines.

Regards,

Brian

EricVanWyk
21-09-2011, 12:44
Cool project!

Disclaimer - I am a developer at National Instruments in the academic group.

You may want to consider basing your curriculum off of the more recent releases of this toolkit. These are available as modules for LabVIEW 2010 sp1.

Brian Holford
28-09-2011, 20:00
Hi Everyone,

Thanks to the National Instruments guys for a lot of feedback.

I have updated all of the slides and added several sections explaining the why behind several choices.

The slides are geared towards teaching problem solving using Labview and the Mindstorms kits, not so much Labview for Mindstorms. The problem solving approaches are simply what I have gotten to work and if anybody knows an easier/better way to do things please let me know.

The latest FTC version is Labview for Mindstorms and has several great updates that make project management easier.

For the slides I am continuing with 2011 FRC Version (Labview 8.6.1) because the goal is to bring completely new programmers up to a contributing level for the FRC team. Hands on with the Mindstorms kits provides fun hands on learning and Labview provides a great, easy to learn interface that isn't heavily burdened by syntax. 5 cute Mindstorms robots running amok is a completely different thing than a single 80lbs FRC chasis.

The core problem solving approaches should be mostly version independent but where to find things on the menus might change.

More to come!

yara92
09-10-2011, 16:47
Hi James,

Great point:

The NXT mindstorms addon can be downloaded from: https://lumen.ni.com/nicif/us/evallegotoolkit/content.xhtml

It's a free software package so just fill everything out and it will provide you with the ~40meg download.

The version in the link will install directly to the FRC version of Labview 8.6.1 there are also toolkit versions for the newer versions of Labview

I updated the 2nd lesson slides to include loop timing/bandwidth

Soon to come will be Case Statements and State Machines.

Regards,

Brian

I think I have some problem to using toolkit with version of Labview 8.6.1

Brian Holford
11-10-2011, 08:05
Hi Everyone,

Our team is making progress and the latest slides have been uploaded as Lesson 3.
The slides detail how to make a Robot Drive and Turn in response to touch sensor input.
The slides also cover how to display text onto the NXT screen and dynamically locate the text.

Topics Covered:

Case Structures with Boolean Inputs(default)
Using Flow Charts to Plot out Logic (to be updated)
Achieving Goal Specifications with Logical Event Handling
Sync Unlimited Motor Drive: Direction and Steering
"Missing Assignment to Tunnel" Errors and correction
Using the Case Logic Input Inside the Case Structure
Displaying Text on NXT Screen
String Concatenation
Text Location and Clearing
Numeric to String Conversion
Frame Rate and How it Relates to Human Vision

There is a tremendous amount of material to be covered and the slides are in the process of constantly being updated and formatted to improve clarity. If there is a particularly terrible section please let me know. There is a need to finish the training and a lot of the questions that come up in the training sessions are re-worked on the slides before posting but there isn’t always the time to do so. The target audience is a self-motivated inexperienced programmer.

Next Lesson is on Finite State Machines...

To Mohamed:
If you could provide more details on what isn’t working we can possibly help you get things working properly. Make sure that you have the correct versions of everything installed. National Instruments has really great tutorials and instructions for getting started.

Our team had significant challenges 2 years ago(my rookie year) with the FTC and FRC versions of Labview on the same computer. There is a proper install order that must be followed in order for the versions to co-exist. Perhaps the gentlemen from NI can post a link to the explanation of the proper install order.

Regards,

Brian

yara92
13-10-2011, 16:46
Hi Brain1
Actually I am trying to use Connecting the NXT to TETRIX™ Elements Attaching HiTechnic Controllers and just to use simple program LV. Always I have something wrong sometimes with the Versions. Attachment some pic of this errors.
Is there anything that I can use just to controlled the Tetrix Motores with the NXT and program it by my LV version 8.61 last year FRC.
The reason for that I won't to Mentored my new kids at the team to understand the basic of robotics since using what we have, we have no extra money to by new programs or versions
Team 1946


10979

10980

10981

Brian Holford
23-10-2011, 15:27
Hi everyone,

I have uploaded the 4th unit section on Finite State Machines in Labview.
https://sites.google.com/site/0123icdesign/labview_mindstorm_training

The examples created are:
A speed controller like a ceiling fan
A up/down numeric counter
A Multi-Click Counter

Finite State Machines Topics Covered:

What they are
State Diagrams
Mealy vs Moore
Why and where to use
Determining States
Abstraction and Black Box Design
Speed Controller
Identifying the Task from Specifications
Drawing the State Diagram and Identifying the States
Identifying the Transitions
Determining the Output Response
Converting the State Diagram into a Labview Program
Mapping States to Cases of a Case Structure in Labview
Debugging an NXT program
Using Numeric, Strings, and Enumerated Data Types as input to Case Structures
Converting from a Moore machine to a Mealy machine
Local Variables in Labview
Sample Rate and iteration based timing and delays



A few slides were also used to establish that mistakes are an important part of learning and encouragement to dig into things when they don't work properly.

I'm actively working on all of the lessons(units really) and the information in each is somewhat dynamic still.

To Mohamed: (check your messages)

The concepts employed in the curriculum are typically how these problems would be solved in a hardware solution. The overall problem solving concepts are portable to any language, particularly other versions of Labview. Labview and the Mindstorms Kits are used as teaching tools that provide real-time, hands on feedback.

The real FRC environment with the cRIO hardware is easier to work in because of the feedback structures and more flexibility with the case structure inputs and Framed Sequences!
Team 358 has a very helpful website that describes how to solve several common tasks in the Labview FRC environment
http://team358.org/files/programming/ControlSystem2009-/LabVIEW/

Regards,

Brian

Greg Shaw
23-10-2011, 17:11
I am very excited to see this post. Last year we were a rookie FRC team (3601). We conquered a lot of the learning curve but our programming was done mostly by our mentor team. This year we are gearing up for FRC season #2 and we just got a grant to do FTC with some middle school kids. Between my high school FRC kids and my middle school FTC kids I am hoping we can figure out Labview. Also, we just picked up a new mentor with programming experience. He does not know labview but he has past programming experience . Thank you very much for creating and posting this tutorial. Any other tips for conquering programming are appreciated.

Brian Holford
04-12-2011, 18:08
Hi Everyone,

Two new Sections have been added to:
https://sites.google.com/site/0123icdesign/labview_mindstorm_training

Labview_Mindstorms_trackingsystems_Lesson5
Introduction to Discrete Time Tracking Systems

transducers
Introduces analog to digital converter topics
Sample rates
How electronics can see faster than people
Closing the Loop (but without going into DiffEQ or feedback theory)
Edge Avoiding Robot (Because everyone in the world has done a line tracker)
calibrating software for a real world analog sensor
Step Size and Speed
Experimenting with how fast a motor can run

Mindstorms_Lesson6_SndCtl
Explores the development and considerations of a Sound Controlled Robot
The importance of breaking down a complex program into steps
starting with something very basic
Then adding error and exception handling to improve robustness
That mistakes happen and how to fix them
Sound from Continuous versus non-continuous sources
The pain of "One off" errors
Creating Sub-Vi's
Appendix's for
A) Modulo based periodic functions
B) Tracking of a Continuous Time Sound

These presentations are still being improved and I'm not yet satisfied with the handling of the material. Tomorrow will be the 3rd week on the Sound Controlled Robot.

The next and possibly final section is going to be on how to develop a joystick interface since the build season is rapidly approaching. I might just provide the code and let the students have fun with the robots with the time of year and all. Time will tell.

Regards,

Brian
http://brainSTEMeducation.com

Brian Holford
17-12-2011, 22:07
Hi Everyone,

I have put together a Labview guide for established programmers: How to do normal programming tasks in a Labview environment.

The guide can be found here:
https://sites.google.com/site/0123icdesign/labview_mindstorm_training/LabviewforProgrammers.ppt?attredirects=0&d=1

Sections 5 and 6 have also been updated since the last post...
https://sites.google.com/site/0123icdesign/labview_mindstorm_training

Regards,

Brian

Brian Holford
06-09-2012, 06:36
Hi Everyone,

I have updated Lesson 1 for the latest version of labview and I'm working through the rest of the material as the fall training season progresses.
https://docs.google.com/viewer?a=v&pid=sites&srcid=ZGVmYXVsdGRvbWFpbnwwMTIzaWNkZXNpZ258Z3g6OGQ1 ZDJmMzFjYmMxMTY0

I have also updated the state machine training sections but haven't posted those yet.

https://sites.google.com/site/0123icdesign/labview_mindstorm_training

Brian Holford
29-10-2012, 22:26
New Material just posted (rough draft form) on Loops, Case Structures, Local Variables, Real World Time and Math as demonstrated with getting an NXT to play the Star Wars Intro Theme

https://docs.google.com/viewer?a=v&pid=sites&srcid=ZGVmYXVsdGRvbWFpbnwwMTIzaWNkZXNpZ258Z3g6NDdl ODk5ZGEwYTIxN2ExNg

Star wars source code can be found in the files of:
https://sites.google.com/site/0123icdesign/labview_mindstorm_training

Also, a list of exercises to understand real world timing of loops on an embedded system (NXT)
https://sites.google.com/site/0123icdesign/labview_mindstorm_training/loops

regards,

Brian