NerdKits - electronics education for a digital generation

You are not logged in. [log in]

NEW: Learning electronics? Ask your questions on the new Electronics Questions & Answers site hosted by CircuitLab.

Microcontroller Programming » Newbie needs help with first attempt at flashing....

December 11, 2010
by mbobak
mbobak's Avatar

Hi all,

I'm trying to flash my first program, (the initialload.c example code).

It compiled fine, but, when I get to the flashing step, I get:

C:\Documents and Settings\Mbobak\My     Documents\Downloads\NerdKits\Nerdkit_Code\Co
de\initialload>make
avrdude -c avr109 -p m168 -b 115200 -P COM5 -U flash:w:initialload.hex:a

Connecting to programmer: .
Found programmer: Id = "  ""; type =
Software Version =  . ; Hardware Version =  .
avrdude: error: buffered memory access not supported. Maybe it isn't
a butterfly/AVR109 but a AVR910 device?
make: *** [initialload-upload] Error 1

Anyone have an idea what my problem may be?

Thanks,

-Mark

December 11, 2010
by met_fredrik
met_fredrik's Avatar

Sure the MCU is set to programming mode? And the COM port is the right one? :)

December 11, 2010
by hevans
(NerdKits Staff)

hevans's Avatar

Hi mbobak,

met_fredrik is exactly right. The error you are getting is a pretty generic error that pretty much means your computer can't talk to your MCU. Make sure all the wires are nice and snug, make sure your battery connections are right, and make sure you are in programming mode.

If you still can't it to work post some good close up pictures, we might be able to help you find the issue.

Humberto

December 11, 2010
by mbobak
mbobak's Avatar

Hi Guys,

Thanks for your reply. Yes, double checked, I'm on COM5. And the programming mode, that's with the switch 'up', that is, closed on pins 24 and 25, correct?

At this point, I think I'm going to strip it down and recheck all the wiring.

Also, I think the project for tomorrow is going to be to build a mounting board, so I can mount my breadboard, battery, and LCD, so that they are in a fixed position relative to each other. Right now, seems I'm stumbling and pulling wires when reaching for other wires, and I've got a bit of a tangled mess on my hands.

-Mark

December 11, 2010
by mbobak
mbobak's Avatar

Making progress!

C:\Documents and Settings\Mbobak\My Documents\Downloads\NerdKits\Nerdkit_Code\Co
de\initialload>make
avrdude -c avr109 -p m168 -b 115200 -P COM5 -U flash:w:initialload.hex:a

Connecting to programmer: .
Found programmer: Id = "FDL v02"; type = S
    Software Version = 0.2; No Hardware Version given.
Programmer supports auto addr increment.
Programmer supports buffered memory access with buffersize=128 bytes.

Programmer supports the following devices:
    Device code: 0x35

avrdude: AVR device initialized and ready to accept instructions

Reading | ################################################## | 100% 0.02s

avrdude: Device signature = 0x1e9406
avrdude: NOTE: FLASH memory has been specified, an erase cycle will be performed

         To disable this feature, specify the -D option.
avrdude: erasing chip
avrdude: reading input file "initialload.hex"
avrdude: input file initialload.hex auto detected as Intel Hex
avrdude: writing flash (7808 bytes):

Writing | ################################################## | 100% 1.22s

avrdude: 7808 bytes of flash written
avrdude: verifying flash memory against initialload.hex:
avrdude: load data flash data from input file initialload.hex:
avrdude: input file initialload.hex auto detected as Intel Hex
avrdude: input file initialload.hex contains 7808 bytes
avrdude: reading on-chip flash data:

Reading | ################################################## | 100% 0.97s

avrdude: verifying ...
avrdude: 7808 bytes of flash verified

avrdude done.  Thank you.

Yay!

Of course, now I switch program mode off, and power cycled the system, and I get nothing....so, I'm sure it's just a loose connection somewhere. I'll be better off when I get this stuff mounted.

FYI, my bonehead move that was causing my problem? At some point, the battery power became detached, when I plugged it back in, I plugged it in on the right side instead of the left. As soon as I moved it to the left, I was in business!

Thanks for the help, I'm sure I'll have many more questions as I progress.

-Mark

Post a Reply

Please log in to post a reply.

Did you know that a square wave sounds different than a sine wave? Learn more...