First of all, appologize for a rather loooong mail, most of it is a
trace output from avarice when trying to load programfile using load
command in avrgdbs. Now, my problem is that
1) I am not able to make avr-gdb load programfile correctly, I only get
packet erros, but those are ignoerd and
2) It takes an enormous time to load, 15 minutes, and it fails in the end
..even though it continue loading it is not working. When using simulavr
and same procedure I can start debug at once but simulavr is limited and
not debug on target as I want. I see from avarice log that the loading
comes out of synch, but i do not see any reason. Both commands has been
issued from within the same folder. Flashing target by using avrdude
works as it should and no errors are given and veryfing is ok.
Am I doing something wrong?
Using LinuxMint 10 (basically the same as ubuntu 10.04)
jtagicemk2
atmega644p
avarice version is 2.10
_*When avarice has been set-up as shown below, then I am starting
avr-gdb with my elf file as input as such:*_
*$avr-gdb Z003.elf*
GNU gdb 6.8
Copyright (C) 2008 Free Software Foundation, Inc.
This GDB was configured as "--host=i686-pc-linux-gnu --target=avr"...
(gdb) target remote localhost:1234
Remote debugging using localhost:1234
0x0000fffe in ?? ()
(gdb) load
Loading section .text, size 0x5702 lma 0x0
Ignoring packet error, continuing...
Ignoring packet error, continuing...
Remote connection closed
(gdb)quit
_*The following is the output from avarice*_
*$avarice -2 -Patmega644p -d -e -B 1000000 -jusb :1234 *
Found JTAG ICE, serno: 00B0000044DD
Attempting synchronisation at bitrate 19200
command[0x01, 1]: 01
recv: 0x1b
recv: 0x00
recv: 0x00
recv: 0x1c
recv: 0x00
recv: 0x00
recv: 0x00
recv: 0x0e
sDATA: reading 28 bytes
read: 86 01 ff 07 06 00 ff 07 06 01 00 b0 00 00 44 dd 4a 54 41 47 49 43
45 6d 6b 49 49 00
recv: 0xa2
recv: 0x95
CRC OK
Got message seqno 0 (command_sequence == 0)
response: 86 01 FF 07 06 00 FF 07 06 01 00 B0 00 00 44 DD 4A 54 41 47 49
43 45 6D 6B 49 49 00
JTAG ICE mkII sign-on message:
Communications protocol version: 1
M_MCU:
boot-loader FW version: 255
firmware version: 6.07
hardware version: 0
S_MCU:
boot-loader FW version: 255
firmware version: 6.07
hardware version: 1
command[0x02, 1]: 02 03 01
recv: 0x1b
recv: 0x01
recv: 0x00
recv: 0x01
recv: 0x00
recv: 0x00
recv: 0x00
recv: 0x0e
sDATA: reading 1 bytes
read: 80
recv: 0xcd
recv: 0x83
CRC OK
Got message seqno 1 (command_sequence == 1)
response: 80
command[0x0a, 1]: 0A 01
recv: 0x1b
recv: 0x02
recv: 0x00
recv: 0x01
recv: 0x00
recv: 0x00
recv: 0x00
recv: 0x0e
sDATA: reading 1 bytes
read: 80
recv: 0x1d
recv: 0x09
CRC OK
Got message seqno 2 (command_sequence == 2)
response: 80
Automatic device detection:
command[0x03, 1]: 03 0E
recv: 0x1b
recv: 0xff
recv: 0xff
recv: 0x06
recv: 0x00
recv: 0x00
recv: 0x00
recv: 0x0e
sDATA: reading 6 bytes
read: e0 00 00 00 00 00
recv: 0x4e
recv: 0x2d
CRC OK
Got message seqno 65535 (command_sequence == 3)
got asynchronous event: 0xe0
recv: 0x1b
recv: 0x03
recv: 0x00
recv: 0x05
recv: 0x00
recv: 0x00
recv: 0x00
recv: 0x0e
sDATA: reading 5 bytes
read: 81 3f a0 60 09
recv: 0xf5
recv: 0xe3
CRC OK
Got message seqno 3 (command_sequence == 3)
response: 81 3F A0 60 09
JTAG id = 0x960A03F : Ver = 0x0 : Device = 0x960a : Manuf = 0x1f
Looking for device: atmega644p
command[0x0c, 1]: 0C FF 0F E0 F8 FF 3D B9 E8 00 00 00 00 01 00 00 00 B6
0D 00 E0 FF 1D B8 E8 00 00 00 00 01 00 00 00 53 FB 09 DF F7 0F 00 00 00
00 5F 3F 37 37 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 53
FB 09 D8 F7 0F 00 00 00 00 5F 2F 36 36 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 31 57 3B 00 01 08 00 7E 00 00 CE 00 00 00 01 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 3E 3D
00 01 00 00 00 00 00 01 00 00 01 00 00 00 00 1F 00
recv: 0x1b
recv: 0x04
recv: 0x00
recv: 0x01
recv: 0x00
recv: 0x00
recv: 0x00
recv: 0x0e
sDATA: reading 1 bytes
read: 80
recv: 0xac
recv: 0x14
CRC OK
Got message seqno 4 (command_sequence == 4)
response: 80
command[0x14, 1]: 14
recv: 0x1b
recv: 0x05
recv: 0x00
recv: 0x01
recv: 0x00
recv: 0x00
recv: 0x00
recv: 0x0e
sDATA: reading 1 bytes
read: 80
recv: 0x13
recv: 0x95
CRC OK
Got message seqno 5 (command_sequence == 5)
response: 80
command[0x13, 1]: 13
recv: 0x1b
recv: 0x06
recv: 0x00
recv: 0x01
recv: 0x00
recv: 0x00
recv: 0x00
recv: 0x0e
sDATA: reading 1 bytes
read: 80
recv: 0xc3
recv: 0x1f
CRC OK
Got message seqno 6 (command_sequence == 6)
response: 80
command[0x15, 1]: 15
recv: 0x1b
recv: 0x07
recv: 0x00
recv: 0x01
recv: 0x00
recv: 0x00
recv: 0x00
recv: 0x0e
sDATA: reading 1 bytes
read: 80
recv: 0x7c
recv: 0x9e
CRC OK
Got message seqno 7 (command_sequence == 7)
response: 80
command[0x02, 1]: 02 07 05
recv: 0x1b
recv: 0x08
recv: 0x00
recv: 0x01
recv: 0x00
recv: 0x00
recv: 0x00
recv: 0x0e
sDATA: reading 1 bytes
read: 80
recv: 0xce
recv: 0x2f
CRC OK
Got message seqno 8 (command_sequence == 8)
response: 80
command[0x14, 1]: 14
recv: 0x1b
recv: 0x09
recv: 0x00
recv: 0x01
recv: 0x00
recv: 0x00
recv: 0x00
recv: 0x0e
sDATA: reading 1 bytes
read: 80
recv: 0x71
recv: 0xae
CRC OK
Got message seqno 9 (command_sequence == 9)
response: 80
jtagRead
command[0x05, 1]: 05 B3 01 00 00 00 00 00 00 00
recv: 0x1b
recv: 0x0a
recv: 0x00
recv: 0x02
recv: 0x00
recv: 0x00
recv: 0x00
recv: 0x0e
sDATA: reading 2 bytes
read: 82 ff
recv: 0x01
recv: 0x20
CRC OK
Got message seqno 10 (command_sequence == 10)
response: 82 FF
jtagRead
command[0x05, 1]: 05 B2 03 00 00 00 00 00 00 00
recv: 0x1b
recv: 0x0b
recv: 0x00
recv: 0x04
recv: 0x00
recv: 0x00
recv: 0x00
recv: 0x0e
sDATA: reading 4 bytes
read: 82 d2 1f fc
recv: 0xaa
recv: 0x1e
CRC OK
Got message seqno 11 (command_sequence == 11)
response: 82 D2 1F FC
command[0x15, 1]: 15
recv: 0x1b
recv: 0x0c
recv: 0x00
recv: 0x01
recv: 0x00
recv: 0x00
recv: 0x00
recv: 0x0e
sDATA: reading 1 bytes
read: 80
recv: 0x10
recv: 0x39
CRC OK
Got message seqno 12 (command_sequence == 12)
response: 80
command[0x0b, 1]: 0B 01
recv: 0x1b
recv: 0x0d
recv: 0x00
recv: 0x01
recv: 0x00
recv: 0x00
recv: 0x00
recv: 0x0e
sDATA: reading 1 bytes
read: 80
recv: 0xaf
recv: 0xb8
CRC OK
Got message seqno 13 (command_sequence == 13)
response: 80
Waiting for input.
recv: 0x1b
recv: 0xff
recv: 0xff
recv: 0x06
recv: 0x00
recv: 0x00
recv: 0x00
recv: 0x0e
sDATA: reading 6 bytes
read: e0 00 00 00 00 00
recv: 0x4e
recv: 0x2d
CRC OK
command[0x02, 1]: 02 09 00
recv: 0x1b
recv: 0x0e
recv: 0x00
recv: 0x01
recv: 0x00
recv: 0x00
recv: 0x00
recv: 0x0e
sDATA: reading 1 bytes
read: 80
recv: 0x7f
recv: 0x32
CRC OK
Got message seqno 14 (command_sequence == 14)
response: 80
command[0x0b, 1]: 0B 01
recv: 0x1b
recv: 0x0f
recv: 0x00
recv: 0x01
recv: 0x00
recv: 0x00
recv: 0x00
recv: 0x0e
sDATA: reading 1 bytes
read: 80
recv: 0xc0
recv: 0xb3
CRC OK
Got message seqno 15 (command_sequence == 15)
response: 80
Waiting for input.
recv: 0x1b
recv: 0xff
recv: 0xff
recv: 0x06
recv: 0x00
recv: 0x00
recv: 0x00
recv: 0x0e
sDATA: reading 6 bytes
read: e0 00 00 00 00 00
recv: 0x4e
recv: 0x2d
CRC OKGDB: <qSupported>
->GDB:
GDB: <?>
->GDB: S05
GDB: <Hc-1>
->GDB:
GDB: <qC>
->GDB:
GDB: <qOffsets>
->GDB:
GDB: <Hg0>
->GDB:
GDB: <g>
GDB: (Registers)Read 32 bytes from 0x800000
jtagRead
command[0x05, 1]: 05 20 20 00 00 00 00 00 00 00
recv: 0x1b
recv: 0x10
recv: 0x00
recv: 0x21
recv: 0x00
recv: 0x00
recv: 0x00
recv: 0x0e
sDATA: reading 33 bytes
read: 82 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00
recv: 0x2a
recv: 0x1c
CRC OK
Got message seqno 16 (command_sequence == 16)
response: 82 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00
jtagRead
command[0x05, 1]: 05 20 03 00 00 00 5D 00 00 00
recv: 0x1b
recv: 0x11
recv: 0x00
recv: 0x04
recv: 0x00
recv: 0x00
recv: 0x00
recv: 0x0e
sDATA: reading 4 bytes
read: 82 00 00 00
recv: 0x6a
recv: 0x69
CRC OK
Got message seqno 17 (command_sequence == 17)
response: 82 00 00 00
command[0x07, 1]: 07
recv: 0x1b
recv: 0x12
recv: 0x00
recv: 0x05
recv: 0x00
recv: 0x00
recv: 0x00
recv: 0x0e
sDATA: reading 5 bytes
read: 84 00 00 00 00
recv: 0x64
recv: 0x5c
CRC OK
Got message seqno 18 (command_sequence == 18)
response: 84 00 00 00 00
PC = 0
->GDB:
000000000000000000000000000000000000000000000000000000000000000000000000000000
GDB: <qSymbol::>
->GDB:
GDB: <X0,0:>
->GDB:
GDB:
<M0,20:0c9444000c946c0a0c9461000c9461000c9461000c9461000c9461000c946100>
GDB: Write 32 bytes to 0x0
jtagWrite Detected GDB "load" command, erasing flash.
command[0x13, 1]: 13
recv: 0x1b
recv: 0x13
recv: 0x00
recv: 0x01
recv: 0x00
recv: 0x00
recv: 0x00
recv: 0x0e
sDATA: reading 1 bytes
read: 80
recv: 0xda
recv: 0xd3
CRC OK
Got message seqno 19 (command_sequence == 19)
response: 80
command[0x04, 1]: 04 A0 20 00 00 00 00 00 00 00 0C 94 44 00 0C 94 6C 0A
0C 94 61 00 0C 94 61 00 0C 94 61 00 0C 94 61 00 0C 94 61 00 0C 94 61 00
recv: timeout
command[0x04, 2]: 04 A0 20 00 00 00 00 00 00 00 0C 94 44 00 0C 94 6C 0A
0C 94 61 00 0C 94 61 00 0C 94 61 00 0C 94 61 00 0C 94 61 00 0C 94 61 00
recv: timeout
command[0x04, 3]: 04 A0 20 00 00 00 00 00 00 00 0C 94 44 00 0C 94 6C 0A
0C 94 61 00 0C 94 61 00 0C 94 61 00 0C 94 61 00 0C 94 61 00 0C 94 61 00
recv: timeout
command[0x04, 4]: 04 A0 20 00 00 00 00 00 00 00 0C 94 44 00 0C 94 6C 0A
0C 94 61 00 0C 94 61 00 0C 94 61 00 0C 94 61 00 0C 94 61 00 0C 94 61 00
recv: 0x1b
recv: 0x14
recv: 0x00
recv: 0x01
recv: 0x00
recv: 0x00
recv: 0x00
recv: 0x0e
sDATA: reading 1 bytes
read: 80
recv: 0xd4
recv: 0x4f
CRC OK
Got message seqno 20 (command_sequence == 20)
response: 80
->GDB: OK
GDB:
<M20,20:0c9461000c9461000c9461000c9461000c9461000c9461000c9461000c946100>
GDB: Write 32 bytes to 0x20
jtagWrite
command[0x04, 1]: 04 A0 20 00 00 00 20 00 00 00 0C 94 61 00 0C 94 61 00
0C 94 61 00 0C 94 61 00 0C 94 61 00 0C 94 61 00 0C 94 61 00 0C 94 61 00
recv: 0x1b
recv: 0x14
recv: 0x00
recv: 0x01
recv: 0x00
recv: 0x00
recv: 0x00
recv: 0x0e
sDATA: reading 1 bytes
read: 80
recv: 0xd4
recv: 0x4f
CRC OK
Got message seqno 20 (command_sequence == 21)
got wrong sequence number, 20 != 21
recv: timeout
***** AND A LOT MORE STUFF LIKE THIS *****
GDB: Write 32 bytes to 0x180
jtagWrite
command[0x04, 1]: 04 A0 20 00 00 00 80 01 00 00 9E B7 40 97 0F B6 F8 94
9E BF 0F BE 8D BF ED B7 FE B7 31 96 31 83 20 83 80 E0 91 E0 93 83 82 83
recv: 0x1b
recv: 0x1f
recv: 0x00
recv: 0x01
recv: 0x00
recv: 0x00
recv: 0x00
recv: 0x0e
sDATA: reading 1 bytes
read: 80
recv: 0xb8
recv: 0xe8
CRC OK
Got message seqno 31 (command_sequence == 32)
got wrong sequence number, 31 != 32
>Here I breakout and quit avr-gdb and avarice
------------------------------------------------------------------------------
This SF Dev2Dev email is sponsored by:
WikiLeaks The End of the Free Internet
http://p.sf.net/sfu/therealnews-com
_______________________________________________
avarice-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/avarice-user