EmbDev.net

Forum: µC & Digital Electronics m1284p makes AVR Dragon "hang"?


Author: Christian Thorge S. (christianthorge_s)
Posted on:
Attached files:

Rate this post
0 useful
not useful
Hello all,

a few days ago I bricked two ATMega1284P's trying to use the Arduino IDE 
with them (see 
http://maniacbug.wordpress.com/2011/11/27/arduino-...). I 
was using a USBasp clone from .cn (which worked for Arduino-on-ATTiny85, 
btw).

The following takes place under Mac OS X 10.8.3 and (later, for the 
Atmel Studio 6.1-part) Windows 7:

To unbrick I got myself an AVR Dragon and connected everything according 
to the instructions here:
http://support.atmel.no/knowledgebase/avrstudiohel...
(checked the wiring and "direction" of the m1284p twice). See attached 
picture.

Now, for the strange part: Inserting the m1284p into the TexTool (or the 
board directly) makes the Dragon "hang", ie. it is unresponsive.

Without the 1284 avrdude works, but of course cannot talk to a device:
# avrdude -c dragon_pp -p m1284p -n -v -P usb

avrdude: usbdev_open(): Found AVRDRAGON, serno: 00A20002xxxx
JTAG ICE mkII sign-on message:
Communications protocol version: 1
M_MCU:
  boot-loader FW version:        255
  firmware version:              7.33
  hardware version:              1
S_MCU:
  boot-loader FW version:        255
  firmware version:              7.33
  hardware version:              7
Serial number:                   00:a2:00:02:xx:xx
Device ID:                       AVRDRAGON
         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
           flash         65    10   256    0 yes    131072  256    512  4500  4500 0xff 0xff
           lock           0     0     0    0 no          1    0      0  9000  9000 0x00 0x00
           lfuse          0     0     0    0 no          1    0      0  9000  9000 0x00 0x00
           hfuse          0     0     0    0 no          1    0      0  9000  9000 0x00 0x00
           efuse          0     0     0    0 no          1    0      0  9000  9000 0x00 0x00
           signature      0     0     0    0 no          3    0      0     0     0 0x00 0x00
           calibration    0     0     0    0 no          1    0      0     0     0 0x00 0x00

         Programmer Type : DRAGON_PP
         Description     : Atmel AVR Dragon in PP mode
         Vtarget         : 5.0 V
         SCK period      : 1.00 us

avrdude: AVR device initialized and ready to accept instructions

Reading | ################################################## | 100% 0.15s

avrdude: Device signature = 0xffffff
avrdude: Yikes!  Invalid device signature.
         Double check connections and try again, or use -F to override
         this check.

avrdude: jtagmkII_close(): bad response to GO command: RSP_ILLEGAL_EMULATOR_MODE

avrdude done.  Thank you.

With the m1284p inserted, it goes dead on me:
# avrdude -c dragon_pp -p m1284p -n -v -P usb
avrdude: Version 5.11.1, compiled on Mar 26 2013 at 19:58:26
         Using Port                    : usb
         Using Programmer              : dragon_pp
avrdude: usbdev_open(): did not find any USB device "usb"

The same (though not as verbose ;) goes for Atmel Studio 6.1 under 
Windows 7.

Any ideas what I could be doing wrong?

Thank you,
 Christian.

Author: Christian Thorge S. (christianthorge_s)
Posted on:

Rate this post
0 useful
not useful
To check if "everything else" works, I've tried the Dragon with an 
ATTiny13A I found under the couch; things seem to be ok with this little 
device:
# avrdude -c dragon_hvsp -p t13 -n -v -P usb

avrdude: Version 5.11.1, compiled on Mar 26 2013 at 19:58:26
(...)
         Using Port                    : usb
         Using Programmer              : dragon_hvsp
avrdude: usbdev_open(): Found AVRDRAGON, serno: 00A20002xxxx
JTAG ICE mkII sign-on message:
Communications protocol version: 1
M_MCU:
  boot-loader FW version:        255
  firmware version:              7.33
  hardware version:              1
S_MCU:
  boot-loader FW version:        255
  firmware version:              7.33
  hardware version:              7
Serial number:                   00:a2:00:02:xx:xx
Device ID:                       AVRDRAGON
         AVR Part                      : ATtiny13
         Chip Erase delay              : 4000 us
         PAGEL                         : P00
         BS2                           : P00
         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     5     4    0 no         64    4      0  4000  4000 0xff 0xff
           flash         65     6    32    0 yes      1024   32     32  4500  4500 0xff 0xff
           signature      0     0     0    0 no          3    0      0     0     0 0x00 0x00
           lock           0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
           calibration    0     0     0    0 no          2    0      0     0     0 0x00 0x00
           lfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
           hfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00

         Programmer Type : DRAGON_HVSP
         Description     : Atmel AVR Dragon in HVSP mode
         Vtarget         : 5.0 V
         SCK period      : 1.00 us

avrdude: AVR device initialized and ready to accept instructions

Reading | ################################################## | 100% 0.15s

avrdude: Device signature = 0x1e9007
avrdude: safemode: lfuse reads as 6A
avrdude: safemode: hfuse reads as FF

avrdude: safemode: lfuse reads as 6A
avrdude: safemode: hfuse reads as FF
avrdude: safemode: Fuses OK
avrdude: jtagmkII_close(): bad response to GO command: RSP_ILLEGAL_EMULATOR_MODE

avrdude done.  Thank you.

The error on the last line seems to be "known and ok", see 
http://lists.gnu.org/archive/html/avrdude-dev/2009... for 
more ("The attempt to send a CMND_GO command even in ISP mode is a 
benign bug
that slipped in somehow in one of the recent releases.")

Good night,
 Christian.

Reply

Entering an e-mail address is optional. If you want to receive reply notifications by e-mail, please log in.

Rules — please read before posting

  • Post long source code as attachment, not in the text
  • Posting advertisements is forbidden.

Formatting options

  • [c]C code[/c]
  • [avrasm]AVR assembler code[/avrasm]
  • [code]code in other languages, ASCII drawings[/code]
  • [math]formula (LaTeX syntax)[/math]




Bild automatisch verkleinern, falls nötig
Note: the original post is older than 6 months. Please don't ask any new questions in this thread, but start a new one.