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.

BQ27Z561-R1: How to Write Device Name ?

Part Number: BQ27Z561-R1
Other Parts Discussed in Thread: BQSTUDIO

Hi, Team

     We want to change Device Name to "AQPR1".

     But when I try to read out it, there is a confusing thing.

     Device Name Data read from AltManufacturerAccess() 0x004A Device Name and dataflash 0x4080 are different, one is length byte + data, the other is data + somelse I don't know.

     

   So if I want to change the Device Name to "AQPR1", how can I write it ? write to 0x004A or 0x4080 ? Does it need a length byte to write in byte0?

    

  • Hi Zhu Jay,

    You write to 0x4080. Using AltManufacturingAccess() 0x004A will only return the value stored in 0x4080. It does require a length byte at byte 0.

    Best,

    Jessica

  • Hi Jessica,

         Thanks for your reply.

         But I see that 0x004A is a R/W Register.

         

        Anyway, I already writed it success. So I share my procedure here.

        It has some special rule here that when I writed to 0x4080, other characters must be supplemented by spaces. Or it would be failure to read by 0x004A.

        e.g. write AQPR1 :  writeDataFlash(0x4080,DATA,21)    DATA[22] = { 0x05, 0x41 ,0x51,0x50,0x52,0x31,0x20,0x20,0x20,...,0x20} 

         There need one more space or it will change to 0 , but I don't know why.

       And I find that writing to 0x004A  also can change Device Name .  It is easy to do that.

        e.g. write AQPR1 :  writeDataFlash(0x004A,DATA,6)      DATA[6] =  { 0x05, 0x41 ,0x51,0x50,0x52,0x31}

         Please correct me if anything is wrong.

       Best,

       Jay

  • Not sure the detail in your API. Posted the I2C transaction in bqStudio for your reference. 

    Two points need to be noted. 

    1. After sending 0x3E, need to send 0x60 with checksum. Otherwise, the updating process is failed.

    2. After modified something, please read back to ensure what you write is successful. 

  • can you please provide same example using c code