ISPnub - Stand-alone AVR programmer module
The driver will work on both 32 and 64 bit platforms. On Linux And Mac OS X no kernel driver is required, just use AVRdude and specify the correct port. The programmer will work with a wide variety of Atmel AVR microcontrollers including the Atmega8a and Atmega168a. USBasp is a USB in-circuit programmer for Atmel AVR controllers. It simply consists of an ATMega8 and a few passive components. The programmer uses a firmware-only USB driver, no special USB controller is needed. Some of the key features include: a. Works under multiple platforms. Linux, Mac OS X and Windows are tested, b.
Like it? You can support via PayPal:Features
- Works under multiple platforms. Linux, Mac OS X and Windows are tested.
- No special controllers or smd components are needed.
- Programming speed is up to 5kBytes/sec.
- SCK option to support targets with low clock speed (< 1,5MHz).
Download
Firmware and circuit
The following packages include circuit and firmware.usbasp.2011-05-28.tar.gz (519 kB) TPI support, supports programmers with ATMega88 and ATMega8.
usbasp.2009-02-28.tar.gz (260 kB)
usbasp.2007-10-23.tar.gz (172 kB)
usbasp.2007-07-23.tar.gz (176 kB)
Usbasp Mac Os X Driver
usbasp.2006-12-29.tar.gz (118 kB) Supports programmers with ATMega48 and ATMega8.usbasp.2006-09-16.tar.gz (116 kB) New VID/PID!
usbasp.2005-11-14.tar.gz (175 kB)
usbasp.2005-07-03.tar.gz (166 kB)
usbasp.2005-04-21.tar.gz (169 kB)
Please refer to Readme.txt for details on building, installing and using USBasp.
Drivers
On Linux and MacOS X no kernel driver is needed. Windows requires a driver for USBasp. Please use this driver installation tool for Windows (see also: successful setup on Windows 10):Zadig - USB driver installation made easy
Software
- AVRDUDE supports USBasp since version 5.2.
- BASCOM-AVR supports USBasp since version 1.11.9.6.
- Khazama AVR Programmer is a Windows XP/Vista GUI application for USBasp and avrdude.
- eXtreme Burner - AVR is a Windows GUI Software for USBasp based USB AVR programmers.
Hardware
Schematic
Partlist
Partnumber | Value | Reichelt No |
---|---|---|
C1 | 4,7u | RAD 4,7/35 |
C2 | 100n | X7R-5 100N |
C3, C4 | 22p | KERKO 22P |
D1, D2 | 3V6 zener | ZF 3,6 |
CON1 | USB-B | USB BW |
CON2 | 10pol | WSL 10W |
IC1 | ATmega8-16 | ATMEGA 8-16 (not programmed!) |
JP1, JP2 | 2pol 2,54mm | SL 1X36G 2,54 |
LED1 | 3mm LED green | LED 3MM 2MA GN |
LED2 | 3mm LED red | LED 3MM 2MA RT |
Q1 | 12Mhz | 12,0000-HC49U-S |
R1, R2 | 68 | 1/4W 68 |
R3 | 2,2k | 1/4W 2,2k |
R4, R5, R6, R7 | 270 | 1/4W 270 |
R8 | 10k | 1/4W 10k |
R9, R10 | 1k | 1/4W 1k |
M1, M2 | Jumper | JUMPER 2,54GL SW |
M3 | Socket 28S | GS 28-S |
M4 | Case | TEKO 10007 |
M5 | PCB | - |
User PCB layouts
Here is a list of tested PCB layouts. If you have designed your own PCB, please let me know.usbasp_single_side.t3001.zip by Thomas Fischl Single-Side PCB, TARGET 3001! layout file Size: 90x40 mm (optimized for case Hammond 1591ATBU) | |
lv_usbasp.tar.gz by Pawel Szramowski (11/2007) With Low-voltage front-end. Single-Side PCB, EAGLE layout files, some SMD components | |
by Bernhard Walle Double-Side PCB, EAGLE layout files, part list with order numbers for Reichelt.de and Conrad.de Size: optimized for case Hammond 1591ATBU | |
http://thomaspfeifer.net/atmel_usb_programmer.htm by Thomas Pfeifer Single-Side PCB, PDF layout files, SMD components | |
by Tomasz Ostrowski Single-Side PCB, PDF and EPS layout files, only four 0805 SMD parts, rest discrete components | |
USBasp_CH.zip by Christian Heigemeyr Single-Side PCB, with some SMD 0805 components, PDF-files With additional buttons for reset and disconnection of the target | |
USBasp.sch, USBasp.pcb ComponentSide.pdf, TopSide.pdf, Schematics.pdf by Zhurov Pavel Single-Side PCB, P-CAD 2002 format and PDF files Crosspiece TXD and RXD are added for the ISP connector | |
usbasp_gr.rar by J.A. de Groot The board is single sided (EAGLE format), measures 3 by 8 cm and uses only regular components. | |
usbasb_mg.zip by Matthias Görner Single-Side PCB, eagle-format, with PS/PDF-files integrated sockets for target chips ATmega8 and ATmega32 | |
Tarball with layout by Hannes Östlund Doubleside-Side PCB, SMD components, very small | |
by Sergiy Bogdancev (01/2010) 3.3V version, ATMega48 only. Single-side PCB, ExpressPCB layout format + socket board for varies AVRs. Without future serial interface, chip initially must be programmed with another programmer. | |
Eaglefiles (sch/brd) and CAD case design (dxf) by Hans Hafner, HTL Mössingerstrasse-Klagenfurt, Österreich, hans.hafner (at) htl-klu (dot) at (01/2010) CNC-milled case (DXF file available), Eagle layout, only a few SMD parts | |
Different USBasp versions: Easy to built non-smd, smd version and a very small USBasp by Sven Hedin (01/2011) Eagle files available. | |
USB Key AVR Programmer by Fabio Baltieri (09/2011) Very small USB key like dimensions. SMD parts. | |
AVR ISP Programmer by Jaroslav Vadel (04/2012) Small programmer. SMD parts. | |
Target project and PDFs (layout/schematics) by Marius Schäfer (09/2013) | |
tinyUSBboard with USBasp-compatible firmware by Stephan Bärwolf (04/2014) | |
USBasp on breadboard with socket for controller daughter boards. by Fabian Hummel (11/2018) | |
Tjaart van Aswegen designed an SMD board: DIP TRACE and GERBER files. by Tjaart van Aswegen (09/2019) | |
Feature rich (e.g. different voltage levels, integrated USB to serial converter, USB-C connector) USBasp compatible design. AVR Programmer Github project. by Brian Pepin (12/2019) | |
USBasp with ZIF socket and through hole components. by Bruno (04/2020) | |
USBasp board with additional 6pin header and selectable target supply (3.3V/off/5.0V). by Marty E. (10/2020) | |
John included a 40 pin universal socket which takes 8, 14, 20 and 28 pin devices. He also added a versatile crystal oscillator with outputs of 1, 2, 4, 8 and 16 Mhz to clock the chips. There is also the standard 6pin ICSP connector and a user led connected to the MOSI pin. by John P. (11/2020) |
Links
http://www.obdev.at/products/avrusb/ Firmware-only AVR USB driverhttp://libusb.sourceforge.net/ libusb
http://libusb-win32.sourceforge.net/ LibUsb-Win32
http://www.nongnu.org/avrdude/ AVRDUDE - AVR Downloader/UploaDEr
The CH340G USB-to-UART chip is used by a number of inexpensive development boards (e.g. WEMOS and LOLIN branded boards) and USB-to-serial adapters. It is manufactured by a Chinese company called WinChipHead or WCH (International web site, Chinese web site). Unfortunately, it often causes problems on macOS. This guide helps you resolve any problems you might have with the boards and adapters.
Like many USB-to-serial solutions, it requires a driver that creates the serial port when the board or adapter is plugged into a USB port of your Mac. Starting with macOS 10.14 Mojave, macOS provides suitable drivers out of the box, implemented by Apple itself. So no additional software is needed.
Main issues
There are three main issues:
- Most boards only work for upload speeds / data rates up to 460,800 bps.
- Many users have additional drivers from WCH or Repleo installed, either from earlier macOS versions or because of obsolete tips and instructions on the internet. With the additional drivers, two serial ports will be created and one of them will be non-functional. Furthermore PlatformIO will no longer be able to automatically select the port.
- There are many forums and web pages with instructions how to install the WCH driver. Unfortunately, they are obsolete. While they were helpful back then, they now cause additional trouble.
Setup
Usbasp Drivers Windows 10
Do not install any additional software for the CH340G if you are using the macOS 10.14 Mojave or later (including macOS Big Sur). macOS includes all the required components. Additional software will cause additional problems.
Usbasp Driver Windows 7
In your PlatformIO project, add the below line to platformio.ini
and you should be ready to upload your sketch:
If you have an older macOS version and cannot upgrade to the latest version, you can download the driver from here.
How to check for Apple drivers
macOS Catalina, macOS Big Sur and later:
should result in something like:
For macOS Mojave, check with ls -l /System/Library/Extensions
.
How to check for other drivers
You can check for additional drivers by executing (in a terminal):
The output will look something like this:
The last entry usbserial.kext
is the WCH driver. You should uninstall it (see below). The same would apply to the driver from Repleo. It’s called osx-ch341.kext
.
If you can’t see any of these drivers, also check ls -l /System/Library/Extensions
.
How to uninstall the WCH driver
To uninstall the driver:
- Unplug all boards/adapters with a CH340G chip
- Execute the following commands to first unload and then uninstall the driver:
If you remove the driver without first unloading it, you will have to reboot your Mac. If you stick to the order, no reboot is required.
If you want to remove a different driver or a driver in a different location, modify the command line, e.g.:
How to limit the upload speed
The CH340G and/or its driver do not reliably work with speeds of 921,600, yet that’s the default in PlatformIO for many boards. So the below line is required in platformio.ini
:
Monitor speed is usually 115,200 and therefore does not need to be changed.
Checking for the serial port
When you plug in your board, the serial port should appear in /dev
and have a name starting with ‘cu.’:
This is the list of all serial ports. /dev/cu.usbserial-1410
is the serial port created by Apple’s driver.
Usbasp Programmer Software
If the output however looks like so, there is a problem:
Two entries have been created for the same board because two drivers for the CH340G chip are installed. One of the ports will work, the other one will cause an error when a connection is attempted. The solution is to uninstall all non-Apple drivers (see above).
Troubleshooting
The general approach for troubleshooting is:
- Uninstall the WCH driver
- Limit the upload speed
- Reboot
Specific problems
Resource busy: ‘/dev/cu.usbserial-1410’
If a resource busy error, occurs, the selected serial port is most likely blocked by a second driver. Uninstalling the WCH driver or other non-Apple drivers (see above) should fix it.
Timed out waiting for packet content*
If a Timed out waiting for packet content error occurs, the upload speed is likely too high. Limit the upload speed (see above) to fix the issue.