Hi, All!

First of all sorry for my bad English :)

I've started learning openocd just recently. I want use it with
AT91SAM9XE512 cpu. I use openocd/Debian/sid version.

I have SAM-ICE device. It was detected and works fine on my system.
But I need some advices what to do :)

When I tried to seek target/.cfg for my CPU, I couldn't do it. So I
wrote my version of this file:
http://paste.org/pastebin/view/21358

It works fine: I can load/read any memory cell/register, now I can
develop/debug my code using Linux/SAM-ICE jtag. But I have some
hardship to write into internal flash.

Could anybody help me?

I looked through flash driver list, but haven't found suitable driver.
As I understood (if I understood properly) new drivers can be written
only using C. How can I write internal flash on my device? May be
someone have already written driver for my CPU? Or may be there is a
documentation how to write new driver?

PS:
It would be nice if 'manual' driver was: which would recure a few
characteristic like: wordwidth, blocksize and procedure which can write
a block into fhash, like
proc write_block { data_block address_block } { ... }

Using such driver users would write full-grown configs for new CPUs.


And I have additional question:
I tried to write a small TCL-program to write internal flash for
openocd. I've been stumbled with ocd_mem2array mem2array and mirror
functions.

ocd_mem2array/ocd_array2mem don't want work on my system, they throw
an error:
    Error: mem2array: no command context

(this error was thrown by this code:
    ocd_mem2array $ADDRESS ary 32 2
)

I tried to use
    $TARGET mem2array $ADDRESS ary 32 2
but it don't throw any errors and don't write any datas into ary.

So I was forced to use mdw/mww commands, but they aren't handy if You
need to read/write TCL-array <-> CPU.

How can I write/read arrays? 

PPS: Thanks for Your great work!

-- 
... mpd is off

. ''`.                               Dmitry E. Oboukhov
: :’  :   email: un...@debian.org jabber://un...@uvw.ru
`. `~’              GPGKey: 1024D / F8E26537 2006-11-21
  `- 1B23 D4F8 8EC0 D902 0555  E438 AB8C 00CF F8E2 6537

Attachment: signature.asc
Description: Digital signature

_______________________________________________
Openocd-development mailing list
Openocd-development@lists.berlios.de
https://lists.berlios.de/mailman/listinfo/openocd-development

Reply via email to