Guest wrote:
> Thx, I misread the IAP_LOCATION. With the new adress 0x7FFFFFF1 the
> Prepare
> command works fine.
> New problemm is, if I will write to flash the source adress is not on a
> correct boundary.
>
> void IAP_Write (void)
> {
> // Copy RAM to Flash
> // setting function pointer
> IAP_Entry = (IAP) IAP_LOCATION;
> // set command code
> iap_command[0] = 51;
> // destination flash where data byte to be written
> iap_command[1] = (unsigned long)0x00018000;
> // source RAM address where data bytes are to be read
> iap_command[2] = (unsigned short)&contrast_lokal;
> // number of bytes to be written
> iap_command[3] = 256;
> // set system clock frequency, unit kHz
> iap_command[4] = 60000;
> // prepare sectors for write
> IAP_Entry(iap_command,iap_result);
> }
>
> I inexperienced about thumb and arm mode because the arm porzessor is
> new for me.
hi,
i am using LPC-2148 and want to write some coefficients in Flash i have
tried to use IAP code as given in the manual, but it is not working. it
seems you have faced same problem few days back. can you please guide me
how to use this IAP functions for FLash read or Write and how to select
Thumb mode