SAM7-Pxxx Board from OLIMEX - OpenOCD

Hi,

Yesterday i get a new SAM7-Pxxx Board with an Atme AT91SAM7S256 on it.

Everything seems to work perfectly till I cleared the flash memory with SAM-BA!

Now I have the problem tha Ecplise is not working anymore with the Controller, or better OpenOCD say that the number of discovered devices in JTAGchain(578) doesn’t match configuration (1)!!!

I tried also to connect the Board via USB, but nothing happened, also in my System Overview (WinXP)!

No new Hardware added to the list!

Why?

Is something broken, if yes, what?

Best regards

Tobias Eckhardt

Hi Tobias,

Probably nothing is broken, you just have a processor with no program in the flash memory. You have erased the onchip SAMBA code that lets you connect using RS232 or USB.

So at the moment there is no code in flash to start the USB system on the board. And the board runs the nonexisting code, with the slowest possible clock.

You can either use JTAG and OpenOCD to download a program to flash or restore the SAMBA code using the system recovery procedure:

http://olimex.com/dev/SAM-BA%20Notes.htm

Regards,

Magnus

I already tried this, but it didn’t work. I always get the failure message “No valid processor ID found!”

By the way. I’m using the OLIMEX Board (SAM7-P256)!

Any other idea?

Thanks so far.

Tobi

Tried JTAG programming or SAMBA System recovery ?

When, from what program, do you get this message ?

If there is no code to initialize the clock/pll then the chip runs very slowly and the JTAG speed must be decreased. For FT2232 based JTAG interfaces this means setting jtag_speed to a high value, 10 or 20 works for me ( SAM7-P64 )

/Magnus

Hi Magnus!

First to your questions.

SAMBA System recovery still not working! Not new Hardware will be recognized after i did:

Power off

set jumper Test

Power on

wait >10sec

power off

unset jumper Test

Power on

and the directly connect to the PC!

Is ist possible that there is no Boatloader anymore in the ROM or whereever!

If this is possible how do i get a new Boatloader on my Board?

The message “No valid processor ID found” came from SAM-BA!

The other message with…JTAG chain…occur from ecplise when i start the openocd routine!

Here is the message in detail:

make -k program

Flash Programming with OpenOCD…

'C:/Programme/openocd-2007re141/bin/'openocd-ftd2xx.exe -f 'C:/Programme/openocd-2007re141/bin/'at91sam7s256-armusbocd-flash-program.cfg # program the onchip FLASH here

Info: openocd.c:86 main(): Open On-Chip Debugger (2007-04-16 19:30 CEST)

Error: jtag.c:1230 jtag_examine_chain(): number of discovered devices in JTAG chain (578) doesn’t match configuration (1)

make: *** [program] Error -1

Now to your tip.

I changed the speed from 2 to 10, 20 or 30! Nothing changed! :frowning:

When i unplug the JTAG cable from the EK-Board i get another message in ecplise. The message says the the cable is not connected with the EK-Board.

That says me that there must be a way to fix it, but which way???

Do you have another idea?

For example how i get a new bootloader in this board? Perhaps with ecplise?

Thanks so far!

Best regards from Cologne

Tobi

Hi,

First, if you are going to use Eclipse, OpenOcd and JTAG then you do not need the Samba bootloader.

Next the problems with JTAG. Are you running gdb and OpenOcd from Eclipse before you try to program the board ?

It seems so since you get the message about unplgging the JTAG cable. In this case the make file starts a new instance of OpenOcd and that will not work if there is already one running.

/Magnus

Hi,

i know that i don’t need this Samba Bootloader, i used this program after i tried everthing with ecplise.

I’m not running gdb and OpenOCD before i start ecplise!

If i start ecplise and everything is connected correctly i get the message with the “discovered devices…”

if i now unplug the JTAG Cable the correct error message ooccur when i plug the jtag on the board and start the procedure in ecplise again i get the message “discovered devices…” again.

That seems that it has nothing to do with more than 2 instances! Correct ?

I would say that there is no bootloader in the flash memory, so nothing can be load into the ram, so nothing can be execute

What i need is the bootloader program which i can load into the flash easily.

Is this correct? What would you say?

Does Atmel can give me the bootloader or does i need the bootloader from OLIMEX?

Thanks so far

Tobi

Hi,

i found the problem!

The Security Bit was set! And there are two ways to unset this Bit.

Via Software and via 3,3 Volt on Pin 55!

THe Second way was the only possibility!

It works, thanks!

Best regards to sweden

Tobi