AVR Programmer pin configuration and AVRDude and Atmel Studio

Programmer Pin Diagram and Configuration

This post is more for me to remember and access easily in the future since I’ve spent a considerable amount of time doing this (for the second time!).

I have 2 AVR programmers and after a lot of trial and error, I realised that the pinout is different for each of them. Also, the datasheets for both the programmers are hopelessly unclear and show the pinout for the pins on the programmer. When you plug in a ribbon cable and turn it around to face you, the pin configuration becomes a mirror image and it’s quite taxing on the brain to correlate the pin config from the board to the cable. Hence the images below for reference!

For the programmer from nskelectronics, the pinout diagram is as per the image below:

nsk avr programmer pin config-small

For the AVR Programmer from Online TPS, the pinout diagram is as shown below:

onlinetps avr programmer pin config-small

Setting up AVRDude in Atmel Studio

If you are like me, then you probably just downloaded AVRDude into your downloads folder (on Windows) and are looking to link to that directly from Atmel Studio so that you don’t have to copy paste the hex file everytime. So, here is the configuration that I use for the parameters in Atmel Studio’s external tools which allows me to program the chip without having to leave Atmel Studio (showing for Atmel Studio version 6.2). This configuration works even if there are spaces in the path like “Atmel Studio” etc, because we’re setting the Initial Directory to be the TargetDir which would be either “Debug” or “Release” depending on the build target that you set in Atmel Studio. For more information on the available variables for external tools, refer to the Atmel Studio help page.

Command: C:\Users\myuser\Downloads\avrdude-6.0.1-mingw32\avrdude.exe
Arguments: -c usbasp -p t2313 -U flash:w:”$(TargetName).hex”
Initial Directory: $(TargetDir)
“Use Output Window”

avrdude atmel external tools setup

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s