AnsweredAssumed Answered

Migrating from LPC1343 to LPC1347

Question asked by Denys Yurchenko on Jan 2, 2018
Latest reply on Jan 4, 2018 by Denys Yurchenko

Hi, ALL

 

I'm successfully migrate SW from LPC1343 to LPC1347, except FW upgrade via USB IAP.

 

This is my SW code that run on LPC1343 and not run on LPC1347:

 

#define init_msdstate() *((uint32_t *)(0x10000054)) = 0x00000000

.....

/* Disable SYSTICK timer and interrupt before calling into ISP */
SysTick->CTRL &= ~(SysTick_CTRL_ENABLE_Msk | SysTick_CTRL_TICKINT_Msk);

 

/* Initialize Storage state machine */
init_msdstate();

 

/*
* Set stack pointer to ROM value (reset default) This must be the last
* piece of code executed before calling ISP, because most C expressions
* and function returns will fail after the stack pointer is changed.
*/
__set_MSP( * ( (uint32_t *) 0x1FFF0000 ) );

/*
* Invoke ISP. We call "iap_entry" to invoke
* ISP because the ISP entry is done through the same
* command interface as IAP.
*/
flash_LPC13XX_IAP_ReInvokeISP();

/* Code will never return! */

......

 

Because I use RAM2 for USB drivers, I changed  #define init_msdstate() to:

 

#define init_msdstate() *((uint32_t *)(0x20004054)) = 0x00000000

 

BUT, it still doesn't works.

 

Whats wrong?

Outcomes