This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

error: #35: "SSP not configured in RTE_Device.h!"

When i try to do my glcd program in keil Mcb 1760with(Nxp LPC1768) MCU, I am Getting the following error --- C:\Keil_v5\ARM\PACK\Keil\LPC1700_DFP\2.1.0\RTE_Driver\SSP_LPC17xx.c(77): error: #35: #error directive: "SSP not configured in RTE_Device.h!" can any one help me to configure ssp in RTE Device .h

Parents
  • i am a beginner in arm ... i found it hard to correct it...i checked in the RTE_Device.h but i think SSP is already configured in it i m including the code part of ssp configuration in RTE_DEvive.h bellow

    /*******************************************************************************************/

    // <e> SSP0 (Synchronous Serial Port 0) [Driver_SPI0]
    // Configuration settings for Driver_SPI0 in component ::Drivers:SPI
    #define RTE_SSP0 0

    // <h> Pin Configuration
    // <o> SSP0_SSEL <0=>Not used <1=>P0_16 <2=>P1_21
    // Slave Select for SSP0
    #define RTE_SSP0_SSEL_PIN_SEL 1
    #if (RTE_SSP0_SSEL_PIN_SEL == 0)
    #define RTE_SSP0_SSEL_PIN_EN 0
    #elif (RTE_SSP0_SSEL_PIN_SEL == 1) #define RTE_SSP0_SSEL_PORT 0 #define RTE_SSP0_SSEL_BIT 16 #define RTE_SSP0_SSEL_FUNC 2
    #elif (RTE_SSP0_SSEL_PIN_SEL == 1) #define RTE_SSP0_SSEL_PORT 1 #define RTE_SSP0_SSEL_BIT 21 #define RTE_SSP0_SSEL_FUNC 3
    #else #error "Invalid SSP0 SSP0_SSEL Pin Configuration!"
    #endif
    #ifndef RTE_SSP0_SSEL_PIN_EN
    #define RTE_SSP0_SSEL_PIN_EN 1
    #endif

    // <o> SSP0_SCK <0=>P0_15 <1=>P1_20
    // Serial clock for SSP0
    #define RTE_SSP0_SCK_PIN_SEL 0
    #if (RTE_SSP0_SCK_PIN_SEL == 0) #define RTE_SSP0_SCK_PORT 0 #define RTE_SSP0_SCK_BIT 15 #define RTE_SSP0_SCK_FUNC 2
    #elif (RTE_SSP0_SCK_PIN_SEL == 1) #define RTE_SSP0_SCK_PORT 1 #define RTE_SSP0_SCK_BIT 20 #define RTE_SSP0_SCK_FUNC 3
    #else #error "Invalid SSP0 SSP0_SCK Pin Configuration!"
    #endif

    // <o> SSP0_MISO <0=>P0_17 <1=>P1_23
    // Master In Slave Out for SSP0
    #define RTE_SSP0_MISO_PIN_SEL 0
    #if (RTE_SSP0_MISO_PIN_SEL == 0) #define RTE_SSP0_MISO_PORT 0 #define RTE_SSP0_MISO_BIT 17 #define RTE_SSP0_MISO_FUNC 2
    #elif (RTE_SSP0_MISO_PIN_SEL == 1) #define RTE_SSP0_MISO_PORT 1 #define RTE_SSP0_MISO_BIT 23 #define RTE_SSP0_MISO_FUNC 3
    #else #error "Invalid SSP0 SSP0_MISO Pin Configuration!"
    #endif

    // <o> SSP0_MOSI <0=>P0_18 <1=>P1_24
    // Master Out Slave In for SSP0
    #define RTE_SSP0_MOSI_PIN_SEL 0
    #if (RTE_SSP0_MOSI_PIN_SEL == 0) #define RTE_SSP0_MOSI_PORT 0 #define RTE_SSP0_MOSI_BIT 18 #define RTE_SSP0_MOSI_FUNC 2
    #elif (RTE_SSP0_MOSI_PIN_SEL == 1) #define RTE_SSP0_MOSI_PORT 1 #define RTE_SSP0_MOSI_BIT 24 #define RTE_SSP0_MOSI_FUNC 3
    #else #error "Invalid SSP0 SSP0_MOSI Pin Configuration!"
    #endif

    // </h>
    // <h> DMA
    // <e> Tx
    // <o1> Channel <0=>0 <1=>1 <2=>2 <3=>3 <4=>4 <5=>5 <6=>6 <7=>7
    // </e>
    #define RTE_SSP0_DMA_TX_EN 0
    #define RTE_SSP0_DMA_TX_CH 0
    // <e> Rx
    // <o1> Channel <0=>0 <1=>1 <2=>2 <3=>3 <4=>4 <5=>5 <6=>6 <7=>7
    // </e>
    #define RTE_SSP0_DMA_RX_EN 0
    #define RTE_SSP0_DMA_RX_CH 1
    // </h> DMA
    // </e>

    // <e> SSP1 (Synchronous Serial Port 1) [Driver_SPI1]
    // Configuration settings for Driver_SPI1 in component ::Drivers:SPI
    #define RTE_SSP1 0

    // <h> Pin Configuration
    // <o> SSP1_SSEL <0=>Not used <1=>P0_6
    // Slave Select for SSP1
    #define RTE_SSP1_SSEL_PIN_SEL 1
    #if (RTE_SSP1_SSEL_PIN_SEL == 0) #define RTE_SSP1_SSEL_PIN_EN 0
    #elif (RTE_SSP1_SSEL_PIN_SEL == 1) #define RTE_SSP1_SSEL_PORT 0 #define RTE_SSP1_SSEL_BIT 6 #define RTE_SSP1_SSEL_FUNC 2
    #else #error "Invalid SSP1 SSP1_SSEL Pin Configuration!"
    #endif
    #ifndef RTE_SSP1_SSEL_PIN_EN
    #define RTE_SSP1_SSEL_PIN_EN 1
    #endif

    // <o> SSP1_SCK <0=>P0_7 <1=>P1_31
    // Serial clock for SSP1
    #define RTE_SSP1_SCK_PIN_SEL 0
    #if (RTE_SSP1_SCK_PIN_SEL == 0) #define RTE_SSP1_SCK_PORT 0 #define RTE_SSP1_SCK_BIT 7 #define RTE_SSP1_SCK_FUNC 2
    #elif (RTE_SSP1_SCK_PIN_SEL == 1) #define RTE_SSP1_SCK_PORT 1 #define RTE_SSP1_SCK_BIT 31 #define RTE_SSP1_SCK_FUNC 2
    #else #error "Invalid SSP1 SSP1_SCK Pin Configuration!"
    #endif

    // <o> SSP1_MISO <0=>P0_8
    // Master In Slave Out for SSP1
    #define RTE_SSP1_MISO_PIN_SEL 0
    #if (RTE_SSP1_MISO_PIN_SEL == 0) #define RTE_SSP1_MISO_PORT 0 #define RTE_SSP1_MISO_BIT 8 #define RTE_SSP1_MISO_FUNC 2
    #else #error "Invalid SSP1 SSP1_MISO Pin Configuration!"
    #endif

    // <o> SSP1_MOSI <0=>P0_9 <1=>P1_24
    // Master Out Slave In for SSP0
    #define RTE_SSP1_MOSI_PIN_SEL 0
    #if (RTE_SSP1_MOSI_PIN_SEL == 0) #define RTE_SSP1_MOSI_PORT 0 #define RTE_SSP1_MOSI_BIT 9 #define RTE_SSP1_MOSI_FUNC 2
    #else #error "Invalid SSP1 SSP1_MOSI Pin Configuration!"
    #endif

    // </h>
    // <h> DMA
    // <e> Tx
    // <o1> Channel <0=>0 <1=>1 <2=>2 <3=>3 <4=>4 <5=>5 <6=>6 <7=>7
    // </e>
    #define RTE_SSP1_DMA_TX_EN 0
    #define RTE_SSP1_DMA_TX_CH 2
    // <e> Rx
    // <o1> Channel <0=>0 <1=>1 <2=>2 <3=>3 <4=>4 <5=>5 <6=>6 <7=>7
    // </e>
    #define RTE_SSP1_DMA_RX_EN 0
    #define RTE_SSP1_DMA_RX_CH 3
    // </h> DMA
    // </e>

    /**************************************************************************************/

    i am also including my ssp driver part

    #define ARM_SPI_DRV_VERSION ARM_DRIVER_VERSION_MAJOR_MINOR(2,3) // driver version

    #if ((defined(RTE_Drivers_SPI0) || defined(RTE_Drivers_SPI1) || defined(RTE_Drivers_SPI2)) && (!RTE_SSP0) && (!RTE_SSP1) && (!RTE_SSP2))
    #error "SSP not configured in RTE_Device.h!"
    #endif
    #if ((RTE_SSP0) && \ ((RTE_SSP0_DMA_TX_EN && !RTE_SSP0_DMA_RX_EN) || \ (RTE_SSP0_DMA_RX_EN && !RTE_SSP0_DMA_TX_EN)))
    #error "Both Tx and Rx DMA for SSP0 have to be enabled or disabled in RTE_Device.h!"
    #endif
    #if ((RTE_SSP1) && \ ((RTE_SSP1_DMA_TX_EN && !RTE_SSP1_DMA_RX_EN) || \ (RTE_SSP1_DMA_RX_EN && !RTE_SSP1_DMA_TX_EN)))
    #error "Both Tx and Rx DMA for SSP1 have to be enabled or disabled in RTE_Device.h!"
    #endif
    #if defined (LPC177x_8x)
    #if ((RTE_SSP2) && \ ((RTE_SSP2_DMA_TX_EN && !RTE_SSP2_DMA_RX_EN) || \ (RTE_SSP2_DMA_RX_EN && !RTE_SSP2_DMA_TX_EN)))
    #error "Both Tx and Rx DMA for SSP2 have to be enabled or disabled in RTE_Device.h!"
    #endif
    #endif

    can you help me with it

    i found this difficulty when i was using my gcld to display

Reply
  • i am a beginner in arm ... i found it hard to correct it...i checked in the RTE_Device.h but i think SSP is already configured in it i m including the code part of ssp configuration in RTE_DEvive.h bellow

    /*******************************************************************************************/

    // <e> SSP0 (Synchronous Serial Port 0) [Driver_SPI0]
    // Configuration settings for Driver_SPI0 in component ::Drivers:SPI
    #define RTE_SSP0 0

    // <h> Pin Configuration
    // <o> SSP0_SSEL <0=>Not used <1=>P0_16 <2=>P1_21
    // Slave Select for SSP0
    #define RTE_SSP0_SSEL_PIN_SEL 1
    #if (RTE_SSP0_SSEL_PIN_SEL == 0)
    #define RTE_SSP0_SSEL_PIN_EN 0
    #elif (RTE_SSP0_SSEL_PIN_SEL == 1) #define RTE_SSP0_SSEL_PORT 0 #define RTE_SSP0_SSEL_BIT 16 #define RTE_SSP0_SSEL_FUNC 2
    #elif (RTE_SSP0_SSEL_PIN_SEL == 1) #define RTE_SSP0_SSEL_PORT 1 #define RTE_SSP0_SSEL_BIT 21 #define RTE_SSP0_SSEL_FUNC 3
    #else #error "Invalid SSP0 SSP0_SSEL Pin Configuration!"
    #endif
    #ifndef RTE_SSP0_SSEL_PIN_EN
    #define RTE_SSP0_SSEL_PIN_EN 1
    #endif

    // <o> SSP0_SCK <0=>P0_15 <1=>P1_20
    // Serial clock for SSP0
    #define RTE_SSP0_SCK_PIN_SEL 0
    #if (RTE_SSP0_SCK_PIN_SEL == 0) #define RTE_SSP0_SCK_PORT 0 #define RTE_SSP0_SCK_BIT 15 #define RTE_SSP0_SCK_FUNC 2
    #elif (RTE_SSP0_SCK_PIN_SEL == 1) #define RTE_SSP0_SCK_PORT 1 #define RTE_SSP0_SCK_BIT 20 #define RTE_SSP0_SCK_FUNC 3
    #else #error "Invalid SSP0 SSP0_SCK Pin Configuration!"
    #endif

    // <o> SSP0_MISO <0=>P0_17 <1=>P1_23
    // Master In Slave Out for SSP0
    #define RTE_SSP0_MISO_PIN_SEL 0
    #if (RTE_SSP0_MISO_PIN_SEL == 0) #define RTE_SSP0_MISO_PORT 0 #define RTE_SSP0_MISO_BIT 17 #define RTE_SSP0_MISO_FUNC 2
    #elif (RTE_SSP0_MISO_PIN_SEL == 1) #define RTE_SSP0_MISO_PORT 1 #define RTE_SSP0_MISO_BIT 23 #define RTE_SSP0_MISO_FUNC 3
    #else #error "Invalid SSP0 SSP0_MISO Pin Configuration!"
    #endif

    // <o> SSP0_MOSI <0=>P0_18 <1=>P1_24
    // Master Out Slave In for SSP0
    #define RTE_SSP0_MOSI_PIN_SEL 0
    #if (RTE_SSP0_MOSI_PIN_SEL == 0) #define RTE_SSP0_MOSI_PORT 0 #define RTE_SSP0_MOSI_BIT 18 #define RTE_SSP0_MOSI_FUNC 2
    #elif (RTE_SSP0_MOSI_PIN_SEL == 1) #define RTE_SSP0_MOSI_PORT 1 #define RTE_SSP0_MOSI_BIT 24 #define RTE_SSP0_MOSI_FUNC 3
    #else #error "Invalid SSP0 SSP0_MOSI Pin Configuration!"
    #endif

    // </h>
    // <h> DMA
    // <e> Tx
    // <o1> Channel <0=>0 <1=>1 <2=>2 <3=>3 <4=>4 <5=>5 <6=>6 <7=>7
    // </e>
    #define RTE_SSP0_DMA_TX_EN 0
    #define RTE_SSP0_DMA_TX_CH 0
    // <e> Rx
    // <o1> Channel <0=>0 <1=>1 <2=>2 <3=>3 <4=>4 <5=>5 <6=>6 <7=>7
    // </e>
    #define RTE_SSP0_DMA_RX_EN 0
    #define RTE_SSP0_DMA_RX_CH 1
    // </h> DMA
    // </e>

    // <e> SSP1 (Synchronous Serial Port 1) [Driver_SPI1]
    // Configuration settings for Driver_SPI1 in component ::Drivers:SPI
    #define RTE_SSP1 0

    // <h> Pin Configuration
    // <o> SSP1_SSEL <0=>Not used <1=>P0_6
    // Slave Select for SSP1
    #define RTE_SSP1_SSEL_PIN_SEL 1
    #if (RTE_SSP1_SSEL_PIN_SEL == 0) #define RTE_SSP1_SSEL_PIN_EN 0
    #elif (RTE_SSP1_SSEL_PIN_SEL == 1) #define RTE_SSP1_SSEL_PORT 0 #define RTE_SSP1_SSEL_BIT 6 #define RTE_SSP1_SSEL_FUNC 2
    #else #error "Invalid SSP1 SSP1_SSEL Pin Configuration!"
    #endif
    #ifndef RTE_SSP1_SSEL_PIN_EN
    #define RTE_SSP1_SSEL_PIN_EN 1
    #endif

    // <o> SSP1_SCK <0=>P0_7 <1=>P1_31
    // Serial clock for SSP1
    #define RTE_SSP1_SCK_PIN_SEL 0
    #if (RTE_SSP1_SCK_PIN_SEL == 0) #define RTE_SSP1_SCK_PORT 0 #define RTE_SSP1_SCK_BIT 7 #define RTE_SSP1_SCK_FUNC 2
    #elif (RTE_SSP1_SCK_PIN_SEL == 1) #define RTE_SSP1_SCK_PORT 1 #define RTE_SSP1_SCK_BIT 31 #define RTE_SSP1_SCK_FUNC 2
    #else #error "Invalid SSP1 SSP1_SCK Pin Configuration!"
    #endif

    // <o> SSP1_MISO <0=>P0_8
    // Master In Slave Out for SSP1
    #define RTE_SSP1_MISO_PIN_SEL 0
    #if (RTE_SSP1_MISO_PIN_SEL == 0) #define RTE_SSP1_MISO_PORT 0 #define RTE_SSP1_MISO_BIT 8 #define RTE_SSP1_MISO_FUNC 2
    #else #error "Invalid SSP1 SSP1_MISO Pin Configuration!"
    #endif

    // <o> SSP1_MOSI <0=>P0_9 <1=>P1_24
    // Master Out Slave In for SSP0
    #define RTE_SSP1_MOSI_PIN_SEL 0
    #if (RTE_SSP1_MOSI_PIN_SEL == 0) #define RTE_SSP1_MOSI_PORT 0 #define RTE_SSP1_MOSI_BIT 9 #define RTE_SSP1_MOSI_FUNC 2
    #else #error "Invalid SSP1 SSP1_MOSI Pin Configuration!"
    #endif

    // </h>
    // <h> DMA
    // <e> Tx
    // <o1> Channel <0=>0 <1=>1 <2=>2 <3=>3 <4=>4 <5=>5 <6=>6 <7=>7
    // </e>
    #define RTE_SSP1_DMA_TX_EN 0
    #define RTE_SSP1_DMA_TX_CH 2
    // <e> Rx
    // <o1> Channel <0=>0 <1=>1 <2=>2 <3=>3 <4=>4 <5=>5 <6=>6 <7=>7
    // </e>
    #define RTE_SSP1_DMA_RX_EN 0
    #define RTE_SSP1_DMA_RX_CH 3
    // </h> DMA
    // </e>

    /**************************************************************************************/

    i am also including my ssp driver part

    #define ARM_SPI_DRV_VERSION ARM_DRIVER_VERSION_MAJOR_MINOR(2,3) // driver version

    #if ((defined(RTE_Drivers_SPI0) || defined(RTE_Drivers_SPI1) || defined(RTE_Drivers_SPI2)) && (!RTE_SSP0) && (!RTE_SSP1) && (!RTE_SSP2))
    #error "SSP not configured in RTE_Device.h!"
    #endif
    #if ((RTE_SSP0) && \ ((RTE_SSP0_DMA_TX_EN && !RTE_SSP0_DMA_RX_EN) || \ (RTE_SSP0_DMA_RX_EN && !RTE_SSP0_DMA_TX_EN)))
    #error "Both Tx and Rx DMA for SSP0 have to be enabled or disabled in RTE_Device.h!"
    #endif
    #if ((RTE_SSP1) && \ ((RTE_SSP1_DMA_TX_EN && !RTE_SSP1_DMA_RX_EN) || \ (RTE_SSP1_DMA_RX_EN && !RTE_SSP1_DMA_TX_EN)))
    #error "Both Tx and Rx DMA for SSP1 have to be enabled or disabled in RTE_Device.h!"
    #endif
    #if defined (LPC177x_8x)
    #if ((RTE_SSP2) && \ ((RTE_SSP2_DMA_TX_EN && !RTE_SSP2_DMA_RX_EN) || \ (RTE_SSP2_DMA_RX_EN && !RTE_SSP2_DMA_TX_EN)))
    #error "Both Tx and Rx DMA for SSP2 have to be enabled or disabled in RTE_Device.h!"
    #endif
    #endif

    can you help me with it

    i found this difficulty when i was using my gcld to display

Children