# Introducing Pro Trinket

## Overview

![](https://cdn-learn.adafruit.com/assets/assets/000/018/949/medium800/adafruit_products_2000_top_ORIG.jpg?1408559399)

Trinket's got a big sister in town - the Pro Trinket! Pro Trinket combines everything you love about Trinket with the familiarity of the core Arduino chip, the ATmega328. It's like an Arduino Pro Mini with more pins and USB tossed in.

![](https://cdn-learn.adafruit.com/assets/assets/000/018/977/medium800/adafruit_products_2000-09.jpg?1408574643)

Trinket's a year old now, and while its been great to see tons of tiny projects, sometimes you just need more pins, more FLASH, and more RAM. That's why we designed Pro Trinket, with 18 GPIO, 2 extra analog inputs, 28K of flash, and 2K of RAM.

![](https://cdn-learn.adafruit.com/assets/assets/000/018/950/medium800/adafruit_products_2000_side_ORIG.jpg?1408559411)

Like the Trinket, it has onboard USB bootloading support - we opted for a MicroUSB jack this time. We also added Optiboot support, so you can either program your Pro Trinket over USB or with a FTDI cable just like the Pro Mini and friends.

![](https://cdn-learn.adafruit.com/assets/assets/000/018/951/medium800/adafruit_products_ftdicable.jpg?1408559426)

The Pro Trinket PCB measures only 1.5" x 0.7" x 0.2" (without headers) but packs the same capability as an Arduino UNO. So it's great once you've finished up a prototype on an official Arduino UNO and want to make the project smaller.

![](https://cdn-learn.adafruit.com/assets/assets/000/018/976/medium800/adafruit_products_2010-02.jpg?1408574622)

The Pro Trinket 5V uses the Atmega328P chip, which is the same core chip in the Arduino UNO/Duemilanove/Mini/etc. at the same speed and voltage. So you'll be happy to hear that not only is Pro Trinket programmable using the Arduino IDE as you already set up, but 99% of Arduino projects will work out of the box!

Here's some things you may have to consider when adapting Arduino sketches:

- Pins #2 and #7 are not available (they are exclusively for USB)
- The onboard 5V regulator can provide 150mA output, not 800mA out
- You cannot plug shields directly into the Pro Trinket
- SoftwareSerial will not work on the 3V Pro Trinket without changes. [See this FAQ](../../../../introducing-pro-trinket/faq#faq-1).
- There is no Serial-to-USB chip onboard. This is to keep the Pro Trinket small and inexpensive, you can use any FTDI cable to connect to the FTDI port for a Serial connection. The USB connection is for uploading new code only.
- The bootloader on the Pro Trinket use 4KB of FLASH so the maximum sketch size is 28,672 bytes. The bootloader does not affect RAM usage.
- Trinket is supported on Linux, Mac OS or Windows!

![](https://cdn-learn.adafruit.com/assets/assets/000/018/953/medium800/adafruit_products_2000_iso_demo_ORIG.jpg?1408559466)

Here's some handy specifications:

- ATmega328P onboad chip in QFN package
- 16MHz clock rate, 28K FLASH available
- USB bootloader with a nice LED indicator looks just like a USBtinyISP so you can program it with AVRdude and/or the Arduino IDE **&nbsp;** (with a few simple config modifications).
- Also has headers for an FTDI port for reprogramming
- Micro-USB jack for power and/or USB uploading, you can put it in a box or tape it up and use any USB cable for when you want to reprogram.
- On-board 5.0V power regulator with 150mA output capability and ultra-low dropout. Up to 16V input, reverse-polarity protection, thermal and current-limit protection.
- Power with either USB or external output (such as a battery) - it'll automatically switch over
- On-board green power LED and red pin #13 LED
- Reset button for entering the bootloader or restarting the program.
- Works with 99% of existing Arduino sketches (anything that doesn't use more than 28K, and doesn't require pins #2 and #7)
- **Mounting holes! Yeah!**

# Introducing Pro Trinket

## Guided Tour

![](https://cdn-learn.adafruit.com/assets/assets/000/018/927/medium800/adafruit_products_pinouts.jpg?1408552117)

Let me take you on a tour of your Trinket! Each trinket is assembled here at Adafruit and comes chock-full of good design to make it a joy to use.

- **Micro-B USB connector** - We went with the ultra-common micro-B USB connector for power and/or USB bootloading. We use a special half SMT/half thru hole connector with extra big pads so the connector is very strong. It's also a proper USB connector, so you can use any length cable. Don't forget to use a data+power USB cable if you want to bootload! Some really inexpensive USB cables are 'power only'
- **Green Power LED** - you'll know that the board is powered up when this bright LED is lit
- **Red #13 LED** - this LED does double duty. Its connected with a series resistor to the digital #13 GPIO pin. It pulses or blinks nicely when the Pro Trinket is in bootloader mode, and its also handy for when you want an indicator LED.
- **Battery + Input** - take your Trinket anywhere and power it from an external battery. This pin can take up 16V DC input, and has reverse-polarity, over-curent and thermal protections. The circuitry inside will use either the battery or USB power, safely switching from one to the other. If both are connected, it will use whichever has the higher voltage
- **USB Power Output** - You can also snag the 5V power from the USB jack in case you need 500mA+ current from your computer or portable USB power pack.
- **Breadboard friendly pins** - You can easily plug this into a little breadboard and have plenty of space for working and plugging stuff in
- **GPIO pins** - 18 GPIO pins + 2 analog-only pins, at 3 or 5V logic, check the next section for a detailed pinout guide
- **3 or 5V output** - an onboard regulator provides 3.3V or 5V output for powering LEDs, sensors, small motors, etc.
- **Reset Button** - an onboard reset button will launch the bootloader when pressed and the Trinket is plugged into a computer. If it is not connected to a computer, it's smart enough to go straight to the program.
- **External Reset Pin** - we bring out the reset pin so you can reset or restart your Trinket on the road. If the Trinket is in a box or otherwise hard to get to, you can wire up a button to this pin for an external reset button.
- **Three mounting holes** make it easy to attach with 2mm screws (M2 metric or #2 imperial) or even tiny zip-ties, string, etc.

![](https://cdn-learn.adafruit.com/assets/assets/000/018/928/medium800/adafruit_products_bottom.jpg?1408552182)

On the bottom there's a spot for a [2-pin JST-PH connector](https://www.adafruit.com/products/1769). this is optional and can be soldered on by hand. It will let you use a lipoly or&nbsp;[AAA battery pack](https://www.adafruit.com/products/727) or&nbsp;[a JST cable](https://www.adafruit.com/product/261) for other power input. It's connected to the GND and VBAT pins

# Introducing Pro Trinket

## Pinouts

![](https://cdn-learn.adafruit.com/assets/assets/000/107/302/medium800/adafruit_products_Adafruit_Pro_Trinket_5V_Pinout.png?1639433482)

[PDF for Pro Trinket 5V PrettyPins Diagram](https://github.com/adafruit/Adafruit-Pro-Trinket-PCBs/blob/master/Adafruit_Pro_Trinket_5V_Pinout.pdf)

[PDF for Pro Trinket 3V PrettyPins Diagram](https://github.com/adafruit/Adafruit-Pro-Trinket-PCBs/blob/master/Adafruit_Pro_Trinket_3V_Pinout.pdf)

Danger: 

![](https://cdn-learn.adafruit.com/assets/assets/000/018/929/medium800/adafruit_products_power.jpg?1408552472)

# Power Pins

We'll start with the top pins **BAT+,**  **GND** , **USB+** , and **3V** or **5V**

- **BAT+** is the **Battery + Input** pin. If you want to power the Pro Trinket from a battery or power adapter or solar panel or any other kind of power source, connect the **+** (positive) pin here! You can connect **up to 16V DC**. If you have a 3V Pro Trinket, you'll want at least 3.5V input to get a good 3.3V output. If you have a 5V Pro Trinket, 5.5V or higher is suggested. This input is reverse-polarity protected.
- **GND** is the common ground pin, used for logic and power. It is connected to the USB ground and the power regulator, etc. This is the pin you'll want to use for any and all ground connections
- **BUS** is the **USB Bus + Output** pin. If you want to use the USB 5V power for something, like charging a battery, or if you need more than 150mA of current (this pin can supply 500mA+ from USB ports) or to detect when the Pro Trinket is plugged into USB, this pin will have 5V power on it if and only if its plugged into something via the micro B connector. Don't put power into this pin, that's what **BAT+** is for - use it only as an output!
- The next pin is either&nbsp; **3V** or **5V** depending on which Trinket Pro you have. It is the output of the low dropout regulator.

The regulator is powered by either **BUS** or **BAT** (whichever is higher!) It will automatically switch between the two if USB or battery is removed using two schottky diodes. There is a 0.2V dropout due to the diode and maybe 50-100mV minimum drop in the regulator.

The regulator can supply approximately 150mA as long as it doesnt overheat. Make sure that you keep **BAT+** low to minimize heat-loss! About 1 or 2 Volts higher than 3V or 5V is ideal.

# GPIO Pins

&nbsp;Next we will cover the 18 GPIO (General Purpose Input Ouput) pins! 18 GPIO is a big step up from the little Trinket with only 5 or so pins. This is almost as many as a 'full grown' Arduino. In fact, since the Pro Trinket uses the same core chip as an Arduino, nearly any existing project that uses special pins like hardware PWM or SPI will work 'out of the box'.  
  
All the GPIO pins can be used as digital inputs, digital outputs, for LEDs, buttons and switches etc. They can provide up to 20mA of current. Don't connect a motor or other high-power component directly to the pins! [Instead, use a transistor to power the DC motor on/off](http://learn.adafruit.com/adafruit-arduino-lesson-13-dc-motors)

## Logic Level

On a 3V Pro Trinket, the GPIO are 3.3V output level, and should not be used with 5V inputs. On a 5V Pro Trinket, the GPIO are 5V output level, and can be used with 3V inputs but may damage electronic devices that are 3V input only!

![](https://cdn-learn.adafruit.com/assets/assets/000/018/931/medium800/adafruit_products_digpion.jpg?1408552744)

## The Digital Only GPIO Pins

- **RX** - also known as Digital #0, this is the hardware serial input pin. This is used when programming with an FTDI cable but is available when using the native USB to program
- **TX** - also known as Digital #1, this is the hardware serial output pin. This is used when programming with an FTDI cable but is available when using the native USB to program
- **Digital 3** - Also known as external interrupt #1. This pin can also be used as a PWM output pin using **analogWrite()**
- **Digital 4** - Nothing particularly special about this GPIO pin
- **Digital 5** - this pin can also be used as a PWM output pin using **analogWrite()**
- **Digital 6** - this pin can also be used as a PWM output pin using **analogWrite()**
- **Digital 8** - Nothing particularly special about this GPIO pin  
- **Digital 9** - this pin can also be used as a PWM output pin using **analogWrite()** It's also good for driving servos because its a high-speed PWM output
- **Digital 10** - this pin can also be used as a PWM output pin using **analogWrite()** It's also good for driving servos because its a high-speed PWM output
- **Digital 11** - Also known as the SPI **MOSI** pin. this pin can also be used as a PWM output pin using **analogWrite()**
- **Digital 12** - Also known as the SPI **MISO** pin
- **Digital 13** - Also known as the SPI **CLOCK** pin. This is _also_ connected to the red **#13** LED!

Note that **Digital 2** and **Digital 7** are used for the dedicated USB bootloading setup and are not exposed/available!

![](https://cdn-learn.adafruit.com/assets/assets/000/018/932/medium800/adafruit_products_agpio.jpg?1408552821)

## The Analog/Digital GPIO Pins

- **Analog 0** - also known as **Digital 14** , this pin can be a digital I/O pin or an analog input pin
- **Analog 1** - also known as **Digital 15** , this pin can be a digital I/O pin or an analog input pin
- **Analog 2** - also known as **Digital 16** , this pin can be a digital I/O pin or an analog input pin
- **Analog 3** - also known as **Digital 17** , this pin can be a digital I/O pin or an analog input pin
- **Analog 4** - also known as **Digital 18** , this pin can be a digital I/O pin or an analog input pin. It's also the I2C **SDA** pin
- **Analog 5** - also known as **Digital 19** , this pin can be a digital I/O pin or an analog input pin. It's also the I2C **SCL** pin

![](https://cdn-learn.adafruit.com/assets/assets/000/018/933/medium800/adafruit_products_aonly.jpg?1408552853)

## The Analog only pins

The two pins that sit sort-of inside the body of the Pro Trinket, **A6** and **A7** , are analog input only pins. They're kind of an 'extra' that you get with the Pro Trinket. These pins **cannot** be used for LEDs, buttons, servos, etc. They're only for **analogRead()** usage!

If you're used to using an Arduino Uno, you may notice that pins # **2** and # **7** are not available. That's because we use those two pins for the USB bootloader. They are not available for use and are not broken out.

![](https://cdn-learn.adafruit.com/assets/assets/000/018/934/medium800/adafruit_products_others.jpg?1408552885)

# Other Pins

- **Aref** - this is the optional analog reference pin for the analog converter, to be used when you want the 'top' of the analog converter to be different than 3V or 5V. Connect this to your desired reference voltage (between 0 and the Pro Trinket voltage) and use **analogReference(EXTERNAL)**
- **RST** - This is the Reset pin for the Pro Trinket. Connecting this to ground momentarily resets the Trinket and also starts up the bootloader. 

![](https://cdn-learn.adafruit.com/assets/assets/000/018/935/medium800/adafruit_products_ftdi.jpg?1408552917)

# FTDI Breakout

At the bottom is 6 pins in a row that we call the FTDI header. You can use these pins to program the Pro Trinket with an FTDI cable or FTDI Friend. You can also use it for serial debugging.

- **GND** - (Black&nbsp; **BLK** wire on FTDI Cable) same as the power ground pins
- **GND** - ditto
- **5V** - same as the VBUS pin
- **RX** - same as the RX pin
- **TX** - same as the TX pin
- **RST** - (Green&nbsp; **GRN** wire on FTDI Cable)&nbsp; there's a 0.1uF capacitors in between this pin and the Reset pin, so that Arduino-compatible programmers will work correctly with the DTR/RTS-toggle technique

![](https://cdn-learn.adafruit.com/assets/assets/000/018/945/medium800/adafruit_products_ftdiheader.jpg?1408557664)

# Introducing Pro Trinket

## Windows Driver Installation

Info: 

Info: 

Before you plug in your board, you'll need to possibly install a driver!  
  
Click below to download our Driver Installer.

[Download Latest Adafruit Windows Driver Installer](https://github.com/adafruit/Adafruit_Windows_Drivers/releases/latest/adafruit_drivers_*.exe)
Download and run the installer.

![](https://cdn-learn.adafruit.com/assets/assets/000/031/264/medium800/flora_1download.png?1457993219)

Run the installer! Since we bundle the SiLabs and FTDI drivers as well, you'll need to click through the license

![](https://cdn-learn.adafruit.com/assets/assets/000/031/265/medium800/flora_2lic.png?1457993232)

Select which drivers you want to install, we suggest selecting all of them so you don't have to do this again!

![](https://cdn-learn.adafruit.com/assets/assets/000/046/662/medium800/flora_driver-installer-v2000.png?1505789091)

As of version 2.5.0.0, the Adafruit drivers package is no longer signed, and some of the drivers it contains are also no longer signed. You'll need to click the second item in this dialog box when it appears:

![](https://cdn-learn.adafruit.com/assets/assets/000/097/013/medium800/adafruit_flora_unsigned.png?1605201538)

On Windows 7, by default, we install a single driver for most of Adafruit's boards, including the **Feather 32u4, the Feather M0, Feather M0, Express, Circuit Playground, Circuit Playground Express,&nbsp;Gemma M0, Trinket M0, Metro M0 Express**. On Windows 10 and 11 that driver is not necessary (it's built in to Windows) and it will not be listed.

The&nbsp; **Trinket / Pro Trinket / Gemma / USBtinyISP** drivers are also installed by default.

You can also, optionally, install the **Arduino Gemma** (different than the Adafruit Gemma!), **Huzzah and Metro 328** drivers.

Click **Install** to do the installin'.

Info: 

![](https://cdn-learn.adafruit.com/assets/assets/000/031/267/medium800/flora_4complete.png?1457993406)

# Manual Driver Installation

If windows needs the driver files (inf/cat) for some reason you can get all the drivers by downloading the source code zip file from this link:

[Latest Adafruit Windows Drivers release](https://github.com/adafruit/Adafruit_Windows_Drivers/releases/latest)
And point windows to the **Drivers** folder when it asks for the driver location

# Introducing Pro Trinket

## Using the USB Bootloader

# About the bootloader

A _bootloader_ is a tiny piece of software residing on the microcontroller that that helps load your own code into the remaining space.  
  
One of the challenges with the Pro Trinket is that we wanted to have a built-in USB bootloader, but the ATmega328 doesn't have built-in USB hardware!   
  
So instead, [Frank (our awesome engineer with mad USB chops)](http://www.frank-zhao.com/) created a USB bootloader that combines the elegance of V-USB with the well-supported and tested nature of the USBtinyISP. This bootloader looks just like a USBtinyISP - and since it uses the unique Adafruit VID/PID we own and that we added to `avrdude` so long ago, it works with only very minimal configuraton tweaks. No need to recompile anything, whew!

Then, since we had a little space left in the bootloader area of the chip, we added Optiboot support. You can use _either_ the USB connector _or_ an FTDI cable so that it acts just like an Arduino Uno for programming, for max flexibility.

The Pro Trinket is smart enough to auto-detect which bootloader you are trying to use. If you plug the USB port in, it will enumerate as a USBtinyISP for USB bootloader. If you plug in FTDI and use the Arduino Uno programming procedure it will use that technique

Danger: 

# Pro Trinket USB Drivers for Windows

The cool thing about the bootloader on the Pro Trinket is it just looks like a classic USBtinyISP AVR programmer. This makes it easy to use with AVRdude or Arduino IDE with only minor configuration changes. Before you start, you may need to install the USBtinyISP USB drivers  
  
**Drivers are only required for Windows, if you are using a Mac or Linux, drivers are not required!**

[Check this page for how to install the driver](../../../../introducing-pro-trinket/windows-setup)

Don't forget to plug in the Pro Trinket via a known-good USB cable to start the process. You should see the green power LED lit and the red bootloading LED pulse indicating that the Trinket is ready to start bootloading. If you've programmed the Pro Trinket since getting it, you can always get it back to the bootloader state by pressing the small onboard reset button

![](https://cdn-learn.adafruit.com/assets/assets/000/018/936/medium800/adafruit_products_reset-button.jpg?1408553504)

# Special Notes on using Pro Trinket with Linux

Pro Trinket is not supported on Linux operating system at this time - try Mac OS or Windows! However, you can try the following - it does work for some computers [![](../../../../assets/divider_icon.gif)](#)   
Linux is fairly picky about who can poke and prod at the USB port. You can always run **avrdude** or **Arduino IDE** as root, which will make sure you have the proper permissions. If you want to be super-cool you can add a _udev_ rule which will let any user (who is not root) connect to the USBtiny driver. That way you don't have to be root all the time!  
  
 [Check http://learn.adafruit.com/usbtinyisp/avrdude#for-linux](http://learn.adafruit.com/usbtinyisp/avrdude#for-linux) for what to add to your udev file.

# How to start the USB bootloader

Before you try to upload code to the Pro Trinket using the USB bootloader it must be in the Bootloader Mode. That means its listening for a sketch or program to be sent to it

Danger: 

The Pro Trinket must be connected to a computer via a USB cable to enter bootloader mode. You can enter the bootloader mode by pressing the little button on the board with your fingernail. The bootloader will 'time out' after 10 seconds, so to re-enter the bootloader mode just re-press the button!  
  
Don't press-and-hold the reset button, be sure to press-and-release!   
  
See the video below for what it looks like to plug it in, have the LED pulse in bootloader mode, time out and then press reset to restart the bootloader

https://www.youtube.com/watch?v=K95UL_3Qpg8

# Introducing Pro Trinket

## Using FTDI Cables

![](https://cdn-learn.adafruit.com/assets/assets/000/018/944/medium800/adafruit_products_ftdiheader.jpg?1408557647)

![](https://cdn-learn.adafruit.com/assets/assets/000/018/940/medium800/adafruit_products_70-00.jpg?1408555652)

For beginners, we suggest using an FTDI cable for programming and debugging, especially if you aren't simply porting an existing Arduino project to Pro Trinket. Much like many Arduino-compatibles, there's a header for connecting a&nbsp;['classic' FTDI cable](https://www.adafruit.com/product/70) or [FTDI friend.](https://www.adafruit.com/product/284)

![](https://cdn-learn.adafruit.com/assets/assets/000/018/938/medium800/adafruit_products_ftdi.jpg?1408554279)

The bootloader on Pro Trinket is **dual USB & FTDI**"optiboot" so you can use either the USB port or the FTDI breakout to upload. However, only the FTDI port allows you to use Serial debugging. So it's a bit of a tradeoff - USB is inexpensive, built-in but requires a button press to start & there's no debugging, FTDI requires an extra cable but has auto-reset and debug console.

# Select the correct Board in IDE

Make sure you're selecting the FTDI-program type in the Boards menu!

![](https://cdn-learn.adafruit.com/assets/assets/000/018/939/medium800/adafruit_products_protrinkftdi.png?1408555156)

# Connect FTDI Friend or Cable

You'll need to solder 6-pin header onto the FTDI breakout first. Match the black wire and green wire with the BLK and GRN markings on the PCB next to the FTDI header

![](https://cdn-learn.adafruit.com/assets/assets/000/018/942/medium800/adafruit_products_ftdifriend.jpg?1408557626)

![](https://cdn-learn.adafruit.com/assets/assets/000/018/943/medium800/adafruit_products_ftdicable.jpg?1408557633)

[Don't forget you'll need to install FTDI VCP drivers, available from FTDI chip.](http://www.ftdichip.com/Drivers/VCP.htm)&nbsp;Then select the COM port from the Tools menu as well, to upload!

![](https://cdn-learn.adafruit.com/assets/assets/000/018/941/medium800/adafruit_products_ftdicom.png?1408555812)

Of course, you can use the FTDI cable for debugging not just programming!

To use the FTDI cable to debug programs, add the standard `Serial.begin(baudrate);` line as you would with an UNO and `Serial.print` or `Serial.println` as you expect! Then select **Tools / Serial monitor** after loading your program. The Trinket will re-start when you launch the monitor so you can see your data right from the start; be patient while the Trinket finishes starting.

# Introducing Pro Trinket

## Setting up Arduino IDE

Chances are, you picked up a Trinket because it is programmable with the Arduino IDE. The Pro Trinket uses the same core chip as Arduino UNO, and the 5V Pro Trinket uses the same clock rate and voltage so its pretty much a full Arduino-compatible, just smaller!

The only changes you may have to consider when adapting Arduino sketches are:

- Pins #2 and #7 are not available
- The onboard 5V regulator can provide 150mA output, not 800mA out
- You cannot plug shields directly into the Pro Trinket
- There is no Serial-to-USB chip onboard. This is to keep the Pro Trinket small and inexpensive, you can use any FTDI cable to connect to the FTDI port for a Serial connection
- The bootloader on the Pro Trinket use 4KB of FLASH so the maximum sketch size is 28,672 bytes. The bootloader does not affect RAM usage.

Danger: 

Warning: 

# Arduino IDE Setup

Just follow the steps in the **[Adafruit Arduino IDE setup guide](../../../../adafruit-arduino-ide-setup/overview)**&nbsp;to add Adafruit board support to the Arduino IDE to program Pro Trinket!

Don't forget to also [install Windows drivers if you are using Windows](../../../../adafruit-arduino-ide-setup/windows-setup), or [setup udev on Linux](../../../../adafruit-arduino-ide-setup/linux-setup)

When you're finished installing the IDE come back to this page to continue the Pro Trinket guide.

# Blink!

OK let's practice uploading a sketch by uploading the classic Blink sketch with the USB bootloader. This program with blink the onboard red LED that is connected to pin #13.

The sketch is in **File-\>Examples-\>Basics-\>Blink**

![](https://cdn-learn.adafruit.com/assets/assets/000/018/894/medium800/adafruit_products_openblink.png?1408400681)

Warning: 

Select the **Pro Trinket 5V/16MHz (USB)** or **Pro Trinket 3V/12MHz (USB)** board from the **Tools-\>Board** menu

![](https://cdn-learn.adafruit.com/assets/assets/000/018/895/medium800/adafruit_products_protrinkboards.png?1408400773)

Next go into the **Tools -\> Programmer** menu and select the **USBtinyISP** programmer.

![](https://cdn-learn.adafruit.com/assets/assets/000/035/379/medium800/adafruit_products_usbtiny.png?1472869636)

Plug in the Trinket, make sure you see the green LED lit (power good) and the red LED pulsing. Press the button if the red LED is not pulsing, to get into bootloader mode.   
  
Click the **Upload** button (or select **File-\>Upload** )

![](https://cdn-learn.adafruit.com/assets/assets/000/018/896/medium800/adafruit_products_upload.png?1408400834)

If everything goes smoothly you should see the following (no red error messages) and of course, the red LED on the trinket will blink on/off once a second

![](https://cdn-learn.adafruit.com/assets/assets/000/018/897/medium800/adafruit_products_doneuploading.png?1408400894)

# Something Went Wrong!

## If you get the error message avrdude: Error: Could not find USBtiny device (0x1781/0xc9f)

That means the bootloader wasn't active. Make sure to press the button on the Trinket to activate the bootloader _before_ clicking the Upload button. Also, check that you see the red pulsing LED on #13 that indicates the USB bootloader enumerated to your computer

![](https://cdn-learn.adafruit.com/assets/assets/000/018/898/medium800/adafruit_products_nousbtiny.png?1408400933)

Also, don't forget to install the Windows driver if you're using windows!

# Introducing Pro Trinket

## Hints for Arduino-compatibility

![](https://cdn-learn.adafruit.com/assets/assets/000/018/937/medium800/adafruit_products_2000_side_ORIG.jpg?1408554084)

The Pro Trinket uses the Atmega328P chip, which is the same core chip in the Arduino UNO/Duemilanove/Mini/etc. It's the 'classic' Arduino chip! So you'll be happy to hear that not only is Pro Trinket programmable using the Arduino IDE as you already set up, but 99% of Arduino projects will work out of the box!

The Pro Trinket 5V runs at 16MHz, just like the Uno. The Pro Trinket 3V runs at 12MHz, which we suggest for 'power users' who want a 3V Arduino-compatible and don't mind its a bit slower at 12MHz.

The only changes you may have to consider when adapting Arduino sketches are:

- Pins #2 and #7 are not available
- That means you do not get access to interrupt #0. Use interrupt #1 on pin #3 instead with `attachInterrupt (1, functionname, condition);`
- The onboard 3.3V or 5V regulator can provide 150mA output, not 800mA out
- You cannot plug shields directly into the Pro Trinket
- There is no Serial-to-USB chip onboard. This is to keep the Pro Trinket small and inexpensive, you can use any FTDI cable to connect to the FTDI port for a Serial connection
- The 3V Pro Trinket runs at 12MHz not 16MHz so its a bit slower.
- The bootloader on the Pro Trinket use 4KB of FLASH so the maximum sketch size is 28,672 bytes. The bootloader does not affect RAM usage.

# Introducing Pro Trinket

## Re-programming Bootloader

If you'd like to reprogram the bootloader on your Pro Trinket, or update the bootloader to not have the Optiboot-loop-on-RX bug, download this zip of two Arduino sketches

These are only tested on an UNO! For non-UNOs you'll need to swap pins 11, 12, 13 for the hardware SPI pins but we haven't tested it at all, so UNO only please.

[protrinketbootloaders_2015_06_09.zip](https://learn.adafruit.com/system/assets/assets/000/025/838/original/protrinketbootloaders_2015_06_09.zip?1433871884)
Load one or the other onto the Uno, depending on which type you are programming, then connect

- Pro Trinket 13 -\> Arduino 13 (Use ~1K series resistor if prog'ing Pro Trinket 3V)
- Pro Trinket 12 -\> Arduino 12
- Pro Trinket 11 -\> Arduino 11 (Use ~1K series resistor if prog'ing Pro Trinket 3V)
- Pro Trinket GND -\> Arduino GND
- Pro Trinket VBAT -\> Arduino 5V
- **Pro Trinket RESET -\> Arduino 10** (Use ~1K series resistor if prog'ing Pro Trinket 3V)

open the terminal @ 57600 baud and press G and return (or click Send)

![](https://cdn-learn.adafruit.com/assets/assets/000/023/960/medium800/adafruit_products_loaded.png?1426650030)

# Introducing Pro Trinket

## F.A.Q.

### 

Trinket (and Pro Trinket) **do not** have a USB-serial converter chip on board, this is how we can make them so small! Instead of a serial console, the Trinket is programmed _directly_ over USB. No COM/Serial port is used at all!

### 

Trinket's bootloader is finicky about USB 3 ports, and might not work on them. Try connecting to any USB 2 ports you have or go through a USB 1 or USB 2 hub (nearly all hubs are v2 or v1 instead of v3)

### 

If you're running an older version of the IDE, there may not be support for 12MHz software serial. Find your Arduino installation folder (if you're using a Mac you may need to **explore** the package) and locate the _libraries/SoftwareSerial_ folder and open up **SoftwareSerial.h** inside. Add the following lines&nbsp; **before**

`#elif F_CPU == 8000000`

```
#elif F_CPU == 12000000
static const DELAY_TABLE PROGMEM table[] =
{
// baud rxcenter rxintra rxstop tx
  { 115200, 1, 11, 11, 8, },
  { 57600, 6, 26, 26, 23, },
  { 38400, 14, 41, 42, 39, },
  { 31250, 19, 51, 52, 49, },
  { 28800, 23, 56, 56, 53, },
  { 19200, 37, 86, 86, 83, },
  { 14400, 52, 116, 116, 113, },
  { 9600, 82, 175, 175, 173, },
  { 4800, 172, 354, 354, 351, },
  { 2400, 350, 711, 711, 708, },
  { 1200, 707, 1425, 1425, 1422, },
  { 300, 2850, 5711, 5711, 5708, },
};

const int XMIT_START_ADJUSTMENT = 5;
```

Once added, save and restart the IDE

### 

There's a slight bug in the Optiboot bootloader where it has a busy-wait loop while reading commands. If there is some noise on the RX pin, it can start the bootloader which then waits forever for more data

You can solve this in one of two ways

1. Connect a pullup resistor of anywhere from 2K - 47K from the RX pin to the 5V pin (Pro Trinket 5V) or 3V pin (Pro Trinket 3V)
2. Re-burn the bootloader with our patched version that seems to fix this bug by timing out on noisy RX reads&nbsp;

### 

Try a different USB cable. &nbsp;Some cables are "charge only" and don't have data lines.

And even with data cables, some work better than others.

### 

We haven't personally tried it but some customers report that - Yes you can use an [EZ-Link](https://www.adafruit.com/products/1588) with a 3V or 5V Pro Trinket in FTDI-programming-mode

# Introducing Pro Trinket

## Downloads

# Datasheets & Files

- [Datasheet&nbsp;of ATmega328 Microcontroller](http://adafruit.com/datasheets/ATMEGA328P.pdf)
- [EagleCAD PCB files for both Pro Trinkets](https://github.com/adafruit/Adafruit-Pro-Trinket-PCBs)
- [Fritzing objects in the Adafruit Fritzing library](https://github.com/adafruit/Fritzing-Library)
- [3V 3D Models on GitHub](https://github.com/adafruit/Adafruit_CAD_Parts/tree/main/2010%20ProTrinket%203V)
- [5V 3D Models on GitHub](https://github.com/adafruit/Adafruit_CAD_Parts/tree/main/2000%20ProTrinket%205V)

- [3V Declaration of Conformity](https://cdn-shop.adafruit.com/product-files/2010/CTS-CGZ3150202-00093-E-Pro%20Trinket%203V-EMC-Official%20cert.pdf)
- [3V](https://cdn-shop.adafruit.com/product-files/2010/CTS-CGZ3150202-00093-E-Pro%20Trinket%203V-EMC-Official%20cert.pdf)[EMC Test Report](https://cdn-shop.adafruit.com/product-files/2010/CTS-CGZ3150202-00093-E-Pro%20Trinket%203V-EMC-official%20report%20%281%29.pdf)
- [3V](https://cdn-shop.adafruit.com/product-files/2010/CTS-CGZ3150202-00093-E-Pro%20Trinket%203V-EMC-Official%20cert.pdf)[Statement of Verification](https://cdn-shop.adafruit.com/product-files/2010/CTS-CGZ3150202-00094-E-Pro%20Trinket%203V-FCC%20VOC-Official%20cert.pdf)
- [3V](https://cdn-shop.adafruit.com/product-files/2010/CTS-CGZ3150202-00093-E-Pro%20Trinket%203V-EMC-Official%20cert.pdf)[FCC Test Report](https://cdn-shop.adafruit.com/product-files/2010/CTS-CGZ3150202-00094-E-Pro%20Trinket%203V-FCC%20VOC-official%20report.pdf)
- [3V](https://cdn-shop.adafruit.com/product-files/2010/CTS-CGZ3150202-00093-E-Pro%20Trinket%203V-EMC-Official%20cert.pdf)[IC Test Report](https://cdn-shop.adafruit.com/product-files/2010/CTS-CGZ3150202-00095-E-Pro%20Trinket%203V-IC-Official%20report.pdf)
- [5V Declaration of Conformity](https://cdn-shop.adafruit.com/product-files/2000/CTS-CGZ3150202-00096-E-Pro%20Trinket%205V-EMC-Official%20cert.pdf)
- [5V](https://cdn-shop.adafruit.com/product-files/2000/CTS-CGZ3150202-00096-E-Pro%20Trinket%205V-EMC-Official%20cert.pdf)[EMC Test Report](https://cdn-shop.adafruit.com/product-files/2000/CTS-CGZ3150202-00096-E-Pro%20Trinket%205V-EMC-Official%20report.pdf)
- [5V](https://cdn-shop.adafruit.com/product-files/2000/CTS-CGZ3150202-00096-E-Pro%20Trinket%205V-EMC-Official%20cert.pdf)[Statement of Verification](https://cdn-shop.adafruit.com/product-files/2000/CTS-CGZ3150202-00097-E-Pro%20Trinket%205V-FCC%20VOC-Official%20cert.pdf)
- [5V](https://cdn-shop.adafruit.com/product-files/2000/CTS-CGZ3150202-00096-E-Pro%20Trinket%205V-EMC-Official%20cert.pdf)[FCC Test Report](https://cdn-shop.adafruit.com/product-files/2000/CTS-CGZ3150202-00097-E-Pro%20Trinket%205V-FCC%20VOC-Official%20report.pdf)
- [5V](https://cdn-shop.adafruit.com/product-files/2000/CTS-CGZ3150202-00096-E-Pro%20Trinket%205V-EMC-Official%20cert.pdf)[IC Test Report](https://cdn-shop.adafruit.com/product-files/2000/CTS-CGZ3150202-00098-E-Pro%20Trinket%205V-IC-Official%20report.pdf)

- [PDF for Pro Trinket 3V PrettyPins Diagram](https://github.com/adafruit/Adafruit-Pro-Trinket-PCBs/blob/master/Adafruit_Pro_Trinket_3V_Pinout.pdf)
- [PDF for Pro Trinket 5V PrettyPins Diagram](https://github.com/adafruit/Adafruit-Pro-Trinket-PCBs/blob/master/Adafruit_Pro_Trinket_5V_Pinout.pdf)

[SVG For Pro Trinket 3V PrettyPins Diagram](https://cdn-learn.adafruit.com/assets/assets/000/107/304/original/Adafruit_Pro_Trinket_3V_Pinout.svg?1639433659)
[SVG For Pro Trinket 5V PrettyPins Diagram](https://cdn-learn.adafruit.com/assets/assets/000/107/303/original/Adafruit_Pro_Trinket_5V_Pinout.svg?1639433652)
# Source code

[Original code for the Pro Trinket bootloader on github](https://github.com/adafruit/Adafruit_ProTrinket_Bootloader)  
We do not offer any support for this code, it is released as-is!

Danger: 

# Schematics
### Pro Trinket 5V 16MHz:
![](https://cdn-learn.adafruit.com/assets/assets/000/018/948/medium800/adafruit_products_protrink5vschm.png?1408558753)

## Pro Trinket 3V @ 12MHz
![](https://cdn-learn.adafruit.com/assets/assets/000/018/947/medium800/adafruit_products_protrink3vschm.png?1408558562)

Fabrication print, dimensions in inches (same for both 3V and 5V)

![](https://cdn-learn.adafruit.com/assets/assets/000/018/946/medium800/adafruit_products_protrinkprint.png?1408558495)

## Pro Trinket 3V 3D Model
![](https://cdn-learn.adafruit.com/assets/assets/000/136/274/medium800/adafruit_products_2010_ProTrinket_3V.jpg?1744652022 )

## Pro Trinket 5V 3D Model
![](https://cdn-learn.adafruit.com/assets/assets/000/136/275/medium800/adafruit_products_PCB-Component.jpg?1744652032 )


## Featured Products

### Adafruit Pro Trinket - 5V 16MHz

[Adafruit Pro Trinket - 5V 16MHz](https://www.adafruit.com/product/2000)
 **Deprecation Warning: The Pro Trinket bit-bang USB technique it uses doesn't work as well as it did in 2014, many modern computers won't work well. So while we still carry the Pro Trinket so that people can maintain some older projets, we no longer recommend it.** Please...

In Stock
[Buy Now](https://www.adafruit.com/product/2000)
[Related Guides to the Product](https://learn.adafruit.com/products/2000/guides)
### Adafruit Pro Trinket - 3V 12MHz

[Adafruit Pro Trinket - 3V 12MHz](https://www.adafruit.com/product/2010)
 **Deprecation Warning: The Pro Trinket bit-bang USB technique it uses doesn't work as well as it did in 2014, many modern computers won't work well. So while we still carry the Pro Trinket so that people can maintain some older projets, we no longer recommend it.** Please...

No Longer Stocked
[Buy Now](https://www.adafruit.com/product/2010)
[Related Guides to the Product](https://learn.adafruit.com/products/2010/guides)
### Adafruit Pro Trinket 6-Pack - 3 x 3V and 3 x 5V Trinkets

[Adafruit Pro Trinket 6-Pack - 3 x 3V and 3 x 5V Trinkets](https://www.adafruit.com/product/2085)
**We're no longer selling this pack of Pro Trinket 3V+5V, we recommend our Metro Mini ([5V 328P with USB-Serial Converter](https://www.adafruit.com/product/2590)), [Feather 328P (3.3V 328P with USB-Serial and LiPo...](https://www.adafruit.com/product/3458)**

No Longer Stocked
[Buy Now](https://www.adafruit.com/product/2085)
[Related Guides to the Product](https://learn.adafruit.com/products/2085/guides)
### Adafruit LiIon/LiPoly Backpack Add-On for Pro Trinket/ItsyBitsy

[Adafruit LiIon/LiPoly Backpack Add-On for Pro Trinket/ItsyBitsy](https://www.adafruit.com/product/2124)
If you have an ItsyBitsy or Pro Trinket you probably know it's the perfect little size for a portable project. This LiPoly backpack makes it really easy to do! Instead of wiring 2 or 3 boards together to make a charging system, this little PCB sits on top of the PCB and allows a...

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

[USB cable - USB A to Micro-B](https://www.adafruit.com/product/592)
This here is your standard A to micro-B USB cable, for USB 1.1 or 2.0. Perfect for connecting a PC to your Metro, Feather, Raspberry Pi or other dev-board or microcontroller

Approximately 3 feet / 1 meter long

Out of Stock
[Buy Now](https://www.adafruit.com/product/592)
[Related Guides to the Product](https://learn.adafruit.com/products/592/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)

## Related Guides

- [Glowing Viking Rune wayFinder](https://learn.adafruit.com/glowing-viking-rune-artifact.md)
- [LED Campfire](https://learn.adafruit.com/led-campfire.md)
- [Tent Lantern](https://learn.adafruit.com/tent-lantern.md)
- [Adafruit Arduino IDE Setup](https://learn.adafruit.com/adafruit-arduino-ide-setup.md)
- [Fiddy - the FTDI Clip](https://learn.adafruit.com/fiddy-ftdi-pogo-pin-clip.md)
- [Color Balancing Video Camera Light feat. DotStars](https://learn.adafruit.com/color-balancing-light-box-with-dotstar-cool-warm-white-leds.md)
- [Adafruit Audio FX Sound Board](https://learn.adafruit.com/adafruit-audio-fx-sound-board.md)
- [Infinity Mirror Collar](https://learn.adafruit.com/infinity-mirror-collar.md)
- [MASLOW: an Open WiFi Detector with Adafruit Pro Trinket and CC3000](https://learn.adafruit.com/wifi-hotspot-finder-adafruit-pro-trinket-cc3000.md)
- [Trinket “Question Block” Sound Jewelry](https://learn.adafruit.com/trinket-question-block-sound-jewelry.md)
- [Adafruit Pro Trinket LiPoly/LiIon Backpack](https://learn.adafruit.com/adafruit-pro-trinket-lipoly-slash-liion-backpack.md)
- [Talking d20 20-Sided Gaming Die](https://learn.adafruit.com/talking-d20-20-sided-gaming-die.md)
- [Your Pulse Displayed with NeoPixels](https://learn.adafruit.com/pulse-sensor-displayed-with-neopixels.md)
- [Supernova Poi](https://learn.adafruit.com/supernova-poi.md)
- [Adafruit DS2484 I2C to 1-Wire Bus Adapter Breakout](https://learn.adafruit.com/adafruit-ds2484-i2c-to-1-wire-bus-adapter-breakout.md)
