How to install the latest Arduino IDE?

I have an Arduino UNO, which I need to get working with Ubuntu.

Can somebody explain to me the steps required to install the IDE on Ubuntu?


Solution 1:

Arduino IDE from Ubuntu's repos are usually outdated. There are three main ways to install the latest Arduino IDE: with umake, from arduino.cc tar.gz and as a snap. In all cases you may need to add your user to dialout group (if it doesn't work add it also to tty group):

sudo adduser $USER dialout

Install the latest version from Ubuntu Make (on GitHub)

Ubuntu Make is a command line tool which allows you to download the latest version of popular developer tools on your installation

  1. Install Ubuntu Make

    sudo apt install ubuntu-make
    

    If not using Ubuntu 18.04+ or want the latest versions:

    sudo add-apt-repository ppa:ubuntu-desktop/ubuntu-make
    sudo apt update
    
  1. Install Arduino IDE with umake

    umake electronics arduino
    

Warning: umake ide arduino is deprecated.

This will install it on ~/.local/share/umake/electronics/arduino. If you don't get the shortcut available you'll need to run install.sh found there.

Some other software options (like Eagle or Sublime) are not free software. I recommend instead Fritzing and Atom.io.

Install the latest version from arduino.cc

Just follow official guide (or Canonical's tutorial):

  1. Download the Arduino Software (IDE). lscpu will tell you if 32 or 64 bits. If unsure use 32 bits.
  2. Extract the package (from terminal tar -xvf arduino-1.8.2-linux64.tar.xz).
  3. Run the installation script (./install.sh).

    [1]: http://arduino.esp8266.com/p

Install the latest version using snap package

sudo snap install arduino

If you need any other Python 3 dependencies other than serial, you can install them inside the snap sandbox using the arduino.pip command.

Notes

  • Before installing you might move the folder with binaries to /opt/ or /usr/local/.
  • For ESP8266 see this installation instructions.
  • Installer don't create Launcher icon for me: Just drag it (arduino-arduinoide.desktop) from Desktop:

    screenshot


  • You also have
    • Arduino Web Editor
    • PlatformIO IDE, an extension for Atom.io or Visual Studio Code.
  • With the latest versions come newer features like the "Additional Boards Manager URLs" on Preferences (to add ESP8266 board):

    screenshot

Solution 2:

This is from notes I took when installing an Arduino. It was very helpful when I had to go through the same thing with other computers.

Install Sketch which is used to program Arduinos.
Use one of the following methods.

sudo apt-get install arduino  

or

sudo apt-get install arduino-core  

or
Open "Ubuntu Software Center" Search "arduino"

Set up the vendor ID.
Without Arduino plugged in

lsusb  

This is what I got

Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub  
Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub   
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub  
Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub  
Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub

Again with Arduino plugged in.

lsusb   

This is what I got

Bus 004 Device 003: ID 2341:0043 Arduino SA Uno R3 (CDC ACM)  
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub  
Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub   
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub  
Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub  
Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub  

Look at the addition line.
It will look something like this

Bus 004 Device 003: ID 2341:0043  

Insert the numbers that you have in the command below.

sudo modprobe usbserial vendor=0x2341 product=0x0043 

Let's get the serial port to work

cd /dev  

Without Arduino plugged in

ls

Again with Arduino plugged in.

ls  

Look for the additional tty* NAME. Mine was ttyAMC0, yours may be ttyUSB* or ttyS*.

Now we know which port it is trying to use.

The following is used to log the serial input from the Arduino. You may not need it.

sudo apt-get install minicom

//It may be already installed on your computer.

sudo minicom -s  

You will get a setup menu.

Change first line with /dev/ttyAMC0 or whatever you found in your /dev/ directory.

Save setup as dfl.

I don't know what this does I just read it somewhere and it worked.

It is on ttyACM0. When I looked at the directory /dev I found that ttyACM0 would come and go when the Ardunio was plugged in or taken out.

Install kst //This program will take a your ascii file and put it on chart.
sudo apt-get install kst

newer version will be available at some date.

Install GtkTerm

sudo apt-get install gtkterm

Configure GtkTerm to the port which Arduino is connected to. The Arduino needs to be plugged in and the serial reader in Sketch can't be on.

You should be seeing the ascii numbers scrolling on GtkTerm.

Configure the GtkTerm to log the information to a text file.

If you open the text file now you should see the data in the file. I can't remember if GtkTerm needs to be pause to read this.

Open kst. Use Data wizard to connect to the data text file with ascii.
The data should be column 1.
From here your on you own.