This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

MSP430FR5989: Timeout ReCalScanIF in ESI MSP430FR5989 (2 LC sensor)

Part Number: MSP430FR5989
Other Parts Discussed in Thread: TIDM-LC-WATERMTR

HI

I am testing the ReCalScanIF function, I used timeout Recal is 15s, when I tried the water meter with flow 500L/h. It means it can measure 2 liters in 15s, but don't enough for the RecalScanIF function, it needs 4 rotations ( 4 liters). However, The RecalScanIF function can work well and didn't timeout. I tried to debug with the RecalScanIF function and the result is it only needs about 1.6 liters (loopCounter==16) to finish calibration. Is it wrong?  this happens when the disk passes very slowly.

I tried again with flow 2000L/h (8 liters for 15s) and debug the RecalScanIF function, the result is 4 liter for loopCounter=16. It is right to "LC Sensor Rotation Detection With MSP430Tm Extended" document.

Thanks,

  • Please check the code below (Generation from FlowESIGUI ). Why does the command ask " wait for the Q6 flag" but the code didn't turn on Q6 interrupt?

    ////////////////

    if(gRecalFlag&PERIODIC_AFE2_RECALIBRATION)
    {
    ESI_disableInterrupt(ESI_INTERRUPT_ESISTOP);
    // 4 cycles
    if (loopCounter == 16){
    // set valid calibration
    gRecalFlag |= VALID_RECALIBRATION;
    break;
    }

    // wait for the Q6 flag
    __bis_SR_register(LPM3_bits+GIE);

    } else if (gRecalFlag&INITIAL_AFE2_RECALIBRATION) {
    ESI_disableInterrupt(ESI_INTERRUPT_ESISTOP);

    // 8 cycles
    if (loopCounter == 32){
    // indication of valid calibration
    gRecalFlag |= VALID_RECALIBRATION;
    break;
    }

    // wait for the Q6 flag
    __bis_SR_register(LPM3_bits+GIE);

    }

    ////////////////////////////////////////////

  • Have you try our demo code? Dose it works?

  • Hi Gary,

    I tried with demo code "TIDM-LC-WATERMTR", it work but the RecalScanIF function like FlowESIGUI.

  • Hi Loc

    The calibration work flow as below

    Q6 is used to detect rotation numbers.

**Attention** This is a public forum