Skip to main content
Visitor II
August 25, 2020
Solved

error in Library Header File

  • August 25, 2020
  • 2 replies
  • 919 views

Hi,

I created a new project using ready HAL Libraries on STM32F3, I get an weird error (expected an identifier) on the following line in the file (stm32f303xc.h):

  __IO uint32_t TR;     /*!< RTC time register,                    Address offset: 0x00 */

Can anyone help?

    This topic has been closed for replies.
    Best answer by KnarfB

    As .h files are never compiled on their own, you should check the .c file including it and other include files too. Possibly TR is defined somwhere else as a constant or so.

    2 replies

    KnarfBAnswer
    Super User
    August 25, 2020

    As .h files are never compiled on their own, you should check the .c file including it and other include files too. Possibly TR is defined somwhere else as a constant or so.

    Ala1980Author
    Visitor II
    August 25, 2020

    Yes, you have right, RT was defined in other place too.

    Thank you, solved