Wiring

Below we have three different wiring diagrams. We recommend using the first one (Gemma M0 or Trinket M0) which requires the least amount of wiring, code while providing maximum debug ability.

  1. Gemma M0 or Trinket M0 - Minimal wiring with built in console debug ability, CircuitPython only.
  2. Gemma v2 with USB to TTL Serial Cable - (also works with the Trinket Mini) - with USB to TTL Serial Cable. Arduino only.
  3. Trinket Mini with FTDI Friend (also works with Gemma v2) - Arduino only. 

Wiring Diagram #1 (above) - Gemma M0 or Trinket M0:

No need for a serial breakout with this setup. It is built right into the M0 series. This wiring is straight forward. This setup will only work with the CircuitPython example code.

  • Gemma M0 D0 <--> Piezzo Speaker (+)
  • Gemma M0 D2 <--> IR Output
  • Gemma M0 Vout <--> IR (+)
  • Gemma M0 GND <--> IR (-)
  • Gemma M0 GND <--> Piezo Speaker (-)

 

 

Wiring Diagram #2 (above) - Gemma v2 with USB to TTL Serial Cable

This version allows for a debug console using the older Gemma v2 (ATtiny85 based). This setup is good for detecting IR codes and watching them print to the console. The wiring goes as follows:

  • Gemma v2 D0 (RX) <--> FTDI Green (TX out of the USB port)
  • Gemma v2 D1 (TX) <--> FTDI White (RX out of the USB port)
  • Gemma v2 D2 <-> IR Output
  • Gemma v2 3v3 <--> FTDI Red (+)
  • Gemma v2 GND <--> IR (-)
  • Gemma v2 GND <--> FTDI Black (-)

Wiring Diagram #3 (above) - Trinket Mini with FTDI Friend

The diagram is shown below. The IR data pin is connected to the Trinket GPIO #2 (Gemma Pin D2) and is connected to power and ground. To read codes, you will need to connect Trinket GPIO #0 / Gemma D0 to a serial to USB board such as the FTDI Friend receive RX pin (cross connect).

To demonstrate how the Trinket or Gemma may process IR commands into an action of your choice, a piezo speaker is connected to Trinket Pin GPIO #1 (Gemma Pin D1) to output a tone when a certain IR code is received.

Going further, you can use an IR code to change NeoPixels, a servo, a solenoid, or any other output.

  • If using an FTDI Friend: The green #0 wire should connect to the RX pin and the black GND wire connects to the GND pin
  • If using a USB console cable: The green #0 wire connects to the White Wire on the console cable and the black GND wire to the Black ground wire on the console cable.
This guide was first published on Sep 27, 2013. It was last updated on Sep 27, 2013. This page (Wiring) was last updated on Sep 22, 2019.