Forum - MCS Electronics

 

FAQFAQ SearchSearch RegisterRegister Log inLog in

USBASP error: program enable: no answer. 1

 
Post new topic   Reply to topic    www.mcselec.com Forum Index -> BASCOM-AVR
View previous topic :: View next topic  
Author Message
wiera

Bascom Member



Joined: 06 Dec 2016
Posts: 4

germany.gif
PostPosted: Tue Dec 06, 2016 6:55 pm    Post subject: USBASP error: program enable: no answer. 1 Reply with quote

Hi,

my project includes an Atmega1284P (TQFP44 package) which shall be programmed via a Chinese USBASP programmer using the BASCOM-AVR IDE. Trying to identify the chip, the IDE provides the following error message at any attempt :Error: Program enable: no answer. 1 and the given Chip ID is wrong: either 000000 or FFFFFF.

This error is indicated with Auto, high or low clock frequency of the programmer. I am absolutely sure that the connections needed for programming are correct as well as the 10k resistor for reset pullup. The power supply is ok, too. As the programmer works well in a different project, it seems not to be faulty.

Can the 1284P have a defect? Has anyone a good explanation??

(BASCOM-AVR version : 2.0.7.6 , Latest : 2.0.7.8 )
Back to top
View user's profile
bzijlstra

Bascom Ambassador



Joined: 30 Dec 2004
Posts: 1179
Location: Tilburg - Netherlands

netherlands.gif
PostPosted: Tue Dec 06, 2016 7:27 pm    Post subject: Check forum Reply with quote

Have you done a search in this forum? I see something about libusb and also something about a firmware upgrade.

Ben Zijlstra
Back to top
View user's profile Visit poster's website
wiera

Bascom Member



Joined: 06 Dec 2016
Posts: 4

germany.gif
PostPosted: Tue Dec 06, 2016 10:25 pm    Post subject: Reply with quote

Yes, I did a search on the special error message and only found these general hints concerning USB driver and upgrade of the programmer. I am quite sure that the programmer is working fine, because I use it successfully in other projects with different processors. And BASCOM supports the 1284P chip since several years. In my opinion, the 1284P must be the problem.

Can anyone describe the intent and the reason of this error message in detail??
Back to top
View user's profile
Paulvk

Bascom Member



Joined: 28 Jul 2006
Posts: 1192
Location: SYDNEY

australia.gif
PostPosted: Wed Dec 07, 2016 12:11 am    Post subject: Reply with quote

The clock speed setting is problematic if you have a 20Mhz crystal on the 1284P
you will have to play with the clock speeds to find which one works.
Or you can change the fuse bit and use the internal 8mhz RC while programming
then change back after programming is complete
at lower cpu clock speeds I have found it more stable.
Regards Paul
Back to top
View user's profile
wiera

Bascom Member



Joined: 06 Dec 2016
Posts: 4

germany.gif
PostPosted: Wed Dec 07, 2016 12:41 am    Post subject: Reply with quote

Thank you, Paul.

I cannot change the fuse bits as long as the programmer is not able to connect to the chip and identify it. I played with the clock frequency of the programmer (which is adjustable in the BASCOM IDE) in the range of 8 kHz up to 1500 kHz with no success.

The 1284P chip (brand new) is equipped with an external crystal of 16 MHz and the recommended capacitors. If you apply the power to this brand new chip: would the oszillator already work, even if the fuse bits perhaps claim for the internal oszillator?? I cannot see any oszillation at the crystal pins of the chip in my circuit (oszillograph).
Back to top
View user's profile
Paulvk

Bascom Member



Joined: 28 Jul 2006
Posts: 1192
Location: SYDNEY

australia.gif
PostPosted: Wed Dec 07, 2016 10:52 am    Post subject: Reply with quote

If the 1284P is new and has default fuse bits
8Mhz RC with divide by 8 set so 1Mhz clock

Note I have not used a 10K pullup on my boards with 1284P have both 40pin dip and 44pin tqfp

Regards Paul
Back to top
View user's profile
EDC

Bascom Expert



Joined: 26 Mar 2014
Posts: 677

poland.gif
PostPosted: Wed Dec 07, 2016 12:07 pm    Post subject: Reply with quote

TopicOwner check that use version 2076.
In history.txt attached to version 2079 you can read "- usbasp programmer updated. chosen clock frequency will work. "
I dont know why someone want to use older Bascom version but then I will use some other tools to set fuse bits.
..and some of this chinese USBasp have old firmware that even not handle set CLK by software so you must reprogram it with soft from fishl.de site software.
Back to top
View user's profile Visit poster's website
wiera

Bascom Member



Joined: 06 Dec 2016
Posts: 4

germany.gif
PostPosted: Tue Dec 13, 2016 11:38 pm    Post subject: Reply with quote

Hi,

the problem has been solved! Just for the fans who are interested in the solution:

By programming the fuse bits, I changed the internal RC oszillator to the external crysral oszillator. But the external oszillator did not work, as on of the capacitors connected to the crystal was shorted. After replacing of the capacitor, the external oszillator worked fine and I could address the chip via BASCOM-IDE and USBASP, even with higher clock frequency of the programmer.

As a side action: concerning the ATMEGA48 the BASCOM IDE V2.0.7.6 works very well with the chinese USBASP programmer from betemcu V 2011/03/05 in cluding the change of the programmer's clock frequency.

Thanks for the assistance!
Back to top
View user's profile
Display posts from previous:   
Post new topic   Reply to topic    www.mcselec.com Forum Index -> BASCOM-AVR All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum