NCS-2.1.0 - CONFIG_ADP536X_BUS_NAME not longer valid?

Updating to NCS 2.1.0 the CONFIG_ADP536X_BUS_NAME is still defined but seems to be not longer valid.

The "adp536x.h" is now in the includes. Is there a supported way to use it?

In the boards definition for the Thingy:91 DEVICE_DT_GET(DT_NODELABEL(i2c2)) is used.

Is that the preferred way to address the  adp536x?

Parents
  • Hi, 

    Updating to NCS 2.1.0 the CONFIG_ADP536X_BUS_NAME is still defined but seems to be not longer valid.

    Please kindly elaborate more detail about "but seems to be not longer valid.". What is the log you get?

    Also, check the adp536x/Configuration

    Regards,
    Amanda

Reply
  • Hi, 

    Updating to NCS 2.1.0 the CONFIG_ADP536X_BUS_NAME is still defined but seems to be not longer valid.

    Please kindly elaborate more detail about "but seems to be not longer valid.". What is the log you get?

    Also, check the adp536x/Configuration

    Regards,
    Amanda

Children
  • It's possible to compile

    i2c_dev = device_get_binding(CONFIG_ADP536X_BUS_NAME);

    but with NCS-2.1.0 i2c_dev is always NULL on a Thingy:91.

    Before I used it with NCS-2.0.1, and there the device pointer was returned.

    Anyway, you may just find out, if CONFIG_ADP536X_BUS_NAME is considered to be supported, but may be currently failing, maybe even only on my side, or if it's considered to be replaced by something else.

    > Also, check the adp536x/Configuration

    Of course! It's still in Kconfig there. Therefore it compiles.

    Did you check the current implementation? Could you point me to the source, where this actually used? Because my finding analyzing the code was, that this Kconfig CONFIG_ADP536X_BUS_NAME is not longer used and replaced by DEVICE_DT_GET(DT_NODELABEL(i2c2)).

    I wonder, if someone at nordic is aware and take care of such changes. It makes it very hard to update.

  • Hi Amanda,

    thanks again for the reference!

    The Zephyr project will hardly explain, what Nordic recommends on a deprecated Kconfig and the gap and misleading documentation from Nordic in your first reference.

    Do you consider to answer my question:

    > The "adp536x.h" is now in the includes. Is there a supported way to use it?

    > In the boards definition for the Thingy:91 DEVICE_DT_GET(DT_NODELABEL(i2c2)) is used.

    > Is that the preferred way to address the  adp536x?

    Before you add the next "dead end reference", please ensure, that you read an verify the content of that reference.

  • Hi, 

    You should use DEVICE_DT_GET. There is a detailed transition guide in the Zephyr v3.2.0 release notes devicetree section, and the link I posted in the previous reply. 

    -Amanda

  • So the Kconfig docu about CONFIG_ADP536X_BUS_NAME is deprecated and CONFIG_ADP536X_BUS_NAME doesn't work anymore, right?