UPDI stands for Unified Program and Debug Interface, but this board is so smol and cute that we will call it the Unusually Playful Device Interfacer and pat its head when it does a good job. It's designed to make programming modern ATtiny chips very easy because it has 3V or 5V power and logic select, power and transmit indicator LEDs, and a quick cable for poking into a breadboard.

We have been working a lot with ATtiny816, ATtiny817 and ATtiny1616 chips lately for our seesaw boards. And we're often needing to program them with a CP2102-based breakout with a 1K resistor soldered between the RX and TX pins. But we were hankering for a nicer programmer!

This UPDI Friend makes programming such chips very easy:

  • Select between 3V or 5V power and logic - the 3V regulator can source up to 500mA so it can run even big projects.
  • CH340E USB Serial converter chip with cross-platform drivers.
  • 1K Loop-back Resistor between RX and TX.
  • USB Type C for data and power connection to any computer.
  • JST SH cable included for quick plugging into a breadboard - you can get another JST SH 3-pin cable with sockets or with pin header here.
  • 0.1" spaced breakout holes for custom connections.
  • Green power OK LED
  • Red serial activity LED
  • Inspired by this open-source hardware design from Stefan Wagner!

We use Arduino IDE with the megaTinyCore board support package installed, simply select "Serial UPDI" as the programmer type. We use 230Kbps but 56Kbps is also good.

Power Pins

  • PWR - this is the power output pin from the USB-C port. It can output 3V or 5V depending on the position of the voltage selector switch.
  • GND - common ground for power and logic.

UPDI Pin

  • UPDI - This is the logic output from the UPDI Friend. Connect it to the UPDI data pin on the board you are programming. Its logic level is determined by the position of the voltage selector switch (3V or 5V).

JST SH Port

The JST SH port is located above the UPDI, PWR and GND pin. It lets you connect to those same pins without any soldering using a 3 pin JST SH cable. A male pin connector cable is included with the UPDI Friend. Optionally, a socket pin connector version is available.

The red wire is connected to PWR, the black wire is connected to GND and the white wire is connected to UPDI.

Voltage Selector Switch

In the middle of the board is the voltage selector switch. You can use this switch to change the power and logic level to 3V or 5V. The 3V regulator can source up to 500mA.

LEDs

  • Power LED - Below the voltage switch is the power LED, labeled PWR. It is the green LED.
  • Serial activity LED - To the right of the voltage switch is the serial activity LED, labeled TX. It is the red LED. It will light up anytime data is transferred to the UPDI pin.

Power Pins

  • PWR - this is the power output pin from the USB-C port. It can output 3V or 5V depending on the position of the voltage selector switch.
  • GND - common ground for power and logic.

UPDI Pin

  • UPDI - This is the logic output from the UPDI Friend. Connect it to the UPDI data pin on the board you are programming. Its logic level is determined by the position of the voltage selector switch (3V or 5V).

Unlike our simple UPDI version, this board is HV for High Voltage because it will let you send a quick 12V pulse to the UPDI right before programming. This is required for when the chip is configured to use the UPDI pin as a reset or GPIO. This board will also let you 'unbrick' any chip configured for HV usage, you can use it to reset the fuses for Low Voltage programming.

JST SH Port

The JST SH port is located above the UPDI, PWR and GND pin. It lets you connect to those same pins without any soldering using a 3 pin JST SH cable. A male pin connector cable is included with the UPDI Friend. Optionally, a socket pin connector version is available.

The red wire is connected to PWR, the black wire is connected to GND and the white wire is connected to UPDI.

Voltage Selector Switch

In the middle of the board is the voltage selector switch. You can use this switch to change the power and logic level to 3V or 5V. The 3V regulator can source up to 500mA.

LEDs

  • Power LED - Below the voltage switch is the power LED, labeled PWR. It is the green LED.
  • Serial activity LED - To the right of the voltage switch is the serial activity LED, labeled TX. It is the red LED. It will light up anytime data is transferred to the UPDI pin.

This page is only for use with the High Voltage UPDI Friend. The simple UPDI Friend does not need these steps.

Before you upload code to your board with the High Voltage UPDI Friend, you'll need to edit the boards.txt file in the megaTinyCore board support package. This will enable the high-voltage fuses settings.

Install megaTinyCore

You can compile code for the ATtiny using the megaTinyCore board support package in the Arduino IDE. There are detailed installation instructions in the megaTinyCore GitHub repository. The following steps outline how to install it using the Boards Manager.

In the Arduino IDE, go to Preferences and add the megaTinyCore boards manager URL to the Additional Boards Manager URLs list:

http://drazzy.com/package_drazzy.com_index.json
boards

Tools - Board - Boards Manager and search for megaTinyCore. Click Install to install the board support package.

megatinycore

Edit boards.txt

Navigate to the megaTinyCore board support package folder on your computer. This is usually located in the Arduino15 folder. For example, this is the file path for Windows: 

C:\Users\name\AppData\Local\Arduino15\packages\megaTinyCore\hardware\megaavr\2.6.10

Open the boards.txt file in the folder with your preferred text editor.

Navigate to the "UPDI/RESET PIN CONFIGURATION" section in boards.txt:

Uncomment the last four lines in this section and save boards.txt. With these lines uncommented, you will brick chips that do not have a high voltage programmer, so proceed with caution.

If you uncomment these lines in boards.txt you will brick chips without the high voltage UPDI programmer.

Now you can proceed to upload the code to your board by following the steps on the Using the UPDI Friend page.

We don't provide any support for custom builds of seesaw - but we think this information is cool and useful for the Maker community!

You can reprogram these ATtiny breakouts to run your own firmware. However, the boards do not come with a bootloader. If you want to do development on seesaw (e.g. changing the configuration) you need a separate UPDI programming setup! You can build this setup with a 1K resistor and a USB to Serial cable or with the UPDI Friend board.

USB to TTL Serial Cable With Type A plug and 4 wire sockets
The cable is easiest way ever to connect to your microcontroller/Raspberry Pi/WiFi router serial console port. Inside the big USB plug is a USB<->Serial conversion chip and at...
Angled shot of 25 Through-Hole Resistors - 1.0K ohm 5% 1/4W.
ΩMG! You're not going to be able to resist these handy resistor packs! Well, axially, they do all of the resisting for you!This is a 25 Pack of...

Building a UPDI Programmer

  • USB to Serial cable power to ATtiny VIN (red wire)
  • USB to Serial cable ground to ATtiny G (black wire)
  • USB to Serial cable RX to 1K resistor (white wire)
  • USB to Serial cable TX to 1K resistor (green wire)
  • 1K resistor to ATtiny UPDI pin (white wire)

Wiring with the UPDI Friend

  • UPDI Friend PWR to ATtiny VIN (red wire)
  • UPDI Friend GND to ATtiny G (black wire)
  • UPDI Friend UPDI to ATtiny UPDI pin (white wire)

Install megaTinyCore

You can compile code for the ATtiny using the megaTinyCore board support package in the Arduino IDE. There are detailed installation instructions in the megaTinyCore GitHub repository. The following steps outline how to install it using the Boards Manager.

In the Arduino IDE, go to Preferences and add the megaTinyCore boards manager URL to the Additional Boards Manager URLs list:

http://drazzy.com/package_drazzy.com_index.json

Go to Tools - Board - Boards Manager...

In the Boards Manager, search for megaTinyCore. Click Install to install the board support package.

Program the ATtiny

After the megaTinyCore finishes installing, go to Tools - Board - megaTinyCore and select the board list that includes your ATtiny.

Then, select the chip of your ATtiny.

Next, set clock if needed. The default 20 MHz clock option is only valid if powering with 5V. If powering with 3.3V, select 10 MHz for the clock.

Under Programmer, select SerialUPDI - SLOW: 57600 baud.

Other options can be left at their defaults.

Finally, go to Preferences and check ON Show verbose output during upload. This will give you the upload details and progress in the monitor at the bottom of the Arduino IDE, which is very useful for debugging.

Now you can compile code with the megaTinyCore to upload to the ATtiny with the UPDI programmer by going to Sketch > Upload Using Programmer.

Blink Test

This simple example blinks the ATTiny816 onboard red indicator LED on pin 10.

void setup() {
  pinMode(10, OUTPUT);
}

void loop() {
  digitalWrite(10, HIGH);
  delay(1000);
  digitalWrite(10, LOW);
  delay(1000);
}

If using this with the ATTiny817, you'll want to update the pin to 5, as shown below.

void setup() {
  pinMode(5, OUTPUT);
}

void loop() {
  digitalWrite(5, HIGH);
  delay(1000);
  digitalWrite(5, LOW);
  delay(1000);
}

Upload the sketch using the UPDI programmer. You should see this output in the monitor after the upload has completed successfully:

The red LED on the ATtiny should be blinking!

Schematic and Fab Print - UPDI Friend

components_fab.png
dimensions are in inches

Schematic and Fab Print - High Voltage UPDI Friend

components_fab_hv.png
dimensions are in inches

This guide was first published on Feb 05, 2024. It was last updated on Jun 25, 2024.