write command in intialization file (debug)

Hello,

I've a short question: Is it possible to write one command to an external flash device in the init file (option for target > debug > initialization file)???

Something like that:

#define M16(adr) (*((volatile unsigned short *) (adr)))

FUNC FlashDevice(void) {
   M16(base_adr + 0x0555) = 0xAA;
}

//...

FlashDevice();

best regards
Stefan

More questions in this forum