In this article, we are going to learn how to make a programmer program the 8051 MCU series. Once I got in trouble with this issue but solved it too. You can get help from my experience too. There are many examples online but very few of them really work. Many people published videos on this but if you try yourself, in most cases you are going to fail. Today, you’ll learn the secrete behind this. So let’s make our 8051 MCU Programmer.

Disclaimer: Electricity is always dangerous. Proper skill is required to work with electricity. Do work at your own risk. The author will not be responsible for any misuse or harmful act or any mistake you make. The contents of this website are unique and copyright protected. Kindly don’t do any nonsensical act copying and claiming it as yours. Most of the articles published here are kept as open-source to help you. Take the knowledge for free and use it, but if you are interested you can buy the ready resources offered here. If you need any help or guide feel free to comment below, the author will try to help you. Thanks.

About 8051 MCU series:

The 8051 micro-controller is one of the most popular and most commonly used micro-controllers in various fields like embedded systems, consumer electronics, automobiles, etc. Technically called Intel MCS-51 Architecture, the 8051 micro-controller series was developed by Intel in the year 1980 and was very popular in the ’80s (still are popular).

The 8051 Micro-controller has many features like Serial Communication, Timers, Interrupts, etc. and hence many students and beginners start their work on the concept of Micro-controllers with 8051 Micro-controller (although this trend seems to be changed with the introduction of Arduino).

Even though 8051 Micro-controller might seem a little bit out of fashion, we feel that it is one of the best platforms to get started with microcontrollers, Embedded Systems, and Programming (both C and Assembly). 

8051 MCU (AT89C51)

The 8051 MCU series have several micro-controllers on the list. Among this list, AT89C51/52, AT89S51/52 are the most popular. C series have serial programming options but we can program the S series with a USBasp programmer. Here in this article, we’ll learn to make a programmer program 89S52 MCU.

AT89S52 pin diagram

You may need this one too: PICKit2 PIC programmer.

Programming 89S52:

If you search over the internet how to program 89S52 micro-controller then you’ll get tons of result programming with a USBasp programmer. A programmer like this one will come in the front line:

Common USBasp programmer

You’ll need software for this programmer. Many people suggest using Progisp1.72. This one is very easy and popular for the 8051 series. You can program AT89S51/52 with this programmer.

Progisp1.72 window

You can find other software for USBasp programmers from here. But as we are discussing the 8051 series, I’ll discuss programming 89S52 MCU. Note that 89S51 works in a similar way.

USBasp programmer:

One day I got in trouble with this issue. I had to make my custom USBasp programmer for a product where the programmer has to be built-in with other circuits on a single board. I could use a USBasp dongle programmer but that would never look good for that product.

Chinese USB asp

I started searching about programming 89S52, got tons of results with USBasp. Collected 3 types of programmers from the local market and tested each of them. The Chinese one supports AT89S52 but the German one which I found locally doesn’t support AT89S52. I was confused about this issue which one to use.

I found a circuit diagram for USBasp online and made a test PCB for that to test if my programmer works. I found the firmware in which is actually German-based. Tested my programmer, it can program ATmega8 but can not detect AT89S52. I found ‘Chip Enable Program Error’.

Error message

My USBasp programmer:

Making a USBasp programmer is very easy as it is open source. You can find this circuit diagram over the internet:

USBasp programmer circuit diagram

I made my own PCB using this circuit diagram. Although I removed some parts of it it was not so important to keep.

Here is my programmer:

Problem Solving:

After copying the firmware from the Chinese one (.HEX and EEPROM) I loaded them to Atmega8A of my USBasp programmer with the help of AVRDUDE.


When programming your Atmega8, set L fuse to 0xEF and H fuse to 0xC9. And select the flash(here you’ll get a bin file which will work fine) and EEPROM file. Then program. And it works!. Yes, it can detect and I can program At89S52 MCU.

Successful programming AT89S52

I made a video on this too:

Programming 89S82 with USBasp programmer


I made PCB for my USBasp programmer. And this is tested ok. For your own, you can use it too:

PCB for my USBasp programmer test version


USBasp is an open-source programmer. And I think, there is no such credit claiming that I made it. But my experience sharing may help you to solve your problem and make your work easy. That is why I’m gladly kept it open source for all of you.

Here are the files which you can download and make your own USBasp programmer for the 8051 series with other standard MCUs.

Download PCB file.

Download Firmware.

Download ziadag [driver installer].

I thank all the contributors who made it easy and open-source [USBasp programmer]. And thank you too for reading up to this. I hope you got a similar problem and now you can solve your problem too. If you need any help, feel free to contact me. Thank you.


JLCPCB – Only $2 for PCB Prototype (Any Color)

24 Hours fast turnaround, Excellent quality & Unbeatable prices

$18 Welcome Bonus for new registrations Now!!!

Check this out: 5 coolest multimeters you can buTop 5 Digital Multimeters for beginners

Lab Projects BD

This is a personal electronics blog. The author loves to write on different topics and shares his knowledge to help others.


Starlyte · June 3, 2021 at 5:52 pm

Thank you very much for the tutorial pcb and all. Very complete and helpful.

Leave a Reply

Avatar placeholder

Your email address will not be published. Required fields are marked *