WXK
2023-08-30 72d5e74bf1969d0a1429a14a4f409eddf938d66d
decadriver/deca_device.c
@@ -428,6 +428,7 @@
 *
 * returns DWT_SUCCESS for success, or DWT_ERROR for error
 */
int dwt_configure(dwt_config_t *config)
{
    uint8_t nsSfd_result  = 0;
@@ -435,7 +436,7 @@
    uint8_t chan = config->chan ;
    uint32_t regval ;
    uint16_t reg16 = lde_replicaCoeff[config->rxCode];
    uint8_t prfIndex = dw1000local.prfIndex = config->prf - DWT_PRF_16M;
    volatile uint8_t prfIndex = dw1000local.prfIndex = config->prf - DWT_PRF_16M;
    uint8_t bw = ((chan == 4) || (chan == 7)) ? 1 : 0 ; // Select wide or narrow band
    dw1000local.chan = config->chan ;
@@ -2879,7 +2880,7 @@
 */
void dwt_forcetrxoff(void)
{
    decaIrqStatus_t stat ;
//    decaIrqStatus_t stat ;
    uint8_t temp ;
    uint32_t mask;
@@ -3101,7 +3102,7 @@
 */
void dwt_setinterrupt(uint32_t bitmask, uint8_t enable)
{
    decaIrqStatus_t stat ;
//    decaIrqStatus_t stat ;
    uint32_t mask ;
    // Need to beware of interrupts occurring in the middle of following read modify write cycle