Code: Robotics
  • Code Introduction
  • TUTORIALS
    • A. Meet Your Robot
      • A-1 Circuit Board
      • A-2 Motors and Wheels
      • A-3 Other Components
    • B. Hello World Test
      • B-1 Arduino Code Editor
      • B-2 New App Template
      • B-3 Global Variable
      • B-4 Setup Function
      • B-5 Loop Function
      • B-6 Upload App to Robot
      • B-7 Add Sound
      • B-8 Use Button
    • C. Driving and Turning
      • C-1 Driving
      • C-2 Turns (Pivoting)
      • C-3 Test Wheel Encoders
      • C-4 Drive for Specific Distance
      • C-5 Pivot By Specific Angle
      • C-6 Drive Straight Continuously
    • D. Detect Objects in Path
      • D-1 Test Mechanical Bumpers
      • D-2 Detect Collisions
      • D-3 Test Ultrasonic Sensor
      • D-4 Avoid Collisions
    • E. Detect Lines on Surface
      • E-1 Test IR Line Sensors
      • E-2 Follow Line
      • E-3 Avoid Line
      • E-4 Count Lines Crossed
      • E-5 Follow and Count Lines
    • F. Detect Other Conditions
      • F-1 Detect Surface Drop-Off
      • F-2 Test Accelerometer
      • F-3 Detect If Upside-Down
      • F-4 Detect If Bumped
  • REFERENCES
    • Arduino Language
    • Arduino Code Editor
      • Create New App
      • Save and Rename App
      • Include RedBot Library
      • Verify App Code
      • Upload App to Robot
      • Download Copy of App
      • Use Serial Monitor to View Data
      • Robot Demo App Template
    • Physical Inputs
      • Push Button (D12)
      • Mechanical Bumpers
      • IR Line Sensors
      • Wheel Encoders
      • Accelerometer
      • Ultrasonic Sensor *
    • Physical Outputs
      • LED Light (D13)
      • Speaker (Buzzer)
      • Motors
    • Robot Behaviors
      • Producing Alerts
      • Driving
      • Turning
      • Detecting Objects
      • Detecting Lines
      • Detecting Other Conditions
    • Navigation Modes
      • Distance Navigation
      • Line Counting Navigation
      • Line Following + Counting Navigation
      • Autonomous Navigation
  • LINKS
    • Robotics Project Guidebook
    • Arduino Create Web Editor
    • Arduino Language Reference
    • RedBot Experiment Guide
  • ELEGOO Experiments
    • Getting the Arduino IDE
    • Starting with the `techCar` Template
    • Template Code for techCar.ino
    • Template Experiments
    • Reinstall the Original Remote App Functionality, If Needed
Powered by GitBook
On this page
  • Arduino Create (Web Editor)
  • Arduino IDE (Desktop Editor)
  1. REFERENCES

Arduino Code Editor

PreviousArduino LanguageNextCreate New App

You will use an Arduino code editor (also called an IDE – Integrated Development Environment) to create and save your Arduino apps for your robot. You'll also use the code editor to upload apps to your robot, in order to run them.

You can set up your computer to use an online code editor or a desktop code editor (though your teacher might instruct you to use a particular editor).

Arduino Create (Web Editor)

If possible, it is highly recommended that you use the online Arduino Create web editor to create and save your Arduino programs in the cloud.

The Arduino Create web editor is compatible with Windows, Mac, and Linux and with most browsers (Chrome, Firebox, Safari, and Edge). You will need to create a free Arduino account and also install a plugin (which requires Administrator privileges on your computer).

Here are steps for . The basic steps are:

  1. . Sign up with an email account that you can access which can receive outside email (some school email addresses cannot receive mail from outside the school district). Be sure to create a secure password that you will remember.

  2. After signing up, you will receive an email with a link to verify your new account. Click the link.

  3. After verifying your new account, follow these steps to on your computer (which requires Administrator privileges).

  4. Once the browser plugin is installed, login to the .

Arduino IDE (Desktop Editor)

Alternatively, you can download and install the Arduino IDE desktop editor, which saves your Arduino programs locally on your computer.

Here is the page with links to . The basic steps are:

  1. Click the appropriate download link for your computer platform (Windows, Mac, Linux). If you're using a Windows computer and do not have Administrator access, download the Windows ZIP file for non-admin install. (The Mac download is a different ZIP file.)

  2. The download page asks for a donation – however, you can click the free link to "just download."

  3. After the download is complete, locate the ZIP file in the Downloads folder on your computer, and uncompress the ZIP file:

    • On a Windows computer, right-click the ZIP file, and select "Extract All." Browse to the destination where you want to save the Arduino application (choose Desktop if you don't have Administrator privileges to install in the Programs folder), and click "Extract."

    • On a Mac computer, just double-click the ZIP file. Then drag-and-drop the Arduino application to your Desktop (or to your Applications folder if you have Administrator privileges).

  4. Double-click the Arduino application icon to start the code editor.

WINDOWS ZIP ONLY

If you installed the Arduino desktop editor on Windows using the ZIP file, you also need to install drivers for your Arduino board (the RedBot is equivalent to an Arduino Uno board). You might need Administrator privileges to install the board drivers.

  1. Connect your RedBot's USB cable to the RedBot's Mini-USB port, and connect the other end of the cable to a USB port on your computer.

  2. Place the RedBot so it is standing upright on its back end (with its wheels in the air).

  3. Turn the RedBot's Power switch to ON. (If you received an existing robot and the robot's wheels start spinning, temporarily turn the Motor switch to STOP.)

Follow these . Alternatively, you could follow these .

Getting Started with Arduino Editor on Various Platforms
Create a new Arduino account
install the Arduino Web Editor plugin
Arduino Create Web Editor
download the Arduino IDE
instructions from Arduino to install the board drivers on Windows
instructions from SparkFun to install FTDI board drivers on Windows