Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

[SOLVED] Chip Enable Program Error with 8051 MCU(AT89S51)

Status
Not open for further replies.

Mithun_K_Das

Advanced Member level 3
Advanced Member level 3
Joined
Apr 24, 2010
Messages
899
Helped
24
Reputation
48
Reaction score
26
Trophy points
1,318
Location
Dhaka, Bangladesh, Bangladesh
Activity points
8,254
I've no previous experience with 8051 MCUs. Recently I was trying to work with AT89S51 MCU.
I'm having Chip Enable Program Error when trying to upload hex to MCU using Progisp1.72
001.PNG

I checked many times to ensure this wiring to connect with MCU:
89sxx-ISP-circuit.GIF

Tried two different usbasp programmers and in the last made one to test.
I was able to upload hex to Atmega8, 328, and 32 with these 3 programmers.
IMG_20200311_173416.jpg

Whenever I try with AT89S51, same Chip Enable Program Error. Tried changing Crystal with 4MHz, 11.059MHz, 12MHz. Same problem.

Any suggestion ?
 

Not sure about what exact procedures you did, but since the message log right bellow give indication of a sucessful Write, I would check how fuses are set ( e.g code protect, oscillator ). Try uploading a simple blink led to check at least if something works, even at a wrong timming.
 

Yes, I took a hex file of simple blink led from mikroC example file (which I changed the MCU only) and tried to upload that. But can not even erase the AT89S51. Seems like the USBasp can not detect or not getting any response from MCU. I checked the wiring. It was as like this one: 89sxx-ISP-circuit.GIF

I'm not sure if I missing anything else.
 

From the above picture, the IC on the breadboard seems like being AT89C51, not the AT89S51 you mentioned.
 

seems like being AT89C51, not the AT89S51 you mentioned
Good catch! AT89C51 doesn't support ISP (in circuit serial programming).
 

From the above picture, the IC on the breadboard seems like being AT89C51, not the AT89S51 you mentioned.

OH!!!! I did not noticed that before. Dosen't AT89C51 support ISP?

- - - Updated - - -

I have collected AT89S52 and tried again replacing the IC name in the software and in the project board. But same problem. Am I missing something?

IMG_20200312_112921.jpg

s52.PNG

- - - Updated - - -

I found a user guide of USBasp programmer. They are mentioning that the supported MCUs (page: 5), in that list there is no AT89 series. But on the other hand found many guideline online where many people used USBasp to program AT89S52. I've attached the document here.

list.PNG
 

Attachments

  • User_Guide.pdf
    4.4 MB · Views: 412

Finally I solved after working on it for last few days. Now I can program AT89S51 with USBasp. The problem was the USBasp Firmware. I found that the Chinese one can program 8051 series MCUs. But the standard German one doesn't support 8051. So I took the Chinese one and read the flash and eeprom. Then burned it into a fresh Atmega8A which I used as the MCU of the USBasp programmer. Now I can upload the hex to 8051!!!

Capture.PNG
IMG_20200315_143708.jpg

- - - Updated - - -

Instruction to others who are having similar problem is collect a Chinese one, Connect with it to another USBasp(any) programmer. Read the flash and eeprom. Then burn these two files to your Atmega8A MCU to make a new USBasp programmer which can program 8051 series MCUs.

- - - Updated - - -

Or I've attached these files. You can use these too.
 

Attachments

  • USBasp Chinees Firmwire for 8051 series.rar
    5.3 KB · Views: 461
Just made this simple USBasp. You can try it too.

IMG_20200316_172837.jpg

- - - Updated - - -

Bottom side of the PCB.
00356.jpg
 

Attachments

  • USBasp.pdf
    43.7 KB · Views: 266
  • PCB_USBasp.pdf
    41.1 KB · Views: 204
Finally I solved after working on it for last few days. Now I can program AT89S51 with USBasp. The problem was the USBasp Firmware. I found that the Chinese one can program 8051 series MCUs. But the standard German one doesn't support 8051. So I took the Chinese one and read the flash and eeprom. Then burned it into a fresh Atmega8A which I used as the MCU of the USBasp programmer. Now I can upload the hex to 8051!!!

View attachment 158189
View attachment 158190

- - - Updated - - -

Instruction to others who are having similar problem is collect a Chinese one, Connect with it to another USBasp(any) programmer. Read the flash and eeprom. Then burn these two files to your Atmega8A MCU to make a new USBasp programmer which can program 8051 series MCUs.

- - - Updated - - -

Or I've attached these files. You can use these too.

Thank mate, that chinese firmware working fine, another usbasp for 8051 firmware not work
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top