This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Devicetree overlay and "compatible" property for a non-supported device

I'd like to test the SPI communication between my nRF52833 DK and a ICM-20948 developer board. Keep in mind that the ICM-21948 is a device not listed in the NCS. To activate the SPI0 interface I created an overlay file with the following lines:

&spi0 {
	status = "okay";
	sck-pin = < 0x04 >;
	mosi-pin = < 0x1c >;
	miso-pin = < 0x1d >;
	cs-gpios = <&gpio0 3 GPIO_ACTIVE_LOW>;

	icm20948@0 {
		compatible = "invensense,icm20948";
		reg = <0>;
		label = "ICM20948";
		spi-max-frequency = <7000000>;
	};
};

After the build the spi0 in the zephyr.dts is:

spi0: spi@40003000 {
			compatible = "nordic,nrf-spi";
			#address-cells = < 0x1 >;
			#size-cells = < 0x0 >;
			reg = < 0x40003000 0x1000 >;
			interrupts = < 0x3 0x1 >;
			status = "okay";
			label = "SPI_0";
			sck-pin = < 0x4 >;
			mosi-pin = < 0x1c >;
			miso-pin = < 0x1d >;
			cs-gpios = < &gpio0 0x3 0x1 >;
			icm20948@0 {
				compatible = "invensense,icm20948";
				reg = < 0x0 >;
				label = "ICM20948";
				spi-max-frequency = < 0x6acfc0 >;
			};
		};
 

So I can buil the application but in the overlay file I get an underline error that tell me

Only spi nodes accepted in /soc/spi@40003000/

cause the compatible property is not described by a yaml file like supported devices in the NCS.

Should I take care of this error or can I go on without the fear to run into future problems? Can I create yaml bindings files for my custom devices?

Related