@alliv
hi,
I have a question regarding the software reset API function:
The API looks like this:
void _dwt_disablesequencing(void)
{
_dwt_enableclocks(FORCE_SYS_XTI);
dwt_write16bitoffsetreg(PMSC_ID, PMSC_CTRL1_OFFSET, PMSC_CTRL1_PKTSEQ_DISABLE);
}
void dwt_softreset(void)
{
_dwt_disablesequencing();
dwt_write16bitoffsetreg(AON_ID, AON_WCFG_OFFSET, 0x00);
dwt_write8bitoffsetreg(AON_ID, AON_CFG0_OFFSET, 0x00);
_dwt_aonarrayupload();
dwt_write8bitoffsetreg(PMSC_ID, PMSC_CTRL0_SOFTRESET_OFFSET, PMSC_CTRL0_RESET_ALL);
deca_sleep(1);
dwt_write8bitoffsetreg(PMSC_ID, PMSC_CTRL0_SOFTRESET_OFFSET, PMSC_CTRL0_RESET_CLEAR);
pdw1000local->wait4resp = 0;
}
My question is:
Why is it necessary to disable sequencing if I only want to do a software reset ?
dwt_write16bitoffsetreg(PMSC_ID, PMSC_CTRL1_OFFSET, PMSC_CTRL1_PKTSEQ_DISABLE);
Why is it not just enough to force the device into the INIT state by setting the system clock to XTI ?
_dwt_enableclocks(FORCE_SYS_XTI);