Skip to main content

Topics

This section allows you to view all Topics made by this member. Note that you can only see Topics made in areas you currently have access to.

Topics - broeggle

1
Bus Blaster JTAG debugger / Busblaster, openocd and the BeagleBoard xM
Hi,

I got a busblaster v2 from seeed and tried to use it to debug something using openocd on my BeagleBoard xM
I connected it quite similar to the description of the pandaboard in the docu section - but unfortunately I have no success.

Has anyone ever tried this, or atleast can help me figure out what's wrong.
I double checked the wiring, also trying to connect all of the busblasters pins and also connecting it like the flyswatter beagle adapter cable does - always with the same result.

I invoke openocd-0.5.0 with
Code: [Select]
openocd -f /home/peter/busblaster.cfg -f board/ti_beagleboard_xm.cfg
Open On-Chip Debugger 0.5.0 (2012-01-24-22:59)
Licensed under GNU GPL v2
For bug reports, read
        http://openocd.berlios.de/doc/doxygen/bugs.html
Info : only one transport option; autoselect 'jtag'
2000 kHz
10 kHz
Warn : dm37x.dsp: huge IR length 38
trst_only separate trst_push_pull
Info : max TCK change to: 30000 kHz
Info : clock speed 10 kHz
Info : JTAG tap: dm37x.jrc tap/device found: 0x2b89102f (mfg: 0x017, part: 0xb891, ver: 0x2)
Info : JTAG tap: dm37x.dap enabled
Warn : Invalid ACK 0x6 in JTAG-DP transaction
Polling target failed, GDB will be halted. Polling again in 100ms
Polling target failed, GDB will be halted. Polling again in 300ms
Polling target failed, GDB will be halted. Polling again in 700ms
Polling target failed, GDB will be halted. Polling again in 1500ms
Polling target failed, GDB will be halted. Polling again in 3100ms
Info : accepting 'telnet' connection from 4444
Polling target failed, GDB will be halted. Polling again in 6300ms
> targets
    TargetName        Type      Endian TapName            State     
--  ------------------ ---------- ------ ------------------ ------------
 0* dm37x.cpu          cortex_a8  little dm37x.dap          unknown
Polling target failed, GDB will be halted. Polling again in 6300ms
> scan_chain
  TapName            Enabled  IdCode    Expected  IrLen IrCap IrMask
-- ------------------- -------- ---------- ---------- ----- ----- ------
 0 dm37x.dap              Y    0x00000000 0x00000000    4 0x01  0x0f
 1 dm37x.arm2            n    0x00000000 0x00000000    4 0x01  0x0f
 2 dm37x.dsp              n    0x00000000 0x00000000    38 0x25  0x3f
 3 dm37x.d2d              n    0x00000000 0x00000000    4 0x01  0x0f
 4 dm37x.jrc              Y    0x2b89102f 0x1b89102f    6 0x01  0x3f
                                          0x0b89102f
                                          0x0b89102f
Polling target failed, GDB will be halted. Polling again in 6300ms
Polling target failed, GDB will be halted. Polling again in 6300ms
Polling target failed, GDB will be halted. Polling again in 6300ms
> reset init
10 kHz
JTAG tap: dm37x.jrc tap/device found: 0x2b89102f (mfg: 0x017, part: 0xb891, ver: 0x2)
JTAG tap: dm37x.dap enabled
Invalid ACK 0x6 in JTAG-DP transaction
in procedure 'reset'
> amdm37x_dbginit dm37x.cpu
target not examined yet
Runtime Error: target/amdm37x.cfg:194:
in procedure 'amdm37x_dbginit'
in procedure 'cortex_a8' called at file "target/amdm37x.cfg", line 194

Why is the state always 'unknown', is this related to the
"Warn : Invalid ACK 0x6 in JTAG-DP transaction"
message?

If I connect gdb to open ocd it crashes
Code: [Select]
Info : accepting 'gdb' connection from 3333
Warn : acknowledgment received, but no packet pending
undefined debug reason 6 - target needs reset

my busblaster.cfg:
Code: [Select]
cat  /home/peter/busblaster.cfg 
interface ft2232
ft2232_device_desc "Dual RS232-HS"
ft2232_layout jtagkey
ft2232_vid_pid 0x0403 0x6010
jtag_khz 2000

Can anyone please help me?

Thanks,
Peter
3
Bus Pirate Support / Linux - Bootloader-Programmer
Hi,
I'm currently trying to implement a linux - bootloader programmer for the bus pirate.
In this thead I want to report my progress - and if you would like to help, feel free to contact me.
Another reason I post my progress here is that you can tell me if I do something horribly wrong.

I checked out the svn repo and had a look at the sources.
-> The bootloader is based on the an851 - Application Note can be found here:
http://ww1.microchip.com/downloads/en/A ... 00851b.pdf
More information could be found here:
http://www.microchip.com/Stellent/idcpl ... e=en012031

I also found a linux programmer
http://cockpit.varxec.net/software/pic.html
 - but unfortunately it does not work that well - starting it without any params results in a segfault:
(gdb) r
Starting program: /data/an851/an851host
To read from flash Memory:

Program received signal SIGSEGV, Segmentation fault.
0x00007f994b1be480 in strlen () from /lib/libc.so.6

--> I will investigate these issues later on and provide a patch, but as I want to write a portable client I stick with python an pyserial, using the programms source-code as a reference.


Let's start:
* According to the source the bootloader operates at 9600 baud, 8N1  (however it should have an autobaud feature)
* According to AN p.3 the format is [...]
where STX = 0x0f , ETX=0x04 , CHECKSUM is the 2's complement of the lower byte of the sum of all data.
* On page 9 the read bootloader version information is 0x00 0x02

So my source looks like
Code: [Select]
import serial
ser = serial.Serial('/dev/ttyUSB0', 9600,bytesize=8, parity='N', stopbits=1, timeout=None, xonxoff=0, rtscts=0)

ser.write("x0Fx0Fx00x02xFEx04")

print "reading?"
print ser.read(4)

However I don't receive any data :/

Can somebody perhaps log what the original pic programmer sends over the serial line? - would be cool.
4
Bus Pirate Support / Problems with 1-wire
Hi,

as I already have [s:]spammed[/s:] written in the hackaday comments section http://hackaday.com/2009/07/20/parts-unboxing-the-bus-pirate/ I have some problems with the 1-wire bus.

The search (240) and the read rom macros (51) work quite fine - however if I want to write/read something from the device I receive not the expected values

Code: [Select]
1-WIRE>(240)
1WIRE ROM COMMAND: SEARCH (0xF0)
Found devices at:
Macro 1WIRE address
1.0×2D 0xB7 0xDC 0xEF 0×00 0×00 0×00 0xF9
*DS2431 1K EEPROM
Found 0×01 devices.
The first 10 device IDs are available by MACRO, see (0).

1-WIRE>(85)(1) 0xf0 0×00 0×00 0 1 2 3 4 5 6 7
1WIRE BUS RESET OK
1WIRE WRITE ROM COMMAND: MATCH (0×55) *follow with 64bit address
1WIRE ADDRESS MACRO 1: 0×2D 0xB7 0xDC 0xEF 0×00 0×00 0×00 0xF9
WRITE: 0xF0
WRITE: 0×00
WRITE: 0×00
WRITE: 0×00
WRITE: 0×01
WRITE: 0×02
WRITE: 0×03
WRITE: 0×04
WRITE: 0×05
WRITE: 0×06
WRITE: 0×07

1-WIRE>(85)(1) 0xaa r:3 r:8 R:2 r:2
1WIRE BUS RESET OK
1WIRE WRITE ROM COMMAND: MATCH (0×55) *follow with 64bit address
1WIRE ADDRESS MACRO 1: 0×2D 0xB7 0xDC 0xEF 0×00 0×00 0×00 0xF9
WRITE: 0xAA
BULK READ 0×03 BYTES:
0xFF 0xFF 0xFF # WRONG – should be 0×00 0×00 0×07;
BULK READ 0×08 BYTES:
0xBF 0xE7 0×83 0xFF 0xFF 0xFF 0xFF 0xFF
BULK READ 0×02 BYTES:
0xFF 0xFF
BULK READ 0×02 BYTES:
0xFF 0xFF


I tried it with a 1k and 2.2k and 4.7kohm external pullup, I use the same ds2431 as hackaday
http://hackaday.com/2008/12/24/parts-1k-1-wire-eeprom-ds2431/

Any ideas?

( ! ) Fatal error: Uncaught exception 'Elk_Exception' with message 'Please try again. If you come back to this error screen, report the error to an administrator.' in /var/www/dangerousprototypes/forum/sources/database/Db-mysql.class.php on line 696
( ! ) Elk_Exception: Please try again. If you come back to this error screen, report the error to an administrator. in /var/www/dangerousprototypes/forum/sources/database/Db-mysql.class.php on line 696
Call Stack
#TimeMemoryFunctionLocation
10.01252312976session_write_close ( )...(null):0
20.01282444560ElkArte\sources\subs\SessionHandler\DatabaseHandler->write( )...(null):0
30.01282445336Database_MySQL->query( ).../DatabaseHandler.php:119
40.05572584064Database_MySQL->error( ).../Db-mysql.class.php:273