This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Chip Select pin in SDK 11.0

In NRF52-DK, I am currently working on NRF5 SDK 11.0.

In examples/peripheral/spi/pca10040/, The master spi device is continuously sending "Nordic" string every 200msec to the slave.

My question is are you making Chip Select (CS) pin low every 200 msec when there is data to be sent or you are making it low all the time.?

Rgds,

Parents Reply
  • CS pin is not set high in spi_event_handler(), It is a small function that is called after data is transferred from m_tx_buf. Please correct me.

    At line no: 540 in nrf_drv_spi.c, the function nrf_gpio_pin_clear(p_cb->ss_pin) clears the CS pin.

    Without EasyDMA: At line no: 415 in nrf_drv_spi.c, the function nrf_gpio_pin_set(p_cb->ss_pin) sets the CS pin.

    With EasyDMA: At line no: 502 in nrf_drv_spi.c, the function nrf_gpio_pin_set(p_cb->ss_pin) sets the CS pin.

    Clearing CS and Setting CS pin happens in the same function nrf_drv_spi_transfer() ?

    Thanks,

Children
No Data
Related