4.4.7.1 UPDI and /RESET
The UPDI one-wire interface can be a dedicated pin or a shared pin, depending on the target AVR device. Consult the device data sheet for further information.
When the UPDI interface is on a shared pin, the pin can be configured to be either UPDI, /RESET, or GPIO by setting the RSTPINCFG[1:0] fuses.
The RSTPINCFG[1:0] fuses have the following configurations, as described in the data sheet. The practical implications of each choice are given here.
RSTPINCFG[1:0] | Configuration | Usage |
---|---|---|
00 | GPIO | General purpose I/O pin. In order to access UPDI, a 12V pulse must be applied to this pin. No external Reset source is available. |
01 | UPDI | Dedicated programming and debugging pin. No external Reset source is available. |
10 | Reset | Reset signal input. In order to access UPDI, a 12V pulse must be applied to this pin. |
11 | Reserved | NA |
Note: Older AVR devices have a
programming interface, known as “High-Voltage Programming” (both serial and parallel
variants exist.) In general, this interface requires 12V to be applied to the /RESET
pin for the duration of the programming session. The UPDI interface is an entirely
different interface. The UPDI pin is primarily a programming and debugging pin,
which can be fused to have an alternative function (/RESET or GPIO). If the
alternative function is selected then a 12V pulse is required on that pin in order
to re-activate the UPDI functionality.
Note: If a design requires the sharing of
the UPDI signal due to pin constraints, steps must be taken in order to ensure that
the device can be programmed. To ensure that the UPDI signal can function correctly,
as well as to avoid damage to external components from the 12V pulse, it is
recommended to disconnect any components on this pin when attempting to debug or
program the device. This can be done using a 0Ω resistor, which is mounted by
default and removed or replaced by a pin header while debugging. This configuration
effectively means that programming should be done before mounting the device.