Flash Magic Forum

In-System Programming Support => LPC9xx/LPC9xxx => Topic started by: DB1BMN on November 28, 2006, 09:34:49 AM

Title: [P89LPC935] How to enter ISP mode correctly by firmware
Post by: DB1BMN on November 28, 2006, 09:34:49 AM
Hi,

I
Title: Re: [P89LPC935] How to enter ISP mode correctly by firmware
Post by: Andy Ayre on November 28, 2006, 10:26:47 AM
Are you sending a string to the device to enter ISP mode or a break condition? You must choose one or the other.

The Start Bootrom feature is covered in the Flash Magic manal in detail. In there it describes that the command must be echoed back to Flash Magic followed by a ".". However you can disable the echo by using the commands provided.

Title: Re: [P89LPC935] How to enter ISP mode correctly by firmware
Post by: DB1BMN on November 28, 2006, 10:36:22 AM
Good evening,

then I did not found the right part yet in the docu.
Yes my program parses all serial communiaction and when a string "/BOOT" is received the programm jumps to the routine above and sets the Bits BR in the SSTAT-Register and EBRR in AUXR1.
So I must before send simply the String "/BOOT." back?

How to disable the echo
Title: Re: [P89LPC935] How to enter ISP mode correctly by firmware
Post by: Andy Ayre on November 28, 2006, 10:46:44 AM
Please see section 6.10 Start Bootloader in the manual. It should answer all your questions.

Title: Re: [P89LPC935] How to enter ISP mode correctly by firmware
Post by: DB1BMN on November 29, 2006, 02:19:37 PM
Good Evening,

ok sorry, I´m a little bit stupid. Firstly I thought, you mean the chapter 6 of the controller manual, but it deals about Power Monitoring Functions. Then I found the FlashMagic manal and there are quite good information. OK, I´ve learned, thet after sending the /BOOT-command my controller has to do the IAP-calls setting the Boot-Status-Byte to 1 and then has to reset. After reset it will run the ISP-firmware. OK, so far it does.
When I do this with an external terminal-program, I send "/BOOT<CR><LF>". My controller echoes then to me "/BOOT.<CR><LF>", so I dit unterstand that it has to echoe the dot "." after ther command. It does! So then I can do the operations FlashMagic provides: BlankCheck, and of course program new hex-file. So far if I use an externe Terminal Program.
BUT, if I do so with the FlashMagic´s "Start Bootloader"-function, there is still the error "Start BootROM command - "." incorrectly echoed", but my program is echoing the dot! So what does FM exactly expect here?

Regards, Marek
Title: Re: [P89LPC935] How to enter ISP mode correctly by firmware
Post by: Andy Ayre on November 29, 2006, 02:23:55 PM
If you send /BOOT<cr><lf> then Flash Magic expects /BOOT<cr><lf>.

Try this:

&04/BOOT

Flash Magic should not expect a response back from the device.

Andy
Title: Re: [P89LPC935] How to enter ISP mode correctly by firmware
Post by: DB1BMN on November 30, 2006, 11:44:14 AM
Hi Thank You,

yes that was it, my PRINT-rutines always appende <CR><LF> to each string passed, so that the dot was also followed by cariage return, that was wrong, now I´ve corrected it and it works. I do not need anymore jump the jumper :-)
But never the less, will now add an "real" echo function to my firmware.
Thanks again.

Regards, Marek