IAP of LPC935

Started by Bernhard 'Gustl' Bauer, July 06, 2005, 07:38:36 AM

Previous topic - Next topic

Bernhard 'Gustl' Bauer

Hi,

this may not fit here, but maybe you can help me.

I try to program a LPC935 via IAP calls.  They report a HVE error. Programming with flashmagic works.  I have no IRQs, just booting and getting the data via I2C (polling). So there should be no reason for a  HVE error. I use the 'Program User Code Page' call. The key is set before. Is there something else to be done before?

 I had a look at the code ISP uses for programming. I can find no difference to mine.

Does someone does know where to get the code of the bootrom (0FF00h). Maybe this could explain where the problem is.

TIA

Gustl


erikm

a possible cause will be that you "getting the data via I2C (polling)" use the same RAM slots as the bootloader.

Bernhard 'Gustl' Bauer

I'm not sure what you mean by 'RAM slots'.

I get the data via I2C and write it to a buffer at address 040h. Buffer size is max. 32 bytes. After that I set AA=0. So I2C is sleeping. The source address I give to IAP call is 040h. But I don't understand what should cause trouble.

Gustl


Bernhard 'Gustl' Bauer

Hi,

I have some further input. When I do a sector erase via flashmagic the 'Program User Code Page' call suddenly works. I tought a 'Program User Code Page' call doesn't need an erase before.  What is the difference between a flashmagic erase and the erase within the 'Program User Code Page' call?

Gustl

erikm

"I'm not sure what you mean by 'RAM slots'.
I get the data via I2C and write it to a buffer at address 040h"

what if the ROM code uses, say address 42 for temporary storage?

Erik

Bernhard 'Gustl' Bauer

"what if the ROM code uses, say address 42 for temporary storage?"

But shouldn't that be documented? I have found nothing. Another reason to for a look at the bootram.

Gustl

Andy Ayre

I believe that programming Flash memory requires an erase first, unless you are only programming to set bits (or clear bits depending on the flash technology used).

Embedded Systems Academy, Inc.
support at esacademy dot com