Difference between revisions of "IOIO-OTG"

From Geeetech Wiki
Jump to: navigation, search
(Created page with "==Introduction== The IOIO–OTG is a printed circuit board specially designed to work with the Android device or PC application. With it, you can connect an app on an Android ...")
(No difference)

Revision as of 01:13, 19 August 2014

Introduction

The IOIO–OTG is a printed circuit board specially designed to work with the Android device or PC application. With it, you can connect an app on an Android device or a PC to low level peripherals like PWM, GPIO, ADC, I2C, UART and SPI. The IOIO doesn’t require you to write two pieces of software (board and client), it only require you to write the client-side (Android, PC) software. You can use a high-level programming language (currently Java) with a rich and intuitive API that allows you to manipulate the I/O pins and hardware peripherals on the board. So it is so fast and simple to do some prototyping and development with the IOIO. And this must be attributed to its microcontroller – PIC24FJ256GB206. Unlike the previous IOIO boards, IOIO–OTG can leverage the USB On-The-Go specification to connect as a Host or as a device. The IOIO-OTG acts as a USB Host and supply charging current if the app is running on your Android device while it assumes Device mode and present itself as a virtual serial port if app is running on a Windows, Linux or OSX machine. The IOIO-OTG is all open-source, software, firmware and hardware. The development has been an ongoing process, with new features and bug fixes introduced on a regular basis. New versions of firmware are distributed in a way that makes it very simple for the user to upgrade: connect the IOIO-OTG to a PC and run a simple program to flash the latest version or your own custom one if you're into such adventures. Notes: Avoid powering your IOIO-OTG with 10V over long wires or your board may fail.

Overview

The IOIO-OTG board contains the following components:

  • USB connector (micro-AB, female): Used to connect to host computer, an Android device or a Bluetooth dongle.
  • Power jack (2-pin JST, female): Used for power supply to the board. Voltage between 5V-15V should be supplied.
  • GND pins (10 pins): Ground connection.
  • VIN pins (3 pins): Used for outputting the supply voltage to your circuit, or as an alternative input to the power jack.
  • 5V pins (3 pins): 5V output from the on-board regulator, which can be used in your circuit.
  • 3.3V pins (3 pins): 3.3V from the on-board regulator, which can be used in your circuit.
  • I/O pins (46 pins, numbered 1-46): General purpose I/O pins. Some have special functions, see below.
  • PWR LED (red): Lights when the IOIO is getting power.
  • STAT LED (yellow): General purpose on-board LED, under application control.
  • MCLR pin: Not normally used. Its purpose is for programming new bootloader firmware on the IOIO board.
  • BOOT pin: Special pin used for getting the IOIO into bootloader mode on power-up. Note that this pin is shared with the stat LED.
  • Charge current trimmer (CHG): Adjusts the amount of current supplied on the VBUS line of the USB when acting as a USB host. Typically used in battery-powered application with Android to prevent the Android from draining the battery quickly. Turning in the (+) direction increases charge current.
  • Host switch: In "A" mode, the IOIO-OTG will detect whether it should act as host or as device automatically, according to whichever USB connector is plugged in (micro-A or micro-B). To support non-standard USB cables or adapters that use micro-B type, move the switch to the "H" position to force host mode.

I/O Pins

The I/O pins are the essence of the IOIO. They are used to connect to external circuits using different interfaces. The common denominator to all pins is that they can all serve as 3.3V digital inputs or 3.3V digital outputs. In addition, many of the pins are capable of other functions as detailed in the table at the bottom of this page. For convenience, the common pin functions are presented graphically on the bottom of the board, with a legend:

  • Pins surrounded by a square can be used as analog inputs (3.3V). For more details, see Analog Input.
  • Pins surrounded by a circle are 5V-tolerant, i.e. can be used as 5V logic inputs or product 5V logic output when used in open-drain mode with the help of a pull-up resistor. For more details, see Digital I/O.
  • Pins marked with "P" can be used as peripheral inputs and outputs. Mainly, this includes PWM, Pulse Input, UART, and SPI.
  • The pin marked with "Pi" can be used as peripheral input (but not output).
  • Pins marked with DAx and CLx are used for TWI.