I want to set the GPIO of NRF52840 to the high resistance state. How do I set the GPIO of NRF52840 to the high resistance state, please help me,thanks!
I want to set the GPIO of NRF52840 to the high resistance state. How do I set the GPIO of NRF52840 to the high resistance state, please help me,thanks!
You're right. I'm using a UART peripheral, In fact, the 52840 on the circuit board is connected to a Bluetooth module through a serial port. For faster debugging of the Bluetooth module, the serial port terminal is used to directly communicate with the Bluetooth module. Therefore, I want to set the serial port of 52840 to a high resistance state, that is also high Z. This is what I set up in the program,
But it didn't seem to work, how do I set it?
Still not sure what SDK you are using, but I will assume it is the nRF5 SDK until you say otherwise.
If you initialized the UART using APP_UART_FIFO_INIT() or app_uart_init(), try to uninit the UART first using app_uart_close().
If you used another way to initialize the UART, then see if the file that implemented the init function has an equivalent uninit function.
As you can see in app_uart_close() -> nrfx_uarte_uninit(), it will first disable the uart, and then set the pins to the default state:
I am not sure how the UART drivers would behave if you try to take it's gpios while it is active.
Best regards,
Edvin
Still not sure what SDK you are using, but I will assume it is the nRF5 SDK until you say otherwise.
If you initialized the UART using APP_UART_FIFO_INIT() or app_uart_init(), try to uninit the UART first using app_uart_close().
If you used another way to initialize the UART, then see if the file that implemented the init function has an equivalent uninit function.
As you can see in app_uart_close() -> nrfx_uarte_uninit(), it will first disable the uart, and then set the pins to the default state:
I am not sure how the UART drivers would behave if you try to take it's gpios while it is active.
Best regards,
Edvin