Skip to content

Standard devicetree connectors for boards #15598

@Mani-Sadhasivam

Description

@Mani-Sadhasivam

Is your feature request related to a problem? Please describe.
For the boards belonging to a standard form factor like 96Boards, it would be nice to have a dedicated devicetree connector which can expose the available peripherals like GPIO, I2C, SPI in a generic way so that the sample applications can run on any board adhering to the standard.

Describe the solution you'd like
This could be achieved by having a below devicetree node in board dts:

        96b-ls-con {
                compatible = "96b-ls-con";
                i2c0 = &i2c0;
                uart0 = &uart0;

                gpioa: gpioa {
                        gpios = <&gpio0 1 0>;
                        label = "GPIO-A";
                };
                gpiob: gpiob {
                        gpios = <&gpio0 2 0>;
                        label = "GPIO-B";
                };
        };

Then the applications can make use of the definitions like DT_96B_LS_CON_GPIOA_GPIO_CONTROLLER, DT_96B_LS_CON_GPIOA_GPIO_PIN etc...

For achieving the above solution, a separate connector binding needs to be created and it shall include all possible peripherals.

Describe alternatives you've considered
There is already a concept of shields exist in Zephyr but it is limited to the expansion connectors and specifically not able to handle individual gpio's.

Metadata

Metadata

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions