SPI for waveshare display module alongside uart peripheral

I am trying to connect waveshare e-paper 4.2" display to my nrf54L15, I am currently running a peripheral uart sample code on the board and my plan is to build the project above this and connect the display via SPI ports. 

I see peripheral uart sample uses UART20 which looks like putting me into trouble I tried using SPIS00 using dedicated pins on P2  as follows

#define MOSI_PIN_SLAVE NRF_GPIO_PIN_MAP (2, 4)
#define MISO_PIN_SLAVE NRF_GPIO_PIN_MAP (2, 2)
#define SCK_PIN_SLAVE NRF_GPIO_PIN_MAP (2, 1)
#define CSN_PIN_SLAVE NRF_GPIO_PIN_MAP (2, 5)


But I am running into the problem

zephyr_pre0.elf --intlist-section .intList --intlist-section intList --sw-isr-table --vector-table
gen_isr_tables.py: error: multiple registrations at table_index 74 for irq 74 (0x4a)
Existing handler 0x21839, new handler 0x2d94f
Has IRQ_CONNECT or IRQ_DIRECT_CONNECT accidentally been invoked on the same irq multiple times?


Any suggestion on which will be the right spi and pins I should be using along side the working peripheral uart functionality
Parents
  • Hi Susheel

    Thanks for looking into this, I do not see the conflict after disabling UART, But I want to keep the uart functionality and add the display interface along with the existing code. 

    Do you know how can I make this possible 

    Thanks again
    Jasan Singh

  • Jason,

    When you have a peripheral that shares the same ID, like UART00 and SPIS00, then they cannot be used at the same time as they share the resources on the chip. This is documented here.

    If you want to use UART and SPI together make sure you use UARTXX and SPISYY and XX≠YY then you can use both at the same time.

    Since you want to use logs that use UART00, then make sure not to use any other serial instance like TWIM00, TWIS00, SPIS00 and SPIM00. Use any other available instance of the peripheral.

Reply
  • Jason,

    When you have a peripheral that shares the same ID, like UART00 and SPIS00, then they cannot be used at the same time as they share the resources on the chip. This is documented here.

    If you want to use UART and SPI together make sure you use UARTXX and SPISYY and XX≠YY then you can use both at the same time.

    Since you want to use logs that use UART00, then make sure not to use any other serial instance like TWIM00, TWIS00, SPIS00 and SPIM00. Use any other available instance of the peripheral.

Children
  • I am using the uart straight out of peripheral uart sample, which is uaing uart20 and the spi block I using is spi00 


    / {
    chosen {
    nordic,nus-uart = &uart20;
    };
    };

    #include "../common/common-pinctrl.dtsi"

    &spi00 {
    status = "okay";
    compatible = "nordic,nrf-spis";
    pinctrl-0 = <&spi_slave_dummy>;
    pinctrl-names = "default";
    def-char = <0x44>;
    /delete-property/ pinctrl-1;
    /delete-property/ rx-delay-supported;
    /delete-property/ rx-delay;
    };

    &spi30 {
    status = "okay";
    compatible = "nordic,nrf-spis";
    pinctrl-0 = <&spi_slave_dummy>;
    pinctrl-names = "default";
    def-char = <0x33>;
    /delete-property/ rx-delay-supported;
    /delete-property/ rx-delay;
    };



Related