Because of the Thanksgiving holiday in the U.S., TI E2E™ design support forum responses may be delayed from November 25 through December 2. Thank you for your patience.

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.

BQSTUDIO: BQSTUDIO: Unable to import gg.csv file and write to RAM for bq27220 version 2

Part Number: BQSTUDIO
Other Parts Discussed in Thread: BQ27220, , EV2400

Sorry for the late reply, and need for a related question add, I'm just now jumping back into bqStudio usage for a bq27220 device and realized the import of .gg.csv parameters issue is still occurring.  

 

In my original thread post (see link below), TI mentioned that there was a minimum battery voltage requirement to allow updates to succeed.  My setup is as follows:  GDK connected to bq27220 EVK via I2C, battery connected to bq27220 EVK, GDK load connected to bq27220 EVK load pins.  In reviewing my original screenshot from the forum post it appears that I did not have the GDK load pins connected to the bq27220 EVK (the GDK showed 520mv, but bq27220 EVK showed 4071mV).  I corrected this item, but am still seeing the same issue.  

e2e.ti.com/.../847812

 

In my current setup, I have the GDK load pins connected to the bq27220 EVK.  Both the GDK and bq27220 EVK report 3500mV.  I unseal and unseal full access the bq27220 EVK.  I performed calibration of the bq27220 EVK, updated calibration/configuration/gauging parameters via manual entry per my new battery report files from GPC.  I then "Write_All" of these parameters to bq27220 EVK RAM and then "Read All" to confirm all of the updated settings are correct.  I then export these settings to the .gg.csv file and I do not open the .gg.csv file outside of bqStudio (i.e. not opened with Excel).  I then create the Golden Image files using these same parameters.  

 

I came back to my test setup today and want to reload all of the parameters stored in my .gg.csv file.  Same connection setup as before, boot up the GDK and bq27220 EVK, and then unseal & unseal full access the bq27220  I then import my newly created .gg.csv file to bqStudio.  The 1st screen shot below shows that these items were imported correctly and the calibration/configuration/gauging buttons all show an *, which indicates changes have been made.  However, when I click "Write_All" bqStudio's "Data Memory" reverts to the original values in the bq27220 instead of the imported values I was trying to program from the .gg.csv file (see 2nd screen shot).  Am I missing a step in loading the imported .gg.csv parameters to bq27220 RAM?   Other potential setup issue?  

One oddity that I noticed is that upon clicking "Write_All" the lower right corner of bqStudio reports "Reading Data Memory" (3rd screen shot).  Once that process completes the "Data Memory" pane now displays the original RAM data for the bq27220.  Perhaps the bqStudio tool is reading RAM contents before writing the parameters from the .gg.csv file?  

The only way I've been able to update RAM parameters thus far is via manual entry of each field, which is very time consuming and may lead to errors as many fields must be updated.  It is much preferred to perform a deep analysis of these parameters once and then save the settings to a golden .gg.csv file for later import.  Based on other forum posts (see below) and 100 views of my original post it seems others have encountered this issue as well: 

e2e.ti.com/.../794365

     

bqStudio settings updated via .gg.csv file import

 

bqStudio parameters after "Write_All" to the bq27220.  Red items are original data from bq27220 RAM

 

bqStudio reports "Reading Data Memory" after "Write_All" is clicked (lower right corner)


  • Hello James,

    Double check to make sure your gauge is unsealed (refresh the screen) before trying to write, if the gauge didn't unseal then you will not be able to write to the gauges memory.

    Sincerely,

    Wyatt Keller

  • Wyatt,

    I've double checked that the bq27220 is unsealed.  If you do not issue the unseal and then unseal full access commands the part will report all 0's to the Data Memory pane of bqstudio and also provide an error message in RED at the bottom of the pane detailing the part is still sealed (Screenshot 1 below).    

    If I "unseal" and then "unseal full access" to the bq27220, then a Read All command will display the contents of RAM.  Screenshot 2 below details a Read All after unsealing.  The "Operation Config B" data shown in screenshots 2 & 3 confirms that the bq27220 is indeed unsealed (Operation Config B register = 0x1860).  

    After confirming the unseal is successful, I then import the .gg.csv file again and the Data Memory pane shows the imported parameters as expected.  However, when I "Write_All" to the bq27220 the Data Memory pane data reverts back to the original RAM data from the bq27220 and not the new imported settings.  

    Upon closer inspection I see the following error in the lower left of the Data Memory pane when I attempt the "Write_All" process:  "Value is beyond minimum value defined for parameter.:Configuration (Present OTP).Power.Hibernate V".  See screenshot 4 below.  I'm not sure how this error applies to my situation as I'm only trying to update bq27220 parameters in RAM and not OTP memory.  Does the Write_All command update the contents of RAM or OTP?  When hovering over the Write_All button the info bubble displays "Write all items to DF".  Does DF stand for data flash?  

    Anyway, it seems this error is due to all 0's in the OTP fields, so I went through the arduous process of entering OTP data for all 3 CEDV profiles just to see if the error could be circumvented (entering the OTP values for 1 profile caused a similar error for profiles 2/3).  After entering this OTP data I tried Write_All and received a new error:  "No parameter matched address" error.  See screenshot 5.  I exported all RAM/OTP parameters to a new .gg.csv file, so I tried to import that file and Write_All again but still received the "No parameter matched address" error.  

    Screenshot 1:  Initial read of bq27220 w/o unsealing

    Screenshot 2:  Data Memory pane after unsealing bq27220 and Read All


     


    Screenshot 3:  Data Memory pane with expanded details for Operation Config B register

     


    Screenshot 4:  Error for lack of OTP data

     

    Screenshot 5:  Error after all OTP parameters entered


  • Hello James,

    For this gauge you need to be in FULL ACCESS mode as well to edit data memory, it looks like from the examples you've shown you're only testing in UNSEALED.

    Section 6.1 Data Memory Parameter Update Example shows all the steps, the bq27220 is very particular about the sequence.

    Sincerely,

    Wyatt Keller

  • Wyatt,

    Are you referring to UNSEAL_FULL_ACCESS?  If so, you'll notice from the Log Panel in my previous screen shots that I send the UNSEAL (0x36720414) and then the UNSEAL_FULL_ACCESS (0xFFFFFFFF) commands via bqStudio before I import the .gg.csv file and attempt to Write_All. 

    When in the UNSEAL_FULL_ACCESS mode I can edit data memory items manually from Data Memory pane and can successfully Write_All those modified parameters to the bq27220.  My issue is I can not import those same parameters from the exported .gg.csv file and then Write_All to the bq27220.  For some reason imported settings are not properly handled and written to the bq27220.  

    -James

  • OK, after banging away at the bqStudio tool and blending in steps from Section 6.1 of the bq27220's technical reference manual I found the following sequence would allow import of parameters saved to a .gg.csv file. The bq27220 part is extremely finicky to specific command sequences, hopefully this info helps others work through the hurdles.

     Wyatt/TI:  Feel free to add to or edit this process if there is a more straight forward method.  

    Creation of the .gg.csv file I’m fairly sure this process works, but didn’t fully verify once I landed on a .gg.csv file that finally worked.

    1.  bqStudio must be used to create the initial .gg.csv file. Calibration and battery CEDV parameters should already be tested and ready to load into a golden .gg.csv file.
    2.  Connect the bq27220 to GDK (or even EV2400?).  
    3.  Launch bqStudio, it should auto detect the bq27220.
    4.  Issue the "UNSEAL" command.
    5.  Issue the "UNSEAL_FULL_ACCESS" command.
    6.  Manually enter all parameters for Calibration, Configuration, and Gas Gauging, for both RAM and OTP….noting that you must hit enter 3 times for each parameter in order for the tool to accept the change.
    7.  Write_All to the bq27220
    8.  Export the .gg.csv file. Note that the .gg.csv file is populated with contents from bq27220 memory, not just the parameters entered via the Data Memory pane of bqStudio. Thus the need for a Write_All process before exporting.
    9.  If you want to make changes to the .gg.csv file I recommend making a copy. bqStudio warns about Excel silently changing items, I found that NotePad++ can edit the .gg.csv file and then bqStudio can import without issue.

    Writing .gg.csv file parameters to bq27220

    1.  Connect the bq27220 to GDK (or even EV2400?).  
    2.  Launch bqStudio, it should auto detect the bq27220.
    3.  Issue the "UNSEAL" command.
    4.  Issue the "UNSEAL_FULL_ACCESS" command.
    5.  Issue the "ENTER_CFG_UPDATE" command.
    6.  Import your previously saved .gg.csv file.  
    7.  Issue the “Write_All” command. You’ll notice in the bottom right corner a “Writing Data Memory” progress bar; if not you may have to POR and start from step 3 again. All parameters are now written to the bq27220. You can verify via the “Read All” command. The CC Delta parameter likely won’t match the value from the .gg.csv file, but will be close.
    8.  Issue the “EXIT_CFG_UPDATE” command. “Read All” again to verify parameter sets. You will notice that current calibration items are now all 0’s (CC Offset, CC Cal Temp, CC Gain, CC Delta).
    9.  Issue the "UNSEAL" command.
    10.  Issue the "UNSEAL_FULL_ACCESS" command.
    11.  Import your .gg.csv file again.
    12.  Issue the “Write_All” command. All parameters are now written to the bq27220. You can verify all, including current calibration items, via the “Read All” command (again CC Delta won’t exactly match, but will be close). Also, when you Read All the OTP contents may be all 0’s if it hasn’t been programmed via another method outside the scope of this document. Not an issue for me as I’m only using RAM given the lack of calibration item storage in OTP.  
    13.You can now create a Golden Image for use in host system loading of these parameters.