Skip to content

Arduino Uno Programmer

Wim Jongman edited this page Feb 9, 2020 · 4 revisions

Use the Arduino Uno as an ATtiny programmer

If you have an Arduino lying around, you can use it as a programmer for the ATtiny.

Arjun Ganesan has written an excellent article about it that I will adapt here for use with Sloeber.

I have copied a lot of Arjun's text from this web page which is allowed because Arjun has licensed his text (and by adoption, we also license this text) under the (c) GPL3+ license

Adding ATtiny support

First, we need to add ATtiny support to Sloeber. In Sloeber, open the Arduino menu and select preferences. Inside the window that appears, select the Third party index url's node.

You will see a big text box. Add the following line to the end of the list.

https://raw.githubusercontent.com/damellis/attiny/ide-1.6.x-boards-manager/package_damellis_attiny_index.json

Press Apply and Close.

Activating ATtiny Support

In Sloeber, open the Arduino menu and select preferences again. Inside the window that appears, select the Platforms and Boards node.

Look for the ATtiny board and select it.

Programming the UNO to be a programmer

Import the cc_arduino_isp project from the Sloeber/ATtiny repository and select properties from the context menu. In the preferences that appear, update the correct com port and press Apply and Close.

Select the project and upload it.

Take a look at the console and expect success. If not, fix any issues that appear by going over the steps again.

Hookup the ATtiny

Now you need to connect the ATtiny as described in Arjun's article. So head over there and come back once the ATtiny is hooked up correctly.

ATtiny hookup

Uploading an ATtiny sketch

Let's test the blink project. You can create it from scratch or import it as a test project from the Sloeber/ATtiny repository.

The following steps create a new sketch project.

Fill in the project name

Fill in the blanks to program the ATtiny:

  1. Select the ATtiny platform folder
  2. Select the ATtiny board
  3. Select the "Arduino as ISP" programmer
  4. Select the port of the Uno
  5. Select the default 1MHZ clock.
  6. Select your processor.

  1. Select a sample
  2. Choose Blink

Open Blink.ino and change the port. In this case, it is DP1 which is pin number 6 See the ATtiny pinouts here

Test

Hookup the ATtiny to the Uno and upload the sketch. After success, hook it up and test the blink. The hookup is the same as described in the Blink sketch.