You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
On the nRF52840 there are two UARTEs but the nrf52840_peripherals.h file says there are two UARTEs and a single UART. This isn't entirely correct -- the UART is at address 0x40002000, and UARTE0 is at the same address (UARTE1 is at 0x40028000).
Anyway -- since nrf52840_peripherals.h says there is a UART and two UARTEs, the macros at the top of nrf_drv_uart.h will define both NRF_DRV_UART_WITH_UARTE and NRF_DRV_UART_WITH_UART, which causes the build to fail because there's no way to say "two UARTEs and one UART" so it tries to instantiate two UARTs.
How to recreate:
Set up a project where you want to use two UARTEs. I believe the correct app_config.h stanzas are as follows:
In the SDK, apply_old_config.h will take these defines and define NRFX_UARTE_ENABLED, NRFX_UARTE0_ENABLED and NRFX_UARTE1_ENABLED. nrf_drv_uart.h will set up for two UARTEs since UARTE_PRESENT is defined in nrf52840_peripherals.hand also becauseapply_old_config.hcreatedNRFX_UARTE_ENABLED`
This is all perfect until you realize that nrf_drv_uart.h also defines NRF_DRV_UART_WITH_UART since the peripherals.h file says there is a UART as well as two UARTEs.
I believe this is an error, as the nRF52840 has a total of two UART devices with DMA, not three (two with DMA and one without). I think the correct fix is to modify nrf52840_peripherals.h but before I create a PR I wanted to run this by you.
The text was updated successfully, but these errors were encountered:
Wow, that sounds like a big pain to think about. Good job debugging that. I agree that there are two UART/UARTE peripherals (not three). However, this bug is in the Nordic SDKs, not in any of our files. As a rule we try not to make any edits directly to the Nordic SDK files.
You should try reporting this problem to Nordic devzone and see what Nordic has to say about it. (If you do so, post a link here too)
On the nRF52840 there are two UARTEs but the
nrf52840_peripherals.h
file says there are two UARTEs and a single UART. This isn't entirely correct -- the UART is at address 0x40002000, and UARTE0 is at the same address (UARTE1 is at 0x40028000).Anyway -- since
nrf52840_peripherals.h
says there is a UART and two UARTEs, the macros at the top ofnrf_drv_uart.h
will define bothNRF_DRV_UART_WITH_UARTE
andNRF_DRV_UART_WITH_UART
, which causes the build to fail because there's no way to say "two UARTEs and one UART" so it tries to instantiate two UARTs.How to recreate:
Set up a project where you want to use two UARTEs. I believe the correct
app_config.h
stanzas are as follows:In the SDK,
apply_old_config.h
will take these defines and defineNRFX_UARTE_ENABLED
,NRFX_UARTE0_ENABLED
andNRFX_UARTE1_ENABLED
.nrf_drv_uart.h
will set up for two UARTEs sinceUARTE_PRESENT
is defined in nrf52840_peripherals.hand also because
apply_old_config.hcreated
NRFX_UARTE_ENABLED`This is all perfect until you realize that
nrf_drv_uart.h
also definesNRF_DRV_UART_WITH_UART
since the peripherals.h file says there is a UART as well as two UARTEs.I believe this is an error, as the nRF52840 has a total of two UART devices with DMA, not three (two with DMA and one without). I think the correct fix is to modify
nrf52840_peripherals.h
but before I create a PR I wanted to run this by you.The text was updated successfully, but these errors were encountered: