Yahoo Groups archive

Lpc2000

Index last updated: 2026-04-28 23:31 UTC

Thread

Secondary JTAG activation fails (ARM7, Olimex-Board)

Secondary JTAG activation fails (ARM7, Olimex-Board)

2004-12-29 by Roland Macho

Dear group members,
Have an activation problem with the secondary JTAG interface.
Using the Philips application note AN10255 I tried to convert the 
assembly code of their ARM assembler to the GNU assembler with some 
support of Rowley. The evaluation board is from Olimex (P1).
The code is transferred via JTAG1 to the Flash memory and shows no
errors doing that.
But when changing connector to the JTAG2 interface (secondary) this 
is not activated by the new code.
It seems to be a task of the right checksum. 
But I don't know how to calculate it.

Can somebody explain this to me ?

Here the converted Philips code :

.section .vectors, "ax"
  .code 32
  .align 0

/*********************************************************************
********
 * Exception 
Vectors                                                         *
 
**********************************************************************
*******/
_vectors:
  ldr pc, [pc, #reset_handler_address - . - 8]  /* reset */
  ldr pc, [pc, #undef_handler_address - . - 8]  /* undefined 
instruction */
  ldr pc, [pc, #swi_handler_address - . - 8]    /* swi handler */
  ldr pc, [pc, #pabort_handler_address - . - 8] /* abort prefetch */
  ldr pc, [pc, #dabort_handler_address - . - 8] /* abort data */
#ifdef VECTORED_IRQ_INTERRUPTS
  .word 0xB9205F84                              /* boot loader 
checksum */
  ldr pc, [pc, #-0xFF0]                         /* irq handler */
#else
  .word 0xB8A06F60                              /* boot loader 
checksum */
  ldr pc, [pc, #irq_handler_address - . - 8]    /* irq handler */
#endif
  ldr pc, [pc, #fiq_handler_address - . - 8]    /* fiq handler */

reset_handler_address:
  .word reset_handler
undef_handler_address:
  .word undef_handler
swi_handler_address:
  .word swi_handler
pabort_handler_address:
  .word pabort_handler
dabort_handler_address:
  .word dabort_handler
irq_handler_address:
  .word irq_handler
fiq_handler_address:
  .word fiq_handler

  .section .init, "ax"
  .code 32
  .align 0

/*********************************************************************
*********
 
*                                                                     
       *
 * Default exception 
handlers                                                 *
 
*                                                                     
       *
 
**********************************************************************
********/

reset_handler:
  LDR         R0, JTAG2       /* Load R0 with 0x55400000 */
  LDR         R1, PINSEL1     /* Load R1 with oxE002C004 */
  LDR         R0, [R1]        /* Load PINSEL1 with 0x55400000 */

loop:
  b loop

JTAG2:
  .word         0x55400000
PINSEL1:
  .word         0xE002C004

/*********************************************************************
*********
 
*                                                                     
       *
 * Default exception 
handlers                                                 *
 * These are declared weak symbols so they can be redefined in user 
code.     * 
 
*                                                                     
       *
 
**********************************************************************
********/

undef_handler:
  b undef_handler
  
swi_handler:
  b swi_handler
  
pabort_handler:
  b pabort_handler
  
dabort_handler:
  b dabort_handler
  
irq_handler:
  b irq_handler
  
fiq_handler:
  b fiq_handler

  .weak undef_handler, swi_handler, pabort_handler, dabort_handler, 
irq_handler, fiq_handler
  .end  

Thank's for your help.

Roland

Re: Secondary JTAG activation fails (ARM7, Olimex-Board)

2005-01-01 by sig5534

Most programmers and debuggers are responsible for calculating the 
signature word and putting it into the flash.  The Philips flash 
programmer certainly does this as does my Signum JetJTAG.  If your 
programmer does not, then you will need to calc it yourself. I think 
that is covered in the LPC210x manual.

Chris.

Re: Secondary JTAG activation fails (ARM7, Olimex-Board)

2005-01-01 by Roland Macho

--- In lpc2000@yahoogroups.com, "sig5534" <sig5534@h...> wrote:
> 
> Most programmers and debuggers are responsible for calculating the 
> signature word and putting it into the flash.  The Philips flash 
> programmer certainly does this as does my Signum JetJTAG.  If your 
> programmer does not, then you will need to calc it yourself. I 
think 
> that is covered in the LPC210x manual.
> 
> Chris.

Hi Chris,
Thank's for reply.
I am using Rowley's Crosswork environment. This has all things 
configured for JTAG1 interface but not for the secondary JTAG2.
Normally I should not have to mention about it.
I found some messages on this newsgroup regarding vectored interrupts 
and checksum calculating. Try to follow up. My final problem will be 
to append the result to the code and let it transfer to the right 
place in the flash memory. An example of that would be helpful.

Regards,
Roland

Move to quarantaine

This moves the raw source file on disk only. The archive index is not changed automatically, so you still need to run a manual refresh afterward.