AVR microcontroller cannot enter programming mode

Go To Last Post
8 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

With the new ATMEGA32A chip, I can read the voltage value but not the device address when I download the program to the AVR microcontroller, so I can't enter the programming mode, do I have to set the fuse bit or something before connecting to the microcontroller?

This topic has a solution.
Last Edited: Thu. Aug 5, 2021 - 08:18 AM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

what programmer are you using?

what is your set programming speed ( should be 125KHz or less )?

what software tool are you using ?

what is your power supply?

What are your connections?

 

Assume you do have decoupling caps on the processor.

Assume you have tripple checked that your connections are OK.

 

keep in mind that until you can successfully read back the device signature of the chip there is no need to even think about programming.

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

You have posted in the Arduino forum, but stated that you are using the ATMEGA32A chip. Is there an inconsistency there?

Ross McKenzie, Melbourne Australia

Last Edited: Wed. Aug 4, 2021 - 01:40 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Jimli wrote:
I can't enter the programming mode

Please clarify that:

  • How, exactly, are you attempting to "enter the programming mode" ?
  • What tools are you using?
  • Are you getting any error messages? if so, please post them

Top Tips:

  1. How to properly post source code - see: https://www.avrfreaks.net/comment... - also how to properly include images/pictures
  2. "Garbage" characters on a serial terminal are (almost?) invariably due to wrong baud rate - see: https://learn.sparkfun.com/tutorials/serial-communication
  3. Wrong baud rate is usually due to not running at the speed you thought; check by blinking a LED to see if you get the speed you expected
  4. Difference between a crystal, and a crystal oscillatorhttps://www.avrfreaks.net/comment...
  5. When your question is resolved, mark the solution: https://www.avrfreaks.net/comment...
  6. Beginner's "Getting Started" tips: https://www.avrfreaks.net/comment...
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Jimli wrote:
so I can't enter the programming mode,
RESET must be active.

Jimli wrote:
do I have to set the fuse bit or something before connecting to the microcontroller?
No

 


datasheet via ATMEGA32A | Microchip Technology

[page 269]

After RESET is set low, the Programming Enable instruction needs to be executed first before program/erase operations can be executed.

[page 270]

Figure 27-10. SPI Serial Programming and Verify

 

"Dare to be naïve." - Buckminster Fuller

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

First, verify you have power to both sets of power pins (10/11) and (29/30) and both pair of pins have decoupling caps (100nf) near the pins.

now, I'll assume your attempting to do a serial SPI programming, if not let us know.   you need the following pins connected to your ISP programmer.

MOSI - PB5, MISO - PB6, SCK - PB7, along with reset, vcc, and gnd.    now try to read the device signature with the ISP clock set to 125kHz

 

Let us know if that works.

 

Jim

 

 

Keys to wealth:

Invest for cash flow, not capital gains!

Wealth is attracted, not chased! 

Income is proportional to how many you serve!

Lets go Brandon!

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

valusoft wrote:

You have posted in the Arduino forum, but stated that you are using the ATMEGA32A chip. Is there an inconsistency there?

From other threads it seems he is trying to use an Arduino in "Arduino ISP" mode to program an off-board m32. So there is an Arduino involved in the picture I believe.

This reply has been marked as the solution. 
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 1

I use zf-007 series downloader.

When I downloaded the ISP, there was a watchdog circuit connected to the RESET on the board, and when I disconnected it I found there was no more problem.