[ARM] Support of s16le wav files

[ACT] New GVARS menu started
[X9D] Volume control added
This commit is contained in:
bsongis
2013-01-17 19:02:15 +00:00
parent 0287369be2
commit 5a11cf03cb
18 changed files with 244 additions and 142 deletions
+11 -9
View File
@@ -1434,12 +1434,12 @@ void checkTrims()
{
uint8_t event = getEvent(true);
if (event && !IS_KEY_BREAK(event)) {
int8_t k = (event & EVT_KEY_MASK) - TRM_BASE;
int8_t k = EVT_KEY_MASK(event) - TRM_BASE;
int8_t s = g_model.trimInc;
#else
uint8_t checkTrim(uint8_t event)
{
int8_t k = (event & EVT_KEY_MASK) - TRM_BASE;
int8_t k = EVT_KEY_MASK(event) - TRM_BASE;
int8_t s = g_model.trimInc;
if (k>=0 && k<8 && !IS_KEY_BREAK(event)) {
#endif
@@ -1992,7 +1992,7 @@ PLAY_FUNCTION(playValue, uint8_t idx)
#endif
#if defined(CPUARM)
static uint8_t currentSpeakerVolume = 255;
uint8_t currentSpeakerVolume = 255;
uint8_t requiredSpeakerVolume;
uint8_t fnSwitchDuration[NUM_FSW] = { 0 };
#define FSW_PRESSLONG_DURATION 100
@@ -2873,13 +2873,8 @@ void doMixerCalculations()
#if defined(DSM2)
if (s_rangecheck_mode) AUDIO_PLAY(AU_FRSKY_CHEEP);
#endif
#if defined(CPUARM)
if (currentSpeakerVolume != requiredSpeakerVolume) {
setVolume(requiredSpeakerVolume);
currentSpeakerVolume = requiredSpeakerVolume;
}
#if defined(CPUARM)
return true;
#endif
}
@@ -2919,6 +2914,13 @@ void perMain()
}
#endif
#if defined(CPUARM)
if (currentSpeakerVolume != requiredSpeakerVolume) {
currentSpeakerVolume = requiredSpeakerVolume;
setVolume(currentSpeakerVolume);
}
#endif
// TODO merge these 2 branches
#if defined(PCBSKY9X)
if (Eeprom32_process_state != E32_IDLE)