Hello,
SDK17.2, keil5,nRF21540-DK
my project use i2c and spi, but got error:
Error: L6200E: Symbol SPIM0_SPIS0_TWIM0_TWIS0_SPI0_TWI0_IRQHandler multiply defined (by nrfx_twim.o and nrfx_spim.o).

Best regards
Hello,
SDK17.2, keil5,nRF21540-DK
my project use i2c and spi, but got error:
Error: L6200E: Symbol SPIM0_SPIS0_TWIM0_TWIS0_SPI0_TWI0_IRQHandler multiply defined (by nrfx_twim.o and nrfx_spim.o).

Best regards
Hi,
The serial instances in nRF52840 can only be used for one protocol at a time, either SPI or TWI, as they share the same base address (see Instantiation).
If you want to use TWI and SPI at the same time, you need to use one instance for SPI (e.g. SPI0) and another instance for TWI (e.g. TWI1). If you do not need to have SPI and TWI enabled at the same time, it is also possible to share one instance through the Peripheral Resource Sharing (PRS) module. You then need to enable the corresponding PRS box for the instance (e.g. set NRFX_PRS_ENABLED and NRFX_PRS_BOX_0_ENABLED to 1 in your sdk_config.h file).
Best regards,
Jørgen
Hi,
The serial instances in nRF52840 can only be used for one protocol at a time, either SPI or TWI, as they share the same base address (see Instantiation).
If you want to use TWI and SPI at the same time, you need to use one instance for SPI (e.g. SPI0) and another instance for TWI (e.g. TWI1). If you do not need to have SPI and TWI enabled at the same time, it is also possible to share one instance through the Peripheral Resource Sharing (PRS) module. You then need to enable the corresponding PRS box for the instance (e.g. set NRFX_PRS_ENABLED and NRFX_PRS_BOX_0_ENABLED to 1 in your sdk_config.h file).
Best regards,
Jørgen
Hi,
thanks, it work well,

but every time download app hex it not work (no log output) even reset button,
it must download s140_nrf52_7.2.0_softdevice.hex once again,
why?


Best regards
As long as you do not perform a full chip erase during programming, or your application erasing part of the softdevice flash area, it should not be necessary to program the softdevice each time you program the application. Can you read out the flash from the chip after programming the application (without reprogramming softdevice), to see if there are any modifications to the softdevice area?
You can use nrfjprog from this task (flash code will be stored in flash.hex):
nrfjprog --readcode flash.hex
Hi,
thanks for reply,
step 1: erase all --> download softdev --> download app , UART no log output even reset button.
step 2 base step 1: --> download softdev , UART get log output.


nrfjprog --readcode flash.hex, two file as follow:

Best regards
If one of the readouts is from after step 1, it does not look like the softdevice have been programmed. In the second readout, the softdevice is present. Could you do the readout after programming softdevice in step 1, and describe how you program the softdevice?
Hi,
thanks for reply,
Could you do the readout after programming softdevice in step 1,
it's can't readout when no app in mcu.
and describe how you program the softdevice?

I feel programming app destroys softdevice.


Best regards