[mc1322x] CodeSourcery , flash loader

Andrew Pullin pullin at berkeley.edu
Wed May 5 22:09:16 EDT 2010


On 05/02/2010 11:03 AM, Mariano Alvira wrote:
> On Sun, May 02, 2010 at 10:20:24AM -0700, Andrew Pullin wrote:
>    
>> Well, I didn't figure it out until I looked at the FTDI site, where they
>> say that JTAG-over-MPSSE is possible. Although I can't see *exactly* how
>> it works, since the example they give is written in Delphi, of all
>> things. I guess this is also completely hinged on someone implementing
>> support for the MPSSE calls into OpenOCD, and the mc1322x specific JTAG
>> data, and the feature doesn't mean much before then?
>>      
> OpenOCD supports the FT2232H and MPSSE. OpenOCD also supports the
> ARM7TDMI-S (which is why you can use it with the mc13224v at
> all). I've added the necessary config files to mainline
> openocd. mc13224v.cfg sets up the memory space for Openocd. Then
> redbee-econotag.cfg tells openocd look for an FT2232H and to do
> JTAG-over-MPSSE on the right channel/interface (the nomenclature there
> is mixed). This also sets which pins should be used for reset.
>
> For more details, see:
>
>     http://mc1322x.devl.org/openocd.html
>
> I also have a bitbanging utility that used libftdi to bit bang the
> mc13224v on the econotag (or any other board really, it's easy to
> extend). It's called bbmc. You can use bbmc to do a reset or a VREF2
> erase of the flash. See:
>
>     http://mc1322x.devl.org/bbmc.html
>
>    
Ah, ok, OpenOCD seems to work, for the most part. If I connect via gdb, 
I can load & run a program as per the instructions on the site. 
Unfortunately, debugging doesn't seem to be working? If I do a "break 
main", and then "continue", it won't work right:
     Warning:
     Cannot insert breakpoint 8.
     Error accessing memory address 0x400982: Unknown error 4294967295.

Single instruction stepping seems to work and output the proper source 
lines, but OpenOCD occasionally generates "Error: address + size 
wrapped(0xfffffffe, 0x00000004)" .

I'm using a development version of OpenOCD, 0.5.0-dev-00191-gcc5f3c8, 
built with --enable-maintainer-mode . Have you gotten breakpoints and 
debugging to work fully?

>> If the Econotag has onboard JTAG, does that mean that there's a way to
>> do a similar thing with the redbee-dev, not needed a JTAG pod?
>>      
> Yes, you plug in an EconoTAG and run:
>
>     openocd -f board/redbee-econotag.cfg
>    
That seems to work for the Econotag, but the small redbee + dev board 
only enumerates one USB->serial device when I plug it in, which seems to 
be the communication UART.


-Andrew



More information about the mc1322x mailing list