Installing and Using the A Tree

The A tree is the actual Arduino 101* product firmware source code and the Arduino C++ class libraries for the ARC core, tool sets and materials organized for embedded developers who want to go beyond what is possible in the Arduino IDE by targeting both cores.

Note: ALWAYS open a new terminal or new shell when you install or use the A tree after you have installed or used the M tree or Z tree.


  • x86: Arduino 101 firmware
  • ARC: Arduino sketches (.ino) or *.cpp

Supported Platforms

  • Ubuntu 16.04 - 64 bit and Ubuntu 14.04 - 64 bit


Prior to installing the CODK-A, run a software update and install curl:

$ sudo apt-get update
$ sudo apt-get install curl

Use the following commands to create a directory, clone the GitHub repository, install the dependencies and setup the environment:

$ mkdir -p ~/CODK && cd $_
$ git clone
$ cd CODK-A
$ make clone
$ sudo make install-dep
$ make setup

Note: The sudo make install-dep command will add the user to the "dialout" group, so you need to log out and log back in for the update to be effective.

Compiling the x86 and/or ARC

At the start of every development session, the following command must be run from within the CODK-A directory to set the environment.

$ export CODK_DIR=$(pwd)

Use the following commands to compile the x86 and ARC after you have installed the CODK-A.

To compile  x86:

$ make compile-x86

To compile ARC:

$ make compile-arc

The top-level Makefile builds the ASCIITable example by default. See the section "Connecting and Verifying the Board Proof or Life" for step-by-step instructions to run the example on Arduino 101 or tinyTILE board.

Uploading a Binary Image to the Board (Flashing)

Flashing Using USB/DFU

To flash the x86 binary image:

$ make upload-x86-dfu

To flash the ARC binary image:

$ make upload-arc-dfu

Flashing Using JTAG

To flash the x86 binary image:

$ make upload-x86-jtag

To flash the ARC binary image:

$ make upload-arc-jtag

Flashing Using J-Link

To flash the x86 binary image:

$ make upload-x86-jlink

To flash the ARC binary image:

$ make upload-arc-jlink

Updating the Bluetooth® low energy firmware

The Intel® Curie™ ODK requires an update of the BLE firmware. If your board is based on the factory settings, run the following command to update the Bluetooth® low energy firmware:

$ make upload-ble-dfu

The script will prompt you to manually reset the board.


See the section Software Developer Tools.

Using the Sketch Converter

For users wishing to base their ARC application on an Arduino sketch, a utility is included to convert a sketch to a C++ file.

From within the CODK-A directory, run the following commands to convert an Arduino sketch (<sketch-filename>.ino) to C++:

$ export CODK_DIR=$(pwd)
$ cd $CODK_DIR/arc/examples/<folder-name>
$ make convert-sketch SKETCH=<sketch_filename>.ino

The resulting C++ file created in the application directory will be named <sketch_filename>.ino.cpp

Copy and paste an application Makefile from another example, and edit the content to add the special libraries required. In the following example code, two libraries are required. The variable is empty for simple examples.

LIBDIRS  =  $(ARDUINOIDE_DIR)/libraries/WiFi/src \

Build and run the application as usual

$ make compile
$ make upload SERIAL_PORT=/dev/ttyACM0

Running the Application

The flashing/upload process will automatically reset the board and run the application.

Switching to Another Tree

  • Exit out of the current terminal to clear out the environment variables.
  • Restore the Arduino 101 board factory settings as explained in section Reflashing the Arduino 101 with Factory Settings 
  • Open a new terminal and use the cd command into the desired tree.
For more complete information about compiler optimizations, see our Optimization Notice.