Here is the code I use,according to DEMO.
void g_v_MCModeInit(void)
{
vuint32_t temp,timer;
/* Disable Software Watchdog (SWT) */
SWT_0.SR.R = 0xc520;
SWT_0.SR.R = 0xd928;
SWT_0.CR.R = 0x8000010A;
/* Clear all "Functional Event Status reset sources" to avoid staying in SAFE mode */
MC_RGM.DES.R = 0xFFFFFFFF; //write 1 to clear dest reset events
MC_RGM.FES.R = 0xFFFFFFFF; //write 1 to clear func reset events
MC_ME.ME.R = 0x000005FF; //enable all modes
XOSC.CTL.B.OSCM = 0x1; //Without this code, the start-up phase of the waveform more unstable
XOSC.CTL.B.EOCV = 0x80; //This code with or without observation oscilloscope waveforms found no effect
// Enable the EXTAL clk
MC_ME.DRUN_MC.B.XOSCON=1;
/* RE enter the drun mode, to update the configuration */
MC_ME.MCTL.R = 0x30005AF0; /* Mode & Key */
MC_ME.MCTL.R = 0x3000A50F; /* Mode & Key inverted */
while(MC_ME.GS.B.S_MTRANS == 1); /* Wait for mode entry to complete */
while(MC_ME.GS.B.S_CURRENT_MODE != 0x3); /* Check DRUN mode has been entered */
/* Wait for clock to stabilize */
while(!MC_ME.GS.B.S_XOSC);
Any body help me?
I have assigned similar question from different customer, now waiting for factory response. However it seems it is common behavior of this device.