On Linux I downloaded the "AppImage 64 bits (X86-64)", copied the file
to my home directory, named it "arduino", and made it executable:
cp arduino-ide_2.0.4_Linux_64bit.AppImage ~/arduino
cd ~
chmod a+x arduino
On Linux I can run the arduino software by typing
~/arduino
Running the Arduino IDE (software) at least once before you plug a cable to an Arduino into your computer will set up the right drivers (on Windows and maybe on Macs). Just Quit to kill it (File -> Quit).
On Linux you may need to change permissions on the USB port:
sudo chmod a+rw /dev/ttyACM0
Is your battery charged yet? If not, go do something else until it is.
Throughout what follows, DON'T turn your battery on. The wheels may spin in an annoying way. Put the robot upside down, so even if the wheels spin, it has no effect.
Now connect the Arduino Nano (board says Elegoo on it) on the robot to
your computer with the micro USB cable that cable that came with the robot.
I will show some pictures of an Arduino that I took out of a robot, so we
can see it better. Here is what it looks like plugged in, with a nice red
power light that is on.
Run the Arduino IDE again. You should see something like what is below.
All Arduino programs
have two top level routines. Setup() does initialization, and then loop()
runs over and over again until you stop it.
Click on Select Board, and then click on "Select other board and port...".
You should end up looking at a window like this. Your board is an Arduino Nano,
and you should pick whatever port the software suggests. If that port doesn't
work, start over and try some other port. This is what ports look like in
Linux. On Windows they will probably be COMxx.
You may be asked if you want to update stuff, as at the bottom of this
screen capture. Just say yes.
Now let's install and run an example program that blinks an LED.
File -> Examples -> 01.Basics -> Blink puts
the example program Blink in your editing window.
Your editing window will update:
The green LED will start to blink.
Congratulations, you have run your first Arduino program!
Now try changing the program to make it blink faster.
Replace both occurences of delay(1000) with delay(100).
Press the right arrow button to compile and download.
The green LED should blink faster.
Save the program (File -> Save As) before you exit.
Choose a cute pet name for your program that isn't Blink (like my-blinky).
Then exit. (File -> Quit).
The default is for your program with the cute pet name to end up in a
directory/folder Arduino. Check it out.
Another way to set your board and port is in the Tools menu.
That setting may persist across sessions of the other one you did doesn't
(what seemed to happen to me).
Here are images of my Arduino preferences menu:
To compile, install the program
on your Arduino (upload it to the Arduino), and run it, press the right arrow button