nRF9151DK I/O expander handling

Hello,

I would have a question regarding the use of PCAL6408A I/O expander on nRF9151 DK. The buttons and LEDs on nRF9151 DK are connected both directly to the processor and to the I/O expander which enables to free up some pins. I would have following questions:

1. How can you switch between direct connection and use of an expander? From the nRF9151 DK schematic it seems, that the pin responsible for switching between direct connection/connection via expander (IOEXP_CTRL) is connected to the debugger (nRF5340). Is it enough to enable the expander in the overlay (change it's status to "okay") and based on that debugger will switch on the IOEXP_CTRL pin? Or is some other additional configuration needed?

2. Is there any example available for use of this expander in nRF Connect SDK? It looks like there is a driver available for it:

https://docs.nordicsemi.com/bundle/ncs-2.9.1/page/zephyr/build/dts/api/bindings/gpio/nxp_pcal6408a.html

but I'm not sure how can it be used - do you need only to define the subnodes of node for pcal6408 for each GPIO, and then you can use them in your code as regular GPIOs? Or do you need to use some lower level calls to pcal6408 driver?

Thanks in advance for any help you can provide.

Jacob

Parents Reply Children
No Data
Related