AnsweredAssumed Answered

stray @ in program

Question asked by Ankur Chauhan on Oct 20, 2015
Latest reply on Oct 20, 2015 by Pascal Irrle

Hi,

I'm trying to use MCU initialization by using bellow givin function :

 

void MCU_Init(void)

{

 

 

  /* Common initialization of the write once registers */

  /* SOPT1: COPE=0,COPT=1,STOPE=0,WAITE=1,??=0,RSTOPE=0,BKGDPE=1,RSTPE=0 */

  SOPT1 = 0x52;                

  /* SPMSC1: LVDF=0,LVDACK=0,LVDIE=0,LVDRE=1,LVDSE=1,LVDE=1,??=0,BGBE=0 */

  SPMSC1 = 0x1C;               

  /* SPMSC2: LPR=0,LPRS=0,LPWUI=0,??=0,PPDF=0,PPDACK=0,PPDE=1,PPDC=0 */

  SPMSC2 = 0x02;               

  /* SPMSC3: LVDV=0,LVWV=0,LVWIE=0 */

  SPMSC3 &= ~(byte)(0x38);

 

   /*  System clock initialization */

  if (*(unsigned char*)0x03FF != 0xFF) { /* Test if the device trim value is stored on the specified address */

    MCGTRM = *(unsigned char*)0x03FF;  /* Initialize MCGTRM register from a non volatile memory */

    MCGSC = *(unsigned char*)0x03FE;   /* Initialize MCGSC register from a non volatile memory */

  }

  /* MCGC2: BDIV=0,RANGE=0,HGO=0,LP=0,EREFS=0,ERCLKEN=0,EREFSTEN=0 */

  MCGC2= 0x00;                /* Set MCGC2 register */

  /* MCGC1: CLKS=0,RDIV=0,IREFS=1,IRCLKEN=1,IREFSTEN=0 */

  MCGC1= 0x06;                /* Set MCGC1 register */

  /* MCGC3: LOLIE=0,PLLS=0,CME=0,DIV32=0,VDIV=1 */

  MCGC3= 0x01;                /* Set MCGC3 register */

  /* MCGC4: ??=0,??=0,DMX32=0,??=0,??=0,??=0,DRST_DRS=2 */

  MCGC4= 0x02;                /* Set MCGC4 register */

  while(!MCGSC_LOCK) {                 /* Wait until FLL is locked */

  }

 

}

 

 

I include "mc9s08dv16.h" file for bove macro defination.

but i'm getting

DescriptionResourcePathLocationType
stray '@' in program expected '=', ',', ';', 'asm' or '__attribute__' before numeric constantmc9s08dv16.h/lcd_config/Sourcesline 454C/C++ Problem

this error.

 

what should i do to resolve it.

Outcomes