Robotics Hardware

Gonzalez EV3 - "Move until Near"

Gonzalez EV3 - "Move until Touch"

Gonzalez EV3 - Taking Turns

Gonzalez EV3 - Pseudocode

Gonzalez EV3 - Displaying Text and Graphics

Gonzalez EV3 - "Turn for Angle"

Gonzalez EV3 - "Turning"

Overview: 
Introduce the main concepts, hardware and software components of the RoboRio control system.
Objectives: 

Understand the main concepts and the hardware and software components of the RoboRio robot control system.

Content: 

This lesson is the first in the "off ramp" unit for RoboRio programmers. This unit contains a detailed exploration of writing Java programs for the RoboRio. Don't forget to complete the rest of the Java curriculum starting with Unit 12.

We have been learning a lot about the Java programming language. Now its time to explore how we actually write, compile and deploy Java programs for the RoboRio (FRC) robotics control system.

RoboRio based robots use a far more complex control system than the EV3 (FLL) based robots but is similar to Tetrix (FTC) robots. At the FRC level robots engage in autonomous activity, that is, not under the control of a human, just like EV3/Tetrix robots do. However, autonomous activity is a relatively small part of the match that is played in competition. The larger portion of match time is teleoperated activity, that is, the robot is under remote control by human players. As such, the control system consists of three hardware devices, a robot controller device, a robot attached wireless router (also called the radio) and a driver station PC. The controller and driver station PC are connected over a WiFi network created by the wireless router. Your code development PC may be the same PC as the driver station or a different PC. A different PC is recommended.

The robot controller is the RoboRio device which is a Linux based computer with hardware interfaces (ports) that connect to external devices. The RoboRio hosts the Java JVM that will execute your program. The RoboRio connects to the router (via cable) which functions as a wireless access point, creating a wireless network that the driver station and development PCs can connect to. The RoboRio is manufactured by National Instruments and is also called an NI-roboRIO. The RoboRio manual can be found here. A simpler overview of the RoboRio by FRC team 2168 is found here.

The driver station (DS) PC is a Windows PC running the driver station application provided by FIRST. This application communicates with the RoboRio over the network created by the router. You attach joysticks and other control devices to the DS PC and the DS app sends input information from these devices to the RoboRio and then to your program. The driver station also has a software component called the Dashboard which is a customizable program that you can use to display information from your program or send control information to your program.

The software tools needed to write RoboRio robot control programs are:

  • Java SDK (development PC)
  • Interactive Development Environment (development PC)
  • Plugins for the Interactive Development Environment (development PC)
  • SDK for RoboRio programs (development PC)

We will discuss each of these tools and how to install them in detail.

The Java SDK is required on your development PC to be able to compile Java programs.

An Interactive Development Environment (IDE) is a tool that makes it easy to create, compile and deploy programs to devices. The IDE we will be using is Eclipse. There are plugins to Eclipse supplied by FIRST that customize Eclipse for use in developing RoboRio control programs and the plugin installer includes the SDK for RoboRio.

Note: For 2019, FIRST is switching from Eclipse to Visual Studio Code and a new build system called Gradle. This curriculum will be updated after the official docmentation for this change is published.

 

 

Navigation:

Overview: 
Explore how programming languages are used with robots.
Objectives: 

Understand how programming and programming languages apply to robots.

Content: 

In the simple view, robots are mechanical devices controlled by embedded computers. Robots typically employ sensors, to obtain input about their environment and motors or other actuators that allow the robot to act in or alter that same environment. A necessary component of any robot will be a computer (also called a controller) which is running a program that takes the available input and translates it to an appropriate output. In a robot, output typically is physical action: moving a servo, spinning a motor, etc.

A computer in a robot is different than other computers in that the robot computer has hardware extensions that allow the computer to receive input from various hardware devices (like cameras, joysticks, encoders, touch sensors) and to control hardware devices (such as motors, servos, valves). A program on a PC is typically only looking at input from a keyboard or mouse (for instance) and deciding on an output which might be displaying characters on a screen. A program on a robot is typically looking at input from a joystick or environment sensor and deciding on a physical output, which might be setting a motor speed or opening a valve. The computer interacts with external hardware devices through reading or writing data to a port (or channel) which represents the actual physical connection (plugs and wires) between the controller computer and an external hardware device.

Typically any action a robot takes is the result of the instructions in the program running on the robot's controller responding to external stimuli. In order for a robot to complete its intended function, a programmer had to study the robots intended function and its physical (hardware) design and write the source code that maps all possible inputs to the appropriate outputs, enabling the robot to perform the intended function. A robot cannot function without a program to tell it what to do.

Normally when you program a computer, you will write your program and compile it on the same type of computer on which your program will execute. For instance, when developing for Windows, you will do your programming on a Windows computer and run the resulting program on a Windows computer. Programming robots is different because you will typically develop your program on a different computer than it will be executed on. For your robotics work you will most likely develop your program on a Windows PC and then transfer the program file to a robot's controller (deploying). When you run your robot program on the EV3, Tetrix or RoboRio platform, your program is actually running on a form of Linux. It is good to keep this concept in mind when programming robots, but the Java language has specific features that minimize this as a concern. We will discuss this a bit later.

 

Navigation:

HMS STEM Robotics 101 EV3

Pages