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.

BQ34110: Calibration: what flag to use?

Part Number: BQ34110
Other Parts Discussed in Thread: BQSTUDIO

Status returned by OperationStatus() command has CALMD. Status returned by ManufacturingStatus subcommand has CAL_EN. The latter is mentioned in the EVM manual.

For some reason, while I was coding and testing my code to writing and reading back data from the  DF, I noticed bqStudio sometimes showed these two bits with different levels after toggling the Calibration mode. When I used CALMD to check if the calibration mode was active, I could successfully write to the DF, whereas CAL_EN did not work.

So, which one is safer to use. What could cause both bits to diverge?

When the microcontroller is accessing the fuel gauge, I disconnect the EVM-2400 pod, to avoid contention. When I connect the pod, I stop the processor with the  debugger. BTW, is there a configuration to force bqStudio to not access the FG? 

FWIW, the sequence I am following to write to the DF is:

Unseal-> wait 4s -> Unseal full access -> Enable Cal mode -> Write a low value to Flash Update OK -> Write the intialization data to the DF -> Disable Cal mode->Unseal.

Is this sequence OK?  Sometimes I do not Unseal, as I am testing and do not want to wait for the Unseal delay. Could this cause any problem? Should I reset the FG after the calibration process?

  • Hello Elder,

    Both should be set when you enter calibration mode, CALMD also allows for ADC values to be read from manufacturingData(). CALMD must also be set to read these ADC values and calibrate the gauge.

    You can disable the auto-refresh function on the top left in bqStudio, the bus should not be active when the refresh is off.

    Between your unseal and unseal full access you should keep the delay, removing the delay may prevent you from unsealing.

    Sincerely,

    Wyatt Keller

  • Hello, Wyatt.

    About the CALMD vs. CAL_EN flags, that was my understanding too, i.e. both should be set/reset together when I send the calibration mode toggle command, but for some reason, they were not synced (based on bqStudio screen).

    From your answer, I understand that it is OK using CALMD to verify if calibration mode is active.

    Thank you for the tip on the auto-refresh. I just checked with the protocol analyzer and it works exactly as your said. Super!!!

    BR

    Elder.

  • Hello Elder,

    Yes both should be linked to similar functions, CALMD activates the raw ADC readings as well.

    Great! glad it helped.

    Sincerely,

    Wyatt Keller