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

problem with macro

the following type of macro defining causing error , what should i do? plz help.

#define LCD_DATA P2

error: 'LCD_DATA': undefined identifier

Parents
  • Well, where do you have your #define?

    And have you spelled your #define correctly?

    Because the error message indicates that the preprocessor have not seen and replaced LCD_DATA - but the preprocessor will not generate an error for any unknown symbols. The compiler will, if LCD_DATA is still visible after the preprocessing step.

    So show us real code that gives the error.

Reply
  • Well, where do you have your #define?

    And have you spelled your #define correctly?

    Because the error message indicates that the preprocessor have not seen and replaced LCD_DATA - but the preprocessor will not generate an error for any unknown symbols. The compiler will, if LCD_DATA is still visible after the preprocessing step.

    So show us real code that gives the error.

Children
No data