Sunday, May 24, 2015

Programming - An Overview

[Update 1: Added more info and tons of links]
[Update 2: Diagram Updated]
[Update 3: Vision links added]

In the last few days, weeks, and months we have discuss programming and programmers in a way that typically speaks to the robot and the code that runs in the Roborio.

The bigger picture is...well....bigger.

Take a look at the following block diagram, which is a quick and dirty overview of the various "programming" areas that are present in an FRC team.




Some of these are optional, such as a scouting app (vs Excel or simply paper), and some have many ways of being accomplished, like the robot code itself which can be run in Java, C++, LABView, and even Python.

In the next few days, this diagram is going to be expanded to show the various languages/methods that each task can be accomplished.

For all of the official FRC code and libraries, simulator, and extensive documentation, check out the webpages of the 2015 FRC Control System

So, what are all of the blocks?

On The Robot:
roboRIO - the main robot controller
navX MXP - robotics navigation controller
Leonardo++ - a rugged version of the Arduino Leonardo


LEDs - discrete LEDs to indicate sensor status to the drive team
LED Light Strips - either static strips, or dynamic strips like the NeoPixel

Vision:
Jetson TK1 - vision processor and more
Camera - Microsoft HD3000 or other USB webcam

Examples of how a Jetson TK1 can be used for vision processing are described in this white paper.
What does it look like? Here is a video that shows it in action.

At The Driver's Station:
Drivers Station Software
Smart Dashboard Software
Network Tables

Custom Interface:
TI Launchpad - the interface behind a custom driver station
Button Box - an interface box that the team imagines, designs, and builds to provide buttons/lights for secondary tasks. Takes the place of buttons on the joysticks for easier use and to reduce accidental hits on the small buttons. Examples here, here, and here.

- or -
The custom interface could be a tablet app running a program that accesses the network tables. There is a Python version available on Github.

Simulation:
Before I get to the list of simulators that are available, one quick note.....
Having a working simulator for our robot is critical to reducing the jam up that occurs during the build when everyone is jockeying for space on and around the robot. Being able to take program testing away from the robot itself will GREATLY improve our teams ability to produce a useable robot.

There are several simulators available for FRC robots. The official one is FRCSim and is available here: Using FRCSim with C++ and Java

A thread on ChiefDelphi has a list of several RecycleRush simulations:
http://xantaz.netne.net/FRC2015game/WebFRC2015.html
http://acsrobotics.com/recycle-rush/
https://www.dropbox.com/s/uh1gnpbldf...eRush.rar?dl=0 (downloadable for the link above)
http://acsrobotics.com/recycle-rush-3151/
http://team537.org/about-us-2/team-s...imulator-2015/

Also, just about any Java coding that needs to be tested that doesn't require dedicated hardware can be done either in a desktop environment, or on one of the sims listed above.

Scouting:
Many teams utilize sophisticated methods to enter, collate, and manage scouting data during matches. This is an area where we have started with a simple system and have barely scratched the surface of what is possible.

Team Website, Twitter Page, Instagram, Mailing List, Newsletter:
While this may not seem like a "programming" area, the fact is that all of these things either do have code, or may have code. The website does for sure, but what about the newsletter mailing list generator scripts...for example.

Software and Library Maintenance:
All of these areas have code, functions, notes, test results, etc.. that have to be maintained in some form or fashion. The robot code is housed on Github and is well maintained. The rest of the code has to have a home, and a person or people to keep track of it all.

Sunday, May 17, 2015

Drivetrain Development

Beyond the basic 2015 KOP drivetrain that is 6 wheel/tank drive/4" wheels, there are many other options.

The biggest wow factor has to come with swerve or mecanum. But, there are also variations on tank drive that shouldn't be forgotten.

Tank Drive Options:

  • Number of Drive Wheels: 4, 6, or 8 ... or more?
  • Wheel Size: 4" or 6"... or even 8" ...or maybe even 3.5" wheels
  • Wheel Type and Combination: 
    • 4 or 6 Regular treaded wheels,
    • 4 wheel Omni
    • 6 wheel center treaded, Omni on the corners
    • Omnis only on the front

One team is working on a test chassis that allows for ALL of these combinations.

The description of it is HERE.

This is just one example. A really well thought out example, but just one.

The general idea is to have a multi-purpose platform to build and test ideas in the mechanical side with frame design, frame geometry, build quality experience and speed. On the software side, this is the platform to work out better control methods, drivability, sensor usage, etc... 

What would/should 5190's next platform look like? 

What would it be made out of? 
My vote on this is Versa-everything. 

Here are a couple of guides that everyone should read.

For completeness, here are the various chassis "systems" that are available out there:
Vex Versa Chassis - Vex couldn't have made this stuff any easier. Look at the application guides on the link page. Or go here, here, or here.


For a cool....COOL....internal run drive chassis where the chain is inside 2x1 tubes
AndyMark - Lots of KOP stuff

Others? Leave a comment!

But, the team has to decide what to do, and what to do with Ghost, Lofty, and don't forgot Mosquito sitting under the table collecting dust. What will Ghost-2, SuperLofty, or SonOfMosquito look like??

Thursday, May 14, 2015

One of the things that we discussed continuously during the build season was path planning and motion control. That is, what are the moves that the robot will make in autonomous mode and how do we get from here to there in the fastest, smoothest, and most controllable way.

As with many things FRC, there are several discussions on ChiefDelphi going back years, with examples. Several teams have also posted their robot code.

The main problem for me has been understanding how to implement the information in OUR robot.

This year, there was another thread here, and here, AND a presentation that puts it all together. AND, java source code that could be run on a PC to play and learn.

So, I did just that....played and learned.


The two panes on the right are a velocity/time and path. Straight line go using a trapezoidal velocity profile. The two panes on the left are another one where the path is a bit crazy, even looping over itself. The velocity profile is pretty cool too.

Here is the code I ended up with to get the plots in the picture. I think the Eclipse project info is also in the zipped directory.

Wednesday, May 13, 2015

Hi Everyone.

This is going to be a place for me to share lots of robotics-related stuff (articles, pictures, info, blogs, etc...) that I have found interesting.

There are so many things that I have seen over the last few months that would be great to share and discuss with different team members. What is clear to me is that I don't know what everyone on the team is interested in either.

Wouldn't it be cool to get dialogues going on all the different topics that we deal with on the robotics team? Lets see how it goes.

Ty