Help in programming the Atmega1284 with maniacbug-mighty-1284p.

It's pretty clear that the problem symptom is real for many people, as well as it's true many people have not seen the same problem symptom. The low pass filter does seem to be a 'solution' for many that are seeing that problem. Atmel does not seen to have ever claimed it's a chip internal problem, but rather they speculate that it's most likely a problem that may be caused by noise coupling from the chips clock lines pin(S) to the RX0 pin, so circuit layout external to the chip may be a variable that increases or decreases the possibility of one having the problem, and is supported by the observation that it's only been seen in DIP packaged 1284P chips. Changing to a bootloader that uses the second serial port has been a solution for some that have experienced the problem also.

My participation on this topic has been mostly academic and I just mostly passed on what I had read on the avrfreaks site (which I consider credible on this topic), and from what I've read on postings on this site. I'm still waiting for my 1284P chip to arrive from a slow boat from China (Futurlec, known for good prices and slow deliveries). So far using CrossRoads' 1284P through hole duem.. style board, I've seen no uploading problems using a 644P chip (even with a 60KB test sketch), but I am at least now knowledgeable to know what may or may not happen when I finally do get my 1284P, and possible solutions if indeed I see the uploading problem.

Lefty

Uploading small sketches is fine. I can load the blink sketch via serial every time. It only manifests with larger sketches, even 20k sort of size.

Atmel does not seen to have ever claimed it's a chip internal problem, but rather they speculate that it's most likely a problem that may be caused by noise coupling from the chips clock lines pin(S) to the RX0 pin, so circuit layout external to the chip may be a variable that increases or decreases the possibility of one having the problem,

That seems to be a new piece of information, unless I missed it in the jumble.

oric_dan(333):

Atmel does not seen to have ever claimed it's a chip internal problem, but rather they speculate that it's most likely a problem that may be caused by noise coupling from the chips clock lines pin(S) to the RX0 pin, so circuit layout external to the chip may be a variable that increases or decreases the possibility of one having the problem,

That seems to be a new piece of information, unless I missed it in the jumble.

It was a passing comment by one (or a couple of) avrfreaks poster that apparently sought out ATMEL's help, he was told effectively to clean up his circuit layout. That coupled with the fact that the problem is never mentioned in the errata section of any published Atmel datasheet for the 1284P lends credence to that 'speculation'.

Lefty

It was a passing comment by one (or a couple of) avrfreaks poster that apparently sought out ATMEL's help, he was told effectively to clean up his circuit layout.

This probably explains why Bob's boards "don't" show the problem.

oric_dan(333):

It was a passing comment by one (or a couple of) avrfreaks poster that apparently sought out ATMEL's help, he was told effectively to clean up his circuit layout.

This probably explains why Bob's boards "don't" show the problem.

That could very well be and I will add or subtract from that speculation when my 1284P chip finally arrives. :smiley:

Lefty

tack:
Uploading small sketches is fine. I can load the blink sketch via serial every time. It only manifests with larger sketches, even 20k sort of size.

In my tests, the synch problems manifest both with small (Blink) o large sketches. Simply, without RC filter the chip doesnt' respond to the data sent through the serial line.

retrolefty:
It was a passing comment by one (or a couple of) avrfreaks poster that apparently sought out ATMEL's help, he was told effectively to clean up his circuit layout.

Uhm. this has a sense for me. Since today, I've only tested the 1284P on a breadboard because I didn't want to make a board for the serial programming using the bootloader if I wasn't SURE that I could do that to upload a sketch.

Uhm. this has a sense for me. Since today, I've only tested the 1284P on a breadboard because I didn't want to make a board for the serial programming using the bootloader if I wasn't SURE that I could do that to upload a sketch.

Well that leaves you in a catch 22 situation doesn't it? :smiley:

So maybe make provisions in your PCB to install a resistor/cap filter near the RX0 pin and just don't install the components and jumper around them with a wire jumper or a 'zero' ohm resistor if testing proves they are not required with whatever layout you end up using.

Lefty

The only times I have trouble with serial downloading is when I accidentally leave the DTR cap off, or forget to burn the bootloader first. I'm slowly getting better about that! :grin:

CrossRoads:
The only times I have trouble with serial downloading is when I accidentally leave the DTR cap off, or forget to burn the bootloader first. I'm slowly getting better about that! :grin:

So OK fess up. Did you purposely do some 'special' PCB layout for the clock/RX0 lines on your 1284P boards being aware of the possible problems of noise interactions with serial communications? Or did you just get lucky. :smiley:

Lefty

In one of my earliest design postings here, someone like Grumpy_Mike mentioned that it was good practice to not have signals going under the crystal.
When I wirewrap cards, the crystal is right next to the xtal pins also, with no wires crossing them.
This also goes along with Atmel's Design Consideration app note, see Section 5.
Being an electrical engineer who designed for the defense industry, I know how to follow good design practices.

"Atmel AVR042: AVR Hardware Design Considerations" Rev. 2521K-AVR-03/11

AtmelAVR042 AVR Design Considerations.pdf (236 KB)

retrolefty:
Well that leaves you in a catch 22 situation doesn't it? :smiley:

ROTFL :stuck_out_tongue_closed_eyes:

So maybe make provisions in your PCB to install a resistor/cap filter near the RX0 pin and just don't install the components and jumper around them with a wire jumper or a 'zero' ohm resistor if testing proves they are not required with whatever layout you end up using.

Good solution :wink:

CrossRoads:
Being an electrical engineer who designed for the defense industry, I know how to follow good design practices.

:wink:

EDIT:
link doesn't work :stuck_out_tongue:

Link works, its a forum wide problem. No downloads are working.

Just figured out why I couldn't find an online link earlier - I was searching at maxim-ic.com for it :blush:
I can design, I just can't surf 8)

I am using one of CrossRoad's Bobuino boards for a project of mine. I have loaded variations of my sketch about 50+ times with no problems. The date code is 1050.

Sketch size currently is:

Binary sketch size: 28,640 bytes (of a 130,048 byte maximum)

Estimated used SRAM memory: 2,352 bytes

cyclegadget, how did you get it to display SRAM memory usage?

How does one tell the datecode? Is it stamped on the chip under the p/n, like where
mine says 1216?

I have a bit more of information. First off, I've been reading through the interminably
long thread "ATmega1284P: End to End using 1.0 IDE", and there were gazillions of sketch
uploading and other problems over there, fuse settings/whatever. Was anything finally
resolved, or just a bunch of suggestions proferred?

http://arduino.cc/forum/index.php/topic,80483

My bit of information is, I've been uploading good-sized 32KByte sketches to my 1284 by
the bushload, using IDE 1.0 and 1.3, and using both FTDI cable and FTDI Friend, and not
seen even a single glitch.

I do have the 1284, and not the 1284P, chip programmed with the Bobuino variant of
maniacbug's v4.5 optiboot.

Secondly, my board here is a hacked proto typing shield with a lot of soldered wires and
a lot of wirewraps. In fact, the connection to the RX0 pin is a 3" long wirewrap wire
that I have now purposely strung "between" the crystal pins, just to try and inject some
extra noise onto RX0.

So, no low-pass filter on RX0, RX0 signal passing in between crystal pins, large 32KB
sketch, and nary an uploading glitch after several dozen burns. So, all in all, ...
no problema. Maybe the moon here is in its happy phase, or because I'm playing
Mozart. ???

oric_dan, yes, 1216 is the data code.

oric_dan:
cyclegadget, how did you get it to display SRAM memory usage?

I use ERW Arduino IDE http://arduino.cc/forum/index.php/topic,118440.0.html

I had to added the Bobuino board .txt file to make it work but, it is a very similar process to the standard Arduino IDE.

Also, I just realized that my chip is a 1284P if that makes a difference on my earlier statements. I know for a fact that I am using the maniacbug bootloader as I installed it myself to make sure I had the latest and greatest bootloader.

CrossRoads:
oric_dan, yes, 1216 is the data code.

And it is usually decoded as year 20(12) and week(16) or possibly batch(16)

Lefty