[Horus] Compilation fix

This commit is contained in:
Bertrand Songis
2016-01-15 12:42:37 +01:00
parent 1771a47637
commit b6759d5434
2 changed files with 12 additions and 10 deletions
+1 -1
View File
@@ -774,7 +774,7 @@ void checkSwitches()
#if defined(COLORLCD) #if defined(COLORLCD)
for (int i=0; i<NUM_SWITCHES; i++) { for (int i=0; i<NUM_SWITCHES; i++) {
if (SWITCH_WARNING_ALLOWED(i)) { if (SWITCH_WARNING_ALLOWED(i)) {
unsigned int state = ((g_model.switchWarningState >> (3*i)) & 0x07); unsigned int state = ((states >> (3*i)) & 0x07);
if (state && state-1 != ((switches_states >> (i*2)) & 0x03)) { if (state && state-1 != ((switches_states >> (i*2)) & 0x03)) {
warn = true; warn = true;
} }
+11 -9
View File
@@ -444,7 +444,6 @@ void StopMainThread()
} }
#if defined(CPUARM) #if defined(CPUARM)
struct SimulatorAudio { struct SimulatorAudio {
int volumeGain; int volumeGain;
int currentVolume; int currentVolume;
@@ -454,19 +453,26 @@ struct SimulatorAudio {
pthread_t threadPid; pthread_t threadPid;
} simuAudio; } simuAudio;
bool dacQueue(AudioBuffer *buffer) bool dacQueue(AudioBuffer * buffer)
{ {
return false; return false;
} }
#endif
#if defined(VOLUME_CHIP)
void setScaledVolume(uint8_t volume)
{
simuAudio.currentVolume = min<int>((volumeScale[min<uint8_t>(volume, VOLUME_LEVEL_MAX)] * simuAudio.volumeGain) / 10, 127);
// TRACE("setVolume(): in: %u, out: %u", volume, simuAudio.currentVolume);
}
void setVolume(uint8_t volume) void setVolume(uint8_t volume)
{ {
} }
void setScaledVolume(uint8_t volume) int32_t getVolume()
{ {
simuAudio.currentVolume = min<int>((volumeScale[min<uint8_t>(volume, VOLUME_LEVEL_MAX)] * simuAudio.volumeGain) / 10, 127); return 0;
// TRACE("setVolume(): in: %u, out: %u", volume, simuAudio.currentVolume);
} }
#endif #endif
@@ -1344,7 +1350,3 @@ void serialPrintf(const char * format, ...) { }
void serialCrlf() { } void serialCrlf() { }
void serialPutc(char c) { } void serialPutc(char c) { }
uint16_t stackSize() { return 0; } uint16_t stackSize() { return 0; }
#if defined(VOLUME_CHIP)
int32_t getVolume() { return 0; }
#endif