1 (edited by driggers 2016-02-04 18:45:10)

Topic: firmware sanguinololu 1.3a: The COMPLETE saga

EDIT: This is now solved. See the second post.

I didn't want this to be a forum post.  But nothing works and I need to log what I've tried.

I have a Solidoodle 2 (SD2) with Sanguinololu 1.3a.  It has the auto reset pins jumped, so I shouldn't have to mess with reset button tricks...

I have done a loop-check to make sure that the ftdi and board are responding to serial comments (jump rx to tx on the back of the board and type stuff in the serial monitor).
I have made sure to select the right COM port and board each time.
I have installed and reinstalled ftdi drivers

Using stuff from:
https://github.com/jmgiacalone/sanguino1284p
https://github.com/mlaws/solidoodle2-marlin
https://github.com/ozadr1an/Solidoodle- … in_v1_beta

I instructed a helfpul ebayer to bootload and send me a new atmega1284p-pu as in https://github.com/jmgiacalone/sanguino1284p
He assures me that the fuses are set properly.

I have tried on Mac OS 10.11:
1. Arduino022 with the extras from https://github.com/jmgiacalone/sanguino1284p
2. Solidoodle-Arduino1.0.5 from https://github.com/mlaws/solidoodle2-marlin
2.b Arduino1.0.5 with the extras from https://github.com/jmgiacalone/sanguino1284p

I have tried on Win XP
3. Arduino022 with the extras from https://github.com/jmgiacalone/sanguino1284p
4. Solidoodle-Arduino1.0.5 from https://github.com/mlaws/solidoodle2-marlin
5. Solidoodle-Arduino022 from https://github.com/ozadr1an/Solidoodle- … in_v1_beta
6. Arduino1.01 with the extras from https://github.com/jmgiacalone/sanguino1284p
7. Arduino1.0.5 with the extras from https://github.com/jmgiacalone/sanguino1284p

1 and 2 give avrdude: ser_recv(): programmer is not responding errors, so I think something could be wring with my drivers.  I also don't operate the printer from this computer, so who knows.
2b didn't compile (for the curious https://gist.github.com/anonymous/95211659fbf9c01d1ebf)

3-7 all compile, but the upload throws various errors.  See below for the error on 5 (and possibly 4).  The error for 7 is a stk500_getsync() error.

Binary sketch size: 56180 bytes (of a 129024 byte maximum)
C:\Documents and Settings\Alejandro\My Documents\arduino-0022-solidoodle\arduino-0022\hardware/tools/avr/bin/avrdude -CC:\Documents and Settings\Alejandro\My Documents\arduino-0022-solidoodle\arduino-0022\hardware/tools/avr/etc/avrdude.conf -v -v -v -v -patmega1284p -cstk500v1 -P\\.\COM6 -b57600 -D -Uflash:w:C:\DOCUME~1\ALEJAN~1\LOCALS~1\Temp\build2584711671451896310.tmp\Marlin.cpp.hex:i 

avrdude: Version 5.4-arduino, compiled on Oct 11 2007 at 19:12:32
         Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/

         System wide configuration file is "C:\Documents and Settings\Alejandro\My Documents\arduino-0022-solidoodle\arduino-0022\hardware/tools/avr/etc/avrdude.conf"

         Using Port            : \\.\COM6
         Using Programmer      : stk500v1
         Overriding Baud Rate  : 57600
avrdude: ser_open(): setting dtr
avrdude: Send: 0 [30]   [20] 
avrdude: Send: 0 [30]   [20] 
avrdude: Send: 0 [30]   [20] 
avrdude: Recv: 
avrdude: Recv: 
         AVR Part              : ATMEGA1284P
         Chip Erase delay      : 9000 us
         PAGEL                 : PD7
         BS2                   : PA0
         RESET disposition     : dedicated
         RETRY pulse           : SCK
         serial program mode   : yes
         parallel program mode : yes
         Timeout               : 200
         StabDelay             : 100
         CmdexeDelay           : 25
         SyncLoops             : 32
         ByteDelay             : 0
         PollIndex             : 3
         PollValue             : 0x53
         Memory Detail         :

                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           eeprom        65    10   128    0 no       4096    8      0  9000  9000 0xff 0xff
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           flash         65    10   256    0 yes    131072  256    512  4500  4500 0xff 0xff
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           lock           0     0     0    0 no          1    0      0  9000  9000 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           lfuse          0     0     0    0 no          1    0      0  9000  9000 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           hfuse          0     0     0    0 no          1    0      0  9000  9000 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           efuse          0     0     0    0 no          1    0      0  9000  9000 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           signature      0     0     0    0 no          3    0      0     0     0 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           calibration    0     0     0    0 no          1    0      0     0     0 0x00 0x00

         Programmer Type : STK500
         Description     : Atmel STK500 Version 1.x firmware
avrdude: Send: A [41] . [80]   [20] 
avrdude: Recv: 
avrdude: Recv: 
avrdude: Recv: 
avrdude: Send: A [41] . [81]   [20] 
avrdude: Recv: 
avrdude: Recv: 
avrdude: Recv: 
avrdude: Send: A [41] . [82]   [20] 
avrdude: Recv: 
avrdude: Recv: 
avrdude: Recv: 
avrdude: Send: A [41] . [98]   [20] 
avrdude: Recv: 
avrdude: Recv: 
avrdude: Recv: 
         Hardware Version: 2
         Firmware Version: 1.16
avrdude: Send: A [41] . [84]   [20] 
avrdude: Recv: 

avrdude: stk500_getparm(): (a) protocol error, expect=0x14, resp=0x41
avrdude: Send: A [41] . [85]   [20] 
avrdude: Recv: 

avrdude: stk500_getparm(): (a) protocol error, expect=0x14, resp=0x41
avrdude: Send: A [41] . [86]   [20] 
avrdude: Recv: 

avrdude: stk500_getparm(): (a) protocol error, expect=0x14, resp=0x41
avrdude: Send: A [41] . [87]   [20] 
avrdude: Recv: 

avrdude: stk500_getparm(): (a) protocol error, expect=0x14, resp=0x41
avrdude: Send: A [41] . [89]   [20] 
avrdude: Recv: 

avrdude: stk500_getparm(): (a) protocol error, expect=0x14, resp=0x41
         Vtarget         : 200929192.4 V
         Varef           : 229372.8 V
         Oscillator      : 1.608 Hz
         SCK period      : 0.1 us

avrdude: Send: A [41] . [81]   [20] 
avrdude: Recv: 

avrdude: stk500_getparm(): (a) protocol error, expect=0x14, resp=0x41
avrdude: Send: A [41] . [82]   [20] 
avrdude: Recv: 

avrdude: stk500_getparm(): (a) protocol error, expect=0x14, resp=0x41
avrdude: Send: B [42] . [82] . [00] . [00] . [01] . [01] . [01] . [01] . [03] . [ff] . [ff] . [ff] . [ff] . [01] . [00] . [10] . [00] . [00] . [02] . [00] . [00]   [20] 
avrdude: Recv: 
avrdude: stk500_initialize(): (a) protocol error, expect=0x14, resp=0x42
avrdude: initialization failed, rc=-1
         Double check connections and try again, or use -F to override
         this check.

avrdude: Send: Q [51]   [20] 
avrdude: Recv: 
avrdude: stk500_disable(): protocol error, expect=0x14, resp=0x51

avrdude done.  Thank you.

Any suggestions?
Tomorrow someone will help me bootload the original atmega644p, and I have ordered a pololu avr programmer to bootload the atmega1284p again.

SD2 Sanguinololu 1.3a atmega1284p, wood platform, lawsy's carriages, braided fishing line, pallet wood overhead spool mount, carboard/magnet enclosure, glass bed, E3D v6, bed levelling knobs, extended z-stop, 25A DC-DC SSR for bed heater, everything fixed to the SD2 frame, marlin firmware with some adjustments and extra failsafes enabled.  I'll never give up on you, little printer that could(n't)!

2

Re: firmware sanguinololu 1.3a: The COMPLETE saga

Someone at the newcastle makerspace helped me troubleshoot and solve this for the atmega644p.

First off, we don't know for sure that the lack of bootloader was the problem, but we do know that if there was a bootloader on Solidoodle's original atmega644p chip, then we didn't know enough about it to flash it.

Second, we DEFINITELY did not need to fiddle with the reset button on the Sanguinololu 1.3a because Solidoodle (correctly) jumped the reset pins.

Third, we checked the way the fuses were originally set, and they were Low 0xFF (as opposed to 0xD6), High 0xDC, Ext  0xFD.

Fourth, we were unsuccessful in burning the bootloader with old "prepared" versions of Arduino from https://github.com/ozadr1an/Solidoodle-Marlin_v1 and https://github.com/mlaws/solidoodle2-marlin, and with stuff from the repo at https://github.com/jmgiacalone/sanguino1284p

Fifth, we were successful in burning the bootloader with the latest Arduino IDE 1.6.5 and the USBtiny, by adding the Sanguino board manager (Preferences->Additional board manager URLs):
https://raw.githubusercontent.com/Lausz … index.json
Then using usbtinyisp, select Board: Sanguino
Processor: ATMega644p or ATMega644PA (16MHz)
->Burn bootloader.

Then we went back to a prepared version of Arduino 1.0.5 for Windows from https://github.com/mlaws/solidoodle2-marlin but the sketch would not upload due to some communication error (out of sync or whatever).  This is because the latest version of the bootloader expects a different speed and protocol.  In hardware/boards.txt we had to change two lines so they become

atmega644.upload.protocol=arduino
atmega644.upload.speed=115200

After that it all worked!  Also note that reburning the bootloader with Arduino 1.0.5 did not change the fuses, and that I have only tested the board's responsiveness in Repetier host.

SD2 Sanguinololu 1.3a atmega1284p, wood platform, lawsy's carriages, braided fishing line, pallet wood overhead spool mount, carboard/magnet enclosure, glass bed, E3D v6, bed levelling knobs, extended z-stop, 25A DC-DC SSR for bed heater, everything fixed to the SD2 frame, marlin firmware with some adjustments and extra failsafes enabled.  I'll never give up on you, little printer that could(n't)!

3

Re: firmware sanguinololu 1.3a: The COMPLETE saga

I recall that the batch of SD2s that got shipped without bootloaders was fall 2012, which looks to be about when you got yours.  I remember their attitude was that it wasn't a big deal,  because why would anyone want to flash the firmware? It's supposed to be a consumer-ready plug and print machine.

4

Re: firmware sanguinololu 1.3a: The COMPLETE saga

IanJohnson wrote:

I recall that the batch of SD2s that got shipped without bootloaders was fall 2012, which looks to be about when you got yours.  I remember their attitude was that it wasn't a big deal,  because why would anyone want to flash the firmware? It's supposed to be a consumer-ready plug and print machine.

Fall 2012 it was for me!  (But it was the only $550 assembled printer available at the time.)

SD2 Sanguinololu 1.3a atmega1284p, wood platform, lawsy's carriages, braided fishing line, pallet wood overhead spool mount, carboard/magnet enclosure, glass bed, E3D v6, bed levelling knobs, extended z-stop, 25A DC-DC SSR for bed heater, everything fixed to the SD2 frame, marlin firmware with some adjustments and extra failsafes enabled.  I'll never give up on you, little printer that could(n't)!

5

Re: firmware sanguinololu 1.3a: The COMPLETE saga

Just wanted to say that this thread is heroic.

I'll be attempting to follow along and re-flash my SD2 some day soon. When I first tried months ago, I ran into many of the same issues you've worked through.