2003-11-24 08:01 PM
Reprogramming of Option Bytes via IAP (ST72F561)
2003-11-10 03:28 AM
Hey Forum!
Isn't it possible to reprogram the option bytes via IAP?! erasing and programing of Sector 2,1 works fine in IAP mode but every time i try to erase the option bytes to reprg them the controller seems to make a reset (!?!) and thereafter the only way to get the controller alive is to write valid option bytes via a ICP programer. Could someone help me please Thanks in advance, Dejan2003-11-10 08:40 PM
Hi,
Option bytes, like sector 0, can only be programmed using the ICC protocol, not IAP. regards, Simon2003-11-10 09:01 PM
On HDFlash devices the option bytes can be programmed in user mode (IAP) but with some issues. Have a look at the Flash Programming Referance manual for more info.
Regards sjo2003-11-10 09:40 PM
@sjo:
I've read the spec and found following terms: 1. A new option byte configuration becomes valid only after next device RESET. Nevertheless, the command returns n</div>2003-11-11 02:00 AM
There is an FAQ in the knowledge base related to this(Reference no 58400).
2003-11-11 02:46 AM
I think the issue is when you erase the options they default to 0xFF and so without a valid external clock source the micro would stop running.
Is the watchdog active on the micro (software or hardware), causing the reset. Regards sjo2003-11-11 05:52 PM
Could you explain-
- Is the reset coming between erasing and programming the option bytes OR after reprogramming the option bytes? - What are option byte settings you make when reprogramming?2003-11-11 07:12 PM
Hey,
the Reset comes right afer erasing the optionbyte. But in the prg spec is written that the uC takes over the new configuration NOT until the next reset! Anyway it looks like the uC does a reset after erasing the optionbyte By the way, if I do a write with the same value thats already prg (without a erase!), I get the prg success message! Settings are: Resonator-Osz., Speed 4-8Mhz, Hardware Watchdog ON any suggestions? regards, dejanki [ This message was edited by: DejanKi on 12-11-2003 08:46 ]2003-11-11 09:06 PM
Have you tried without Hardware watchdog active.
I do know that some devices ,eg. 651 will not reprogram (due to device reset) if the Hardware watchdog has been set. Regards sjo