EmbeddedRelated.com
Forums

Reinvoke ISP

Started by joseluispepe007 November 21, 2006
Hi, I'm having a problem with the booloader...
I'm trying to start the ISP using the Reinvoke ISP IAP command, first I
deisable irq and fiq, then clear every register associated with TIMER 1
and then i disable the PLL and finally call the IAP command... The
current consumption of the circuits fall (because the PLL is disabled),
but the Philips Flash utility can't find the device (LPC2103 Olimex
Header).
then i tried sending '?' with a terminal but the LPC has no reply.

Could anyone give me a feeling?

Thanks, JosLuis.

An Engineer's Guide to the LPC2100 Series


I got almost the same with LPC2148.
Loader starts, but fail after writing about 2kB

Probably there are more features to disable (or default).

Big question is: what about watchdog?
- is it auto feeded in re-loaded ISP?
- is it feeded during in-application flash programming?
- is it possible to change watchdog period after it is started ???
I prefer dont use the watchdog for this test, then when this is
working...I'll add the watchdog, but there is another problem.
Jose Luis.
--- In l..., Wojciech Kromer wrote:
>
>
> I got almost the same with LPC2148.
> Loader starts, but fail after writing about 2kB
>
> Probably there are more features to disable (or default).
>
> Big question is: what about watchdog?
> - is it auto feeded in re-loaded ISP?
> - is it feeded during in-application flash programming?
> - is it possible to change watchdog period after it is started ???
>
I'm doing everything what "AN10356 Entering ISP mode from user code
Rev. 03 13 September 2006" says, but after that the LPC2000 Flash
Utility v2.2.3 does not recognize my LPC2103. I'm using an serial port
sniffer and it sends '????????....' but the LPC don't respond, like at
start with P0.14 fixed to Low level.

Any comments ??

Greetings.
Have a look on:
http://198.170.119.119/lpc2100_isp.htm
http://www.standardics.nxp.com/support/documents/microcontrollers/pdf/an10356.pdf
My working (tested on LPC2148 on olimex board) version is:

void go_isp(void){
void (*bootloader_entry)(void)=0;
int i;
unsigned int *p;

portDISABLE_INTERRUPTS(); //FreeRTOS macro

VICIntEnClr=0xffffffff;

PLLCON=0; PLLCFG = 0; PLLFEED = 0xAA; PLLFEED = 0x55;

PLL48CON=0; PLL48CFG = 0; PLL48FEED = 0xAA; PLL48FEED = 0x55;

p=TMR1_BASE_ADDR;
for(i=0;i<0x74/4;i++)*p++=0;
T1IR=0xFF;

PCONP &= ~(1 << 31); PCONP |= 0x03;

U0IER=0x00; U0LCR=0x80; U0DLL=0x01; U0DLM=0x00;
U0LCR=0x00; U0FCR=0x06; U0FDR=0x10;

MEMMAP=0;
VPBDIV=0;

IODIR0 = 0x4000;
IOCLR0 = 0x4000;

WDTC = 0x0ffffff; WDFEED = 0xaa; WDFEED = 0x55;

bootloader_entry();

}