Hekateros/fw/Encoder/Encoder.c
void dbMarkValid(void)
{
  uint16_t  crc;

  // add crc to db
  crc = dbCalcCRC();
  if( eepromRead16(EEPROM_ADDR_CRC) != crc )
  {
    eepromWrite16(EEPROM_ADDR_CRC, crc);
  }

  // lay some magic
  if( eepromRead16(EEPROM_ADDR_MAGIC) != EEPROM_VAL_MAGIC )
  {
    eepromWrite16(EEPROM_ADDR_MAGIC, EEPROM_VAL_MAGIC);
  }
}
/*!
 * \brief Mark database as valid.
 */
\brief Mark database as valid.
\ brief Mark database as valid .
void dbMarkValid(void)
{
  uint16_t  crc;
  crc = dbCalcCRC();
  if( eepromRead16(EEPROM_ADDR_CRC) != crc )
  {
    eepromWrite16(EEPROM_ADDR_CRC, crc);
  }
  if( eepromRead16(EEPROM_ADDR_MAGIC) != EEPROM_VAL_MAGIC )
  {
    eepromWrite16(EEPROM_ADDR_MAGIC, EEPROM_VAL_MAGIC);
  }
}
void dbMarkValid ( void ) { uint16_t crc ; crc = dbCalcCRC ( ) ; if ( eepromRead16 ( EEPROM_ADDR_CRC ) != crc ) { eepromWrite16 ( EEPROM_ADDR_CRC , crc ) ; } if ( eepromRead16 ( EEPROM_ADDR_MAGIC ) != EEPROM_VAL_MAGIC ) { eepromWrite16 ( EEPROM_ADDR_MAGIC , EEPROM_VAL_MAGIC ) ; } }
\brief Mark database as valid.
\ brief Mark database as valid .
// add crc to db // lay some magic