# Programming Arduino with Android and Windows Tablets

## Overview

![](https://cdn-learn.adafruit.com/assets/assets/000/013/454/medium800/microcontrollers_tablets_bento.jpg?1388769758)

Making on the go gets easier every year. With your hacking parts bundled with a computer, you travel to class, the makerspace, or a friend's house and build your favorite circuits. Up to noe, this probably meant carrying around a bulky laptop. But the weight and the value of your primary computing device probably makes that option unappealing ("if my Macbook or laptop were to break, I'd be sunk!").  
  
Fortunately you have some great alternatives today at very reasonable price points. Android tablets with modern versions of the Android operating system can be found below $200. In addition, there is a new crop of modern tablets powered by the Intel Bay Trail CPU and run full versions of Windows 8.1 (not the restricted Windows RT system). You can opt for the full Surface Pro system but that is nearly as bulky as an ultrabook. New 7" and 8" class tablets with high definition screens ("more pixels than retina"), make a much more portable alternative.  
  
With a full Windows system, you have the gamut of developer tools at your fingertips. The Arduino IDE runs well and you can access code from the web, from the cloud, or locally.   
  
With Android, you cannot directly install code from the Arduino project as Android is not a supported operating system. But there are programmers porting the Linux versions to Android.  
  
The main method to communicate from tablet to microcontroller is the USB port. Tablets most often have microUSB ports conforming to the portable OTG (On the Go) specification which is great as they can act as serial ports for peripherals or as mains to control things. [A simple OTG cable, available in the Adafruit shop](http://www.adafruit.com/products/1099 "Link: http://www.adafruit.com/products/1099"), allows the tablet to communicate with outside devices. For an Arduino Uno, you can then use the [regular](http://www.adafruit.com/products/62 "Link: http://www.adafruit.com/products/62") (or [6 inch](http://www.adafruit.com/products/900)) A to B cable. Other boards may require mini or micro USB cables. The OTG cable provides a standard size A socket, making mating cables straightforward.  
  
An appealing alternative to cables is Bluetooth. For Windows, we'll cover programming an Arduino Uno wirelessly via the Adafruit [Bluefruit EZ-Link board](http://www.adafruit.com/products/1588) and [shield](http://www.adafruit.com/products/1628).  
  
These tablets are photographed with the Arduino Uno and [LadyAda's Bento Box](http://www.adafruit.com/products/765), a portable "hack and pack" solution. Bento makes a great carry case for your projects and is about the same size as these new tablets.

### 

Adafruit's [Learn Arduino series](http://learn.adafruit.com/lesson-0-getting-started) is the perfect place to start learning Arduino basics.

# Programming Arduino with Android and Windows Tablets

## Windows Tablets

![](https://cdn-learn.adafruit.com/assets/assets/000/013/459/medium800/microcontrollers_Windows_bento.jpg?1388774059)

Portable microcontroller programming dates back to 1984 and the introduction of the Compaq luggable PC. Lately, it typically involves carrying a laptop to program via USB. But if you believe your laptop is too heavy (or too expensive to risk carrying around willy-nilly) there are new alternatives coming out on the market.  
  
The Dell Venue 8 Pro is typical of a [new class of tablets](http://www.intel.com/content/www/us/en/tablets/shop-tablets.html) from Dell, Toshiba, Lenovo, Acer and others offering a full Windows 8.1 environment in an 8 inch form factor, available in the $200 range. This is a perfect size for portable computing and hacking. These devices include Bluetooth 4.0, 802.11n wifi, microSDXC card slot and microUSB OTG connection.  
  
Note: This tutorial does not explain how to use the Arduino on the Windows RT operating system which is not supported software-wise by the Arduino Team. This tutorial discusses using a tablet with the full Intel-based Windows operating system.![](https://cdn-learn.adafruit.com/assets/assets/000/013/073/medium800/microcontrollers_DV8P-Uno.jpg?1388157290)

## Cabling
You will need a microUSB male OTG to A female cable [available from Adafruit](http://www.adafruit.com/products/1099) and many mobile shops at a reasonable price. This will provide you a full A male connection to plug in a cable to fit your microcontroller. For our Uno example, you would want a standard USB A to B cable (Adafruit sells [long](http://www.adafruit.com/products/62) and easy to pack [short](http://www.adafruit.com/products/900) versions).  

## Arduino Uno Driver
The good news: Drivers for nearly any Arduino are available for Windows. The bad news: Windows 8.1 really, really hates installing unsigned drivers like those supplied for the Uno by the Arduino team. Some tablets may provide provision to go into recovery and allow unsigned drivers. The procedure to do that is [described here](http://www.howtogeek.com/167723/how-to-disable-driver-signature-verification-on-64-bit-windows-8.1-so-that-you-can-install-unsigned-drivers/). Note this may be nearly impossible with the Dell Venue 8 Pro and other tablets enabling Bitlocker to protect the main drive.  
  
If you cannot use the method above to load the unsigned driver included with the Arduino IDE and until there are signed drivers (which should install "normally"), there is a workaround. [This blog post](http://dawdevel.blogspot.com/2012/12/arduino-uno-on-windows-8-without.html) and the accompanying [Youtube video](http://www.youtube.com/watch?v=CdE72XUYC7k&noredirect=1 "Link: http://www.youtube.com/watch?v=CdE72XUYC7k&noredirect=1") go through the steps of loading a signed driver. It installs as a Richochet Wireless USB Modem which is compatible with the Uno.   
  
If you use an Arduino device with FTDI such as Duemilanove or compatibles (NOT UNOs!), there are signed drivers for Windows 8.1 at [http://www.ftdichip.com/Drivers/VCP.htm](http://www.ftdichip.com/Drivers/VCP.htm) (check your version of Windows 32 or 64 bit in the Control Panel, System option). Yes, these are hacks but easy ones. If the Arduino team publishes a signed driver, the modem hack will no longer be needed. It is discussed in their forums at [http://forum.arduino.cc/index.php?topic=205837.0](http://forum.arduino.cc/index.php?topic=205837.0).  

## The Arduino IDE
You may download the Arduino software (integrated development environment or IDE) from the [arduino.cc](http://arduino.cc/en/Main/Software) website. You can alternatively load [version 1.05 from Adafruit](http://learn.adafruit.com/getting-started-with-flora/download-software) with built-in support for Flora, Gemma, and Trinket. If you have SD card storage, you may want to install the software to the card to save flash on 32GB tablets.  
  
Once the IDE is installed, click the desktop icon to get to the Windows desktop. Double-click the Arduino icon and you will be in the development environment. Load the included Blink sketch by clicking File then Examples then 01. Basics then Blink. A new window opens with the Blink software sketch.   
  
Ensure your OTG to Uno cable from the previous section is connected from the tablet to the Uno. The Uno should have the power LED on, powered from the tablet. Use an external power supply for the Uno to save tablet battery life. Set the environment for download by clicking Tools, then Board, then select "Arduino Uno" from the list. Go back to the Tools Menu, then Serial Port, then you usually select the last port (COM7 in my case). You can look up which COM port the Arduino uses by opening Control Panel, then "Devices and Printers" then look for the Arduino Uno. If the communications port is not listed, you can right click the icon, select Properties then click the Hardware tab to see which COM port is listed.   

## Load a Program
Ensure your tablet is connected to the Arduino Uno with the cables noted above. The power light should be lit on the Uno.   
  
To upload the Blink sketch to the Uno, select the right arrow icon. The yellow LED neat the Uno's Pin 13 should now be blinking. The process may take a few seconds longer near the end as the compiled code loads to the Uno.  
  
You can load your own code via a network connection, downloaded from the local flash drive or from a microSD card. When you save programs, I suggest a microSD card as the 32GB flash on the Venue 8 Pro is not a huge amount for a Windows installation (Dell includes Office which bloats the device).![](https://cdn-learn.adafruit.com/assets/assets/000/013/074/medium800/microcontrollers_DV8P-Uno-I2Cdisplay.jpg?1388158312)

## Trinket and Gemma
A Windows tablet will recognize Trinket and Gemma if you have the correct OTG MicroUSB to USB and USB to mini USB cables. You must install the [USBtinyISP driver](http://learn.adafruit.com/usbtinyisp/download). Just like the Uno driver, it is unsigned so Windows will probably complain and not install the driver. For Windows 8.1, that means again [rebooting into recovery](http://www.howtogeek.com/167723/how-to-disable-driver-signature-verification-on-64-bit-windows-8.1-so-that-you-can-install-unsigned-drivers/) to allow unsigned drivers. On my Dell Venue 8 Pro this is very problematic due to Dell enabling Bitlocker and no physical keyboard attached to type in prompts. # Programming Arduino with Android and Windows Tablets

## Bluetooth with Windows Tablets

![](https://cdn-learn.adafruit.com/assets/assets/000/013/456/medium800/microcontrollers_Windows_bento.jpg?1388770117)

## Bluetooth Use
With the newly released [Bluefruit EZ-link board](http://www.adafruit.com/products/1588) and [shield](http://www.adafruit.com/products/1628), you can download your programs without the cable (freeing the tablet for charging).   
  
For the Bluefruit EZ-link board (above), wire to Uno [per the tutorial here](http://learn.adafruit.com/introducing-bluefruit-ez-link/arduino-programming).The shield (below) is a little easier to use since it just plugs on top, but I had a breakout handy and it only takes a few wires to connect it  
  
The benefits of using Bluetooth is that there's no wonky driver nonsense. Bluetooth is built into every single tablet and replaces the "FTDI" or "Uno" driver requirements!  
![](https://cdn-learn.adafruit.com/assets/assets/000/013/460/medium800/microcontrollers_windows-bento-shield.jpg?1388777127)

Info: 

Pairing to EZ-Link on a tablet is just like doing so on a computer: Power up the circuit. Pair the EZ-link via [this tutorial](http://learn.adafruit.com/introducing-bluefruit-ez-link/pair-and-test).   
  
If you go to the Windows 8 desktop, the Bluetooth icon is in the notification area, lower right (you might have to tap the little up arrow to see all the icons, the Bluetooth icon is a blue oval with a B on it). Select **Add a Bluetooth Device** from the menu. You may need to press the Bluefruit "Pair" button on the circuit board. Your tablet should detect something is pairing and load the driver for you (warning - this can take a minute). If your Bluefruit is listed but will not connect, delete the current entry, press the pair button, and it should rediscover the device and allow pairing.   
  
To make sure you have the right COM port, right-click (or press and hold with touch) the Windows icon in Windows 8.1 lower left corner of the screen. Select **Control Panel**. In **Control Panel** select **Devices and Printers**. You should see an Adafruit Bluefruit icon near the bottom of the icon list per the [Bluefruit tutorial](http://http//learn.adafruit.com/introducing-bluefruit-ez-link/pair-and-test). Double click the Adafruit EZ-Link icon then click the Hardware tab. It should say: **Standard Serial over Bluetooth link (COM3)** - it might have a different COM number, no problem, just note it.  
  
In the Arduino IDE, go to the Tools Menu, then Serial Port, then select the COM port you just discovered which belongs to Bluefruit.   
  
If your circuit is built correctly, you can now remotely send a program over Bluetooth to your Uno. The capacitor from Bluefruit DTR pin to the Uno Reset pin is required to have the sketch auto-reboot when loaded. If you do not have one, just push the Uno RESET button after the sketch loads.  
  
Note the load process takes longer wirelessly than with USB. It will work, it just takes 60-90 seconds.

http://youtu.be/2ir_SDi9V3w

# Programming Arduino with Android and Windows Tablets

## Android Tablets

![](https://cdn-learn.adafruit.com/assets/assets/000/013/458/medium800/microcontrollers_android_bento.jpg?1388770563)

The Arduino team does not publish native Android versions of the Arduino IDE. Fortunately Anton Smirnov has come to the rescue with his program ArduinoDroid. It is available from the Google Play app store (free ad-supported, ad-free is $2.99). Load the program and you will have an icon in your all apps listing.  
  
For this part of the tutorial, I will be using a Google/Asus Nexus 7 (2013 version) which has a 7 inch screen and weighs 0.64 pounds. It has dual band wifi 802.11 a/b/g/n, Bluetooth 4.0, and near field (NFC). The base model has 16GB flash and 2GB RAM. It has a microUSB port with OTG (on the go) main and secondary capability. There are a great variety of Android devices using various versions of the Android operating system. Other devices might not be compatible with OTG USB ports or the ArduinoDroid program.

Danger: 

![](https://cdn-learn.adafruit.com/assets/assets/000/013/076/medium800/microcontrollers_Nexus7-Uno3.jpg?1388160877)

## Cabling
You will need a microUSB male OTG to A female cable [available from Adafruit](http://www.adafruit.com/products/1099) and mobile shops at a reasonable price. This will provide you a full A male connection to plug in a cable to fit your microcontroller. For our Uno example, a standard USB A to B cable (Adafruit sells [long](http://www.adafruit.com/products/62) and easy to pack [short](http://www.adafruit.com/products/900) versions).  
  
You may want to power the Uno from a separate power supply - if you use USB power, it will shorten your tablet battery life depending on the current draw and could exceed the power that can be drawn if you connect shields or other devices.  

## The ArduinoDroid Program
The program does not look like the typical Arduino IDE. It is a blank canvas with line numbering. If you turn the tablet in portrait mode, you can have the IDE and keyboard visible at the same time. You use the ... icon in the upper right to select what to do: load a file, or other actions you would do with the Arduino IDE menu bar. If you navigate to Sketch then Examples, you can go to 01. Basics and select the Blink example sketch.   

## Load a Program
You can download your own code via USB (like a flash drive), via Google Drive to a local folder or by cut and paste from a browser. The program is also designed to work with Dropbox (an additional fee may apply). You can select Sketch, then Open and you can select a recent sketch from the device or from Dropbox. Likewise Sketch -\> Save as will save to the tablet local folders or to Dropbox.  
  
The text is color-coded and is edited like any text file.  
  
You can upload your sketch to the Uno by getting the menu using the ... icon, then Actions then you can Verify/Compile. Once it compiles cleanly use the same menu to select upload. I initially had an upload error but the code loaded. Subsequent uploads worked fine.![](https://cdn-learn.adafruit.com/assets/assets/000/013/075/medium800/microcontrollers_Screenshot_2013-12-26-Android.png?1388159635)

## Bluetooth
As of this tutorial's release, ArduinoDroid lacks a method or sending the program via Bluetooth although the author is considering it.  
  
However, once you have your Arduino programmed, there are a wide variety of programs that can initiate Bluetooth communication with an Arduino connected to an Adafruit Bluefruit EZ-Link or Shield. Look in the Google Play app store, search for the term "arduino". # Programming Arduino with Android and Windows Tablets

## Going Further

It is anticipated that portable computing will expand in coming years with new technologies from Intel and manufacturers leveraging low cost, powerful ARM devices.  
  
Sub-$200 portable computing is an exciting development. Certainly these methods will work on many larger devices also.

# But What About iDevices?
Apple devices are harder to interface due to the lack of standard USB ports. MakerShed markets the [RedPark TTL iOS Cable](http://www.makershed.com/Redpark_TTL_Cable_for_iOS_p/msrp03.htm) to interface Apple products with the older dock connector. Apple Bluetooth lacks the SPP protocol required to interface with serial devices like Adafruit Bluefruit.  

# Arduino Devices Other than Uno
Communicating between Android and Arduino Mega, Leonardo, Micro, and Duemilanove should be straightforward and are listed in the ArduinoDroid board type list. The developer is active so more devices may be added but it would appear to be a 1.05 IDE fork so support for Arduino Due, Yun, and Galileo are probably not expected until a major revision  
  
For Windows tablets, most boards should work but it could take some experimentation.  
  
Programming Adafruit's Trinket and Gemma are currently beyond Android. For Windows tablets, installation of the Adafruit tweaked 1.05 IDE works well. You must also be able to install the USBtinyISP driver. On Windows 8.1, the unsigned driver will probably be very problematic.  

# Interaction between Arduino Projects and Tablets
There are programs for many operating systems that allow interaction between an Arduino project and a computer via Wifi, Bluetooth, or USB. That discussion would be lengthy enough for a separate tutorial.   
  
To get you started, there are Android programs in the Google Play store if you search for "Arduino".   
  
On a simpler level, nearly all operating systems can open a terminal or command prompt. If the device can open a serial stream over the communications channel, you may be interacting with your Arduino project.
## Featured Products

### USB OTG Host Cable - MicroB OTG male to A female

[USB OTG Host Cable - MicroB OTG male to A female](https://www.adafruit.com/product/1099)
This cable looks like a USB micro cable but it isn't! Instead of a USB A Plug, it has a USB A Socket on the end. This cable is designed for use with OTG (On the Go) host devices (like the Arduino Due or many tablets) so you can connect a mouse, keyboard, or any other USB device. You'll...

In Stock
[Buy Now](https://www.adafruit.com/product/1099)
[Related Guides to the Product](https://learn.adafruit.com/products/1099/guides)
### USB Cable - Standard A-B

[USB Cable - Standard A-B](https://www.adafruit.com/product/62)
This here is your standard A-B USB cable, for USB 1.1 or 2.0. Perfect for connecting a PC to your Arduino, USBtinyISP (among other things).  
  
3 feet / 1 meter long  
  
Color may vary!

In Stock
[Buy Now](https://www.adafruit.com/product/62)
[Related Guides to the Product](https://learn.adafruit.com/products/62/guides)
### USB Cable - 6" Standard A-B

[USB Cable - 6" Standard A-B](https://www.adafruit.com/product/900)
This here is your standard A-B USB cable, for USB 1.1 or 2.0. Perfect for connecting a PC to your Arduino, USBtinyISP, or USB Boarduino (among other things).  
  
6" long from end to end, its a little more compact than our classic 3' long cable  
  
We had these made to...

In Stock
[Buy Now](https://www.adafruit.com/product/900)
[Related Guides to the Product](https://learn.adafruit.com/products/900/guides)
### Adafruit METRO 328 Fully Assembled - Arduino IDE compatible

[Adafruit METRO 328 Fully Assembled - Arduino IDE compatible](https://www.adafruit.com/product/50)
We sure love the ATmega328 here at Adafruit, and we use them&nbsp;_a lot_&nbsp;for our own projects. The processor has plenty of GPIO, Analog inputs, hardware UART SPI and I2C, timers and PWM galore - just enough for most simple projects. When we need to go small, we use a <a...></a...>

Out of Stock
[Buy Now](https://www.adafruit.com/product/50)
[Related Guides to the Product](https://learn.adafruit.com/products/50/guides)
### Bluefruit EZ-Link - Bluetooth Serial Link & Arduino Programmer

[Bluefruit EZ-Link - Bluetooth Serial Link & Arduino Programmer](https://www.adafruit.com/product/1588)
We are excited to add another product to our growing Adafruit Bluefruit line, this time it's the Bluefruit EZ-Link: the best Bluetooth Serial Link device ever made. Like you, we have purchased all sorts of Bluetooth serial link modules, with high expectations - we just wanted something...

No Longer Stocked
[Buy Now](https://www.adafruit.com/product/1588)
[Related Guides to the Product](https://learn.adafruit.com/products/1588/guides)
### Bluefruit EZ-Link Shield - Bluetooth Arduino Serial & Programmer

[Bluefruit EZ-Link Shield - Bluetooth Arduino Serial & Programmer](https://www.adafruit.com/product/1628)
 **Note:** &nbsp;This product is currently undergoing a revision and will be available again soon!

We are excited to add another product to our growing Adafruit Bluefruit line, this time it's the Bluefruit EZ-Link Shield: the best Bluetooth Serial shield ever made. Like...

No Longer Stocked
[Buy Now](https://www.adafruit.com/product/1628)
[Related Guides to the Product](https://learn.adafruit.com/products/1628/guides)

## Related Guides

- [Arduino Lesson 10. Making Sounds](https://learn.adafruit.com/adafruit-arduino-lesson-10-making-sounds.md)
- [Skill Badge Requirements: Microcontrollers](https://learn.adafruit.com/skill-badge-requirements-microcontrollers.md)
- [Adafruit 4-Channel ADC Breakouts](https://learn.adafruit.com/adafruit-4-channel-adc-breakouts.md)
- [2.2" TFT Display](https://learn.adafruit.com/2-2-tft-display.md)
- [Adafruit Ultimate GPS Logger Shield](https://learn.adafruit.com/adafruit-ultimate-gps-logger-shield.md)
- [Multi-tasking the Arduino - Part 1](https://learn.adafruit.com/multi-tasking-the-arduino-part-1.md)
- [Analog Feedback Servos](https://learn.adafruit.com/analog-feedback-servos.md)
- [Collin's Lab: MIDI](https://learn.adafruit.com/collins-lab-midi.md)
- [LSM303 Accelerometer + Compass Breakout](https://learn.adafruit.com/lsm303-accelerometer-slash-compass-breakout.md)
- [Line Following Zumo Robot Using Simulink](https://learn.adafruit.com/line-following-zumo-robot-programmed-with-simulink.md)
- [Current Limiting Stepper Driver with DRV8871](https://learn.adafruit.com/current-limiting-stepper-driver-with-drv8871.md)
- [Adafruit 1.27" and 1.5" Color OLED Breakout Board](https://learn.adafruit.com/adafruit-1-5-color-oled-breakout-board.md)
- [Using NeoPixels and Servos Together](https://learn.adafruit.com/neopixels-and-servos.md)
- [LED Lightbox](https://learn.adafruit.com/led-lightbox.md)
- [Adafruit Motor Shield](https://learn.adafruit.com/adafruit-motor-shield.md)
