1
0
mirror of https://github.com/DCC-EX/CommandStation-EX.git synced 2025-07-28 09:53:45 +02:00

make it possible to disable EEPROM code to save flash space

This commit is contained in:
Harald Barth
2021-11-08 02:07:21 +01:00
parent 6c75563779
commit 1807189183
11 changed files with 67 additions and 13 deletions

View File

@@ -20,7 +20,9 @@
#include "DIAG.h"
#include "DCC.h"
#include "DCCWaveform.h"
#ifndef DISABLE_EEPROM
#include "EEStore.h"
#endif
#include "GITHUB_SHA.h"
#include "version.h"
#include "FSH.h"
@@ -56,9 +58,11 @@ void DCC::begin(const FSH * motorShieldName, MotorDriver * mainDriver, MotorDriv
// Initialise HAL layer before reading EEprom.
IODevice::begin();
#ifndef DISABLE_EEPROM
// Load stuff from EEprom
(void)EEPROM; // tell compiler not to warn this is unused
EEStore::init();
#endif
DCCWaveform::begin(mainDriver,progDriver);
}