Hello everyone,
I'm currently working on porting a device driver to Zephyr on the nRF9160. I have defined a device tree and set up the device through the .overlay file. As soon as I try to call device_get_binding("WFM200") Zephyr crashes and stays in a boot loop. Everything is working correctly if I call device_get_binding("SPI_2"). I have built the device tree by looking at examples but I suspect that I'm missing something.
Help would be greatly appreciated.
Thanks in advance!
silabs,wfx.yaml:
description: SiLabs WFX module compatible: "silabs,wfx" include: spi-device.yaml properties: cs-gpios: type: phandle-array required: true resetn-gpios: type: phandle-array required: true irq-gpios: type: phandle-array required: true wakeup-gpios: type: phandle-array required: false
nrf9160dk_nrf9160ns.overlay:
&spi2 { compatible = "nordic,nrf-spim"; status = "okay"; sck-pin = <10>; mosi-pin = <11>; miso-pin = <12>; wfx@0 { status = "okay"; compatible = "silabs,wfx"; label = "WFM200"; reg = <0x0>; spi-max-frequency = <8000000>; cs-gpios = <&gpio0 13 GPIO_ACTIVE_LOW>; resetn-gpios = <&gpio0 25 GPIO_ACTIVE_LOW>; irq-gpios = <&gpio0 17 GPIO_ACTIVE_HIGH>; wakeup-gpios = <&gpio0 0 GPIO_ACTIVE_HIGH>; }; };