what is the meaning difference between security byte define ?

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

what is the meaning difference between security byte define ?

1,161件の閲覧回数
tigerlo
Contributor III

What is the difference between if security protect byte FSEC set to 0xFF & 0xFD ?
//FSEC          EQU     0xFE ; no security in flash

//FSEC          EQU     0xFF ; security protect
FSEC EQU 0xFD ; security protect

When I set FSEC to 0xFD , my program execution have something difference with 0xFE(No security)when FSEC setting to 0xFD, the program can't execute correct ? I am very confusing ?

#define FLASH_TEMPERATURE_DELTA_ADDR 0x7C00

FlashAddr=(uint8_t *) FLASH_TEMPERATURE_DELTA_ADDR;
FlashHeader=*FlashAddr;
#if defined (DEBUG_SYATEM_STARTUP)
PRINTF("\r\n FlashHeader = %x , FlashAddr = %x\r\n",FlashHeader,FlashAddr);
#endif
if(FlashHeader!=FLUSHBUFFER_HEADER)
{
GPIO_DRV_ClearPinOutput(kGpioRedLED);
OSA_TimeDelay(2500);
GPIO_DRV_SetPinOutput(kGpioRedLED);
} else {
LED_toggle_red_led(1);
}

The above program can't be executed correctly, I only read  0x7c00 data & light LED , it is very simple.

0 件の賞賛
返信
1 返信

1,068件の閲覧回数
jorge_a_vazquez
NXP Employee
NXP Employee

Hi Tiger Lo

0xFF and 0xFD in FSEC field represent the same MCU secured state.

pastedImage_1.png

Hope this information could help you.
Best Regards

Jorge Alcala

0 件の賞賛
返信