Error while trying to config SPI in VS code .

HI i am working with the nrf 52833 dk board using  nrf connect and trying to implement SPI ,

#define SPI3_NODE DT_NODELABEL(SPI_3)
static const struct spi_dt_spec* dev_spi = SPI_DT_SPEC_GET(SPI3_NODE,SPI_OP_MODE_MASTER,1);

I am getting this error - identifier "__device_dts_ord_DT_N_NODELABEL_SPI_3_BUS_ORD" is undefined. 

I am new to ncs and zephyr , so what is causing this error?

Related