Society of Robots - Robot Forum
Electronics => Electronics => Topic started by: Jdog on December 02, 2008, 03:01:46 PM
-
Hi, I upgraded my microcontroller to the Atmega168. I downloaded the new ponyprog which is compatible with the Atmega168. When I go to upload my code for the 50$ robot everything starts to work but at the very end of writing it it says write failed.
-
Disconnect servos and servos from microcontroller while programming , make sure microcontroller is firmly plugged in , make sure battery is charged
-
I have done all of that, and ponyprog does recognizes it.
-
When using avr studio i chose atmega168. Should I have chosen Atmega 168P?
-
ATmega168P is a different device. you're fine with what you have. Make sure you choose ATmega168 in PonyProg also, and do the probe and test and all that according to the tutorial about ponyprog on here.
-
Do I need a different program for the new microcontroller?
-
The program for an ATmega8 will not work on an ATmega168. You must compile it for the microcontroller you plan to use.
-
you also have to make updates in global.h as well as your makefile, but this is all talked about in the atmega168 upgrade tutorial.