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.

  • TI Thinks Resolved

DS90UB954-Q1: Can I do 32 bit address writes in ALP in Python?

Intellectual 540 points

Replies: 3

Views: 288

Part Number: DS90UB954-Q1

using ds90ub953 / 954 with  ON semi AP1302 ISP. Some registers are 32 bit address.

How could these writes be performed in ALP ?

Can do 16 bit address writes to 8/16/32 bit wide registers ok 

  • Martin,

    First I show below 16-bit read/write examples of imager (i2c address 0xC4). .

    a) First register address 0x3129 is written with a value of 0x80 using the command

       board.WriteI2C(0xC4, 0x31, [0x29, 0x80])

    b) Then register 0x3129 is read back using the command

       board.ReadI2C(0xC4, 0x31, [0x29, 0x01])

    c) Alternatively, you can also use the following command to read back  a single byte

       board.ReadI2C(0xC4, 0x31, [0x29])

    Below I explain with an example how to extend above method for 32-bit address:

    a)      For 32bit address 0x31291304, writing a 16-bit value 0x8010, this can be extended as

    >>> board.WriteI2C(0xC4, 0x31, [0x29, 0x13, 0x04, 0x80, 0x10])

    b)      Then 2 bytes of register 0x31291304 value  can be read back using the command

    board.ReadI2C(0xC4, 0x31, [0x29, 0x13, 0x04, 0x02])

    Please try and let us know.

    Thanks,

    Vishy

  • In reply to Vishy Viswanathan:

    so a 32 bit address for a 32 bit double word value of 0x8010aa55 would be like
    board.WriteI2C(0xC4, 0x31, [0x29, 0x13, 0x04, 0x80, 0x10,0xaa,0x55]) ?
  • In reply to martin DONAGHY:

    Yes. That's correct. I have not tested 32-bit address/ 32-bit data read/writes. But the framework has the support and it should work. Let me know if you run into issues.

    Thanks,
    Vishy

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.