1
0
Fork 0
mirror of https://github.com/opentx/opentx.git synced 2025-07-15 12:25:12 +03:00

Change audio generation files accordingly (#3717)

* Change audio generation files accordingly
New way of working :

units files are ALWAYS named in english based on the names in audio_arm.cpp names.
multiple form (singular, plural(s) are ammended with 0 to 4 suffix, according to languages rules. example : meter1.wav for first form of plural of meter unit,. This filename needs to be the same for all languages (in their respective directories of course)

* Care for gruin9x

* Better form

* Other languages

* Cosmetics
This commit is contained in:
3djc 2016-08-24 23:43:56 +02:00 committed by Bertrand Songis
parent b69c2aa41c
commit 9d9fdf81b4
21 changed files with 699 additions and 414 deletions

View file

@ -135,6 +135,37 @@ const int16_t sineValues[] =
}; };
#if defined(SDCARD) #if defined(SDCARD)
const char * const unitsFilenames[] = {
"",
"volt",
"amp",
"mamp",
"knot",
"mps",
"fps",
"kph",
"mph",
"meter",
"foot",
"celsius",
"fahr",
"percent",
"mamph",
"watt",
"mwatt",
"db",
"rpm",
"g",
"degree",
"radian",
"ml",
"founce",
"hour",
"minute",
"second",
};
const char * const audioFilenames[] = { const char * const audioFilenames[] = {
"hello", "hello",
"bye", "bye",
@ -1235,6 +1266,22 @@ void audioEvent(unsigned int index)
} }
} }
#if defined(SDCARD)
void pushUnit(uint8_t unit, uint8_t idx, uint8_t id)
{
if (unit < DIM(unitsFilenames)) {
char path[AUDIO_FILENAME_MAXLEN+1];
char *tmp = strAppendSystemAudioPath(path);
tmp = strAppendStringWithIndex(tmp, unitsFilenames[unit], idx);
strcpy(tmp, SOUNDS_EXT);
audioQueue.playFile(path, 0, id);
}
else {
TRACE("pushUnit: out of bounds unit : %d", unit); // We should never get here, but given the nature of TTS files, this prevent segfault in case of bug there.
}
}
#endif
void pushPrompt(uint16_t prompt, uint8_t id) void pushPrompt(uint16_t prompt, uint8_t id)
{ {
#if defined(SDCARD) #if defined(SDCARD)

View file

@ -359,11 +359,13 @@ enum AutomaticPromptsEvents {
}; };
void pushPrompt(uint16_t prompt, uint8_t id=0); void pushPrompt(uint16_t prompt, uint8_t id=0);
void pushUnit(uint8_t unit, uint8_t idx, uint8_t id);
void playModelName(); void playModelName();
#define I18N_PLAY_FUNCTION(lng, x, ...) void lng ## _ ## x(__VA_ARGS__, uint8_t id) #define I18N_PLAY_FUNCTION(lng, x, ...) void lng ## _ ## x(__VA_ARGS__, uint8_t id)
#define PLAY_FUNCTION(x, ...) void x(__VA_ARGS__, uint8_t id) #define PLAY_FUNCTION(x, ...) void x(__VA_ARGS__, uint8_t id)
#define PUSH_NUMBER_PROMPT(p) pushPrompt((p), id) #define PUSH_NUMBER_PROMPT(p) pushPrompt((p), id)
#define PUSH_UNIT_PROMPT(p, i) pushUnit((p), (i), id)
#define PLAY_NUMBER(n, u, a) playNumber((n), (u), (a), id) #define PLAY_NUMBER(n, u, a) playNumber((n), (u), (a), id)
#define PLAY_DURATION(d, att) playDuration((d), (att), id) #define PLAY_DURATION(d, att) playDuration((d), (att), id)
#define PLAY_DURATION_ATT , uint8_t flags #define PLAY_DURATION_ATT , uint8_t flags

View file

@ -54,12 +54,22 @@ enum CzechPrompts {
I18N_PLAY_FUNCTION(cz, pushUnitPrompt, int16_t number, uint8_t unitprompt) I18N_PLAY_FUNCTION(cz, pushUnitPrompt, int16_t number, uint8_t unitprompt)
{ {
#if defined(CPUARM)
if (number == 1)
PUSH_UNIT_PROMPT(unitprompt, 0);
else if (number > 1 && number < 5)
PUSH_UNIT_PROMPT(unitprompt, 1);
else
PUSH_UNIT_PROMPT(unitprompt, 2);
#else
unitprompt = CZ_PROMPT_UNITS_BASE+((unitprompt-1)*4);
if (number == 1) if (number == 1)
PUSH_NUMBER_PROMPT(unitprompt); PUSH_NUMBER_PROMPT(unitprompt);
else if (number > 1 && number < 5) else if (number > 1 && number < 5)
PUSH_NUMBER_PROMPT(unitprompt+1); PUSH_NUMBER_PROMPT(unitprompt+1);
else else
PUSH_NUMBER_PROMPT(unitprompt+2); PUSH_NUMBER_PROMPT(unitprompt+2);
#endif
} }
I18N_PLAY_FUNCTION(cz, playNumber, getvalue_t number, uint8_t unit, uint8_t att) I18N_PLAY_FUNCTION(cz, playNumber, getvalue_t number, uint8_t unit, uint8_t att)
@ -196,7 +206,7 @@ I18N_PLAY_FUNCTION(cz, playNumber, getvalue_t number, uint8_t unit, uint8_t att)
} }
if (unit) { if (unit) {
CZ_PUSH_UNIT_PROMPT(tmp, (CZ_PROMPT_UNITS_BASE+((unit-1)*4))); CZ_PUSH_UNIT_PROMPT(tmp, unit);
} }
} }
@ -210,17 +220,17 @@ I18N_PLAY_FUNCTION(cz, playDuration, int seconds PLAY_DURATION_ATT)
uint8_t tmp = seconds / 3600; uint8_t tmp = seconds / 3600;
seconds %= 3600; seconds %= 3600;
if (tmp > 0 || IS_PLAY_TIME()) { if (tmp > 0 || IS_PLAY_TIME()) {
PLAY_NUMBER(tmp, UNIT_HOURS+1, ZENSKY); PLAY_NUMBER(tmp, UNIT_HOURS, ZENSKY);
} }
tmp = seconds / 60; tmp = seconds / 60;
seconds %= 60; seconds %= 60;
if (tmp > 0) { if (tmp > 0) {
PLAY_NUMBER(tmp, UNIT_MINUTES+1, ZENSKY); PLAY_NUMBER(tmp, UNIT_MINUTES, ZENSKY);
} }
if (seconds > 0) { if (seconds > 0) {
PLAY_NUMBER(seconds, UNIT_SECONDS+1, ZENSKY); PLAY_NUMBER(seconds, UNIT_SECONDS, ZENSKY);
} }
} }

View file

@ -66,6 +66,21 @@ enum GermanPrompts {
}; };
#if defined(VOICE) #if defined(VOICE)
#if defined(CPUARM)
#define DE_PUSH_UNIT_PROMPT(u) de_pushUnitPrompt((u), id)
#else
#define DE_PUSH_UNIT_PROMPT(u) pushUnitPrompt((u))
#endif
I18N_PLAY_FUNCTION(de, pushUnitPrompt, uint8_t unitprompt)
{
#if defined(CPUARM)
PUSH_UNIT_PROMPT(unitprompt, 0);
#else
unitprompt = DE_PROMPT_UNITS_BASE + unitprompt*2
PUSH_NUMBER_PROMPT(unitprompt);
#endif
}
I18N_PLAY_FUNCTION(de, playNumber, getvalue_t number, uint8_t unit, uint8_t att) I18N_PLAY_FUNCTION(de, playNumber, getvalue_t number, uint8_t unit, uint8_t att)
{ {
@ -145,7 +160,7 @@ I18N_PLAY_FUNCTION(de, playNumber, getvalue_t number, uint8_t unit, uint8_t att)
PUSH_NUMBER_PROMPT(DE_PROMPT_NULL+number); PUSH_NUMBER_PROMPT(DE_PROMPT_NULL+number);
if (unit) { if (unit) {
PUSH_NUMBER_PROMPT(DE_PROMPT_UNITS_BASE+unit); DE_PUSH_UNIT_PROMPT(unit);
} }
} }
@ -160,8 +175,7 @@ I18N_PLAY_FUNCTION(de, playDuration, int seconds PLAY_DURATION_ATT)
uint8_t tmp = seconds / 3600; uint8_t tmp = seconds / 3600;
seconds %= 3600; seconds %= 3600;
if (tmp > 0 || IS_PLAY_TIME()) { if (tmp > 0 || IS_PLAY_TIME()) {
PLAY_NUMBER(tmp, 0, 0); PLAY_NUMBER(tmp, UNIT_HOURS, 0);
PUSH_NUMBER_PROMPT(DE_PROMPT_UHR);
} }
tmp = seconds / 60; tmp = seconds / 60;
@ -169,17 +183,29 @@ I18N_PLAY_FUNCTION(de, playDuration, int seconds PLAY_DURATION_ATT)
if (tmp > 0 || ore >0) { if (tmp > 0 || ore >0) {
PLAY_NUMBER(tmp, 0, 0); PLAY_NUMBER(tmp, 0, 0);
if (tmp != 1) { if (tmp != 1) {
#if defined(CPUARM)
PUSH_UNIT_PROMPT(UNIT_MINUTES, 1);
} else {
PUSH_UNIT_PROMPT(UNIT_MINUTES, 0);
#else
PUSH_NUMBER_PROMPT(DE_PROMPT_MINUTEN); PUSH_NUMBER_PROMPT(DE_PROMPT_MINUTEN);
} else { } else {
PUSH_NUMBER_PROMPT(DE_PROMPT_MINUTE); PUSH_NUMBER_PROMPT(DE_PROMPT_MINUTE);
#endif
} }
PUSH_NUMBER_PROMPT(DE_PROMPT_UND); PUSH_NUMBER_PROMPT(DE_PROMPT_UND);
} }
PLAY_NUMBER(seconds, 0, 0); PLAY_NUMBER(seconds, 0, 0);
if (seconds != 1) { if (seconds != 1) {
#if defined(CPUARM)
PUSH_UNIT_PROMPT(UNIT_SECONDS, 1);
} else {
PUSH_UNIT_PROMPT(UNIT_SECONDS, 0);
#else
PUSH_NUMBER_PROMPT(DE_PROMPT_SECUNDEN); PUSH_NUMBER_PROMPT(DE_PROMPT_SECUNDEN);
} else { } else {
PUSH_NUMBER_PROMPT(DE_PROMPT_SECUNDE); PUSH_NUMBER_PROMPT(DE_PROMPT_SECUNDE);
#endif
} }
} }

View file

@ -58,10 +58,18 @@ enum EnglishPrompts {
I18N_PLAY_FUNCTION(en, pushUnitPrompt, int16_t number, uint8_t unitprompt) I18N_PLAY_FUNCTION(en, pushUnitPrompt, int16_t number, uint8_t unitprompt)
{ {
#if defined(CPUARM)
if (number == 1)
PUSH_UNIT_PROMPT(unitprompt, 0);
else
PUSH_UNIT_PROMPT(unitprompt, 1);
#else
unitprompt = EN_PROMPT_UNITS_BASE + unitprompt*2;
if (number == 1) if (number == 1)
PUSH_NUMBER_PROMPT(unitprompt); PUSH_NUMBER_PROMPT(unitprompt);
else else
PUSH_NUMBER_PROMPT(unitprompt+1); PUSH_NUMBER_PROMPT(unitprompt+1);
#endif
} }
I18N_PLAY_FUNCTION(en, playNumber, getvalue_t number, uint8_t unit, uint8_t att) I18N_PLAY_FUNCTION(en, playNumber, getvalue_t number, uint8_t unit, uint8_t att)
@ -127,7 +135,7 @@ I18N_PLAY_FUNCTION(en, playNumber, getvalue_t number, uint8_t unit, uint8_t att)
} }
if (unit) { if (unit) {
EN_PUSH_UNIT_PROMPT(tmp, EN_PROMPT_UNITS_BASE + unit*2); EN_PUSH_UNIT_PROMPT(tmp, unit);
} }
} }

View file

@ -90,6 +90,21 @@ enum SpanishPrompts {
}; };
#if defined(VOICE) #if defined(VOICE)
#if defined(CPUARM)
#define ES_PUSH_UNIT_PROMPT(u) es_pushUnitPrompt((u), id)
#else
#define ES_PUSH_UNIT_PROMPT(u) pushUnitPrompt((u))
#endif
I18N_PLAY_FUNCTION(es, pushUnitPrompt, uint8_t unitprompt)
{
#if defined(CPUARM)
PUSH_UNIT_PROMPT(unitprompt, 0);
#else
unitprompt = ES_PROMPT_UNITS_BASE + unitprompt*2;
PUSH_NUMBER_PROMPT(unitprompt);
#endif
}
I18N_PLAY_FUNCTION(es, playNumber, getvalue_t number, uint8_t unit, uint8_t att) I18N_PLAY_FUNCTION(es, playNumber, getvalue_t number, uint8_t unit, uint8_t att)
{ {
@ -173,7 +188,7 @@ I18N_PLAY_FUNCTION(es, playNumber, getvalue_t number, uint8_t unit, uint8_t att)
} }
if (unit) { if (unit) {
PUSH_NUMBER_PROMPT(ES_PROMPT_UNITS_BASE+unit-1); ES_PUSH_UNIT_PROMPT(unit);
} }
} }
@ -191,11 +206,19 @@ I18N_PLAY_FUNCTION(es, playDuration, int seconds PLAY_DURATION_ATT)
ore = tmp; ore = tmp;
if (tmp > 1) { if (tmp > 1) {
PLAY_NUMBER(tmp, 0, 0); PLAY_NUMBER(tmp, 0, 0);
#if defined(CPUARM)
PUSH_UNIT_PROMPT(UNIT_HOURS, 1);
}
else {
PUSH_NUMBER_PROMPT(ES_PROMPT_UNA);
PUSH_UNIT_PROMPT(UNIT_HOURS, 0);
#else
PUSH_NUMBER_PROMPT(ES_PROMPT_HORAS); PUSH_NUMBER_PROMPT(ES_PROMPT_HORAS);
} }
else { else {
PUSH_NUMBER_PROMPT(ES_PROMPT_UNA); PUSH_NUMBER_PROMPT(ES_PROMPT_UNA);
PUSH_NUMBER_PROMPT(ES_PROMPT_HORA); PUSH_NUMBER_PROMPT(ES_PROMPT_HORA);
#endif
} }
} }
@ -204,20 +227,38 @@ I18N_PLAY_FUNCTION(es, playDuration, int seconds PLAY_DURATION_ATT)
if (tmp > 0 || ore >0) { if (tmp > 0 || ore >0) {
if (tmp != 1) { if (tmp != 1) {
PLAY_NUMBER(tmp, 0, 0); PLAY_NUMBER(tmp, 0, 0);
#if defined(CPUARM)
PUSH_UNIT_PROMPT(UNIT_MINUTES, 1);
}
else {
PUSH_NUMBER_PROMPT(ES_PROMPT_UNA);
PUSH_UNIT_PROMPT(UNIT_MINUTES, 0);
#else
PUSH_NUMBER_PROMPT(ES_PROMPT_MINUTOS); PUSH_NUMBER_PROMPT(ES_PROMPT_MINUTOS);
} else { }
else {
PUSH_NUMBER_PROMPT(ES_PROMPT_UN); PUSH_NUMBER_PROMPT(ES_PROMPT_UN);
PUSH_NUMBER_PROMPT(ES_PROMPT_MINUTO); PUSH_NUMBER_PROMPT(ES_PROMPT_MINUTO);
#endif
} }
PUSH_NUMBER_PROMPT(ES_PROMPT_Y); PUSH_NUMBER_PROMPT(ES_PROMPT_Y);
} }
if (seconds != 1) { if (seconds != 1) {
PLAY_NUMBER(seconds, 0, 0); PLAY_NUMBER(seconds, 0, 0);
#if defined(CPUARM)
PUSH_UNIT_PROMPT(UNIT_SECONDS, 1);
}
else {
PUSH_NUMBER_PROMPT(ES_PROMPT_UNA);
PUSH_UNIT_PROMPT(UNIT_SECONDS, 0);
#else
PUSH_NUMBER_PROMPT(ES_PROMPT_SEGUNDOS); PUSH_NUMBER_PROMPT(ES_PROMPT_SEGUNDOS);
} else { }
PUSH_NUMBER_PROMPT(ES_PROMPT_UN); else {
PUSH_NUMBER_PROMPT(ES_PROMPT_SEGUNDO); PUSH_NUMBER_PROMPT(ES_PROMPT_UN);
PUSH_NUMBER_PROMPT(ES_PROMPT_SEGUNDO);
#endif
} }
} }

View file

@ -1,187 +1,200 @@
/* /*
* Authors (alphabetical order) * Authors (alphabetical order)
* - Andre Bernet <bernet.andre@gmail.com> * - Andre Bernet <bernet.andre@gmail.com>
* - Bertrand Songis <bsongis@gmail.com> * - Bertrand Songis <bsongis@gmail.com>
* *
* opentx is based on code named * opentx is based on code named
* gruvin9x by Bryan J. Rentoul: http://code.google.com/p/gruvin9x/, * gruvin9x by Bryan J. Rentoul: http://code.google.com/p/gruvin9x/,
* er9x by Erez Raviv: http://code.google.com/p/er9x/, * er9x by Erez Raviv: http://code.google.com/p/er9x/,
* and the original (and ongoing) project by * and the original (and ongoing) project by
* Thomas Husterer, th9x: http://code.google.com/p/th9x/ * Thomas Husterer, th9x: http://code.google.com/p/th9x/
* *
* This program is free software; you can redistribute it and/or modify * This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 as * it under the terms of the GNU General Public License version 2 as
* published by the Free Software Foundation. * published by the Free Software Foundation.
* *
* This program is distributed in the hope that it will be useful, * This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of * but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details. * GNU General Public License for more details.
* *
*/ */
#include "opentx.h" #include "opentx.h"
enum FrenchPrompts { enum FrenchPrompts {
FR_PROMPT_NUMBERS_BASE = 0, FR_PROMPT_NUMBERS_BASE = 0,
FR_PROMPT_ZERO = FR_PROMPT_NUMBERS_BASE+0, FR_PROMPT_ZERO = FR_PROMPT_NUMBERS_BASE+0,
FR_PROMPT_CENT = FR_PROMPT_NUMBERS_BASE+100, FR_PROMPT_CENT = FR_PROMPT_NUMBERS_BASE+100,
FR_PROMPT_DEUX_CENT = FR_PROMPT_CENT+1, FR_PROMPT_DEUX_CENT = FR_PROMPT_CENT+1,
FR_PROMPT_MILLE = FR_PROMPT_CENT+9, FR_PROMPT_MILLE = FR_PROMPT_CENT+9,
FR_PROMPT_UNE = 110, FR_PROMPT_UNE = 110,
FR_PROMPT_ONZE, FR_PROMPT_ONZE,
FR_PROMPT_VINGT_ET_UNE, FR_PROMPT_VINGT_ET_UNE,
FR_PROMPT_TRENTE_ET_UNE, FR_PROMPT_TRENTE_ET_UNE,
FR_PROMPT_QUARANTE_ET_UNE, FR_PROMPT_QUARANTE_ET_UNE,
FR_PROMPT_CINQUANTE_ET_UNE, FR_PROMPT_CINQUANTE_ET_UNE,
FR_PROMPT_SOIXANTE_ET_UNE, FR_PROMPT_SOIXANTE_ET_UNE,
FR_PROMPT_SOIXANTE_ET_ONZE, FR_PROMPT_SOIXANTE_ET_ONZE,
FR_PROMPT_QUATRE_VINGT_UNE, FR_PROMPT_QUATRE_VINGT_UNE,
FR_PROMPT_VIRGULE = 119, FR_PROMPT_VIRGULE = 119,
FR_PROMPT_ET = 120, FR_PROMPT_ET = 120,
FR_PROMPT_MOINS = 121, FR_PROMPT_MOINS = 121,
FR_PROMPT_MINUIT = 122, FR_PROMPT_MINUIT = 122,
FR_PROMPT_MIDI = 123, FR_PROMPT_MIDI = 123,
FR_PROMPT_UNITS_BASE = 124, FR_PROMPT_UNITS_BASE = 124,
FR_PROMPT_HEURE = FR_PROMPT_UNITS_BASE+UNIT_HOURS, FR_PROMPT_HEURE = FR_PROMPT_UNITS_BASE+UNIT_HOURS,
FR_PROMPT_MINUTE = FR_PROMPT_UNITS_BASE+UNIT_MINUTES, FR_PROMPT_MINUTE = FR_PROMPT_UNITS_BASE+UNIT_MINUTES,
FR_PROMPT_SECONDE = FR_PROMPT_UNITS_BASE+UNIT_SECONDS, FR_PROMPT_SECONDE = FR_PROMPT_UNITS_BASE+UNIT_SECONDS,
FR_PROMPT_VIRGULE_BASE = 180, //,0 - ,9 FR_PROMPT_VIRGULE_BASE = 180, //,0 - ,9
}; };
#if defined(VOICE) #if defined(VOICE)
#define FEMININ 0x80 #if defined(CPUARM)
#define FR_PUSH_UNIT_PROMPT(u) fr_pushUnitPrompt((u), id)
I18N_PLAY_FUNCTION(fr, playNumber, getvalue_t number, uint8_t unit, uint8_t att) #else
{ #define FR_PUSH_UNIT_PROMPT(u) pushUnitPrompt((u))
/* if digit >= 1000000000: #endif
temp_digit, digit = divmod(digit, 1000000000)
prompts.extend(self.getNumberPrompt(temp_digit)) I18N_PLAY_FUNCTION(fr, pushUnitPrompt, uint8_t unitprompt)
prompts.append(Prompt(GUIDE_00_BILLION, dir=2)) {
if digit >= 1000000: #if defined(CPUARM)
temp_digit, digit = divmod(digit, 1000000) PUSH_UNIT_PROMPT(unitprompt, 0);
prompts.extend(self.getNumberPrompt(temp_digit)) #else
prompts.append(Prompt(GUIDE_00_MILLION, dir=2)) unitprompt = FR_PROMPT_UNITS_BASE + unitprompt*2;
*/ PUSH_NUMBER_PROMPT(unitprompt);
#endif
if (number < 0) { }
PUSH_NUMBER_PROMPT(FR_PROMPT_MOINS);
number = -number; #define FEMININ 0x80
}
I18N_PLAY_FUNCTION(fr, playNumber, getvalue_t number, uint8_t unit, uint8_t att)
#if !defined(CPUARM) {
if (unit) { /* if digit >= 1000000000:
unit--; temp_digit, digit = divmod(digit, 1000000000)
convertUnit(number, unit); prompts.extend(self.getNumberPrompt(temp_digit))
if (IS_IMPERIAL_ENABLE()) { prompts.append(Prompt(GUIDE_00_BILLION, dir=2))
if (unit == UNIT_DIST) { if digit >= 1000000:
unit = UNIT_FEET; temp_digit, digit = divmod(digit, 1000000)
} prompts.extend(self.getNumberPrompt(temp_digit))
if (unit == UNIT_SPEED) { prompts.append(Prompt(GUIDE_00_MILLION, dir=2))
unit = UNIT_KTS; */
}
} if (number < 0) {
unit++; PUSH_NUMBER_PROMPT(FR_PROMPT_MOINS);
} number = -number;
#endif }
int8_t mode = MODE(att); #if !defined(CPUARM)
if (mode > 0) { if (unit) {
#if defined(CPUARM) unit--;
if (mode == 2) { convertUnit(number, unit);
number /= 10; if (IS_IMPERIAL_ENABLE()) {
} if (unit == UNIT_DIST) {
#else unit = UNIT_FEET;
// we assume that we are PREC1 }
#endif if (unit == UNIT_SPEED) {
div_t qr = div(number, 10); unit = UNIT_KTS;
if (qr.rem) { }
PLAY_NUMBER(qr.quot, 0, 0); }
PUSH_NUMBER_PROMPT(FR_PROMPT_VIRGULE_BASE + qr.rem); unit++;
number = -1; }
} #endif
else {
number = qr.quot; int8_t mode = MODE(att);
} if (mode > 0) {
} #if defined(CPUARM)
if (mode == 2) {
if (number >= 1000) { number /= 10;
if (number >= 2000) }
PLAY_NUMBER(number / 1000, 0, 0); #else
PUSH_NUMBER_PROMPT(FR_PROMPT_MILLE); // we assume that we are PREC1
number %= 1000; #endif
if (number == 0) div_t qr = div(number, 10);
number = -1; if (qr.rem) {
} PLAY_NUMBER(qr.quot, 0, 0);
if (number >= 100) { PUSH_NUMBER_PROMPT(FR_PROMPT_VIRGULE_BASE + qr.rem);
if (number >= 200) number = -1;
PUSH_NUMBER_PROMPT(FR_PROMPT_ZERO + number/100); }
PUSH_NUMBER_PROMPT(FR_PROMPT_CENT); else {
number %= 100; number = qr.quot;
if (number == 0) }
number = -1; }
}
if (((number % 10) == 1) && number < 90 && (att & FEMININ)) { if (number >= 1000) {
PUSH_NUMBER_PROMPT(FR_PROMPT_UNE+(number/10)); if (number >= 2000)
} PLAY_NUMBER(number / 1000, 0, 0);
else if (number >= 0) { PUSH_NUMBER_PROMPT(FR_PROMPT_MILLE);
PUSH_NUMBER_PROMPT(FR_PROMPT_ZERO+number); number %= 1000;
} if (number == 0)
number = -1;
if (unit) { }
PUSH_NUMBER_PROMPT(FR_PROMPT_UNITS_BASE+unit); if (number >= 100) {
} if (number >= 200)
} PUSH_NUMBER_PROMPT(FR_PROMPT_ZERO + number/100);
PUSH_NUMBER_PROMPT(FR_PROMPT_CENT);
I18N_PLAY_FUNCTION(fr, playDuration, int seconds PLAY_DURATION_ATT) number %= 100;
{ if (number == 0)
if (seconds == 0) { number = -1;
PLAY_NUMBER(0, 0, FEMININ); }
return; if (((number % 10) == 1) && number < 90 && (att & FEMININ)) {
} PUSH_NUMBER_PROMPT(FR_PROMPT_UNE+(number/10));
}
if (seconds < 0) { else if (number >= 0) {
PUSH_NUMBER_PROMPT(FR_PROMPT_MOINS); PUSH_NUMBER_PROMPT(FR_PROMPT_ZERO+number);
seconds = -seconds; }
}
if (unit) {
uint8_t tmp = seconds / 3600; FR_PUSH_UNIT_PROMPT(unit);
seconds %= 3600; }
if (IS_PLAY_TIME() && tmp==0) { }
PUSH_NUMBER_PROMPT(FR_PROMPT_MINUIT);
} I18N_PLAY_FUNCTION(fr, playDuration, int seconds PLAY_DURATION_ATT)
else if (IS_PLAY_TIME() && tmp==12) { {
PUSH_NUMBER_PROMPT(FR_PROMPT_MIDI); if (seconds == 0) {
} PLAY_NUMBER(0, 0, FEMININ);
else if (tmp > 0) { return;
PLAY_NUMBER(tmp, 0, FEMININ); }
PUSH_NUMBER_PROMPT(FR_PROMPT_HEURE);
} if (seconds < 0) {
PUSH_NUMBER_PROMPT(FR_PROMPT_MOINS);
tmp = seconds / 60; seconds = -seconds;
seconds %= 60; }
if (tmp > 0) {
if (IS_PLAY_TIME()) { uint8_t tmp = seconds / 3600;
PLAY_NUMBER(tmp, 0, tmp==1 ? FEMININ : 0); seconds %= 3600;
} if (IS_PLAY_TIME() && tmp==0) {
else { PUSH_NUMBER_PROMPT(FR_PROMPT_MINUIT);
PLAY_NUMBER(tmp, 0, FEMININ); }
PUSH_NUMBER_PROMPT(FR_PROMPT_MINUTE); else if (IS_PLAY_TIME() && tmp==12) {
if (seconds > 0) PUSH_NUMBER_PROMPT(FR_PROMPT_MIDI);
PUSH_NUMBER_PROMPT(FR_PROMPT_ET); }
} else if (tmp > 0) {
} PLAY_NUMBER(tmp, UNIT_HOURS, FEMININ);
}
if (!IS_PLAY_TIME() && seconds > 0) {
PLAY_NUMBER(seconds, 0, FEMININ); tmp = seconds / 60;
PUSH_NUMBER_PROMPT(FR_PROMPT_SECONDE); seconds %= 60;
} if (tmp > 0) {
} if (IS_PLAY_TIME()) {
PLAY_NUMBER(tmp, 0, tmp==1 ? FEMININ : 0);
LANGUAGE_PACK_DECLARE(fr, "Francais"); }
else {
#endif PLAY_NUMBER(tmp, UNIT_MINUTES, FEMININ);
if (seconds > 0)
PUSH_NUMBER_PROMPT(FR_PROMPT_ET);
}
}
if (!IS_PLAY_TIME() && seconds > 0) {
PLAY_NUMBER(seconds, UNIT_SECONDS, FEMININ);
}
}
LANGUAGE_PACK_DECLARE(fr, "Francais");
#endif

View file

@ -58,10 +58,18 @@ enum HungarianPrompts {
I18N_PLAY_FUNCTION(hu, pushUnitPrompt, int16_t number, uint8_t unitprompt) I18N_PLAY_FUNCTION(hu, pushUnitPrompt, int16_t number, uint8_t unitprompt)
{ {
#if defined(CPUARM)
if (number == 1)
PUSH_UNIT_PROMPT(unitprompt, 0);
else
PUSH_UNIT_PROMPT(unitprompt, 1);
#else
unitprompt = HU_PROMPT_UNITS_BASE + unitprompt*2;
if (number == 1) if (number == 1)
PUSH_NUMBER_PROMPT(unitprompt); PUSH_NUMBER_PROMPT(unitprompt);
else else
PUSH_NUMBER_PROMPT(unitprompt+1); PUSH_NUMBER_PROMPT(unitprompt+1);
#endif
} }
I18N_PLAY_FUNCTION(hu, playNumber, getvalue_t number, uint8_t unit, uint8_t att) I18N_PLAY_FUNCTION(hu, playNumber, getvalue_t number, uint8_t unit, uint8_t att)
@ -127,7 +135,7 @@ I18N_PLAY_FUNCTION(hu, playNumber, getvalue_t number, uint8_t unit, uint8_t att)
} }
if (unit) { if (unit) {
HU_PUSH_UNIT_PROMPT(tmp, HU_PROMPT_UNITS_BASE + unit*2); HU_PUSH_UNIT_PROMPT(tmp, unit);
} }
} }

View file

@ -62,6 +62,28 @@ enum ItalianPrompts {
}; };
#if defined(VOICE) #if defined(VOICE)
#if defined(CPUARM)
#define IT_PUSH_UNIT_PROMPT(p, u) it_pushUnitPrompt((p), (u), id)
#else
#define IT_PUSH_UNIT_PROMPT(p, u) pushUnitPrompt((p), (u))
#endif
I18N_PLAY_FUNCTION(it, pushUnitPrompt, int16_t number, uint8_t unitprompt)
{
#if defined(CPUARM)
if (number == 1)
PUSH_UNIT_PROMPT(unitprompt, 0);
else
PUSH_UNIT_PROMPT(unitprompt, 1);
#else
unitprompt = IT_PROMPT_UNITS_BASE + unitprompt*2;
if (number == 1)
PUSH_NUMBER_PROMPT(unitprompt);
else
PUSH_NUMBER_PROMPT(unitprompt+1);
#endif
}
I18N_PLAY_FUNCTION(it, playNumber, getvalue_t number, uint8_t unit, uint8_t att) I18N_PLAY_FUNCTION(it, playNumber, getvalue_t number, uint8_t unit, uint8_t att)
{ {
@ -151,11 +173,7 @@ I18N_PLAY_FUNCTION(it, playNumber, getvalue_t number, uint8_t unit, uint8_t att)
} }
} }
if (unit) { if (unit) {
if (orignumber == 1) { IT_PUSH_UNIT_PROMPT(orignumber, unit);
PUSH_NUMBER_PROMPT(IT_PROMPT_UNITS_BASE+(unit*2));
} else {
PUSH_NUMBER_PROMPT(IT_PROMPT_UNITS_BASE+(unit*2)+1);
}
} }
} }
@ -172,11 +190,15 @@ I18N_PLAY_FUNCTION(it, playDuration, int seconds PLAY_DURATION_ATT)
if (tmp > 0) { if (tmp > 0) {
ore=tmp; ore=tmp;
if (tmp > 1 || IS_PLAY_TIME()) { if (tmp > 1 || IS_PLAY_TIME()) {
#if defined(CPUARM)
PLAY_NUMBER(tmp, UNIT_HOURS, 0);
#else
PLAY_NUMBER(tmp, 0, 0); PLAY_NUMBER(tmp, 0, 0);
PUSH_NUMBER_PROMPT(IT_PROMPT_ORE); PUSH_NUMBER_PROMPT(IT_PROMPT_ORE);
} else { } else {
PUSH_NUMBER_PROMPT(IT_PROMPT_UN); PUSH_NUMBER_PROMPT(IT_PROMPT_UN);
PUSH_NUMBER_PROMPT(IT_PROMPT_ORA); PUSH_NUMBER_PROMPT(IT_PROMPT_ORA);
#endif
} }
} }
if (seconds>0) { if (seconds>0) {
@ -187,11 +209,15 @@ I18N_PLAY_FUNCTION(it, playDuration, int seconds PLAY_DURATION_ATT)
} }
if (tmp > 0) { if (tmp > 0) {
if (tmp != 1) { if (tmp != 1) {
#if defined(CPUARM)
PLAY_NUMBER(tmp, UNIT_MINUTES, 0);
#else
PLAY_NUMBER(tmp, 0, 0); PLAY_NUMBER(tmp, 0, 0);
PUSH_NUMBER_PROMPT(IT_PROMPT_MINUTI); PUSH_NUMBER_PROMPT(IT_PROMPT_MINUTI);
} else { } else {
PUSH_NUMBER_PROMPT(IT_PROMPT_UN); PUSH_NUMBER_PROMPT(IT_PROMPT_UN);
PUSH_NUMBER_PROMPT(IT_PROMPT_MINUTO); PUSH_NUMBER_PROMPT(IT_PROMPT_MINUTO);
#endif
} }
} }
if ((tmp>0 || ore>0) && seconds>0) { if ((tmp>0 || ore>0) && seconds>0) {
@ -200,11 +226,15 @@ I18N_PLAY_FUNCTION(it, playDuration, int seconds PLAY_DURATION_ATT)
} }
if (seconds != 0 || (ore==0 && tmp==0)) { if (seconds != 0 || (ore==0 && tmp==0)) {
if (seconds != 1) { if (seconds != 1) {
#if defined(CPUARM)
PLAY_NUMBER(tmp, UNIT_SECONDS, 0);
#else
PLAY_NUMBER(seconds, 0, 0); PLAY_NUMBER(seconds, 0, 0);
PUSH_NUMBER_PROMPT(IT_PROMPT_SECONDI); PUSH_NUMBER_PROMPT(IT_PROMPT_SECONDI);
} else { } else {
PUSH_NUMBER_PROMPT(IT_PROMPT_UN); PUSH_NUMBER_PROMPT(IT_PROMPT_UN);
PUSH_NUMBER_PROMPT(IT_PROMPT_SECONDO); PUSH_NUMBER_PROMPT(IT_PROMPT_SECONDO);
#endif
} }
} }
} }

View file

@ -37,70 +37,30 @@ enum DutchPrompts {
#if defined(VOICE) #if defined(VOICE)
#if defined(CPUARM) #if defined(CPUARM)
#define NL_PUSH_UNIT_PROMPT(p, u) en_pushUnitPrompt((p), (u), id) #define NL_PUSH_UNIT_PROMPT(p, u) en_pushUnitPrompt((p), (u), id)
#else #else
#define NL_PUSH_UNIT_PROMPT(p, u) pushUnitPrompt((p), (u)) #define NL_PUSH_UNIT_PROMPT(p, u) pushUnitPrompt((p), (u))
#endif #endif
I18N_PLAY_FUNCTION(nl, pushUnitPrompt, int16_t number, uint8_t unitprompt) I18N_PLAY_FUNCTION(nl, pushUnitPrompt, int16_t number, uint8_t unitprompt)
{ {
#if defined(CPUARM)
if (number == 1)
PUSH_UNIT_PROMPT(unitprompt, 0);
else
PUSH_UNIT_PROMPT(unitprompt, 1);
#else
unitprompt = NL_PROMPT_UNITS_BASE + unitprompt*2;
if (number == 1) if (number == 1)
PUSH_NUMBER_PROMPT(unitprompt); PUSH_NUMBER_PROMPT(unitprompt);
else else
PUSH_NUMBER_PROMPT(unitprompt+1); PUSH_NUMBER_PROMPT(unitprompt+1);
#endif
} }
I18N_PLAY_FUNCTION(nl, playNumber, getvalue_t number, uint8_t unit, uint8_t att) I18N_PLAY_FUNCTION(nl, playNumber, getvalue_t number, uint8_t unit, uint8_t att)
{ {
if (number < 0) { if (number < 0) {
PUSH_NUMBER_PROMPT(NL_PROMPT_MINUS); PUSH_NUMBER_PROMPT(NL_PROMPT_MINUS);
number = -number; number = -number;
@ -136,24 +96,16 @@ I18N_PLAY_FUNCTION(nl, playNumber, getvalue_t number, uint8_t unit, uint8_t att)
PLAY_NUMBER(qr.quot, 0, 0); PLAY_NUMBER(qr.quot, 0, 0);
PUSH_NUMBER_PROMPT(NL_PROMPT_POINT_BASE + qr.rem); PUSH_NUMBER_PROMPT(NL_PROMPT_POINT_BASE + qr.rem);
number = -1; number = -1;
} }
else { else {
number = qr.quot; number = qr.quot;
} }
} }
int16_t tmp = number; int16_t tmp = number;
if (number >= 1000) { if (number >= 1000) {
PLAY_NUMBER(number / 1000, 0, 0); PLAY_NUMBER(number / 1000, 0, 0);
PUSH_NUMBER_PROMPT(NL_PROMPT_THOUSAND); PUSH_NUMBER_PROMPT(NL_PROMPT_THOUSAND);
number %= 1000; number %= 1000;
@ -161,9 +113,7 @@ I18N_PLAY_FUNCTION(nl, playNumber, getvalue_t number, uint8_t unit, uint8_t att)
number = -1; number = -1;
} }
if (number >= 100) { if (number >= 100) {
PUSH_NUMBER_PROMPT(NL_PROMPT_HUNDRED + (number/100)-1); PUSH_NUMBER_PROMPT(NL_PROMPT_HUNDRED + (number/100)-1);
number %= 100; number %= 100;
if (number == 0) if (number == 0)
number = -1; number = -1;
@ -172,9 +122,8 @@ I18N_PLAY_FUNCTION(nl, playNumber, getvalue_t number, uint8_t unit, uint8_t att)
PUSH_NUMBER_PROMPT(NL_PROMPT_ZERO + number); PUSH_NUMBER_PROMPT(NL_PROMPT_ZERO + number);
} }
if (unit) { if (unit) {
NL_PUSH_UNIT_PROMPT(tmp, NL_PROMPT_UNITS_BASE + unit*2); NL_PUSH_UNIT_PROMPT(tmp, unit);
} }
} }
@ -190,12 +139,10 @@ I18N_PLAY_FUNCTION(nl, playDuration, int seconds PLAY_DURATION_ATT)
seconds = -seconds; seconds = -seconds;
} }
uint8_t tmp = seconds / 3600; uint8_t tmp = seconds / 3600;
seconds %= 3600; seconds %= 3600;
if (tmp > 0 || IS_PLAY_TIME()) { if (tmp > 0 || IS_PLAY_TIME()) {
PLAY_NUMBER(tmp, UNIT_HOURS, 0); PLAY_NUMBER(tmp, UNIT_HOURS, 0);
} }
tmp = seconds / 60; tmp = seconds / 60;
@ -203,20 +150,10 @@ I18N_PLAY_FUNCTION(nl, playDuration, int seconds PLAY_DURATION_ATT)
if (tmp > 0) { if (tmp > 0) {
PLAY_NUMBER(tmp, UNIT_MINUTES, 0); PLAY_NUMBER(tmp, UNIT_MINUTES, 0);
if (seconds > 0) if (seconds > 0)
PUSH_NUMBER_PROMPT(NL_PROMPT_AND); PUSH_NUMBER_PROMPT(NL_PROMPT_AND);
} }
if (seconds > 0) { if (seconds > 0) {
PLAY_NUMBER(seconds, UNIT_SECONDS, 0); PLAY_NUMBER(seconds, UNIT_SECONDS, 0);
} }
} }

View file

@ -79,6 +79,23 @@ enum PolishPrompts {
I18N_PLAY_FUNCTION(pl, pushUnitPrompt, int16_t number, uint8_t unitprompt) I18N_PLAY_FUNCTION(pl, pushUnitPrompt, int16_t number, uint8_t unitprompt)
{ {
#if defined(CPUARM)
if (number == 1)
PUSH_UNIT_PROMPT(unitprompt, 0);
else if (number > 1 && number < 5)
PUSH_UNIT_PROMPT(unitprompt, 1);
else {
int test_2 =0;
test_2 =number % 10;
int ten=0;
ten=(number - (number % 10))/10;
if ((test_2 > 1 && test_2 < 5) && ten >=2)
PUSH_UNIT_PROMPT(unitprompt, 1);
else
PUSH_UNIT_PROMPT(unitprompt, 2);
}
#else
unitprompt = PL_PROMPT_UNITS_BASE + unitprompt*4;
if (number == 1) if (number == 1)
PUSH_NUMBER_PROMPT(unitprompt); PUSH_NUMBER_PROMPT(unitprompt);
else if (number > 1 && number < 5) else if (number > 1 && number < 5)
@ -93,6 +110,7 @@ I18N_PLAY_FUNCTION(pl, pushUnitPrompt, int16_t number, uint8_t unitprompt)
else else
PUSH_NUMBER_PROMPT(unitprompt+2); PUSH_NUMBER_PROMPT(unitprompt+2);
} }
#endif
} }
I18N_PLAY_FUNCTION(pl, playNumber, getvalue_t number, uint8_t unit, uint8_t att) I18N_PLAY_FUNCTION(pl, playNumber, getvalue_t number, uint8_t unit, uint8_t att)
@ -190,10 +208,6 @@ I18N_PLAY_FUNCTION(pl, playNumber, getvalue_t number, uint8_t unit, uint8_t att)
number = -1; number = -1;
} }
if (number >= 1000) { if (number >= 1000) {
if (number >= 2000) if (number >= 2000)
PLAY_NUMBER(number / 1000, 0, 0); PLAY_NUMBER(number / 1000, 0, 0);
@ -229,7 +243,7 @@ I18N_PLAY_FUNCTION(pl, playNumber, getvalue_t number, uint8_t unit, uint8_t att)
} }
if (unit) { if (unit) {
PL_PUSH_UNIT_PROMPT(tmp, (PL_PROMPT_UNITS_BASE+((unit-1)*4))); PL_PUSH_UNIT_PROMPT(tmp, unit);
} }
} }

View file

@ -85,6 +85,22 @@ enum PortuguesePrompts {
#if defined(VOICE) #if defined(VOICE)
#if defined(CPUARM)
#define PT_PUSH_UNIT_PROMPT(u) pt_pushUnitPrompt((u), id)
#else
#define PT_PUSH_UNIT_PROMPT(u) pushUnitPrompt((u))
#endif
I18N_PLAY_FUNCTION(pt, pushUnitPrompt, uint8_t unitprompt)
{
#if defined(CPUARM)
PUSH_UNIT_PROMPT(unitprompt, 0);
#else
unitprompt = PT_PROMPT_UNITS_BASE + unitprompt*2;
PUSH_NUMBER_PROMPT(unitprompt);
#endif
}
I18N_PLAY_FUNCTION(pt, playNumber, getvalue_t number, uint8_t unit, uint8_t att) I18N_PLAY_FUNCTION(pt, playNumber, getvalue_t number, uint8_t unit, uint8_t att)
{ {
if (number < 0) { if (number < 0) {
@ -151,7 +167,7 @@ I18N_PLAY_FUNCTION(pt, playNumber, getvalue_t number, uint8_t unit, uint8_t att)
PUSH_NUMBER_PROMPT(PT_PROMPT_ZERO+number); PUSH_NUMBER_PROMPT(PT_PROMPT_ZERO+number);
if (unit) { if (unit) {
PUSH_NUMBER_PROMPT(PT_PROMPT_UNITS_BASE+unit-1); PT_PUSH_UNIT_PROMPT(unit);
} }
} }
@ -169,13 +185,25 @@ I18N_PLAY_FUNCTION(pt, playDuration, int seconds PLAY_DURATION_ATT)
ore=tmp; ore=tmp;
if (tmp > 2) { if (tmp > 2) {
PLAY_NUMBER(tmp, 0, 0); PLAY_NUMBER(tmp, 0, 0);
#if defined(CPUARM)
PUSH_UNIT_PROMPT(UNIT_HOURS, 1);
#else
PUSH_NUMBER_PROMPT(PT_PROMPT_HORAS); PUSH_NUMBER_PROMPT(PT_PROMPT_HORAS);
#endif
} else if (tmp==2) { } else if (tmp==2) {
PUSH_NUMBER_PROMPT(PT_PROMPT_DUAS); PUSH_NUMBER_PROMPT(PT_PROMPT_DUAS);
#if defined(CPUARM)
PUSH_UNIT_PROMPT(UNIT_HOURS, 1);
#else
PUSH_NUMBER_PROMPT(PT_PROMPT_HORAS); PUSH_NUMBER_PROMPT(PT_PROMPT_HORAS);
} else if (tmp==1) { #endif
} else if (tmp==1) {
PUSH_NUMBER_PROMPT(PT_PROMPT_UMA); PUSH_NUMBER_PROMPT(PT_PROMPT_UMA);
PUSH_NUMBER_PROMPT(PT_PROMPT_HORA); #if defined(CPUARM)
PUSH_UNIT_PROMPT(UNIT_HOURS, 0);
#else
PUSH_NUMBER_PROMPT(PT_PROMPT_HORAS);
#endif
} }
} }
@ -184,20 +212,36 @@ I18N_PLAY_FUNCTION(pt, playDuration, int seconds PLAY_DURATION_ATT)
if (tmp > 0 || ore >0) { if (tmp > 0 || ore >0) {
if (tmp != 1) { if (tmp != 1) {
PLAY_NUMBER(tmp, 0, 0); PLAY_NUMBER(tmp, 0, 0);
#if defined(CPUARM)
PUSH_UNIT_PROMPT(UNIT_MINUTES, 1);
#else
PUSH_NUMBER_PROMPT(PT_PROMPT_MINUTOS); PUSH_NUMBER_PROMPT(PT_PROMPT_MINUTOS);
#endif
} else { } else {
PUSH_NUMBER_PROMPT(PT_PROMPT_NUMBERS_BASE+1); PUSH_NUMBER_PROMPT(PT_PROMPT_NUMBERS_BASE+1);
#if defined(CPUARM)
PUSH_UNIT_PROMPT(UNIT_MINUTES, 0);
#else
PUSH_NUMBER_PROMPT(PT_PROMPT_MINUTO); PUSH_NUMBER_PROMPT(PT_PROMPT_MINUTO);
#endif
} }
PUSH_NUMBER_PROMPT(PT_PROMPT_E); PUSH_NUMBER_PROMPT(PT_PROMPT_E);
} }
if (seconds != 1) { if (seconds != 1) {
PLAY_NUMBER(seconds, 0, 0); PLAY_NUMBER(seconds, 0, 0);
#if defined(CPUARM)
PUSH_UNIT_PROMPT(UNIT_SECONDS, 1);
#else
PUSH_NUMBER_PROMPT(PT_PROMPT_SEGUNDOS); PUSH_NUMBER_PROMPT(PT_PROMPT_SEGUNDOS);
#endif
} else { } else {
PUSH_NUMBER_PROMPT(PT_PROMPT_NUMBERS_BASE+1); PUSH_NUMBER_PROMPT(PT_PROMPT_NUMBERS_BASE+1);
#if defined(CPUARM)
PUSH_UNIT_PROMPT(UNIT_SECONDS, 0);
#else
PUSH_NUMBER_PROMPT(PT_PROMPT_SEGUNDO); PUSH_NUMBER_PROMPT(PT_PROMPT_SEGUNDO);
#endif
} }
} }

View file

@ -51,6 +51,28 @@ enum SwedishPrompts {
#if defined(VOICE) #if defined(VOICE)
#if defined(CPUARM)
#define SE_PUSH_UNIT_PROMPT(p, u) se_pushUnitPrompt((p), (u), id)
#else
#define SE_PUSH_UNIT_PROMPT(p, u) pushUnitPrompt((p), (u))
#endif
I18N_PLAY_FUNCTION(se, pushUnitPrompt, int16_t number, uint8_t unitprompt)
{
#if defined(CPUARM)
if (number == 1)
PUSH_UNIT_PROMPT(unitprompt, 0);
else
PUSH_UNIT_PROMPT(unitprompt, 1);
#else
unitprompt = SE_PROMPT_UNITS_BASE + unitprompt*2;
if (number == 1)
PUSH_NUMBER_PROMPT(unitprompt);
else
PUSH_NUMBER_PROMPT(unitprompt+1);
#endif
}
I18N_PLAY_FUNCTION(se, playNumber, getvalue_t number, uint8_t unit, uint8_t att) I18N_PLAY_FUNCTION(se, playNumber, getvalue_t number, uint8_t unit, uint8_t att)
{ {
if (number < 0) { if (number < 0) {
@ -114,10 +136,7 @@ I18N_PLAY_FUNCTION(se, playNumber, getvalue_t number, uint8_t unit, uint8_t att)
} }
if (unit) { if (unit) {
if (tmpNumber == 1 ) SE_PUSH_UNIT_PROMPT(tmpNumber, unit);
PUSH_NUMBER_PROMPT(SE_PROMPT_UNITS_BASE+unit*2); // Singular prompts
else
PUSH_NUMBER_PROMPT(SE_PROMPT_UNITS_BASE+unit*2+1); // Plural prompts
} }
} }

View file

@ -69,12 +69,22 @@ enum SlovakPrompts {
I18N_PLAY_FUNCTION(sk, pushUnitPrompt, int16_t number, uint8_t unitprompt) I18N_PLAY_FUNCTION(sk, pushUnitPrompt, int16_t number, uint8_t unitprompt)
{ {
#if defined(CPUARM)
if (number == 1)
PUSH_UNIT_PROMPT(unitprompt, 0);
else if (number > 1 && number < 5)
PUSH_UNIT_PROMPT(unitprompt, 1);
else
PUSH_UNIT_PROMPT(unitprompt, 2);
#else
unitprompt = SK_PROMPT_UNITS_BASE + unitprompt*4;
if (number == 1) if (number == 1)
PUSH_NUMBER_PROMPT(unitprompt); PUSH_NUMBER_PROMPT(unitprompt);
else if (number > 1 && number < 5) else if (number > 1 && number < 5)
PUSH_NUMBER_PROMPT(unitprompt+1); PUSH_NUMBER_PROMPT(unitprompt+1);
else else
PUSH_NUMBER_PROMPT(unitprompt+2); PUSH_NUMBER_PROMPT(unitprompt+2);
#endif
} }
I18N_PLAY_FUNCTION(sk, playNumber, getvalue_t number, uint8_t unit, uint8_t att) I18N_PLAY_FUNCTION(sk, playNumber, getvalue_t number, uint8_t unit, uint8_t att)
@ -214,7 +224,7 @@ I18N_PLAY_FUNCTION(sk, playNumber, getvalue_t number, uint8_t unit, uint8_t att)
} }
if (unit) { if (unit) {
SK_PUSH_UNIT_PROMPT(tmp, (SK_PROMPT_UNITS_BASE+((unit-1)*4))); SK_PUSH_UNIT_PROMPT(tmp, unit);
} }
} }
@ -228,17 +238,17 @@ I18N_PLAY_FUNCTION(sk, playDuration, int seconds PLAY_DURATION_ATT)
uint8_t tmp = seconds / 3600; uint8_t tmp = seconds / 3600;
seconds %= 3600; seconds %= 3600;
if (tmp > 0 || IS_PLAY_TIME()) { if (tmp > 0 || IS_PLAY_TIME()) {
PLAY_NUMBER(tmp, UNIT_HOURS+1, ZENSKY); PLAY_NUMBER(tmp, UNIT_HOURS, ZENSKY);
} }
tmp = seconds / 60; tmp = seconds / 60;
seconds %= 60; seconds %= 60;
if (tmp > 0) { if (tmp > 0) {
PLAY_NUMBER(tmp, UNIT_MINUTES+1, ZENSKY); PLAY_NUMBER(tmp, UNIT_MINUTES, ZENSKY);
} }
if (seconds > 0) { if (seconds > 0) {
PLAY_NUMBER(seconds, UNIT_SECONDS+1, ZENSKY); PLAY_NUMBER(seconds, UNIT_SECONDS, ZENSKY);
} }
} }

View file

@ -17,36 +17,34 @@ for i, s in enumerate(["sto", u"dvěsta", u"třista", u"čtyřista", u"pětset",
systemSounds.append((s, filename(PROMPT_SYSTEM_BASE + 100 + i))) systemSounds.append((s, filename(PROMPT_SYSTEM_BASE + 100 + i)))
for i, s in enumerate([u"tisíce", "jeden", "jedno", u"dvě", u"celá", u"celé", u"celých", u"mínus"]): for i, s in enumerate([u"tisíce", "jeden", "jedno", u"dvě", u"celá", u"celé", u"celých", u"mínus"]):
systemSounds.append((s, filename(PROMPT_SYSTEM_BASE + 110 + i))) systemSounds.append((s, filename(PROMPT_SYSTEM_BASE + 110 + i)))
for i, (s, f) in enumerate([(u"volt", u"volt0"), (u"volty", u"volt1"), (u"voltů", u"volt2"),(u"voltu", u"volt3"),
for i, s in enumerate(["volt", "volty", u"voltů", "voltu", (u"ampér", "amp0"), (u"ampéry", u"amp1"), (u"ampérů", u"amp2"), (u"ampéru", u"amp3"),
u"ampér", u"ampéry", u"ampérů", u"ampéru", (u"miliampér", "mamp0"), (u"miliampéry", u"mamp1"), (u"miliampérů", u"mamp2"), (u"miliampéru", u"mamp3"),
u"miliampér", u"miliampéry", u"miliampérů", u"miliampéru", (u"uzel", "knot0"), (u"uzly", u"knot1"), (u"uzlů", u"knot2"), (u"uzlu", u"knot3"),
u"uzel", u"uzly", u"uzlů", u"uzlu", (u"metr za sekundu", "mps0"), (u"metry za sekundu", u"mps1"), (u"metrů za sekundu", u"mps2"), (u"metru za sekundu", u"mps3"),
"metr za sekundu", "metry za sekundu", u"metrů za sekundu", "metru za sekundu", (u"stopa za sekundu", "fps0"), (u"stopy za sekundu", u"fps1"), (u"stop za sekundu", u"fps2"), (u"stopy za sekundu", u"fps3"),
"stopa za sekundu", "stopy za sekundu", "stop za sekundu", "stopy za sekundu", (u"kilometr za hodinu", "kph0"), (u"kilometry za hodinu", u"kph1"), (u"kilometrů za hodinu", u"kph2"), (u"kilometru za hodinu", u"kph3"),
"kilometr za hodinu", "kilometry za hodinu", u"kilometrů za hodinu", "kilometru za hodinu", (u"míle za hodinu", "mph0"), (u"míle za hodinu", u"mph1"), (u"mil za hodinu", u"mph2"), (u"míle za hodinu", u"mph3"),
u"míle za hodinu", u"míle za hodinu", u"mil za hodinu", u"míle za hodinu", (u"metr", "meter0"), (u"metry", u"meter1"), (u"metrů", u"meter2"), (u"metru", u"meter3"),
"metr", "metry", u"metrů", "metru", (u"stopa", "foot0"), (u"stopy", u"foot1"), (u"stop", u"foot2"),(u"stopy", u"foot3"),
"stopa", "stopy", "stop", "stopy", (u"stupeň celsia", "celsius0"), (u"stupně celsia", u"celsius1"), (u"stupňů celsia", u"celsius2"), (u"stupně celsia", u"celsius3"),
u"stupeň celsia", u"stupně celsia", u"stupňů celsia", u"stupně celsia", (u"stupeň fahrenheita", "fahr0"), (u"stupně fahrenheita", u"fahr1"), (u"stupňů fahrenheita", u"fahr2"), (u"stupně fahrenheita", u"fahr3"),
u"stupeň fahrenheita", u"stupně fahrenheita", u"stupňů fahrenheita", u"stupně fahrenheita", (u"procento", "percent0"), (u"procenta", u"percent1"), (u"procent", u"percent2"), (u"procenta", u"percent3"),
"procento", "procenta", "procent", "procenta", (u"miliampérhodina", "mamph0"), (u"miliampérhodiny", u"mamph1"), (u"miliampérhodin", u"mamph2"), (u"miliampérhodiny", u"mamph3"),
u"miliampérhodina", u"miliampérhodiny", u"miliampérhodin", u"miliampérhodiny", (u"vat", "watt0"), (u"vaty", u"watt1"), (u"vatů", u"watt2"), (u"vatu", u"watt3"),
"vat", "vaty", u"vatů", "vatu", (u"milivat", "mwatt0"), (u"milivaty", u"mwatt1"), (u"milivatů", u"mwatt2"), (u"milivatu", u"mwatt3"),
"milivat", "milivaty", u"milivatů", "milivatu", (u"decibel", "db0"), (u"decibely", u"db1"), (u"decibelů", u"db2"), (u"decibelu", u"db3"),
"decibel", "decibely", u"decibelů", "decibelu", (u"otáčka za minutu", "rpm0"), (u"otáčky za minutu", u"rpm1"), (u"otáček za minutu", u"rpm2"), (u"otáčky za minutu", u"rpm3"),
u"otáčka za minutu", u"otáčky za minutu", u"otáček za minutu", u"otáčky za minutu", (u"", "g0"), (u"", "g1"), (u"", "g2"), (u"", "g3"),
u"", u"", u"", u"" (u"stupeň", "degree0"), (u"stupně", u"degree1"), (u"stupňů", u"degree2"), (u"stupně", u"degree3"),
u"stupeň", u"stupně", u"stupňů", u"stupně", (u"radián", "rad0"), (u"radiány", "rad1"), (u"radiánů", "rad2"), (u"radiánu", "rad3"),
u"", u"", u"", u"", (u"mililitr", "ml0"), (u"mililitry", u"ml1"), (u"mililitrů", u"ml2"), (u"mililitru", u"ml3"),
u"mililitr", u"mililitry", u"mililitrů", "mililitru", (u"dutá unce", "founce0"), (u"duté unce", u"founce1"), (u"dutých uncí", u"founce2"), (u"duté unce", u"founce3"),
u"dutá unce", u"duté unce", u"dutých uncí", u"duté unce", (u"hodina", "hour0"), (u"hodiny", u"hour1"), (u"hodin", u"hour2"), (u"hodiny", u"hour3"),
"hodina", "hodiny", "hodin", "hodiny", (u"minuta", "minute0"), (u"minuty", u"minute1"), (u"minut", u"minute2"), (u"minuty", u"minute3"),
"minuta", "minuty", "minut", "minuty", (u"sekunda", "second0"), (u"sekundy", u"second1"), (u"sekund", u"second2"), (u"sekundy", u"second3"),
"sekunda", "sekundy", "sekund", "sekundy", ]):
]): systemSounds.append((s, filename(f, PROMPT_SYSTEM_BASE + 118 + i)))
systemSounds.append((s, filename(PROMPT_SYSTEM_BASE + 118 + i)))
for s, f, a in [(u"střed trimu", "midtrim", 495), for s, f, a in [(u"střed trimu", "midtrim", 495),
(u"maximum trimu", "endtrim", NO_ALTERNATE), (u"maximum trimu", "endtrim", NO_ALTERNATE),
(u"baterie rádia je vybitá", "lowbatt", 485), (u"baterie rádia je vybitá", "lowbatt", 485),

View file

@ -13,13 +13,34 @@ for i in range(101):
systemSounds.append(("tausend", filename(PROMPT_SYSTEM_BASE + 101))) systemSounds.append(("tausend", filename(PROMPT_SYSTEM_BASE + 101)))
for i, s in enumerate(["comma", "und", "minus", "uhr", "minute", "minuten", "sekunde", "sekunden"]): for i, s in enumerate(["comma", "und", "minus", "uhr", "minute", "minuten", "sekunde", "sekunden"]):
systemSounds.append((s, filename(PROMPT_SYSTEM_BASE + 102 + i))) systemSounds.append((s, filename(PROMPT_SYSTEM_BASE + 102 + i)))
for i, s in enumerate(["", "Volt", "Ampere", "MilliAmpere", "Knoten", for i, (s, f) in enumerate([(u"Volt","volt0"),
"Meter pro sekunde", "Fuesse pro sekunde", (u"Ampere", "amp0"),
"kilometer pro stunde", "Meilen pro Stunde", "Meter", (u"MilliAmpere", "mamp0"),
"Fuesse", "Grad", "Grad Fahrenheit", "Prozent", (u"Knoten", "knot0"),
"Milliampere pro stunde", "Watt", "Milli Watt", "db", "R P M", "g", "degree", "radians", (u"Meter pro sekunde", "mps0"),
"Milliliter", "Unze", "Uhr", "Minuten", "Secunden"]): (u"Fuesse pro sekunde", "fps0"),
systemSounds.append((s, filename(PROMPT_SYSTEM_BASE + 110 + i))) (u"kilometer pro stunde", "kph0"),
(u"Meilen pro Stunde", "mph0"),
(u"Meter", "meter0"),
(u"Fuesse", "foot0"),
(u"Grad", "celsius0"),
(u"Grad Fahrenheit", "fahr0"),
(u"Prozent", "percent0"),
(u"mMilliampere pro stunde", "mamps0"),
(u"Watt", "watt0"),
(u"Milli Watt", "mwatt0"),
(u"db", "db0"),
(u"R P M", "rpm0"),
(u"g", "g0"),
(u"degree", "degree0"),
(u"radians", "rad0"),
(u"Milliliter", "ml0"),
(u"Unze", "founce0"),
(u"Uhr", "hour0"),
(u"Minuten", "minute0"),
(u"Secunden", "second0"),
]):
systemSounds.append((s, filename(f, PROMPT_SYSTEM_BASE + 110 + i)))
for s, f, a in [(u"Sender ist inaktiv,bitte Ueberpruefen Sie", "inactiv", 486), for s, f, a in [(u"Sender ist inaktiv,bitte Ueberpruefen Sie", "inactiv", 486),
(u"Senderakku niedrig", "lowbatt", 485), (u"Senderakku niedrig", "lowbatt", 485),
(u"Gaskanal nicht Null, bitte pruefen", "thralert", 481), (u"Gaskanal nicht Null, bitte pruefen", "thralert", 481),

View file

@ -14,34 +14,34 @@ for i in range(9):
systemSounds.append((str(100 * (i + 1)), filename(PROMPT_SYSTEM_BASE + 100 + i))) systemSounds.append((str(100 * (i + 1)), filename(PROMPT_SYSTEM_BASE + 100 + i)))
for i, s in enumerate(["thousand", "and", "minus", "point"]): for i, s in enumerate(["thousand", "and", "minus", "point"]):
systemSounds.append((s, filename(PROMPT_SYSTEM_BASE + 109 + i))) systemSounds.append((s, filename(PROMPT_SYSTEM_BASE + 109 + i)))
for i, s in enumerate(["volt", "volts", for i, (s, f) in enumerate([("volt", "volt0"), ("volts", "volt1"),
"amp", "amps", ("amp", "amp0"), ("amps", "amp1"),
"milliamp", "milliamps", ("milliamp", "mamp0"), ("milliamps", "mamp1"),
"knot", "knots", ("knot", "knot0"), ("knots", "knot1"),
"meter per second", "meters per second", ("meter per second", "mps0"), ("meters per second", "mps1"),
"foot per second", "feet per second", ("foot per second", "fps0"), ("feet per second", "fps1"),
"kilometer per hour", "kilometers per hour", ("kilometer per hour", "kph0"), ("kilometers per hour", "kph1"),
"mile per hour", "miles per hour", ("mile per hour", "mph0"), ("miles per hour", "mph1"),
"meter", "meters", ("meter", "meter0"), ("meters", "meter1"),
"foot", "feet", ("foot", "foot0"), ("feet", "foot1"),
"degree celsius", "degrees celsius", ("degree celsius", "celsius0"), ("degrees celsius", "celsius1"),
"degree fahrenheit", "degrees fahrenheit", ("degree fahrenheit", "fahr0"), ("degrees fahrenheit", "fahr1"),
"percent", "percent", ("percent", "percent0"),
"milliamp-hour", "milliamp-hours", ("milliamp-hour", "mamph0"), ("milliamp-hours", "mamph1"),
"watt", "watts", ("watt", "watt0"), ("watts", "watt1"),
"milli-watt", "milli-watts", ("milli-watt", "mwatt0"), ("milli-watts", "mwatt1"),
"db", "db", ("db", "db0"),
"r p m", "r p m", ("r p m", "rpm0"),
"g", "g", ("g", "g0"),
"degree", "degrees", ("degree", "degree0"), ("degrees", "degree1"),
"radian", "radians", ("radian", "rad0"), ("radians", "rad1"),
"milliliter", "milliliters", ("milliliter", "ml0"), ("milliliters", "ml1"),
"fluid ounce", "fluid ounces", ("fluid ounce", "founce0"), ("fluid ounces", "founce1"),
"hour", "hours", ("hour", "hour0"), ("hours", "hour1"),
"minute", "minutes", ("minute", "minute0"), ("minutes", "minute1"),
"second", "seconds", ("second", "second0"), ("seconds", "second1"),
]): ]):
systemSounds.append((s, filename(PROMPT_SYSTEM_BASE + 115 + i))) systemSounds.append((s, filename(f, PROMPT_SYSTEM_BASE + 115 + i)))
for i, s in enumerate(["point zero", "point one", "point two", "point three", for i, s in enumerate(["point zero", "point one", "point two", "point three",
"point four", "point five", "point six", "point four", "point five", "point six",
"point seven", "point eight", "point nine"]): "point seven", "point eight", "point nine"]):

View file

@ -22,8 +22,34 @@ systemSounds.append(("nuevecientos", filename(PROMPT_SYSTEM_BASE + 109)))
systemSounds.append(("mil", filename(PROMPT_SYSTEM_BASE + 110))) systemSounds.append(("mil", filename(PROMPT_SYSTEM_BASE + 110)))
for i, s in enumerate(["coma", "un", "una", "y", "meno", "hora", "horas", "minuto", "minutos", "segundo", "segundos"]): for i, s in enumerate(["coma", "un", "una", "y", "meno", "hora", "horas", "minuto", "minutos", "segundo", "segundos"]):
systemSounds.append((s, filename(PROMPT_SYSTEM_BASE + 111 + i))) systemSounds.append((s, filename(PROMPT_SYSTEM_BASE + 111 + i)))
for i, s in enumerate([u"Voltio", u"ampério", u"metros por segundo", u"", u"kilómetro por hora", u"metros", u"grados", u"por ciento", u"miliamperios", u"miliamperios por hora", u"vatio", u"db", u"pés", u"nós", u"horas", u"minutos", u"segundos", u"RPM", u"g", u"mililitro", u"onzas"]): for i, (s, f) in enumerate([(u"Voltio","volt0"),
systemSounds.append((s, filename(PROMPT_SYSTEM_BASE + 122 + i))) (u"ampério", "amp0"),
(u"miliamperios", "mamp0"),
(u"knots", "knot0"),
(u"metros por segundo", "mps0"),
(u"pie por segundo", "fps0"),
(u"kilómetro por hora", "kph0"),
(u"millas por hora", "mph0"),
(u"metros", "meter0"),
(u"pie", "foot0"),
(u"grados", "celsius0"),
(u"fahrenheit", "fahr0"),
(u"por ciento", "percent0"),
(u"miliamperios por hora", "mamph0"),
(u"vatio", "watt0"),
(u"millivatio", "mwatt0"),
(u"db", "db0"),
(u"RPM", "rpm0"),
(u"g", "g0"),
(u"grados", "degree0"),
(u"radianes ", "rad0"),
(u"mililitro", "ml0"),
(u"onzas", "founce0"),
(u"horas", "hour0"),
(u"minutos", "minute0"),
(u"segundos", "second0"),
]):
systemSounds.append((s, filename(f, PROMPT_SYSTEM_BASE + 122 + i)))
for s, f, a in [(u"me tienes abandonada", "inactiv", 486), for s, f, a in [(u"me tienes abandonada", "inactiv", 486),
(u"batería del transmisor baja", "lowbatt", 485), (u"batería del transmisor baja", "lowbatt", 485),
(u"El acelerador está activado, por favor, corrijalo", "thralert", 481), (u"El acelerador está activado, por favor, corrijalo", "thralert", 481),

View file

@ -15,34 +15,34 @@ for i, s in enumerate(["une", "onze", "vingt et une", "trente et une", "quarante
systemSounds.append((s, filename(PROMPT_SYSTEM_BASE + 110 + i))) systemSounds.append((s, filename(PROMPT_SYSTEM_BASE + 110 + i)))
for i, s in enumerate(["virgule", "et", "moins", "minuit", "midi"]): for i, s in enumerate(["virgule", "et", "moins", "minuit", "midi"]):
systemSounds.append((s, filename(PROMPT_SYSTEM_BASE + 119 + i))) systemSounds.append((s, filename(PROMPT_SYSTEM_BASE + 119 + i)))
for i, s in enumerate([u"volts", for i, (s, f) in enumerate([(u"volts","volt0"),
u"ampères", (u"ampères", "amp0"),
u"milli ampères", (u"milli ampères", "mamp0"),
u"knots", (u"knots", "knot0"),
u"mètres seconde", (u"mètres seconde", "mps0"),
u"pieds par seconde", (u"pieds par seconde", "fps0"),
u"kilomètre heure", (u"kilomètre heure", "kph0"),
u"miles par heure", (u"miles par heure", "mph0"),
u"mètres", (u"mètres", "meter0"),
u"pieds", (u"pieds", "foot0"),
u"degrés", (u"degrés", "celsius0"),
u"degrés fahrenheit", (u"degrés fahr", "degf0"),
u"pourcents", (u"pourcents", "percent0"),
u"milli ampères / heure", (u"milli ampères heure", "mamph0"),
u"watt", (u"watt", "watt0"),
u"milli watt", (u"milli watt", "mwatt0"),
u"db", (u"db", "db0"),
u"tours minute", (u"tours minute", "rpm0"),
u"g", (u"g", "g0"),
u"degrés", (u"degrés", "degree0"),
u"radians", (u"radians", "rad0"),
u"millilitres", (u"millilitres", "ml0"),
u"onces", (u"onces", "founce0"),
u"heure", (u"heure", "hour0"),
u"minute", (u"minute", "minute0"),
u"seconde" (u"seconde", "second0"),
]): ]):
systemSounds.append((s, filename(PROMPT_SYSTEM_BASE + 125 + i))) systemSounds.append((s, filename(f, PROMPT_SYSTEM_BASE + 125 + i)))
for i, s in enumerate(["virgule 0", "virgule 1", "virgule 2", "virgule 3", "virgule 4", "virgule 5", "virgule 6", "virgule 7", "virgule 8", "virgule 9"]): for i, s in enumerate(["virgule 0", "virgule 1", "virgule 2", "virgule 3", "virgule 4", "virgule 5", "virgule 6", "virgule 7", "virgule 8", "virgule 9"]):
systemSounds.append((s, filename(PROMPT_SYSTEM_BASE + 180 + i))) systemSounds.append((s, filename(PROMPT_SYSTEM_BASE + 180 + i)))
for s, f, a in [(u"Trim centré", "midtrim", 495), for s, f, a in [(u"Trim centré", "midtrim", 495),

View file

@ -14,29 +14,34 @@ systemSounds.append(("mila", filename(PROMPT_SYSTEM_BASE + 101)))
systemSounds.append(("mille", filename(PROMPT_SYSTEM_BASE + 102))) systemSounds.append(("mille", filename(PROMPT_SYSTEM_BASE + 102)))
for i, s in enumerate(["virgola", "un", "e", "meno", "ora", "ore", "minuto", "minuti", "secondo", "secondi"]): for i, s in enumerate(["virgola", "un", "e", "meno", "ora", "ore", "minuto", "minuti", "secondo", "secondi"]):
systemSounds.append((s, filename(PROMPT_SYSTEM_BASE + 103 + i))) systemSounds.append((s, filename(PROMPT_SYSTEM_BASE + 103 + i)))
for i, s in enumerate(["", "", for i, (s, f) in enumerate([(u"volt", "volt0"),
"volt", "volt", (u"ampere", "amp0"),
"ampere", "ampere", (u"milliampers", "mamp0"),
"milliampers", "milliampers", (u"nodo", "knot0"), ("nodi", "knot1"),
"nodo", "nodi", (u"metro al secondo", "mps0"), ("metri al secondo", "msp1"),
"metro al secondo", "metri al secondo", (u"piede al secondo", "fps0"), ("piedi al secondo", "fps1"),
"piede al secondo", "piedi al secondo", (u"chilometro ora", "kph0"), ("kilometers per hour", "kph1"),
"chilometro ora", "chilometri ora", (u"miglio per ora", "mph0"), ("miglia per ora", "mph1"),
"miglio per ora", "miglia per ora", (u"metro", "meter0"), ("metri", "meter1"),
"metro", "metri", (u"piede", "foot0"), ("piedi", "foot1"),
"piede", "piedi", (u"grado celsius", "celsius0"), ("gradi celsius", "celsius1"),
"grado celsius", "gradi celsius", (u"grado fahrenheit", "fahr0"), ("gradi fahrenheit", "fahr1"),
"grado fahrenheit", "gradi fahrenheit", (u"percento", "percent0"),
"percento", "percento", (u"milliampere ora", "mamph0"),
"milliampere ora", "milliampere ora", (u"watt", "watt0"),
"watt", "watt", (u"milli-watt", "mwatt0"), ("milli-watts", "mwatt1"),
"decibel", "decibel", (u"db", "db0"),
"R P M", "R P M", (u"r p m", "rpm0"),
"g", "g", (u"g", "g0"),
"grado", "gradi", (u"grado", "degree0"), ("gradi", "degree1"),
"millilitro", "millilitri", (u"radian", "rad0"), ("radians", "rad1"),
"oncia", "once"]): (u"millilitro", "m10"), ("millilitri", "m11"),
systemSounds.append((s, filename(PROMPT_SYSTEM_BASE + 113 + i))) (u"oncia", "founce0"), ("once", "founce1"),
(u"hour", "hour0"), ("hours", "hour1"),
(u"minute", "minute0"), ("minutes", "minute1"),
(u"second", "second0"), ("seconds", "second1"),
]):
systemSounds.append((s, filename(f, PROMPT_SYSTEM_BASE + 113 + i)))
for s, f, a in [(u"radio inattiva controllare", "inactiv", 486), for s, f, a in [(u"radio inattiva controllare", "inactiv", 486),
(u"batteria della radio scarica", "lowbatt", 485), (u"batteria della radio scarica", "lowbatt", 485),
(u"controllo motore non in posizione, verificare", "thralert", 481), (u"controllo motore non in posizione, verificare", "thralert", 481),

View file

@ -22,8 +22,34 @@ systemSounds.append(("novecentos", filename(PROMPT_SYSTEM_BASE + 109)))
systemSounds.append(("mil", filename(PROMPT_SYSTEM_BASE + 110))) systemSounds.append(("mil", filename(PROMPT_SYSTEM_BASE + 110)))
for i, s in enumerate(["virgula", "uma", "duas", "e", "menos", "hora", "horas", "minuto", "minutos", "segundo", "segundos"]): for i, s in enumerate(["virgula", "uma", "duas", "e", "menos", "hora", "horas", "minuto", "minutos", "segundo", "segundos"]):
systemSounds.append((s, filename(PROMPT_SYSTEM_BASE + 111 + i))) systemSounds.append((s, filename(PROMPT_SYSTEM_BASE + 111 + i)))
for i, s in enumerate([u"Volt", u"ampére", u"metros por segundo", u"", u"quilômetros por hora", u"metros", u"graus", u"cento", u"miliamperes", u"miliamperes por hora", u"watt", u"db", u"pés", u"nós", u"horas", u"minutos", u"segundos", u"RPM", u"g", u"mililitri", u"onças"]): for i, (s, f) in enumerate([("Volt", "volt0"),
systemSounds.append((s, filename(PROMPT_SYSTEM_BASE + 122 + i))) ("ampére", "amp0"),
("miliamperes", "mamp0"),
("knot", "knot0"),
("metros por segundo", "mps0"),
("foot per second", "fps0"),
("quilômetros por hora", "kph0"),
("mile per hour", "mph0"),
("metros", "meter0"),
("foot", "foot0"),
("degree celsius", "celsius0"),
("degree fahrenheit", "fahr0"),
("percent", "percent0"),
("miliamperes por hora", "mamph0"),
("watt", "watt0"),
("milli-watt", "mwatt0"),
("db", "db0"),
("r p m", "rpm0"),
("g", "g0"),
("degree", "degree0"),
("radian", "rad0"),
("milliliter", "ml0"),
("onças", "founce0"),
("horas", "hour0"),
("minutos", "minute0"),
("segundos", "second0"),
]):
systemSounds.append((s, filename(f, PROMPT_SYSTEM_BASE + 122 + i)))
for s, f, a in [(u"atenção, o rádio foi esquecido ligado, por favor desligue-o", "inactiv", 486), for s, f, a in [(u"atenção, o rádio foi esquecido ligado, por favor desligue-o", "inactiv", 486),
(u"bateria do rádio fraca", "lowbatt", 485), (u"bateria do rádio fraca", "lowbatt", 485),
(u"atenção,acelerador não está no mínimo", "thralert", 481), (u"atenção,acelerador não está no mínimo", "thralert", 481),