Simplest 128 atmega programmer

Atmega 128 is like other AVR microcontrollers. They are ISP – is in-system programmable. Earlier I wrote an article about an AVR ISP programmer where 74HC244 buffer is used. Using buffer is safer for your AVR.

But what if you need 128 atmega programmers without any parts? Then you can connect your microcontroller directly to the LPT port or use protection resistors (220R) just in case. of course circuit works without resistors, but you put your LPT port at risk.

Just connect GND, SCK, MISO, MOSI, and RESET to adequate LPT pins, and you can program atmega’s flash memory without removing it from a socket. Programming software can be PonyProg


  1. Thank’s for your information. It’s a good web (with a spirit of Ubuntu)

  2. “device missing or unknown device(-24)”
    massage is displayed
    “ignore” not fix it
    Plese help.

  3. Doe’s your PonyProg settings look like:

  4. Can i use that for atmega8 ?

  5. yes you can. it works wit all AVR microcontrollers that support ISP programming interface.

  6. I made a simple serial-port isp programmer. The control lines are the same,i just use a tri-state buffer to “protect” the avr. (It’s working because I’ve successfully tested it with 90s2313)
    Then I connected it to mega128: miso/mosi lines connected to chip’s E1 and E0, reset pulled-high (10k), 8mhz crystal (22pF capacitors), sck, every gnd and vcc connected (i also connected agnd)
    Reading failed (invalid signature)…
    I examined the datasheet carefully and noted PEN\ pin… It says it should be kept low for spi programming…I tried to program the chip both ways (PEN\ untouched, and holding it low) but none worked. however ponyprog atmega128 connection schematic doesn’t mention any connection to this pin. I would like to know what’s the correct configuration…
    btw…the distance between the programmer and the avr is about 20cm of ordinary wire.. (with a breadboard in the middle of the way…) can it interfere?
    Thank you!

  7. For Atmega128 The MOSI/MISO pins are PE0 and PE1 for data in SPI Programming mode. Look in Atmega128 datasheet page 304.

  8. yes…i said that on the first msg(pins E1 and E0)…. i double checked it again, and It keeps unworking.. what can it be?… I shorted the crystal connection… (the 10mhz crystal was 20cm away from the chip).. can it be an “isp-unprogramable” chip? or is the chip damaged anyhow?

  9. btw…can the avr get damaged by a static discharge? I have always handled it by hand…i noticed that when i hold the device on reset, some IO pins remain high….that isn’t normal, is it?

  10. Can i use that for atmega32 ?

  11. Of course you can. It is same ISP programmer for all AVR microcontrolles.

  12. i get “device missing or unknown device(-24)” with exactly the same circuit as above and the powerlines.

    i got atmega162 and im using lpt1 (with reset inverted)


  13. i now stuck at writing program part.
    i tested the probe and it is fine.
    then i try is it can detect my chip, then i click read device, and it can run.
    then i open my hex file, when i press write , and it stuck and my pc hang at there, any steps i done wrong or …any step i miss it?? thx for last msg reply since the last msg b4 i post is on august,..very happy..thx

  14. LPT pins 20 : 25 should be connected to ground. I’ll test that.

  15. hi guys..

    want to ask ur favour..can u give me the spi connection circuit of atmega 16 using ps2 joystick?

  16. hi guys.. i’ve also tired this technique.. but not working. Ponyprog says error (-24) device not found. anyupdate?? what have i done wrong?? idea ? i’m using ATMEGA32L PLZ PLZ PLZ help.. i need it very badly.

  17. Working from first try with ATMEGA 8/8L

    Thank you.

  18. dude it keeps on giving the same message over and over even after i change the layout “device missing or unknown device(-24)”
    i even tried connectin a vcc
    no use 🙁
    the probing works fine and so does the calibration…but i cant seem to read or write
    need help FAST!

  19. Thank you for the note to use PE0, PE1 I was using MISO and MOSI, your reply save my time.. every thing is OK now .

  20. i wish i had the chance to study in your country for this much that i have done but i still know that i am coming to explode there just by next year so be expectant

  21. i am using atmega32, all the settings are done according to the figure,probe gives test ok, when i try to write it gives “device missing or unknown device(-24)” then ignoring it gives something else, it writes 100%, verifies 100% then it gives writing failed.what am i doing wrong ? does it really work ? any help is appreciated….thanx.

  22. bit d7 dosn’t work in my pc i excute som prog. in it why is so it?

  23. always error 24 mising devise bur test connection ok, how plz

  24. Hello i made the device and i think that works ok because no errors from ponyprog but when i try to read flash and eeprom from the already programmed device i only get this: \FF FF FF FF\ exept if i read the calibration byte that returns 0x99.
    what happend???
    thanks the device is a atmega1281

  25. im using ATmega32.
    and getting the same programming problem.
    device not found.

    ny ohter circuit or site rreference…plz reply asap

  26. I had the same problem – error “device missing or unknown device(-24)”. May sound incredible, but in my case what helped, was to replug the lpt connector.

  27. Hi guys,

    i have the -24 error as many other people do but it seems that nobody care, there a many requests for the same issue and no single answer.

    It used to work in the past with other (older) computers.I have tried winXP32, Win7-32.


  28. Hello all, can this programmer supports to program the IC AT89S51 or AT89Sxx…?

  29. Hello!
    I wonder can this simplest ever design be used on AT89c5131A -UL ??

  30. Guis, it works! But AVR chip needs to be powered up. I powered up Attiny 26 from the computr’s supply, and it works well! Tested!
    The resistors in my case are 330 Ohms for more LPT security.

Leave a Reply