diff --git a/speaker/.gitignore b/speaker/.gitignore
new file mode 100644
index 000000000..3e3980000
--- /dev/null
+++ b/speaker/.gitignore
@@ -0,0 +1 @@
+/OpenTXspeak.suo
diff --git a/speaker/App.xaml b/speaker/App.xaml
new file mode 100644
index 000000000..c38764331
--- /dev/null
+++ b/speaker/App.xaml
@@ -0,0 +1,8 @@
+
+
+
+
+
diff --git a/speaker/App.xaml.cs b/speaker/App.xaml.cs
new file mode 100644
index 000000000..b6053db6e
--- /dev/null
+++ b/speaker/App.xaml.cs
@@ -0,0 +1,16 @@
+using System;
+using System.Collections.Generic;
+using System.Configuration;
+using System.Data;
+using System.Linq;
+using System.Windows;
+
+namespace OpenTXspeak
+{
+ ///
+ /// Interaction logic for App.xaml
+ ///
+ public partial class App : Application
+ {
+ }
+}
diff --git a/speaker/MainWindow.xaml b/speaker/MainWindow.xaml
new file mode 100644
index 000000000..ca5ce1fbc
--- /dev/null
+++ b/speaker/MainWindow.xaml
@@ -0,0 +1,118 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/speaker/MainWindow.xaml.cs b/speaker/MainWindow.xaml.cs
new file mode 100644
index 000000000..09f97b600
--- /dev/null
+++ b/speaker/MainWindow.xaml.cs
@@ -0,0 +1,198 @@
+using System;
+using System.IO;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Windows;
+using System.Windows.Controls;
+using System.Windows.Data;
+using System.Windows.Documents;
+using System.Windows.Input;
+using System.Windows.Media;
+using System.Windows.Media.Imaging;
+using System.Windows.Navigation;
+using System.Windows.Shapes;
+using System.Speech.Synthesis;
+using System.Speech.AudioFormat;
+
+namespace OpenTXspeak
+{
+ public partial class MainWindow : Window
+ {
+ SentenceTables tables = new SentenceTables();
+ Languages languages = new Languages();
+ Language curLang;
+ Sentences sentences = new Sentences();
+ SpeechSynthesizer synth = new SpeechSynthesizer();
+ int added_files = 0;
+
+ public MainWindow()
+ {
+ InitializeComponent();
+ lvSentences.ItemsSource = sentences;
+ cbLanguages.ItemsSource = languages;
+
+ foreach (InstalledVoice voice in synth.GetInstalledVoices())
+ {
+ cbVoices.Items.Add(voice.VoiceInfo.Name);
+ }
+ cbVoices.SelectedIndex = 0;
+
+ languages.Add("English", "en");
+ languages.Add("Italian", "it");
+ languages.Add("Swedish", "se");
+ curLang = languages[0];
+ cbLanguages.SelectedIndex = 0; // Note: Sets current langugage -> triggers loadlanguage()
+ }
+
+ private void loadLanguage()
+ {
+ string[] system_strings;
+ string[] other_strings;
+
+ try
+ {
+ system_strings = System.IO.File.ReadAllLines(@"SOUNDS\" + curLang.sName + @"\SYSTEM\system_sounds.txt");
+ other_strings = System.IO.File.ReadAllLines(@"SOUNDS\" + curLang.sName + @"\other_sounds.txt");
+ }
+ catch (IOException)
+ {
+ system_strings = tables.default_system_strings[tables.toInt(curLang.sName)];
+ other_strings = tables.default_other_strings[tables.toInt(curLang.sName)];
+ }
+ sentences.RemoveRange(0, sentences.Count);
+
+ foreach (string str in system_strings)
+ sentences.Add(str);
+
+ sentences.Add(@";^ System Sounds ^;");
+
+ foreach (string str in other_strings)
+ sentences.Add(str);
+
+ lvSentences.Items.Refresh(); // Workaround - Two way binding is better
+ }
+
+ private void cbLanguages_SelectionChanged(object sender, SelectionChangedEventArgs e)
+ {
+ curLang = (Language)e.AddedItems[0];
+ loadLanguage();
+ }
+
+ private void lvSentences_MouseDoubleClick(object sender, MouseButtonEventArgs e)
+ {
+ synth.SetOutputToDefaultAudioDevice();
+ synth.Rate = (int)this.voiceRateSlider.Value;
+
+ if (this.lvSentences.SelectedItems.Count < 1)
+ return;
+
+ Sentence sentence = (Sentence)this.lvSentences.SelectedItem;
+ synth.SelectVoice(cbVoices.Text);
+ try { synth.Speak(sentence.voiceString); }
+ catch (Exception){} // Workaround - Some TTS engines crashes on destruction
+ }
+
+ private void openTXLogo_MouseLeftButtonDown(object sender, MouseButtonEventArgs e)
+ {
+ AboutWindow aboutWindow = new AboutWindow();
+ aboutWindow.ShowDialog();
+ }
+
+ private void buttonPlay_Click(object sender, RoutedEventArgs e)
+ {
+ lvSentences_MouseDoubleClick(sender, null);
+ }
+
+ private void buttonAddItem_Click(object sender, RoutedEventArgs e)
+ {
+ added_files++;
+ sentences.Add(new Sentence("new_file_" + added_files.ToString() + ";New Description;New Voice Message"));
+ this.lvSentences.Items.Refresh();
+ this.lvSentences.SelectedIndex = this.lvSentences.Items.Count - 1;
+ this.lvSentences.ScrollIntoView(this.lvSentences.SelectedItem);
+ }
+
+ private void buttonSaveFiles_Click(object sender, RoutedEventArgs e)
+ {
+ Cursor oldCursor = this.Cursor;
+ this.Cursor = Cursors.Wait;
+
+ synth.Rate = (int)this.fileRateSlider.Value;
+
+ int sampleRate = 32000;
+ if ((bool)this.rb16khz.IsChecked)
+ sampleRate = 16000;
+ else if ((bool)this.rb8khz.IsChecked)
+ sampleRate = 8000;
+
+ SpeechAudioFormatInfo audioFormat = new SpeechAudioFormatInfo(sampleRate, AudioBitsPerSample.Sixteen, AudioChannel.Mono);
+
+ System.IO.Directory.CreateDirectory(@"SOUNDS\" + curLang.sName + @"\SYSTEM");
+ StreamWriter sw = File.CreateText(@"SOUNDS\" + curLang.sName + @"\SYSTEM\system_sounds.txt");
+ int i;
+ for (i = 0; sentences[i].fileName != ""; i++)
+ {
+ sw.WriteLine(sentences[i].toRaw());
+ synth.SetOutputToWaveFile(@"SOUNDS\" + curLang.sName + @"\SYSTEM\" + sentences[i].fileName + ".wav", audioFormat);
+ try { synth.Speak(sentences[i].voiceString); }
+ catch (Exception){} // Workaround - Some TTS engines crashes on destruction
+ }
+ sw.Close();
+ sw = File.CreateText(@"SOUNDS\" + curLang.sName + @"\other_sounds.txt");
+ for (i++; i < sentences.Count; i++)
+ {
+ sw.WriteLine(sentences[i].toRaw());
+ synth.SetOutputToWaveFile(@"SOUNDS\" + curLang.sName + @"\" + sentences[i].fileName + ".wav", audioFormat);
+ try { synth.Speak(sentences[i].voiceString); }
+ catch (Exception){} // Workaround - Some TTS engines crashes on destruction
+ }
+ sw.Close();
+ synth.SetOutputToNull(); // Workaround - The synth does not release the sound file like it should
+ this.Cursor = oldCursor;
+ }
+ }
+
+ public class Language
+ {
+ public string lName { get; set; }
+ public string sName { get; set; }
+ }
+
+ public class Languages : List
+ {
+ public void Add(string longer, string shorter)
+ {
+ this.Add(new Language { lName = longer, sName = shorter });
+ }
+ }
+
+ public class Sentence
+ {
+ public string fileName { get; set; }
+ public string description { get; set; }
+ public string voiceString { get; set; }
+
+ public Sentence(string rawString)
+ {
+ string[] words = rawString.Split(';');
+ fileName = words[0];
+ description = words[1];
+ voiceString = words[2];
+ }
+
+ public string toRaw()
+ {
+ return fileName + ";" + description + ";" + voiceString;
+ }
+ }
+
+ public class Sentences : List
+ {
+ public void Add(string rawString)
+ {
+ string[] words = rawString.Split(';');
+ this.Add(new Sentence(rawString));
+ }
+ }
+}
diff --git a/speaker/OpenTXspeak.csproj b/speaker/OpenTXspeak.csproj
new file mode 100644
index 000000000..1cf98833e
--- /dev/null
+++ b/speaker/OpenTXspeak.csproj
@@ -0,0 +1,117 @@
+
+
+
+ Debug
+ x86
+ 8.0.30703
+ 2.0
+ {8143D08D-1861-42DD-A861-56B15DE42A69}
+ WinExe
+ Properties
+ OpenTXspeak
+ OpenTXspeak
+ v4.0
+ Client
+ 512
+ {60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}
+ 4
+
+
+ x86
+ true
+ full
+ false
+ bin\Debug\
+ DEBUG;TRACE
+ prompt
+ 4
+
+
+ x86
+ pdbonly
+ true
+ bin\Release\
+ TRACE
+ prompt
+ 4
+
+
+ icon.ico
+
+
+
+
+
+
+
+
+
+
+
+ 4.0
+
+
+
+
+
+
+
+ MSBuild:Compile
+ Designer
+
+
+ AboutWindow.xaml
+
+
+ App.xaml
+
+
+
+ MSBuild:Compile
+ Designer
+
+
+ MainWindow.xaml
+ Code
+
+
+ Designer
+ MSBuild:Compile
+
+
+
+
+ Code
+
+
+ True
+ True
+ Resources.resx
+
+
+ True
+ Settings.settings
+ True
+
+
+ ResXFileCodeGenerator
+ Resources.Designer.cs
+
+
+ SettingsSingleFileGenerator
+ Settings.Designer.cs
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/speaker/OpenTXspeak.sln b/speaker/OpenTXspeak.sln
new file mode 100644
index 000000000..842f18837
--- /dev/null
+++ b/speaker/OpenTXspeak.sln
@@ -0,0 +1,20 @@
+
+Microsoft Visual Studio Solution File, Format Version 11.00
+# Visual C# Express 2010
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "OpenTXspeak", "OpenTXspeak.csproj", "{8143D08D-1861-42DD-A861-56B15DE42A69}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|x86 = Debug|x86
+ Release|x86 = Release|x86
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {8143D08D-1861-42DD-A861-56B15DE42A69}.Debug|x86.ActiveCfg = Debug|x86
+ {8143D08D-1861-42DD-A861-56B15DE42A69}.Debug|x86.Build.0 = Debug|x86
+ {8143D08D-1861-42DD-A861-56B15DE42A69}.Release|x86.ActiveCfg = Release|x86
+ {8143D08D-1861-42DD-A861-56B15DE42A69}.Release|x86.Build.0 = Release|x86
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+EndGlobal
diff --git a/speaker/Properties/AssemblyInfo.cs b/speaker/Properties/AssemblyInfo.cs
new file mode 100644
index 000000000..f794f125a
--- /dev/null
+++ b/speaker/Properties/AssemblyInfo.cs
@@ -0,0 +1,55 @@
+using System.Reflection;
+using System.Resources;
+using System.Runtime.CompilerServices;
+using System.Runtime.InteropServices;
+using System.Windows;
+
+// General Information about an assembly is controlled through the following
+// set of attributes. Change these attribute values to modify the information
+// associated with an assembly.
+[assembly: AssemblyTitle("OpenTX Speaker")]
+[assembly: AssemblyDescription("This application is used to edit OpenTX voice strings and generate audio files for use in the FrSky Taranis radio.")]
+[assembly: AssemblyConfiguration("")]
+[assembly: AssemblyCompany("Kjell Kernen")]
+[assembly: AssemblyProduct("OpenTX Speaker")]
+[assembly: AssemblyCopyright("Copyright © The OpenTX Team 2014")]
+[assembly: AssemblyTrademark("")]
+[assembly: AssemblyCulture("")]
+
+// Setting ComVisible to false makes the types in this assembly not visible
+// to COM components. If you need to access a type in this assembly from
+// COM, set the ComVisible attribute to true on that type.
+[assembly: ComVisible(false)]
+
+//In order to begin building localizable applications, set
+//CultureYouAreCodingWith in your .csproj file
+//inside a . For example, if you are using US english
+//in your source files, set the to en-US. Then uncomment
+//the NeutralResourceLanguage attribute below. Update the "en-US" in
+//the line below to match the UICulture setting in the project file.
+
+//[assembly: NeutralResourcesLanguage("en-US", UltimateResourceFallbackLocation.Satellite)]
+
+
+[assembly: ThemeInfo(
+ ResourceDictionaryLocation.None, //where theme specific resource dictionaries are located
+ //(used if a resource is not found in the page,
+ // or application resource dictionaries)
+ ResourceDictionaryLocation.SourceAssembly //where the generic resource dictionary is located
+ //(used if a resource is not found in the page,
+ // app, or any theme specific resource dictionaries)
+)]
+
+
+// Version information for an assembly consists of the following four values:
+//
+// Major Version
+// Minor Version
+// Build Number
+// Revision
+//
+// You can specify all the values or you can default the Build and Revision Numbers
+// by using the '*' as shown below:
+// [assembly: AssemblyVersion("1.0.*")]
+[assembly: AssemblyVersion("0.4")]
+[assembly: AssemblyFileVersion("0.4")]
diff --git a/speaker/Properties/Resources.Designer.cs b/speaker/Properties/Resources.Designer.cs
new file mode 100644
index 000000000..a0655403b
--- /dev/null
+++ b/speaker/Properties/Resources.Designer.cs
@@ -0,0 +1,71 @@
+//------------------------------------------------------------------------------
+//
+// This code was generated by a tool.
+// Runtime Version:4.0.30319.18444
+//
+// Changes to this file may cause incorrect behavior and will be lost if
+// the code is regenerated.
+//
+//------------------------------------------------------------------------------
+
+namespace OpenTXspeak.Properties
+{
+
+
+ ///
+ /// A strongly-typed resource class, for looking up localized strings, etc.
+ ///
+ // This class was auto-generated by the StronglyTypedResourceBuilder
+ // class via a tool like ResGen or Visual Studio.
+ // To add or remove a member, edit your .ResX file then rerun ResGen
+ // with the /str option, or rebuild your VS project.
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")]
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
+ internal class Resources
+ {
+
+ private static global::System.Resources.ResourceManager resourceMan;
+
+ private static global::System.Globalization.CultureInfo resourceCulture;
+
+ [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
+ internal Resources()
+ {
+ }
+
+ ///
+ /// Returns the cached ResourceManager instance used by this class.
+ ///
+ [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
+ internal static global::System.Resources.ResourceManager ResourceManager
+ {
+ get
+ {
+ if ((resourceMan == null))
+ {
+ global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("OpenTXspeak.Properties.Resources", typeof(Resources).Assembly);
+ resourceMan = temp;
+ }
+ return resourceMan;
+ }
+ }
+
+ ///
+ /// Overrides the current thread's CurrentUICulture property for all
+ /// resource lookups using this strongly typed resource class.
+ ///
+ [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
+ internal static global::System.Globalization.CultureInfo Culture
+ {
+ get
+ {
+ return resourceCulture;
+ }
+ set
+ {
+ resourceCulture = value;
+ }
+ }
+ }
+}
diff --git a/speaker/Properties/Resources.resx b/speaker/Properties/Resources.resx
new file mode 100644
index 000000000..af7dbebba
--- /dev/null
+++ b/speaker/Properties/Resources.resx
@@ -0,0 +1,117 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ text/microsoft-resx
+
+
+ 2.0
+
+
+ System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
+ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
\ No newline at end of file
diff --git a/speaker/Properties/Settings.Designer.cs b/speaker/Properties/Settings.Designer.cs
new file mode 100644
index 000000000..41fee29f5
--- /dev/null
+++ b/speaker/Properties/Settings.Designer.cs
@@ -0,0 +1,30 @@
+//------------------------------------------------------------------------------
+//
+// This code was generated by a tool.
+// Runtime Version:4.0.30319.18444
+//
+// Changes to this file may cause incorrect behavior and will be lost if
+// the code is regenerated.
+//
+//------------------------------------------------------------------------------
+
+namespace OpenTXspeak.Properties
+{
+
+
+ [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "10.0.0.0")]
+ internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase
+ {
+
+ private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
+
+ public static Settings Default
+ {
+ get
+ {
+ return defaultInstance;
+ }
+ }
+ }
+}
diff --git a/speaker/Properties/Settings.settings b/speaker/Properties/Settings.settings
new file mode 100644
index 000000000..033d7a5e9
--- /dev/null
+++ b/speaker/Properties/Settings.settings
@@ -0,0 +1,7 @@
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/speaker/aboutWindow.xaml b/speaker/aboutWindow.xaml
new file mode 100644
index 000000000..4445e167f
--- /dev/null
+++ b/speaker/aboutWindow.xaml
@@ -0,0 +1,27 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/speaker/aboutWindow.xaml.cs b/speaker/aboutWindow.xaml.cs
new file mode 100644
index 000000000..a7597e2c7
--- /dev/null
+++ b/speaker/aboutWindow.xaml.cs
@@ -0,0 +1,39 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Reflection;
+using System.Text;
+using System.Windows;
+using System.Windows.Controls;
+using System.Windows.Data;
+using System.Windows.Documents;
+using System.Windows.Input;
+using System.Windows.Media;
+using System.Windows.Media.Imaging;
+using System.Windows.Shapes;
+
+namespace OpenTXspeak
+{
+ public partial class AboutWindow : Window
+ {
+ public AboutWindow()
+ {
+ InitializeComponent();
+ Assembly app = Assembly.GetExecutingAssembly();
+
+ AssemblyTitleAttribute title = (AssemblyTitleAttribute)app.GetCustomAttributes(typeof(AssemblyTitleAttribute), false)[0];
+ AssemblyProductAttribute product = (AssemblyProductAttribute)app.GetCustomAttributes(typeof(AssemblyProductAttribute), false)[0];
+ AssemblyCopyrightAttribute copyright = (AssemblyCopyrightAttribute)app.GetCustomAttributes(typeof(AssemblyCopyrightAttribute), false)[0];
+ AssemblyCompanyAttribute company = (AssemblyCompanyAttribute)app.GetCustomAttributes(typeof(AssemblyCompanyAttribute), false)[0];
+ AssemblyDescriptionAttribute description = (AssemblyDescriptionAttribute)app.GetCustomAttributes(typeof(AssemblyDescriptionAttribute), false)[0];
+ Version version = app.GetName().Version;
+
+ this.Title = String.Format("About {0}", title.Title);
+ this.lblProductName.Content = product.Product;
+ this.lblVersion.Content = String.Format("Version {0}", version.ToString());
+ this.lblCopyright.Content = copyright.Copyright.ToString();
+ this.lblCompanyName.Content = company.Company;
+ this.description.Text = description.Description;
+ }
+ }
+}
diff --git a/speaker/icon.ico b/speaker/icon.ico
new file mode 100644
index 000000000..e81c703b7
Binary files /dev/null and b/speaker/icon.ico differ
diff --git a/speaker/sentencetables.cs b/speaker/sentencetables.cs
new file mode 100644
index 000000000..e9b65a4cd
--- /dev/null
+++ b/speaker/sentencetables.cs
@@ -0,0 +1,698 @@
+using System;
+using System.Collections.Generic;
+using System.Configuration;
+using System.Data;
+using System.Linq;
+using System.Windows;
+
+namespace OpenTXspeak
+{
+ public class SentenceTables
+ {
+ private static string[] default_en_system_strings =
+ { "0000;0;0",
+ "0001;1;1",
+ "0002;2;2",
+ "0003;3;3",
+ "0004;4;4",
+ "0005;5;5",
+ "0006;6;6",
+ "0007;7;7",
+ "0008;8;8",
+ "0009;9;9",
+ "0010;10;10",
+ "0011;11;11",
+ "0012;12;12",
+ "0013;13;13",
+ "0014;14;14",
+ "0015;15;15",
+ "0016;16;16",
+ "0017;17;17",
+ "0018;18;18",
+ "0019;19;19",
+ "0020;20;20",
+ "0021;21;21",
+ "0022;22;24",
+ "0023;23;23",
+ "0024;24;24",
+ "0025;25;25",
+ "0026;26;26",
+ "0027;27;27",
+ "0028;28;28",
+ "0029;29;29",
+ "0030;30;30",
+ "0031;31;31",
+ "0032;32;32",
+ "0033;33;33",
+ "0034;34;34",
+ "0035;35;35",
+ "0036;36;36",
+ "0037;37;37",
+ "0038;38;38",
+ "0039;39;39",
+ "0040;40;40",
+ "0041;41;41",
+ "0042;42;42",
+ "0043;43;43",
+ "0044;44;44",
+ "0045;45;45",
+ "0046;46;46",
+ "0047;47;47",
+ "0048;48;48",
+ "0049;49;49",
+ "0050;50;50",
+ "0051;51;51",
+ "0052;52;52",
+ "0053;53;53",
+ "0054;54;54",
+ "0055;55;55",
+ "0056;56;56",
+ "0057;57;57",
+ "0058;58;58",
+ "0059;59;59",
+ "0060;60;60",
+ "0061;61;61",
+ "0062;62;62",
+ "0063;63;63",
+ "0064;64;64",
+ "0065;65;65",
+ "0066;66;66",
+ "0067;67;67",
+ "0068;68;68",
+ "0069;69;69",
+ "0070;70;70",
+ "0071;71;71",
+ "0072;72;72",
+ "0073;73;73",
+ "0074;74;74",
+ "0075;75;75",
+ "0076;76;76",
+ "0077;77;77",
+ "0078;78;78",
+ "0079;79;79",
+ "0080;80;80",
+ "0081;81;81",
+ "0082;82;82",
+ "0083;83;83",
+ "0084;84;84",
+ "0085;85;85",
+ "0086;86;86",
+ "0087;87;87",
+ "0088;88;88",
+ "0089;89;89",
+ "0090;90;90",
+ "0091;91;91",
+ "0092;92;92",
+ "0093;93;93",
+ "0094;94;94",
+ "0095;95;95",
+ "0096;96;96",
+ "0097;97;97",
+ "0098;98;98",
+ "0099;99;99",
+ "0100;100;100",
+ "0101;200;200",
+ "0102;300;300",
+ "0103;400;400",
+ "0104;500;500",
+ "0105;600;600",
+ "0106;700;700",
+ "0107;800;800",
+ "0108;900;900",
+ "0109;thousand;thousand",
+ "0111;minus;minus",
+ "0112;point;point",
+ "0115;volt;volt",
+ "0116;volts;volts",
+ "0117;amp;ampere",
+ "0118;amps;ampere",
+ "0119;meter per second;meter per second",
+ "0120;meters per second;meters per second",
+ "0123;kmh;k-m-h",
+ "0124;kmh;k-m-h",
+ "0125;meter;meter",
+ "0126;meters;meters",
+ "0127;degree;degree",
+ "0128;degrees;degrees",
+ "0129;percent;percent",
+ "0130;percent;percent",
+ "0131;milliamp;milliamp",
+ "0132;milliamps;milliamps",
+ "0133;mah;m-a-h",
+ "0134;mah;m-a-h",
+ "0135;watt;watt",
+ "0136;watts;watts",
+ "0137;db;db",
+ "0138;db;db",
+ "0140;feet;feet",
+ "0141;knot;knot",
+ "0142;knots;knots",
+ "0143;hour;hour",
+ "0144;hours;hours",
+ "0145;minute;minute",
+ "0146;minutes;minutes",
+ "0147;second;second",
+ "0148;seconds;seconds",
+ "0149;rpm;r-p-m",
+ "0150;rpm;r-p-m",
+ "0151;g;gee",
+ "0152;g;gees",
+ "0160;point zero;point zero",
+ "0161;point one;point one",
+ "0162;point two;point two",
+ "0163;point three;point three",
+ "0164;point four;point four",
+ "0165;point five;point five",
+ "0166;point six;point six",
+ "0167;point seven;point seven",
+ "0168;point eight;point eight",
+ "0169;point nine;point nine",
+ "a1_org;a1 low;a1 low",
+ "a1_red;a1 critical;a1 critical",
+ "a2_org;a2 low;a2 low",
+ "a2_red;a2 critical;a2 critical",
+ "endtrim;maximum trim reached;maximum trim reached",
+ "inactiv;inactivity alarm;inactivity alarm",
+ "lowbatt;radio battery low;radio battery low",
+ "midtrim;trim center;center",
+ "rssi_org;rf signal low;rf signal low",
+ "rssi_red;rf signal critical;rf signal critical",
+ "swalert;switch warning;switch warning",
+ "swr_red;radio antenna defective;radio antenna defective",
+ "tada;welcome to opentx;welcome to open T-X",
+ "telemko;telemetry lost;telemetry lost",
+ "telemok;telemetry recover;telemetry recover",
+ "thralert;throttle warning;throttle warning",
+ "timer10;10 seconds;10 seconds",
+ "timer20;20 seconds;20 seconds",
+ "timer30;30 seconds;30 seconds",
+ "timerlt3;timer sound;a a a a" };
+
+ private static string[] default_en_other_strings =
+ { "atti;attitude;attitude",
+ "batcrit;battery critical;battery critical",
+ "batlow;low battery;low battery",
+ "camcenter;camera center;camera center",
+ "camfix;camera fixed;camera fixed",
+ "cammanual;camera manual;camera manual",
+ "capacity;capacity;capacity",
+ "engdis;engine disabled;engine disabled",
+ "engoff;engine off;engine off",
+ "engon;engine on;engine on",
+ "flaps1;flaps 1;flaps 1",
+ "flaps2;flaps 2;flaps 2",
+ "flapsdn;flaps down;flaps down",
+ "flapsup;flaps up;flaps up",
+ "fltmode1;flight mode one;flight mode one",
+ "fltmode2;flight mode two;flight mode two",
+ "fltmode3;flight mode three;flight mode three",
+ "fltmode4;flight mode four;flight mode four",
+ "fltmode5;flight mode five;flight mode five",
+ "fltmode6;flight mode six;flight mode six",
+ "fltmode7;flight mode seven;flight mode seven",
+ "fltmode8;flight mode eight;flight mode eight",
+ "fsoff;failsafe off;failsafe off",
+ "fson;failsafe on;failsafe on",
+ "geardn;gear down;gear down",
+ "gearup;gear upp;gear upp",
+ "gps;gps;G-P-S",
+ "horn;horn sound;eeeeeeeee",
+ "hirates;hi rates;hi rates",
+ "htoff;head tracker off;head tracker off",
+ "hton;head tracker on;head tracker on",
+ "ioc;ioc;ioc",
+ "iocoff;ioc off;ioc off",
+ "lowrates;lowrates;lowrates",
+ "manual;manual;manual",
+ "normal;normal;normal",
+ "nrmmod;normal mode;normal mode",
+ "pouet;small horn;ee , ee",
+ "shutter;camera shutter sound;klick",
+ "thrhold;throttle locked;throttle locked",
+ "thrrel;throttle released;throttle released",
+ "wizz;wizzing sound;shiss" };
+
+ private static string[] default_se_system_strings =
+ { "0000;0;0",
+ "0001;1;en",
+ "0002;2;2",
+ "0003;3;3",
+ "0004;4;4",
+ "0005;5;5",
+ "0006;6;6",
+ "0007;7;7",
+ "0008;8;8",
+ "0009;9;9",
+ "0010;10;10",
+ "0011;11;11",
+ "0012;12;12",
+ "0013;13;13",
+ "0014;14;14",
+ "0015;15;15",
+ "0016;16;16",
+ "0017;17;17",
+ "0018;18;18",
+ "0019;19;19",
+ "0020;20;20",
+ "0021;21;tjugoen",
+ "0022;22;24",
+ "0023;23;23",
+ "0024;24;24",
+ "0025;25;25",
+ "0026;26;26",
+ "0027;27;27",
+ "0028;28;28",
+ "0029;29;29",
+ "0030;30;30",
+ "0031;31;trettioen",
+ "0032;32;32",
+ "0033;33;33",
+ "0034;34;34",
+ "0035;35;35",
+ "0036;36;36",
+ "0037;37;37",
+ "0038;38;38",
+ "0039;39;39",
+ "0040;40;40",
+ "0041;41;fyrtioen",
+ "0042;42;42",
+ "0043;43;43",
+ "0044;44;44",
+ "0045;45;45",
+ "0046;46;46",
+ "0047;47;47",
+ "0048;48;48",
+ "0049;49;49",
+ "0050;50;50",
+ "0051;51;femtioen",
+ "0052;52;52",
+ "0053;53;53",
+ "0054;54;54",
+ "0055;55;55",
+ "0056;56;56",
+ "0057;57;57",
+ "0058;58;58",
+ "0059;59;59",
+ "0060;60;60",
+ "0061;61;sextioen",
+ "0062;62;62",
+ "0063;63;63",
+ "0064;64;64",
+ "0065;65;65",
+ "0066;66;66",
+ "0067;67;67",
+ "0068;68;68",
+ "0069;69;69",
+ "0070;70;70",
+ "0071;71;sjuttioen",
+ "0072;72;72",
+ "0073;73;73",
+ "0074;74;74",
+ "0075;75;75",
+ "0076;76;76",
+ "0077;77;77",
+ "0078;78;78",
+ "0079;79;79",
+ "0080;80;80",
+ "0081;81;åttioen",
+ "0082;82;82",
+ "0083;83;83",
+ "0084;84;84",
+ "0085;85;85",
+ "0086;86;86",
+ "0087;87;87",
+ "0088;88;88",
+ "0089;89;89",
+ "0090;90;90",
+ "0091;91;nittioen",
+ "0092;92;92",
+ "0093;93;93",
+ "0094;94;94",
+ "0095;95;95",
+ "0096;96;96",
+ "0097;97;97",
+ "0098;98;98",
+ "0099;99;99",
+ "0100;100;100",
+ "0101;200;200",
+ "0102;300;300",
+ "0103;400;400",
+ "0104;500;500",
+ "0105;600;600",
+ "0106;700;700",
+ "0107;800;800",
+ "0108;900;900",
+ "0109;thousand;tusen",
+ "0111;minus;minus",
+ "0112;point;komma",
+ "0115;volt;volt",
+ "0116;volts;volt",
+ "0117;amp;ampere",
+ "0118;amps;ampere",
+ "0119;meter per second;meter per sekund",
+ "0120;meters per second;meter per sekund",
+ "0123;kmh;kilometer i timmen",
+ "0124;kmh;kilometer i timmen",
+ "0125;meter;meter",
+ "0126;meters;meter",
+ "0127;degree;grad",
+ "0128;degrees;grader",
+ "0129;percent;procent",
+ "0130;percent;procent",
+ "0131;milliamp;milliampere",
+ "0132;milliamps;milliampere",
+ "0133;mah;milliampere-timme",
+ "0134;mah;milliampere-timmar",
+ "0135;watt;watt",
+ "0136;watts;watt",
+ "0137;db;dessibell",
+ "0138;db;dessibell",
+ "0140;feet;fot",
+ "0141;knot;knop",
+ "0142;knots;knop",
+ "0143;hour;timme",
+ "0144;hours;timmar",
+ "0145;minute;minut",
+ "0146;minutes;minuter",
+ "0147;second;sekund",
+ "0148;seconds;sekunder",
+ "0149;rpm;varv i minuten",
+ "0150;rpm;varv i minuten",
+ "0151;g;g",
+ "0152;g;g",
+ "0160;point zero;komma noll",
+ "0161;point one;komma en",
+ "0162;point two;komma två",
+ "0163;point three;komma tre",
+ "0164;point four;komma fyra",
+ "0165;point five;komma fem",
+ "0166;point six;komma sex",
+ "0167;point seven;komma sju",
+ "0168;point eight;komma åtta",
+ "0169;point nine;komma nio",
+ "a1_org;a1 low;a1 låg",
+ "a1_red;a1 critical;a1 kritisk",
+ "a2_org;a2 low;a2 låg",
+ "a2_red;a2 critical;a2 kritisk",
+ "endtrim;maximum trim reached;maximum trim",
+ "inact;inactivity alarm;inaktivitets-larm",
+ "lowbat;radio battery low;Låg radiobatterispänning",
+ "midtrim;trim center;center",
+ "rssi_org;rf signal low;Svag radio-signal",
+ "rssi_red;rf signal critical;Kritisk radio-signal",
+ "swalert;switch warning;brytar-varning",
+ "swr_red;;radio-antennen är defekt",
+ "tada;;Välkommen till open Te Ex",
+ "telemko;;telemetri förlorad",
+ "telemok;;telemetri åter",
+ "thralert;;gas-varning",
+ "timer10;;10 sekunder",
+ "timer20;;20 sekunder",
+ "timer30;;30 sekunder",
+ "timerlt3;timer sound;a a a a" };
+
+ private static string[] default_se_other_strings =
+ { "atti;;lutning",
+ "batcrit;;kritisk batteri-nivå",
+ "batlow;;låg batteri-nivå",
+ "camcenter;;kamera centrerad",
+ "cammanual;;manuell kamera-kontroll",
+ "capacity;;kapacitet",
+ "engdis;;motor säkrad",
+ "engoff;;motor avslagen",
+ "engon;;motor på",
+ "flaps1;;flaps läge, ett",
+ "flaps2;;flaps läge två",
+ "flapsdn;;flaps ned",
+ "flapsup;;flaps upp",
+ "fltmode1;;flyg-läge, ett",
+ "fltmode2;;flyg-läge två",
+ "fltmode3;;flyg-läge tre",
+ "fltmode4;;flyg-läge fyra",
+ "fltmode5;;flyg-läge fem",
+ "fltmode6;;flyg-läge sex",
+ "fltmode7;;flyg-läge sju",
+ "fltmode8;;flyg-läge åtta",
+ "fsoff;;fäjlsäif avslagen",
+ "fson;;fäjlsäif på",
+ "geardn;;landningsställ ned",
+ "gearup;;landningsställ upp",
+ "gps;;GPS",
+ "hirates;;höga nivåer",
+ "htoff;;head tracker avslagen",
+ "hton;;head tracker på",
+ "horn;horn sound;eeeeeeeee",
+ "ioc;;i o c",
+ "iocoff;;i o c avslagen",
+ "lowrates;;låga nivåer",
+ "manual;;manuell",
+ "normal;;normal",
+ "nrmmod;;normalt läge",
+ "pouet;small horn;ee , ee",
+ "shutter;camera shutter sound;klick",
+ "thrhold;;gas säkrad",
+ "thrrel;;gas osäkrad",
+ "speed;;hastighet",
+ "start;;start",
+ "thermal;;termik",
+ "wizz;wizzing sound;shiss" };
+
+ private static string[] default_it_system_strings =
+ { "0000;0;0",
+ "0001;1;1",
+ "0002;2;2",
+ "0003;3;3",
+ "0004;4;4",
+ "0005;5;5",
+ "0006;6;6",
+ "0007;7;7",
+ "0008;8;8",
+ "0009;9;9",
+ "0010;10;10",
+ "0011;11;11",
+ "0012;12;12",
+ "0013;13;13",
+ "0014;14;14",
+ "0015;15;15",
+ "0016;16;16",
+ "0017;17;17",
+ "0018;18;18",
+ "0019;19;19",
+ "0020;20;20",
+ "0021;21;21",
+ "0022;22;24",
+ "0023;23;23",
+ "0024;24;24",
+ "0025;25;25",
+ "0026;26;26",
+ "0027;27;27",
+ "0028;28;28",
+ "0029;29;29",
+ "0030;30;30",
+ "0031;31;31",
+ "0032;32;32",
+ "0033;33;33",
+ "0034;34;34",
+ "0035;35;35",
+ "0036;36;36",
+ "0037;37;37",
+ "0038;38;38",
+ "0039;39;39",
+ "0040;40;40",
+ "0041;41;41",
+ "0042;42;42",
+ "0043;43;43",
+ "0044;44;44",
+ "0045;45;45",
+ "0046;46;46",
+ "0047;47;47",
+ "0048;48;48",
+ "0049;49;49",
+ "0050;50;50",
+ "0051;51;51",
+ "0052;52;52",
+ "0053;53;53",
+ "0054;54;54",
+ "0055;55;55",
+ "0056;56;56",
+ "0057;57;57",
+ "0058;58;58",
+ "0059;59;59",
+ "0060;60;60",
+ "0061;61;61",
+ "0062;62;62",
+ "0063;63;63",
+ "0064;64;64",
+ "0065;65;65",
+ "0066;66;66",
+ "0067;67;67",
+ "0068;68;68",
+ "0069;69;69",
+ "0070;70;70",
+ "0071;71;71",
+ "0072;72;72",
+ "0073;73;73",
+ "0074;74;74",
+ "0075;75;75",
+ "0076;76;76",
+ "0077;77;77",
+ "0078;78;78",
+ "0079;79;79",
+ "0080;80;80",
+ "0081;81;81",
+ "0082;82;82",
+ "0083;83;83",
+ "0084;84;84",
+ "0085;85;85",
+ "0086;86;86",
+ "0087;87;87",
+ "0088;88;88",
+ "0089;89;89",
+ "0090;90;90",
+ "0091;91;91",
+ "0092;92;92",
+ "0093;93;93",
+ "0094;94;94",
+ "0095;95;95",
+ "0096;96;96",
+ "0097;97;97",
+ "0098;98;98",
+ "0099;99;99",
+ "0100;100;100",
+ "0101;mila;mila",
+ "0102;mille;mille",
+ "0103;virgola;virgola",
+ "0104;un;un",
+ "0105;e;e",
+ "0106;meno;meno",
+ "0107;ora;ora",
+ "0108;ore;ore",
+ "0109;minuto;minuto",
+ "0110;minuti;minuti",
+ "0111;secondo;secondo",
+ "0112;secondi;secondi",
+ "0113;;volt",
+ "0114;;ampere",
+ "0115;;metri per secondo",
+ "0116;;",
+ "0117;;chilometri/ora",
+ "0118;;metri",
+ "0119;;gradi",
+ "0120;;percento",
+ "0121;;milliampere",
+ "0122;;milliampere/ora",
+ "0123;;watt",
+ "0124;;db",
+ "0125;;piedi",
+ "0126;;nodi",
+ "0127;;ore",
+ "0128;;minuti",
+ "0129;;secondi",
+ "0130;;R P M",
+ "0131;;g",
+ "0132;;timer",
+ "0133;;timer",
+ "0134;;trasmissione",
+ "0135;;ricezione",
+ "0136;;A1",
+ "0137;;A2",
+ "0138;;altitudine",
+ "0139;;motore",
+ "0140;;carburante",
+ "0141;;temperatura",
+ "0142;;temperatura",
+ "0143;;velocità",
+ "0144;;distanza",
+ "0145;;altitudine",
+ "0146;;cella lipo",
+ "0147;;totale lipo",
+ "0148;;tensione",
+ "0149;;corrente",
+ "0150;;consumo",
+ "0151;;potenza",
+ "0152;;accellerazione X",
+ "0153;;accellerazione Y",
+ "0154;;accellerazione Z",
+ "0155;;direzione",
+ "0156;;variometro",
+ "0157;;minimo",
+ "0158;;massimo",
+ "a1_org;A1 in allarme;A1 in allarme",
+ "a1_red;A1 critico;A1 critico",
+ "a2_org;A2 in allarme;A2 in allarme",
+ "a2_red;A2 critico;A2 critico",
+ "eebad;eeprom corrotta;eeprom corrotta",
+ "eeformat;formattazone eeprom in corso;formattazone eeprom in corso",
+ "endtrim;massimo trim raggiunto;massimo trim raggiunto",
+ "error;errore;errore",
+ "highmah;assorbimento elevato;assorbimento elevato",
+ "hightemp;temperatura elevata;temperatura elevata",
+ "inactiv;radio inattiva controllare;radio inattiva controllare",
+ "lowbatt;batteria della radio scarica;batteria della radio scarica",
+ "midpot;potenziometro centrato;potenziometro centrato",
+ "midtrim;trim centrato;trim centrato",
+ "rssi_org;Segnale radio basso;Segnale radio basso",
+ "rssi_red;Segnale radio critico;Segnale radio critico",
+ "swalert;interruttori non in posizione, verificare;interruttori non in posizione, verificare",
+ "swr_red;Problema all'antenna della radio;Problema all'antenna della radio",
+ "tada;;Benvenuto",
+ "telemko;Telemetria assente;Telemetria assente",
+ "telemok;Telemetria disponibile;Telemetria disponibile",
+ "thralert;controllo motore non in posizione, verificare;controllo motore non in posizione, verificare",
+ "timer10;dieci secondi;dieci secondi",
+ "timer20;venti secondi;venti secondi",
+ "timer30;trenta secondi;trenta secondi",
+ "timerlt3;timer sound;a a a a" };
+
+ private static string[] default_it_other_strings =
+ { "attero;;atterraggiio",
+ "crowof;;crow off",
+ "crowon;;crow on",
+ "engoff;;motore spento",
+ "flapdn;;flap estesi",
+ "flapup;;flap rientrati",
+ "fltmd1;;fase di volo 1",
+ "fltmd2;;fase di volo 2",
+ "fltmd3;;fase di volo 3",
+ "fltmd4;;fase di volo 4",
+ "fltmd5;;fase di volo 5",
+ "fltmd6;;fase di volo 6",
+ "fltmd7;;fase di volo 7",
+ "fltmd8;;fase di volo 8",
+ "fltmd9;;fase di volo 9",
+ "geardn;;carrello aperto",
+ "gearup;;carrello chiuso",
+ "gps;;GPS",
+ "lowbat;;batteria scarica",
+ "nrmmod;;modo volo normale",
+ "spdmod;;modo velocità",
+ "thmmod;;modo termica",
+ "tohigh;;troppo alto",
+ "tolow;;troppo basso",
+ "trnoff;;modalità maestro disattiva",
+ "trnon;;modalità maestro attiva" };
+
+
+ public string[][] default_system_strings = new string[15][];
+ public string[][] default_other_strings = new string[15][];
+
+ public int toInt(string langStr)
+ {
+ if (langStr == "se") return 1;
+ if (langStr == "it") return 2;
+ else return 0; //English default
+ }
+
+ public SentenceTables()
+ {
+ default_other_strings[toInt("en")] = default_en_other_strings;
+ default_system_strings[toInt("en")] = default_en_system_strings;
+
+ default_other_strings[toInt("se")] = default_se_other_strings;
+ default_system_strings[toInt("se")] = default_se_system_strings;
+
+ default_other_strings[toInt("it")] = default_it_other_strings;
+ default_system_strings[toInt("it")] = default_it_system_strings;
+ }
+ }
+}