For either the nrf52840 or the nrf52833 which pins are responsible for configuring the serial preference SPI, UART and I2C and how to map them. Are they any software examples of this?
For either the nrf52840 or the nrf52833 which pins are responsible for configuring the serial preference SPI, UART and I2C and how to map them. Are they any software examples of this?
which pins are responsible for configuring the serial preference SPI, UART and I2C and how to map them.
It's SW controlled. See any peripheral example.
Thank you for the quick response. I am quite new to the nordic devices and interfacing them through SPI. Would it be possible for you to walk me through an example detailing the configuration of pins capable of SPI,UART and I2C.
Second question are all gpio pins of the nrf52833 capable of being configured as a serial port?
Thank you for the quick response. I am quite new to the nordic devices and interfacing them through SPI. Would it be possible for you to walk me through an example detailing the configuration of pins capable of SPI,UART and I2C.
Second question are all gpio pins of the nrf52833 capable of being configured as a serial port?
Sherwood said:Second question are all gpio pins of the nrf52833 capable of being configured as a serial port?
Yes.
Sherwood said:Thank you for the quick response. I am quite new to the nordic devices and interfacing them through SPI. Would it be possible for you to walk me through an example detailing the configuration of pins capable of SPI,UART and I2C.
Any example uses the driver API, I suggest you read SPIM driver API documentation when going through the SPI Master Example, as well as read the SPIM — Serial peripheral interface master with EasyDMA chapter of the product specification. Most API calls to the driver will eventually result in a read or write to one of the peripheral's Registers, by reading the specification of the peripheral you can understand what any driver function does by looking at what values is written to what register.
You can at any point in time in a debug session halt the CPU and read the values of the SPIM register to see whether it is configured correctly or not, by comparing it to the Registers description.
For instance, the PSEL.SCK, PSEL.MOSI, and PSEL.MISO register controls the pin selections.
In the SPIM Driver example where in the code are the mosi,miso,sck pins assigned to their respective gpio ports? They are defined as NRFX_SPIM_PIN_NOT_USED, but where are they assigned to the physical pins
In examples/peripheral/spi/main.c line 84.