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

How to enable P0.09 and P0.10 as GPIO pins on the nRF52 instead of NFC pins?

Hi,

I'm using nrf52 custom board designed for our project,For this we have P0.09 and P0.10 as rx and tx used for uart, when i configured this two pins as rx and tx it is not showing any data on the uart.I have read the datasheet and i have seen this link devzone.nordicsemi.com/.../
but i'm not able to resolve the problem ,please help me ASAP.

Regards,

Prudhvi.

Parents
  • Hi Eliot, I just wanna know whether you fix this problem or not. I encounter the same issue. P0.09 is used as UART RX pin. It always reports "APP_UART_COMMUNICATION_ERROR" after initialization. CONFIG_NFCT_PINS_AS_GPIOS CFLAG is defined. I checked the NRF_UICR->NFCPINS register, it is 0xFFFFFFFE.

  • (Your post should have been a comment, not an answer, btw). Yes, I got it working. Confirm you're using CFLAGS += -DCONFIG_NFCT_PINS_AS_GPIOS in the Makefile, not just a #define CONFIG_NFCT_PINS_AS_GPIOS (1) in the code. If you can, get the UART working on some other pins first to validate your code, then move it onto these pins. Or run the UART example app, but with the pins changed and the CFLAG added. Or find the point where CONFIG_NFCT_PINS_AS_GPIOS is used in the SDK and put in an #error Foo to confirm the preprocessor is including that code.

Reply
  • (Your post should have been a comment, not an answer, btw). Yes, I got it working. Confirm you're using CFLAGS += -DCONFIG_NFCT_PINS_AS_GPIOS in the Makefile, not just a #define CONFIG_NFCT_PINS_AS_GPIOS (1) in the code. If you can, get the UART working on some other pins first to validate your code, then move it onto these pins. Or run the UART example app, but with the pins changed and the CFLAG added. Or find the point where CONFIG_NFCT_PINS_AS_GPIOS is used in the SDK and put in an #error Foo to confirm the preprocessor is including that code.

Children
Related