4 Replies Latest reply on Apr 10, 2018 1:01 PM by nikic_3249331

    Em_EEPROM_config is a const and causing warnings in PSoC Creator 4.2

      I'm trying to incorporate the example from the eeprom example:

      CE195313 PSoC Emulated EEPROM

      into my project.


      However when I compile the code, it generates Em_EEPROM_config as a const, and therefore causes warnings when I compile with the following line:


      eepromReturnValue = Cy_Em_EEPROM_Init(&Em_EEPROM_config, &Em_EEPROM_context);




      The warning is:

      prj.M0121: passing argument 1 of 'Cy_Em_EEPROM_Init' discards 'const' qualifier from pointer target type [-Wdiscarded-qualifiers]


      The example project does not generate this as a const, but mine does in PSoC Creator 4.2.


      Any help would be much appreciated.