diff options
48 files changed, 222 insertions, 70 deletions
diff --git a/apps/features.txt b/apps/features.txt index 888e9d2210..14204dfb6d 100644 --- a/apps/features.txt +++ b/apps/features.txt | |||
@@ -102,6 +102,10 @@ masf | |||
102 | masd | 102 | masd |
103 | #endif | 103 | #endif |
104 | 104 | ||
105 | #if defined(HAVE_MORSE_INPUT) | ||
106 | morse_input | ||
107 | #endif | ||
108 | |||
105 | #if defined(HAVE_PITCHSCREEN) | 109 | #if defined(HAVE_PITCHSCREEN) |
106 | pitchscreen | 110 | pitchscreen |
107 | #endif | 111 | #endif |
diff --git a/apps/keymaps/keymap-creativezv.c b/apps/keymaps/keymap-creativezv.c index c75a5b29cd..b88c1409cd 100644 --- a/apps/keymaps/keymap-creativezv.c +++ b/apps/keymaps/keymap-creativezv.c | |||
@@ -213,6 +213,7 @@ static const struct button_mapping button_context_keyboard[] = { | |||
213 | { ACTION_KBD_UP, BUTTON_UP|BUTTON_REPEAT, BUTTON_NONE }, | 213 | { ACTION_KBD_UP, BUTTON_UP|BUTTON_REPEAT, BUTTON_NONE }, |
214 | { ACTION_KBD_DOWN, BUTTON_DOWN, BUTTON_NONE }, | 214 | { ACTION_KBD_DOWN, BUTTON_DOWN, BUTTON_NONE }, |
215 | { ACTION_KBD_DOWN, BUTTON_DOWN|BUTTON_REPEAT, BUTTON_NONE }, | 215 | { ACTION_KBD_DOWN, BUTTON_DOWN|BUTTON_REPEAT, BUTTON_NONE }, |
216 | { ACTION_KBD_MORSE_SELECT, BUTTON_SELECT|BUTTON_REL, BUTTON_NONE }, | ||
216 | LAST_ITEM_IN_LIST | 217 | LAST_ITEM_IN_LIST |
217 | }; /* button_context_keyboard */ | 218 | }; /* button_context_keyboard */ |
218 | 219 | ||
diff --git a/apps/keymaps/keymap-creativezvm.c b/apps/keymaps/keymap-creativezvm.c index 12694bc473..b355018892 100644 --- a/apps/keymaps/keymap-creativezvm.c +++ b/apps/keymaps/keymap-creativezvm.c | |||
@@ -212,6 +212,7 @@ static const struct button_mapping button_context_keyboard[] = { | |||
212 | { ACTION_KBD_UP, BUTTON_UP|BUTTON_REPEAT, BUTTON_NONE }, | 212 | { ACTION_KBD_UP, BUTTON_UP|BUTTON_REPEAT, BUTTON_NONE }, |
213 | { ACTION_KBD_DOWN, BUTTON_DOWN, BUTTON_NONE }, | 213 | { ACTION_KBD_DOWN, BUTTON_DOWN, BUTTON_NONE }, |
214 | { ACTION_KBD_DOWN, BUTTON_DOWN|BUTTON_REPEAT, BUTTON_NONE }, | 214 | { ACTION_KBD_DOWN, BUTTON_DOWN|BUTTON_REPEAT, BUTTON_NONE }, |
215 | { ACTION_KBD_MORSE_SELECT, BUTTON_SELECT|BUTTON_REL, BUTTON_NONE }, | ||
215 | LAST_ITEM_IN_LIST | 216 | LAST_ITEM_IN_LIST |
216 | }; /* button_context_keyboard */ | 217 | }; /* button_context_keyboard */ |
217 | 218 | ||
diff --git a/apps/keymaps/keymap-e200.c b/apps/keymaps/keymap-e200.c index 487fb11130..2deac631ac 100644 --- a/apps/keymaps/keymap-e200.c +++ b/apps/keymaps/keymap-e200.c | |||
@@ -265,6 +265,8 @@ static const struct button_mapping button_context_keyboard[] = { | |||
265 | { ACTION_KBD_SELECT, BUTTON_SELECT, BUTTON_NONE }, | 265 | { ACTION_KBD_SELECT, BUTTON_SELECT, BUTTON_NONE }, |
266 | { ACTION_KBD_DONE, BUTTON_UP, BUTTON_NONE }, | 266 | { ACTION_KBD_DONE, BUTTON_UP, BUTTON_NONE }, |
267 | { ACTION_KBD_ABORT, BUTTON_POWER, BUTTON_NONE }, | 267 | { ACTION_KBD_ABORT, BUTTON_POWER, BUTTON_NONE }, |
268 | { ACTION_KBD_MORSE_INPUT, BUTTON_REC|BUTTON_REL, BUTTON_REC }, | ||
269 | { ACTION_KBD_MORSE_SELECT, BUTTON_SELECT|BUTTON_REL, BUTTON_NONE }, | ||
268 | 270 | ||
269 | LAST_ITEM_IN_LIST | 271 | LAST_ITEM_IN_LIST |
270 | }; /* button_context_keyboard */ | 272 | }; /* button_context_keyboard */ |
diff --git a/apps/keymaps/keymap-fuze.c b/apps/keymaps/keymap-fuze.c index e44ee518f2..3e89cc595f 100644 --- a/apps/keymaps/keymap-fuze.c +++ b/apps/keymaps/keymap-fuze.c | |||
@@ -266,6 +266,7 @@ static const struct button_mapping button_context_keyboard[] = { | |||
266 | { ACTION_KBD_SELECT, BUTTON_SELECT, BUTTON_NONE }, | 266 | { ACTION_KBD_SELECT, BUTTON_SELECT, BUTTON_NONE }, |
267 | { ACTION_KBD_DONE, BUTTON_UP, BUTTON_NONE }, | 267 | { ACTION_KBD_DONE, BUTTON_UP, BUTTON_NONE }, |
268 | { ACTION_KBD_ABORT, BUTTON_HOME|BUTTON_REPEAT, BUTTON_NONE }, | 268 | { ACTION_KBD_ABORT, BUTTON_HOME|BUTTON_REPEAT, BUTTON_NONE }, |
269 | { ACTION_KBD_MORSE_SELECT, BUTTON_SELECT|BUTTON_REL, BUTTON_NONE }, | ||
269 | 270 | ||
270 | LAST_ITEM_IN_LIST | 271 | LAST_ITEM_IN_LIST |
271 | }; /* button_context_keyboard */ | 272 | }; /* button_context_keyboard */ |
diff --git a/apps/keymaps/keymap-m200.c b/apps/keymaps/keymap-m200.c index 78a4947b2f..e3aa093a81 100644 --- a/apps/keymaps/keymap-m200.c +++ b/apps/keymaps/keymap-m200.c | |||
@@ -274,6 +274,7 @@ static const struct button_mapping button_context_keyboard[] = { | |||
274 | { ACTION_KBD_DONE, BUTTON_VOL_UP, BUTTON_NONE }, | 274 | { ACTION_KBD_DONE, BUTTON_VOL_UP, BUTTON_NONE }, |
275 | { ACTION_KBD_DONE, BUTTON_VOL_DOWN, BUTTON_NONE }, | 275 | { ACTION_KBD_DONE, BUTTON_VOL_DOWN, BUTTON_NONE }, |
276 | { ACTION_KBD_ABORT, BUTTON_POWER, BUTTON_NONE }, | 276 | { ACTION_KBD_ABORT, BUTTON_POWER, BUTTON_NONE }, |
277 | { ACTION_KBD_MORSE_SELECT, BUTTON_SELECT|BUTTON_REL, BUTTON_NONE }, | ||
277 | 278 | ||
278 | LAST_ITEM_IN_LIST | 279 | LAST_ITEM_IN_LIST |
279 | }; /* button_context_keyboard */ | 280 | }; /* button_context_keyboard */ |
diff --git a/apps/keymaps/keymap-mr500.c b/apps/keymaps/keymap-mr500.c index 36ffea46de..0b1dc767f2 100644 --- a/apps/keymaps/keymap-mr500.c +++ b/apps/keymaps/keymap-mr500.c | |||
@@ -191,6 +191,7 @@ static const struct button_mapping button_context_keyboard[] = { | |||
191 | { ACTION_KBD_UP, BUTTON_RC_PLAY|BUTTON_REPEAT, BUTTON_NONE }, | 191 | { ACTION_KBD_UP, BUTTON_RC_PLAY|BUTTON_REPEAT, BUTTON_NONE }, |
192 | { ACTION_KBD_DOWN, BUTTON_RC_DOWN, BUTTON_NONE }, | 192 | { ACTION_KBD_DOWN, BUTTON_RC_DOWN, BUTTON_NONE }, |
193 | { ACTION_KBD_DOWN, BUTTON_RC_DOWN|BUTTON_REPEAT, BUTTON_NONE }, | 193 | { ACTION_KBD_DOWN, BUTTON_RC_DOWN|BUTTON_REPEAT, BUTTON_NONE }, |
194 | { ACTION_KBD_MORSE_SELECT, BUTTON_RC_HEART|BUTTON_REL, BUTTON_NONE }, | ||
194 | 195 | ||
195 | LAST_ITEM_IN_LIST | 196 | LAST_ITEM_IN_LIST |
196 | }; /* button_context_keyboard */ | 197 | }; /* button_context_keyboard */ |
diff --git a/apps/keymaps/keymap-recorder.c b/apps/keymaps/keymap-recorder.c index 6c8ae0460e..0ab0e5f8c6 100644 --- a/apps/keymaps/keymap-recorder.c +++ b/apps/keymaps/keymap-recorder.c | |||
@@ -197,6 +197,7 @@ static const struct button_mapping button_context_keyboard[] = { | |||
197 | { ACTION_KBD_UP, BUTTON_UP|BUTTON_REPEAT, BUTTON_NONE }, | 197 | { ACTION_KBD_UP, BUTTON_UP|BUTTON_REPEAT, BUTTON_NONE }, |
198 | { ACTION_KBD_DOWN, BUTTON_DOWN, BUTTON_NONE }, | 198 | { ACTION_KBD_DOWN, BUTTON_DOWN, BUTTON_NONE }, |
199 | { ACTION_KBD_DOWN, BUTTON_DOWN|BUTTON_REPEAT, BUTTON_NONE }, | 199 | { ACTION_KBD_DOWN, BUTTON_DOWN|BUTTON_REPEAT, BUTTON_NONE }, |
200 | { ACTION_KBD_MORSE_SELECT, BUTTON_PLAY|BUTTON_REL, BUTTON_NONE }, | ||
200 | 201 | ||
201 | LAST_ITEM_IN_LIST | 202 | LAST_ITEM_IN_LIST |
202 | }; /* button_context_keyboard */ | 203 | }; /* button_context_keyboard */ |
diff --git a/apps/keymaps/keymap-x5.c b/apps/keymaps/keymap-x5.c index 8b94118ac1..69602d7ca7 100644 --- a/apps/keymaps/keymap-x5.c +++ b/apps/keymaps/keymap-x5.c | |||
@@ -132,9 +132,10 @@ static const struct button_mapping button_context_keyboard[] = { | |||
132 | { ACTION_KBD_UP, BUTTON_UP|BUTTON_REPEAT, BUTTON_NONE }, | 132 | { ACTION_KBD_UP, BUTTON_UP|BUTTON_REPEAT, BUTTON_NONE }, |
133 | { ACTION_KBD_DOWN, BUTTON_DOWN, BUTTON_NONE }, | 133 | { ACTION_KBD_DOWN, BUTTON_DOWN, BUTTON_NONE }, |
134 | { ACTION_KBD_DOWN, BUTTON_DOWN|BUTTON_REPEAT, BUTTON_NONE }, | 134 | { ACTION_KBD_DOWN, BUTTON_DOWN|BUTTON_REPEAT, BUTTON_NONE }, |
135 | { ACTION_KBD_SELECT, BUTTON_SELECT|BUTTON_REL, BUTTON_SELECT }, | 135 | { ACTION_KBD_SELECT, BUTTON_SELECT, BUTTON_NONE }, |
136 | { ACTION_KBD_DONE, BUTTON_PLAY, BUTTON_NONE }, | 136 | { ACTION_KBD_DONE, BUTTON_PLAY, BUTTON_NONE }, |
137 | { ACTION_KBD_ABORT, BUTTON_REC, BUTTON_NONE }, | 137 | { ACTION_KBD_ABORT, BUTTON_REC, BUTTON_NONE }, |
138 | { ACTION_KBD_MORSE_SELECT, BUTTON_SELECT|BUTTON_REL, BUTTON_NONE }, | ||
138 | 139 | ||
139 | LAST_ITEM_IN_LIST | 140 | LAST_ITEM_IN_LIST |
140 | }; /* button_context_keyboard */ | 141 | }; /* button_context_keyboard */ |
diff --git a/apps/lang/english.lang b/apps/lang/english.lang index 9fa1f7b7b3..198a3c7358 100644 --- a/apps/lang/english.lang +++ b/apps/lang/english.lang | |||
@@ -13210,3 +13210,20 @@ | |||
13210 | *: "Queue Last Shuffled" | 13210 | *: "Queue Last Shuffled" |
13211 | </voice> | 13211 | </voice> |
13212 | </phrase> | 13212 | </phrase> |
13213 | <phrase> | ||
13214 | id: LANG_MORSE_INPUT | ||
13215 | desc: in Settings -> System | ||
13216 | user: core | ||
13217 | <source> | ||
13218 | *: none | ||
13219 | morse_input: "Use Morse Code Input" | ||
13220 | </source> | ||
13221 | <dest> | ||
13222 | *: none | ||
13223 | morse_input: "Use Morse Code Input" | ||
13224 | </dest> | ||
13225 | <voice> | ||
13226 | *: none | ||
13227 | morse_input: "Use Morse Code Input" | ||
13228 | </voice> | ||
13229 | </phrase> | ||
diff --git a/apps/menus/settings_menu.c b/apps/menus/settings_menu.c index c11bf0eb3d..135e632479 100644 --- a/apps/menus/settings_menu.c +++ b/apps/menus/settings_menu.c | |||
@@ -257,6 +257,10 @@ MENUITEM_SETTING(usb_hid, &global_settings.usb_hid, NULL); | |||
257 | MENUITEM_SETTING(usb_keypad_mode, &global_settings.usb_keypad_mode, NULL); | 257 | MENUITEM_SETTING(usb_keypad_mode, &global_settings.usb_keypad_mode, NULL); |
258 | #endif | 258 | #endif |
259 | 259 | ||
260 | #ifdef HAVE_MORSE_INPUT | ||
261 | MENUITEM_SETTING(morse_input, &global_settings.morse_input, NULL); | ||
262 | #endif | ||
263 | |||
260 | #ifdef HAVE_BUTTON_LIGHT | 264 | #ifdef HAVE_BUTTON_LIGHT |
261 | MENUITEM_SETTING(buttonlight_timeout, &global_settings.buttonlight_timeout, NULL); | 265 | MENUITEM_SETTING(buttonlight_timeout, &global_settings.buttonlight_timeout, NULL); |
262 | #endif | 266 | #endif |
@@ -280,6 +284,9 @@ MAKE_MENU(system_menu, ID2P(LANG_SYSTEM), | |||
280 | #endif | 284 | #endif |
281 | &poweroff, | 285 | &poweroff, |
282 | &limits_menu, | 286 | &limits_menu, |
287 | #ifdef HAVE_MORSE_INPUT | ||
288 | &morse_input, | ||
289 | #endif | ||
283 | #if CONFIG_CODEC == MAS3507D | 290 | #if CONFIG_CODEC == MAS3507D |
284 | &line_in, | 291 | &line_in, |
285 | #endif | 292 | #endif |
@@ -287,7 +294,7 @@ MAKE_MENU(system_menu, ID2P(LANG_SYSTEM), | |||
287 | &car_adapter_mode, | 294 | &car_adapter_mode, |
288 | #endif | 295 | #endif |
289 | #ifdef IPOD_ACCESSORY_PROTOCOL | 296 | #ifdef IPOD_ACCESSORY_PROTOCOL |
290 | &serial_bitrate, | 297 | &serial_bitrate, |
291 | #endif | 298 | #endif |
292 | #ifdef HAVE_ACCESSORY_SUPPLY | 299 | #ifdef HAVE_ACCESSORY_SUPPLY |
293 | &accessory_supply, | 300 | &accessory_supply, |
diff --git a/apps/recorder/keyboard.c b/apps/recorder/keyboard.c index e6a3c927e3..1e9e8f32ab 100644 --- a/apps/recorder/keyboard.c +++ b/apps/recorder/keyboard.c | |||
@@ -49,45 +49,47 @@ | |||
49 | #define DEFAULT_MARGIN 6 | 49 | #define DEFAULT_MARGIN 6 |
50 | #define KBD_BUF_SIZE 500 | 50 | #define KBD_BUF_SIZE 500 |
51 | 51 | ||
52 | #if (CONFIG_KEYPAD == IRIVER_H100_PAD) || \ | 52 | #if (CONFIG_KEYPAD == ONDIO_PAD) \ |
53 | (CONFIG_KEYPAD == IRIVER_H300_PAD) | 53 | || (CONFIG_KEYPAD == IPOD_1G2G_PAD) \ |
54 | #define KBD_CURSOR_KEYS /* certain key combos move the cursor even if not | 54 | || (CONFIG_KEYPAD == IPOD_3G_PAD) \ |
55 | in line edit mode */ | 55 | || (CONFIG_KEYPAD == IPOD_4G_PAD) \ |
56 | #define KBD_MODES /* I-Rivers can use picker, line edit and cursor keys */ | 56 | || (CONFIG_KEYPAD == IRIVER_IFP7XX_PAD) \ |
57 | #define KBD_MORSE_INPUT /* I-Rivers have a Morse input mode */ | 57 | || (CONFIG_KEYPAD == IAUDIO_X5M5_PAD) \ |
58 | 58 | || (CONFIG_KEYPAD == IAUDIO_M3_PAD) \ | |
59 | #elif CONFIG_KEYPAD == ONDIO_PAD /* restricted Ondio keypad */ | 59 | || (CONFIG_KEYPAD == IRIVER_H10_PAD) |
60 | #define KBD_MODES /* Ondio uses 2 modes, picker and line edit */ | 60 | /* no key combos to move the cursor if not in line edit mode */ |
61 | 61 | #define KBD_MODES /* uses 2 modes, picker and line edit */ | |
62 | #elif (CONFIG_KEYPAD == IPOD_1G2G_PAD) || (CONFIG_KEYPAD == IPOD_3G_PAD) \ | 62 | |
63 | || (CONFIG_KEYPAD == IPOD_4G_PAD) | 63 | #elif (CONFIG_KEYPAD == IRIVER_H100_PAD) \ |
64 | #define KBD_MODES /* iPod uses 2 modes, picker and line edit */ | 64 | || (CONFIG_KEYPAD == IRIVER_H300_PAD) \ |
65 | #define KBD_MORSE_INPUT | 65 | || (CONFIG_KEYPAD == GIGABEAT_PAD) \ |
66 | 66 | || (CONFIG_KEYPAD == GIGABEAT_S_PAD) \ | |
67 | #elif CONFIG_KEYPAD == IRIVER_IFP7XX_PAD | 67 | || (CONFIG_KEYPAD == SANSA_E200_PAD) \ |
68 | #define KBD_MODES /* iFP7xx uses 2 modes, picker and line edit */ | 68 | || (CONFIG_KEYPAD == SANSA_FUZE_PAD) \ |
69 | 69 | || (CONFIG_KEYPAD == SANSA_C200_PAD) \ | |
70 | #elif (CONFIG_KEYPAD == IAUDIO_X5M5_PAD) || (CONFIG_KEYPAD == IAUDIO_M3_PAD) | 70 | || (CONFIG_KEYPAD == SAMSUNG_YH_PAD) |
71 | #define KBD_MODES /* iAudios use 2 modes, picker and line edit */ | 71 | /* certain key combos move the cursor even if not in line edit mode */ |
72 | |||
73 | #elif CONFIG_KEYPAD == IRIVER_H10_PAD | ||
74 | #define KBD_MODES /* iriver H10 uses 2 modes, picker and line edit */ | ||
75 | #define KBD_MORSE_INPUT | ||
76 | |||
77 | #elif CONFIG_KEYPAD == GIGABEAT_PAD | ||
78 | #define KBD_CURSOR_KEYS | 72 | #define KBD_CURSOR_KEYS |
79 | #define KBD_MODES | 73 | #define KBD_MODES /* uses 2 modes, picker and line edit */ |
80 | #define KBD_MORSE_INPUT | ||
81 | 74 | ||
82 | #elif CONFIG_KEYPAD == SANSA_E200_PAD \ | 75 | #else |
83 | || CONFIG_KEYPAD == SANSA_FUZE_PAD \ | 76 | #define KBD_CURSOR_KEYS /* certain keys move the cursor, no line edit mode */ |
84 | || CONFIG_KEYPAD == SANSA_C200_PAD \ | 77 | #endif |
85 | || CONFIG_KEYPAD == SAMSUNG_YH_PAD | ||
86 | #define KBD_CURSOR_KEYS | ||
87 | #define KBD_MODES | ||
88 | 78 | ||
89 | #elif CONFIG_KEYPAD == MROBE100_PAD | 79 | #if (CONFIG_KEYPAD == IRIVER_H100_PAD) \ |
90 | #define KBD_MORSE_INPUT | 80 | || (CONFIG_KEYPAD == IRIVER_H300_PAD) \ |
81 | || (CONFIG_KEYPAD == IPOD_1G2G_PAD) \ | ||
82 | || (CONFIG_KEYPAD == IPOD_3G_PAD) \ | ||
83 | || (CONFIG_KEYPAD == IPOD_4G_PAD) \ | ||
84 | || (CONFIG_KEYPAD == IRIVER_H10_PAD) \ | ||
85 | || (CONFIG_KEYPAD == GIGABEAT_PAD) \ | ||
86 | || (CONFIG_KEYPAD == GIGABEAT_S_PAD) \ | ||
87 | || (CONFIG_KEYPAD == MROBE100_PAD) \ | ||
88 | || (CONFIG_KEYPAD == SANSA_E200_PAD) \ | ||
89 | || (CONFIG_KEYPAD == PHILIPS_HDD1630_PAD) \ | ||
90 | || (CONFIG_KEYPAD == PHILIPS_SA9200_PAD) | ||
91 | /* certain key combos toggle input mode between keyboard input and Morse input */ | ||
92 | #define KBD_TOGGLE_INPUT | ||
91 | #endif | 93 | #endif |
92 | 94 | ||
93 | struct keyboard_parameters | 95 | struct keyboard_parameters |
@@ -124,7 +126,7 @@ struct keyboard_parameters | |||
124 | static struct keyboard_parameters kbd_param[NB_SCREENS]; | 126 | static struct keyboard_parameters kbd_param[NB_SCREENS]; |
125 | static bool kbd_loaded = false; | 127 | static bool kbd_loaded = false; |
126 | 128 | ||
127 | #ifdef KBD_MORSE_INPUT | 129 | #ifdef HAVE_MORSE_INPUT |
128 | /* FIXME: We should put this to a configuration file. */ | 130 | /* FIXME: We should put this to a configuration file. */ |
129 | static const char *morse_alphabets = | 131 | static const char *morse_alphabets = |
130 | "abcdefghijklmnopqrstuvwxyz1234567890,.?-@ "; | 132 | "abcdefghijklmnopqrstuvwxyz1234567890,.?-@ "; |
@@ -134,7 +136,6 @@ static const unsigned char morse_codes[] = { | |||
134 | 0x2f,0x27,0x23,0x21,0x20,0x30,0x38,0x3c,0x3e,0x3f, | 136 | 0x2f,0x27,0x23,0x21,0x20,0x30,0x38,0x3c,0x3e,0x3f, |
135 | 0x73,0x55,0x4c,0x61,0x5a,0x80 }; | 137 | 0x73,0x55,0x4c,0x61,0x5a,0x80 }; |
136 | 138 | ||
137 | static bool morse_mode = false; | ||
138 | #endif | 139 | #endif |
139 | 140 | ||
140 | /* Loads a custom keyboard into memory | 141 | /* Loads a custom keyboard into memory |
@@ -306,7 +307,8 @@ int kbd_input(char* text, int buflen) | |||
306 | unsigned char *utf8; | 307 | unsigned char *utf8; |
307 | bool cur_blink = true; /* Cursor on/off flag */ | 308 | bool cur_blink = true; /* Cursor on/off flag */ |
308 | int ret = 0; /* assume success */ | 309 | int ret = 0; /* assume success */ |
309 | #ifdef KBD_MORSE_INPUT | 310 | #ifdef HAVE_MORSE_INPUT |
311 | bool morse_mode = global_settings.morse_input; | ||
310 | bool morse_reading = false; | 312 | bool morse_reading = false; |
311 | unsigned char morse_code = 0; | 313 | unsigned char morse_code = 0; |
312 | int morse_tick = 0; | 314 | int morse_tick = 0; |
@@ -534,10 +536,10 @@ int kbd_input(char* text, int buflen) | |||
534 | pm->main_x = 0; | 536 | pm->main_x = 0; |
535 | pm->keyboard_margin -= pm->keyboard_margin/2; | 537 | pm->keyboard_margin -= pm->keyboard_margin/2; |
536 | 538 | ||
537 | #ifdef KBD_MORSE_INPUT | 539 | #ifdef HAVE_MORSE_INPUT |
538 | pm->old_main_y = pm->main_y; | 540 | pm->old_main_y = pm->main_y; |
539 | if (morse_mode) | 541 | if (morse_mode) |
540 | pm->main_y = sc_h - pm->font_h; | 542 | pm->main_y = sc_h - pm->font_h - BUTTONBAR_HEIGHT; |
541 | #endif | 543 | #endif |
542 | } | 544 | } |
543 | 545 | ||
@@ -567,7 +569,7 @@ int kbd_input(char* text, int buflen) | |||
567 | FOR_NB_SCREENS(l) | 569 | FOR_NB_SCREENS(l) |
568 | screens[l].clear_display(); | 570 | screens[l].clear_display(); |
569 | 571 | ||
570 | #ifdef KBD_MORSE_INPUT | 572 | #ifdef HAVE_MORSE_INPUT |
571 | if (morse_mode) | 573 | if (morse_mode) |
572 | { | 574 | { |
573 | FOR_NB_SCREENS(l) | 575 | FOR_NB_SCREENS(l) |
@@ -615,7 +617,7 @@ int kbd_input(char* text, int buflen) | |||
615 | } | 617 | } |
616 | } | 618 | } |
617 | else | 619 | else |
618 | #endif /* KBD_MORSE_INPUT */ | 620 | #endif /* HAVE_MORSE_INPUT */ |
619 | { | 621 | { |
620 | /* draw page */ | 622 | /* draw page */ |
621 | FOR_NB_SCREENS(l) | 623 | FOR_NB_SCREENS(l) |
@@ -752,7 +754,7 @@ int kbd_input(char* text, int buflen) | |||
752 | sc->getwidth(), pm->font_h + 2); | 754 | sc->getwidth(), pm->font_h + 2); |
753 | else /* highlight the key that has focus */ | 755 | else /* highlight the key that has focus */ |
754 | #endif | 756 | #endif |
755 | #ifdef KBD_MORSE_INPUT | 757 | #ifdef HAVE_MORSE_INPUT |
756 | if(!morse_mode) | 758 | if(!morse_mode) |
757 | #endif | 759 | #endif |
758 | sc->fillrect(pm->font_w*pm->x, | 760 | sc->fillrect(pm->font_w*pm->x, |
@@ -771,14 +773,14 @@ int kbd_input(char* text, int buflen) | |||
771 | pm = ¶m[button_screen]; | 773 | pm = ¶m[button_screen]; |
772 | sc = &screens[button_screen]; | 774 | sc = &screens[button_screen]; |
773 | 775 | ||
774 | #if defined(KBD_MODES) || defined(KBD_MORSE_INPUT) | 776 | #if defined(KBD_MODES) || defined(HAVE_MORSE_INPUT) |
775 | /* Remap some buttons to allow to move | 777 | /* Remap some buttons to allow to move |
776 | * cursor in line edit mode and morse mode. */ | 778 | * cursor in line edit mode and morse mode. */ |
777 | #if defined(KBD_MODES) && defined(KBD_MORSE_INPUT) | 779 | #if defined(KBD_MODES) && defined(HAVE_MORSE_INPUT) |
778 | if (pm->line_edit || morse_mode) | 780 | if (pm->line_edit || morse_mode) |
779 | #elif defined(KBD_MODES) | 781 | #elif defined(KBD_MODES) |
780 | if (pm->line_edit) | 782 | if (pm->line_edit) |
781 | #else /* defined(KBD_MORSE_INPUT) */ | 783 | #else /* defined(HAVE_MORSE_INPUT) */ |
782 | if (morse_mode) | 784 | if (morse_mode) |
783 | #endif | 785 | #endif |
784 | { | 786 | { |
@@ -787,7 +789,7 @@ int kbd_input(char* text, int buflen) | |||
787 | if (button == ACTION_KBD_RIGHT) | 789 | if (button == ACTION_KBD_RIGHT) |
788 | button = ACTION_KBD_CURSOR_RIGHT; | 790 | button = ACTION_KBD_CURSOR_RIGHT; |
789 | } | 791 | } |
790 | #endif /* defined(KBD_MODES) || defined(KBD_MORSE_INPUT) */ | 792 | #endif /* defined(KBD_MODES) || defined(HAVE_MORSE_INPUT) */ |
791 | 793 | ||
792 | switch ( button ) | 794 | switch ( button ) |
793 | { | 795 | { |
@@ -798,7 +800,7 @@ int kbd_input(char* text, int buflen) | |||
798 | 800 | ||
799 | case ACTION_KBD_PAGE_FLIP: | 801 | case ACTION_KBD_PAGE_FLIP: |
800 | { | 802 | { |
801 | #ifdef KBD_MORSE_INPUT | 803 | #ifdef HAVE_MORSE_INPUT |
802 | if (morse_mode) | 804 | if (morse_mode) |
803 | break; | 805 | break; |
804 | #endif | 806 | #endif |
@@ -810,7 +812,7 @@ int kbd_input(char* text, int buflen) | |||
810 | break; | 812 | break; |
811 | } | 813 | } |
812 | 814 | ||
813 | #ifdef KBD_MORSE_INPUT | 815 | #if defined(HAVE_MORSE_INPUT) && defined(KBD_TOGGLE_INPUT) |
814 | case ACTION_KBD_MORSE_INPUT: | 816 | case ACTION_KBD_MORSE_INPUT: |
815 | morse_mode = !morse_mode; | 817 | morse_mode = !morse_mode; |
816 | 818 | ||
@@ -822,7 +824,7 @@ int kbd_input(char* text, int buflen) | |||
822 | if (morse_mode) | 824 | if (morse_mode) |
823 | { | 825 | { |
824 | pm->old_main_y = pm->main_y; | 826 | pm->old_main_y = pm->main_y; |
825 | pm->main_y = sc->getheight() - pm->font_h; | 827 | pm->main_y = sc->getheight() - pm->font_h - BUTTONBAR_HEIGHT; |
826 | } | 828 | } |
827 | else | 829 | else |
828 | { | 830 | { |
@@ -831,7 +833,7 @@ int kbd_input(char* text, int buflen) | |||
831 | } | 833 | } |
832 | /* FIXME: We should talk something like Morse mode.. */ | 834 | /* FIXME: We should talk something like Morse mode.. */ |
833 | break; | 835 | break; |
834 | #endif /* KBD_MORSE_INPUT */ | 836 | #endif /* KBD_TOGGLE_INPUT */ |
835 | 837 | ||
836 | case ACTION_KBD_RIGHT: | 838 | case ACTION_KBD_RIGHT: |
837 | if (++pm->x >= pm->max_chars) | 839 | if (++pm->x >= pm->max_chars) |
@@ -864,7 +866,7 @@ int kbd_input(char* text, int buflen) | |||
864 | break; | 866 | break; |
865 | 867 | ||
866 | case ACTION_KBD_DOWN: | 868 | case ACTION_KBD_DOWN: |
867 | #ifdef KBD_MORSE_INPUT | 869 | #ifdef HAVE_MORSE_INPUT |
868 | #ifdef KBD_MODES | 870 | #ifdef KBD_MODES |
869 | if (morse_mode) | 871 | if (morse_mode) |
870 | { | 872 | { |
@@ -877,7 +879,7 @@ int kbd_input(char* text, int buflen) | |||
877 | if (morse_mode) | 879 | if (morse_mode) |
878 | break; | 880 | break; |
879 | #endif | 881 | #endif |
880 | #endif /* KBD_MORSE_INPUT */ | 882 | #endif /* HAVE_MORSE_INPUT */ |
881 | { | 883 | { |
882 | #ifdef KBD_MODES | 884 | #ifdef KBD_MODES |
883 | if (pm->line_edit) | 885 | if (pm->line_edit) |
@@ -907,7 +909,7 @@ int kbd_input(char* text, int buflen) | |||
907 | break; | 909 | break; |
908 | 910 | ||
909 | case ACTION_KBD_UP: | 911 | case ACTION_KBD_UP: |
910 | #ifdef KBD_MORSE_INPUT | 912 | #ifdef HAVE_MORSE_INPUT |
911 | #ifdef KBD_MODES | 913 | #ifdef KBD_MODES |
912 | if (morse_mode) | 914 | if (morse_mode) |
913 | { | 915 | { |
@@ -920,7 +922,7 @@ int kbd_input(char* text, int buflen) | |||
920 | if (morse_mode) | 922 | if (morse_mode) |
921 | break; | 923 | break; |
922 | #endif | 924 | #endif |
923 | #endif /* KBD_MORSE_INPUT */ | 925 | #endif /* HAVE_MORSE_INPUT */ |
924 | { | 926 | { |
925 | #ifdef KBD_MODES | 927 | #ifdef KBD_MODES |
926 | if (pm->line_edit) | 928 | if (pm->line_edit) |
@@ -955,7 +957,7 @@ int kbd_input(char* text, int buflen) | |||
955 | done = true; | 957 | done = true; |
956 | break; | 958 | break; |
957 | 959 | ||
958 | #ifdef KBD_MORSE_INPUT | 960 | #ifdef HAVE_MORSE_INPUT |
959 | case ACTION_KBD_MORSE_SELECT: | 961 | case ACTION_KBD_MORSE_SELECT: |
960 | if (morse_mode && morse_reading) | 962 | if (morse_mode && morse_reading) |
961 | { | 963 | { |
@@ -965,10 +967,10 @@ int kbd_input(char* text, int buflen) | |||
965 | } | 967 | } |
966 | 968 | ||
967 | break; | 969 | break; |
968 | #endif /* KBD_MORSE_INPUT */ | 970 | #endif /* HAVE_MORSE_INPUT */ |
969 | 971 | ||
970 | case ACTION_KBD_SELECT: | 972 | case ACTION_KBD_SELECT: |
971 | #ifdef KBD_MORSE_INPUT | 973 | #ifdef HAVE_MORSE_INPUT |
972 | #ifdef KBD_MODES | 974 | #ifdef KBD_MODES |
973 | if (morse_mode && !pm->line_edit) | 975 | if (morse_mode && !pm->line_edit) |
974 | #else | 976 | #else |
@@ -984,7 +986,7 @@ int kbd_input(char* text, int buflen) | |||
984 | } | 986 | } |
985 | break; | 987 | break; |
986 | } | 988 | } |
987 | #endif /* KBD_MORSE_INPUT */ | 989 | #endif /* HAVE_MORSE_INPUT */ |
988 | 990 | ||
989 | /* inserts the selected char */ | 991 | /* inserts the selected char */ |
990 | #ifdef KBD_MODES | 992 | #ifdef KBD_MODES |
@@ -1088,7 +1090,7 @@ int kbd_input(char* text, int buflen) | |||
1088 | /* speak revised text */ | 1090 | /* speak revised text */ |
1089 | break; | 1091 | break; |
1090 | 1092 | ||
1091 | #if !defined (KBD_MODES) || defined (KBD_CURSOR_KEYS) | 1093 | #ifdef KBD_CURSOR_KEYS |
1092 | case ACTION_KBD_BACKSPACE: | 1094 | case ACTION_KBD_BACKSPACE: |
1093 | if (pm->hangul) | 1095 | if (pm->hangul) |
1094 | { | 1096 | { |
@@ -1114,7 +1116,7 @@ int kbd_input(char* text, int buflen) | |||
1114 | if (global_settings.talk_menu) /* voice UI? */ | 1116 | if (global_settings.talk_menu) /* voice UI? */ |
1115 | talk_spell(text, false); /* speak revised text */ | 1117 | talk_spell(text, false); /* speak revised text */ |
1116 | break; | 1118 | break; |
1117 | #endif /* !defined (KBD_MODES) || defined (KBD_CURSOR_KEYS) */ | 1119 | #endif /* KBD_CURSOR_KEYS */ |
1118 | 1120 | ||
1119 | case ACTION_KBD_CURSOR_RIGHT: | 1121 | case ACTION_KBD_CURSOR_RIGHT: |
1120 | pm->hangul = false; | 1122 | pm->hangul = false; |
@@ -1145,7 +1147,7 @@ int kbd_input(char* text, int buflen) | |||
1145 | break; | 1147 | break; |
1146 | 1148 | ||
1147 | case BUTTON_NONE: | 1149 | case BUTTON_NONE: |
1148 | #ifdef KBD_MORSE_INPUT | 1150 | #ifdef HAVE_MORSE_INPUT |
1149 | if (morse_reading) | 1151 | if (morse_reading) |
1150 | { | 1152 | { |
1151 | int j; | 1153 | int j; |
@@ -1172,7 +1174,7 @@ int kbd_input(char* text, int buflen) | |||
1172 | if (global_settings.talk_menu) /* voice UI? */ | 1174 | if (global_settings.talk_menu) /* voice UI? */ |
1173 | talk_spell(text, false); /* speak revised text */ | 1175 | talk_spell(text, false); /* speak revised text */ |
1174 | } | 1176 | } |
1175 | #endif /* KBD_MORSE_INPUT */ | 1177 | #endif /* HAVE_MORSE_INPUT */ |
1176 | break; | 1178 | break; |
1177 | 1179 | ||
1178 | default: | 1180 | default: |
@@ -1198,6 +1200,14 @@ int kbd_input(char* text, int buflen) | |||
1198 | if (ret < 0) | 1200 | if (ret < 0) |
1199 | splash(HZ/2, ID2P(LANG_CANCEL)); | 1201 | splash(HZ/2, ID2P(LANG_CANCEL)); |
1200 | 1202 | ||
1203 | #ifdef HAVE_MORSE_INPUT | ||
1204 | if(global_settings.morse_input != morse_mode) | ||
1205 | { | ||
1206 | global_settings.morse_input = morse_mode; | ||
1207 | settings_save(); | ||
1208 | } | ||
1209 | #endif /* HAVE_MORSE_INPUT */ | ||
1210 | |||
1201 | FOR_NB_SCREENS(l) | 1211 | FOR_NB_SCREENS(l) |
1202 | screens[l].setfont(FONT_UI); | 1212 | screens[l].setfont(FONT_UI); |
1203 | viewportmanager_set_statusbar(oldbars); | 1213 | viewportmanager_set_statusbar(oldbars); |
diff --git a/apps/settings.h b/apps/settings.h index 880078885f..eba592aca8 100644 --- a/apps/settings.h +++ b/apps/settings.h | |||
@@ -798,6 +798,10 @@ struct user_settings | |||
798 | int compressor_release_time; | 798 | int compressor_release_time; |
799 | #endif | 799 | #endif |
800 | 800 | ||
801 | #ifdef HAVE_MORSE_INPUT | ||
802 | bool morse_input; /* text input method setting */ | ||
803 | #endif | ||
804 | |||
801 | }; | 805 | }; |
802 | 806 | ||
803 | /** global variables **/ | 807 | /** global variables **/ |
diff --git a/apps/settings_list.c b/apps/settings_list.c index b0a1a76b3a..9f290e2a18 100644 --- a/apps/settings_list.c +++ b/apps/settings_list.c | |||
@@ -1635,6 +1635,10 @@ const struct settings_list settings[] = { | |||
1635 | VIEWPORT_SETTING(remote_ui_vp_config, "remote ui viewport"), | 1635 | VIEWPORT_SETTING(remote_ui_vp_config, "remote ui viewport"), |
1636 | #endif | 1636 | #endif |
1637 | #endif | 1637 | #endif |
1638 | |||
1639 | #ifdef HAVE_MORSE_INPUT | ||
1640 | OFFON_SETTING(0, morse_input, LANG_MORSE_INPUT, false, "morse input", NULL), | ||
1641 | #endif | ||
1638 | }; | 1642 | }; |
1639 | 1643 | ||
1640 | const int nb_settings = sizeof(settings)/sizeof(*settings); | 1644 | const int nb_settings = sizeof(settings)/sizeof(*settings); |
diff --git a/firmware/export/config-creativezv.h b/firmware/export/config-creativezv.h index 5454038f0c..eff5a506c0 100644 --- a/firmware/export/config-creativezv.h +++ b/firmware/export/config-creativezv.h | |||
@@ -76,6 +76,9 @@ | |||
76 | #define HAVE_HEADPHONE_DETECTION | 76 | #define HAVE_HEADPHONE_DETECTION |
77 | //#define HAVE_TOUCHPAD | 77 | //#define HAVE_TOUCHPAD |
78 | 78 | ||
79 | /* Define this to enable morse code input */ | ||
80 | #define HAVE_MORSE_INPUT | ||
81 | |||
79 | /* Define this if you do software codec */ | 82 | /* Define this if you do software codec */ |
80 | #define CONFIG_CODEC SWCODEC | 83 | #define CONFIG_CODEC SWCODEC |
81 | 84 | ||
diff --git a/firmware/export/config-creativezvm.h b/firmware/export/config-creativezvm.h index 37d2eb48cf..d8005bb83d 100644 --- a/firmware/export/config-creativezvm.h +++ b/firmware/export/config-creativezvm.h | |||
@@ -77,6 +77,9 @@ | |||
77 | #define HAVE_HEADPHONE_DETECTION | 77 | #define HAVE_HEADPHONE_DETECTION |
78 | //#define HAVE_TOUCHPAD | 78 | //#define HAVE_TOUCHPAD |
79 | 79 | ||
80 | /* Define this to enable morse code input */ | ||
81 | #define HAVE_MORSE_INPUT | ||
82 | |||
80 | /* Define this if you do software codec */ | 83 | /* Define this if you do software codec */ |
81 | #define CONFIG_CODEC SWCODEC | 84 | #define CONFIG_CODEC SWCODEC |
82 | 85 | ||
diff --git a/firmware/export/config-creativezvm60gb.h b/firmware/export/config-creativezvm60gb.h index e34515ca44..3e95ae7be7 100644 --- a/firmware/export/config-creativezvm60gb.h +++ b/firmware/export/config-creativezvm60gb.h | |||
@@ -76,6 +76,9 @@ | |||
76 | #define HAVE_HEADPHONE_DETECTION | 76 | #define HAVE_HEADPHONE_DETECTION |
77 | //#define HAVE_TOUCHPAD | 77 | //#define HAVE_TOUCHPAD |
78 | 78 | ||
79 | /* Define this to enable morse code input */ | ||
80 | #define HAVE_MORSE_INPUT | ||
81 | |||
79 | /* Define this if you do software codec */ | 82 | /* Define this if you do software codec */ |
80 | #define CONFIG_CODEC SWCODEC | 83 | #define CONFIG_CODEC SWCODEC |
81 | 84 | ||
diff --git a/firmware/export/config-e200.h b/firmware/export/config-e200.h index dd65e6a37d..687878ce06 100644 --- a/firmware/export/config-e200.h +++ b/firmware/export/config-e200.h | |||
@@ -73,6 +73,9 @@ | |||
73 | 73 | ||
74 | #define CONFIG_KEYPAD SANSA_E200_PAD | 74 | #define CONFIG_KEYPAD SANSA_E200_PAD |
75 | 75 | ||
76 | /* Define this to enable morse code input */ | ||
77 | #define HAVE_MORSE_INPUT | ||
78 | |||
76 | /* Define this if you do software codec */ | 79 | /* Define this if you do software codec */ |
77 | #define CONFIG_CODEC SWCODEC | 80 | #define CONFIG_CODEC SWCODEC |
78 | /* There is no hardware tone control */ | 81 | /* There is no hardware tone control */ |
diff --git a/firmware/export/config-e200v2.h b/firmware/export/config-e200v2.h index b4985ecd6d..d42f28ac2f 100644 --- a/firmware/export/config-e200v2.h +++ b/firmware/export/config-e200v2.h | |||
@@ -73,6 +73,9 @@ | |||
73 | 73 | ||
74 | #define CONFIG_KEYPAD SANSA_E200_PAD | 74 | #define CONFIG_KEYPAD SANSA_E200_PAD |
75 | 75 | ||
76 | /* Define this to enable morse code input */ | ||
77 | #define HAVE_MORSE_INPUT | ||
78 | |||
76 | /* Define this if you do software codec */ | 79 | /* Define this if you do software codec */ |
77 | #define CONFIG_CODEC SWCODEC | 80 | #define CONFIG_CODEC SWCODEC |
78 | 81 | ||
diff --git a/firmware/export/config-fmrecorder.h b/firmware/export/config-fmrecorder.h index 97dc52ebb5..d9f3a95f3e 100644 --- a/firmware/export/config-fmrecorder.h +++ b/firmware/export/config-fmrecorder.h | |||
@@ -48,6 +48,9 @@ | |||
48 | /* define this if you have a Recorder style 10-key keyboard */ | 48 | /* define this if you have a Recorder style 10-key keyboard */ |
49 | #define CONFIG_KEYPAD RECORDER_PAD | 49 | #define CONFIG_KEYPAD RECORDER_PAD |
50 | 50 | ||
51 | /* Define this to enable morse code input */ | ||
52 | #define HAVE_MORSE_INPUT | ||
53 | |||
51 | /* define this if you have a real-time clock */ | 54 | /* define this if you have a real-time clock */ |
52 | #define CONFIG_RTC RTC_M41ST84W | 55 | #define CONFIG_RTC RTC_M41ST84W |
53 | 56 | ||
diff --git a/firmware/export/config-fuze.h b/firmware/export/config-fuze.h index e9b54e14fd..cc6669af39 100644 --- a/firmware/export/config-fuze.h +++ b/firmware/export/config-fuze.h | |||
@@ -78,6 +78,9 @@ | |||
78 | 78 | ||
79 | #define CONFIG_KEYPAD SANSA_FUZE_PAD | 79 | #define CONFIG_KEYPAD SANSA_FUZE_PAD |
80 | 80 | ||
81 | /* Define this to enable morse code input */ | ||
82 | #define HAVE_MORSE_INPUT | ||
83 | |||
81 | /* Define this if you do software codec */ | 84 | /* Define this if you do software codec */ |
82 | #define CONFIG_CODEC SWCODEC | 85 | #define CONFIG_CODEC SWCODEC |
83 | 86 | ||
diff --git a/firmware/export/config-gigabeat-s.h b/firmware/export/config-gigabeat-s.h index 344c572e40..7f55797a07 100644 --- a/firmware/export/config-gigabeat-s.h +++ b/firmware/export/config-gigabeat-s.h | |||
@@ -49,10 +49,8 @@ | |||
49 | 49 | ||
50 | #define CONFIG_KEYPAD GIGABEAT_S_PAD | 50 | #define CONFIG_KEYPAD GIGABEAT_S_PAD |
51 | 51 | ||
52 | /* Define keyboard features */ | 52 | /* Define this to enable morse code input */ |
53 | #define KBD_CURSOR_KEYS /* allow non-line edit cursor movement */ | 53 | #define HAVE_MORSE_INPUT |
54 | #define KBD_MODES /* enable line edit */ | ||
55 | #define KBD_MORSE_INPUT /* enable morse code input */ | ||
56 | 54 | ||
57 | /* Define this if you do software codec */ | 55 | /* Define this if you do software codec */ |
58 | #define CONFIG_CODEC SWCODEC | 56 | #define CONFIG_CODEC SWCODEC |
diff --git a/firmware/export/config-gigabeat.h b/firmware/export/config-gigabeat.h index a20a5d87ff..363312a415 100644 --- a/firmware/export/config-gigabeat.h +++ b/firmware/export/config-gigabeat.h | |||
@@ -65,6 +65,9 @@ | |||
65 | 65 | ||
66 | #define CONFIG_KEYPAD GIGABEAT_PAD | 66 | #define CONFIG_KEYPAD GIGABEAT_PAD |
67 | 67 | ||
68 | /* Define this to enable morse code input */ | ||
69 | #define HAVE_MORSE_INPUT | ||
70 | |||
68 | /* Define this if you do software codec */ | 71 | /* Define this if you do software codec */ |
69 | #define CONFIG_CODEC SWCODEC | 72 | #define CONFIG_CODEC SWCODEC |
70 | 73 | ||
diff --git a/firmware/export/config-h10.h b/firmware/export/config-h10.h index 6ad7a8ddc5..cde1b6075e 100644 --- a/firmware/export/config-h10.h +++ b/firmware/export/config-h10.h | |||
@@ -76,6 +76,9 @@ | |||
76 | 76 | ||
77 | #define CONFIG_KEYPAD IRIVER_H10_PAD | 77 | #define CONFIG_KEYPAD IRIVER_H10_PAD |
78 | 78 | ||
79 | /* Define this to enable morse code input */ | ||
80 | #define HAVE_MORSE_INPUT | ||
81 | |||
79 | /* Define this if you do software codec */ | 82 | /* Define this if you do software codec */ |
80 | #define CONFIG_CODEC SWCODEC | 83 | #define CONFIG_CODEC SWCODEC |
81 | 84 | ||
diff --git a/firmware/export/config-h100.h b/firmware/export/config-h100.h index 520079b8a0..d01ee1f3f9 100644 --- a/firmware/export/config-h100.h +++ b/firmware/export/config-h100.h | |||
@@ -69,6 +69,9 @@ | |||
69 | 69 | ||
70 | #define CONFIG_REMOTE_KEYPAD H100_REMOTE | 70 | #define CONFIG_REMOTE_KEYPAD H100_REMOTE |
71 | 71 | ||
72 | /* Define this to enable morse code input */ | ||
73 | #define HAVE_MORSE_INPUT | ||
74 | |||
72 | /* Define this if you do software codec */ | 75 | /* Define this if you do software codec */ |
73 | #define CONFIG_CODEC SWCODEC | 76 | #define CONFIG_CODEC SWCODEC |
74 | 77 | ||
diff --git a/firmware/export/config-h10_5gb.h b/firmware/export/config-h10_5gb.h index e39c6a6bbf..e69f6c2b20 100644 --- a/firmware/export/config-h10_5gb.h +++ b/firmware/export/config-h10_5gb.h | |||
@@ -59,6 +59,9 @@ | |||
59 | 59 | ||
60 | #define CONFIG_KEYPAD IRIVER_H10_PAD | 60 | #define CONFIG_KEYPAD IRIVER_H10_PAD |
61 | 61 | ||
62 | /* Define this to enable morse code input */ | ||
63 | #define HAVE_MORSE_INPUT | ||
64 | |||
62 | /* Define this if you do software codec */ | 65 | /* Define this if you do software codec */ |
63 | #define CONFIG_CODEC SWCODEC | 66 | #define CONFIG_CODEC SWCODEC |
64 | 67 | ||
diff --git a/firmware/export/config-h120.h b/firmware/export/config-h120.h index da75c60ecf..8751c121cc 100644 --- a/firmware/export/config-h120.h +++ b/firmware/export/config-h120.h | |||
@@ -68,6 +68,9 @@ | |||
68 | 68 | ||
69 | #define CONFIG_REMOTE_KEYPAD H100_REMOTE | 69 | #define CONFIG_REMOTE_KEYPAD H100_REMOTE |
70 | 70 | ||
71 | /* Define this to enable morse code input */ | ||
72 | #define HAVE_MORSE_INPUT | ||
73 | |||
71 | /* Define this if you do software codec */ | 74 | /* Define this if you do software codec */ |
72 | #define CONFIG_CODEC SWCODEC | 75 | #define CONFIG_CODEC SWCODEC |
73 | 76 | ||
diff --git a/firmware/export/config-h300.h b/firmware/export/config-h300.h index 09fce49b10..d2348397d2 100644 --- a/firmware/export/config-h300.h +++ b/firmware/export/config-h300.h | |||
@@ -61,6 +61,9 @@ | |||
61 | 61 | ||
62 | #define CONFIG_REMOTE_KEYPAD H300_REMOTE | 62 | #define CONFIG_REMOTE_KEYPAD H300_REMOTE |
63 | 63 | ||
64 | /* Define this to enable morse code input */ | ||
65 | #define HAVE_MORSE_INPUT | ||
66 | |||
64 | /* Define this if you do software codec */ | 67 | /* Define this if you do software codec */ |
65 | #define CONFIG_CODEC SWCODEC | 68 | #define CONFIG_CODEC SWCODEC |
66 | 69 | ||
diff --git a/firmware/export/config-hdd1630.h b/firmware/export/config-hdd1630.h index f44f7d1729..c9a3b035ca 100644 --- a/firmware/export/config-hdd1630.h +++ b/firmware/export/config-hdd1630.h | |||
@@ -77,6 +77,9 @@ | |||
77 | 77 | ||
78 | #define CONFIG_KEYPAD PHILIPS_HDD1630_PAD | 78 | #define CONFIG_KEYPAD PHILIPS_HDD1630_PAD |
79 | 79 | ||
80 | /* Define this to enable morse code input */ | ||
81 | #define HAVE_MORSE_INPUT | ||
82 | |||
80 | /* define this if the target has volume keys which can be used in the lists */ | 83 | /* define this if the target has volume keys which can be used in the lists */ |
81 | #define HAVE_VOLUME_IN_LIST | 84 | #define HAVE_VOLUME_IN_LIST |
82 | 85 | ||
diff --git a/firmware/export/config-iaudiom5.h b/firmware/export/config-iaudiom5.h index 00e07a92cd..03add43dbf 100644 --- a/firmware/export/config-iaudiom5.h +++ b/firmware/export/config-iaudiom5.h | |||
@@ -83,6 +83,9 @@ | |||
83 | 83 | ||
84 | #define CONFIG_KEYPAD IAUDIO_X5M5_PAD | 84 | #define CONFIG_KEYPAD IAUDIO_X5M5_PAD |
85 | 85 | ||
86 | /* Define this to enable morse code input */ | ||
87 | #define HAVE_MORSE_INPUT | ||
88 | |||
86 | #define AB_REPEAT_ENABLE 1 | 89 | #define AB_REPEAT_ENABLE 1 |
87 | #define ACTION_WPSAB_SINGLE ACTION_WPS_BROWSE | 90 | #define ACTION_WPSAB_SINGLE ACTION_WPS_BROWSE |
88 | 91 | ||
diff --git a/firmware/export/config-iaudiox5.h b/firmware/export/config-iaudiox5.h index a6b48b98a8..bafe51f12d 100644 --- a/firmware/export/config-iaudiox5.h +++ b/firmware/export/config-iaudiox5.h | |||
@@ -85,6 +85,9 @@ | |||
85 | 85 | ||
86 | #define CONFIG_KEYPAD IAUDIO_X5M5_PAD | 86 | #define CONFIG_KEYPAD IAUDIO_X5M5_PAD |
87 | 87 | ||
88 | /* Define this to enable morse code input */ | ||
89 | #define HAVE_MORSE_INPUT | ||
90 | |||
88 | #define AB_REPEAT_ENABLE 1 | 91 | #define AB_REPEAT_ENABLE 1 |
89 | #define ACTION_WPSAB_SINGLE ACTION_WPS_BROWSE | 92 | #define ACTION_WPSAB_SINGLE ACTION_WPS_BROWSE |
90 | 93 | ||
diff --git a/firmware/export/config-ipod1g2g.h b/firmware/export/config-ipod1g2g.h index 835b75bd85..cde745e874 100644 --- a/firmware/export/config-ipod1g2g.h +++ b/firmware/export/config-ipod1g2g.h | |||
@@ -77,6 +77,9 @@ | |||
77 | 77 | ||
78 | #define HAVE_SCROLLWHEEL | 78 | #define HAVE_SCROLLWHEEL |
79 | 79 | ||
80 | /* Define this to enable morse code input */ | ||
81 | #define HAVE_MORSE_INPUT | ||
82 | |||
80 | /* Define this if you do software codec */ | 83 | /* Define this if you do software codec */ |
81 | #define CONFIG_CODEC SWCODEC | 84 | #define CONFIG_CODEC SWCODEC |
82 | 85 | ||
diff --git a/firmware/export/config-ipod3g.h b/firmware/export/config-ipod3g.h index 7cab8846ef..e82cc92f56 100644 --- a/firmware/export/config-ipod3g.h +++ b/firmware/export/config-ipod3g.h | |||
@@ -78,6 +78,9 @@ | |||
78 | 78 | ||
79 | #define HAVE_SCROLLWHEEL | 79 | #define HAVE_SCROLLWHEEL |
80 | 80 | ||
81 | /* Define this to enable morse code input */ | ||
82 | #define HAVE_MORSE_INPUT | ||
83 | |||
81 | /* Define this if you do software codec */ | 84 | /* Define this if you do software codec */ |
82 | #define CONFIG_CODEC SWCODEC | 85 | #define CONFIG_CODEC SWCODEC |
83 | 86 | ||
diff --git a/firmware/export/config-ipod4g.h b/firmware/export/config-ipod4g.h index 6195e0c1b6..c00a6788c6 100644 --- a/firmware/export/config-ipod4g.h +++ b/firmware/export/config-ipod4g.h | |||
@@ -76,6 +76,9 @@ | |||
76 | 76 | ||
77 | #define CONFIG_KEYPAD IPOD_4G_PAD | 77 | #define CONFIG_KEYPAD IPOD_4G_PAD |
78 | 78 | ||
79 | /* Define this to enable morse code input */ | ||
80 | #define HAVE_MORSE_INPUT | ||
81 | |||
79 | /* Define this if you do software codec */ | 82 | /* Define this if you do software codec */ |
80 | #define CONFIG_CODEC SWCODEC | 83 | #define CONFIG_CODEC SWCODEC |
81 | 84 | ||
diff --git a/firmware/export/config-ipodcolor.h b/firmware/export/config-ipodcolor.h index 7c7897b67b..751522d47b 100644 --- a/firmware/export/config-ipodcolor.h +++ b/firmware/export/config-ipodcolor.h | |||
@@ -60,6 +60,9 @@ | |||
60 | 60 | ||
61 | #define CONFIG_KEYPAD IPOD_4G_PAD | 61 | #define CONFIG_KEYPAD IPOD_4G_PAD |
62 | 62 | ||
63 | /* Define this to enable morse code input */ | ||
64 | #define HAVE_MORSE_INPUT | ||
65 | |||
63 | /* Define this if you do software codec */ | 66 | /* Define this if you do software codec */ |
64 | #define CONFIG_CODEC SWCODEC | 67 | #define CONFIG_CODEC SWCODEC |
65 | 68 | ||
diff --git a/firmware/export/config-ipodmini.h b/firmware/export/config-ipodmini.h index be3ab2bc96..129829ffbb 100644 --- a/firmware/export/config-ipodmini.h +++ b/firmware/export/config-ipodmini.h | |||
@@ -77,6 +77,9 @@ | |||
77 | 77 | ||
78 | #define HAVE_SCROLLWHEEL | 78 | #define HAVE_SCROLLWHEEL |
79 | 79 | ||
80 | /* Define this to enable morse code input */ | ||
81 | #define HAVE_MORSE_INPUT | ||
82 | |||
80 | /* Define this if you do software codec */ | 83 | /* Define this if you do software codec */ |
81 | #define CONFIG_CODEC SWCODEC | 84 | #define CONFIG_CODEC SWCODEC |
82 | 85 | ||
diff --git a/firmware/export/config-ipodmini2g.h b/firmware/export/config-ipodmini2g.h index 53476b177f..8087269485 100644 --- a/firmware/export/config-ipodmini2g.h +++ b/firmware/export/config-ipodmini2g.h | |||
@@ -75,6 +75,9 @@ | |||
75 | 75 | ||
76 | #define CONFIG_KEYPAD IPOD_4G_PAD | 76 | #define CONFIG_KEYPAD IPOD_4G_PAD |
77 | 77 | ||
78 | /* Define this to enable morse code input */ | ||
79 | #define HAVE_MORSE_INPUT | ||
80 | |||
78 | /* Define this if you do software codec */ | 81 | /* Define this if you do software codec */ |
79 | #define CONFIG_CODEC SWCODEC | 82 | #define CONFIG_CODEC SWCODEC |
80 | 83 | ||
diff --git a/firmware/export/config-ipodnano.h b/firmware/export/config-ipodnano.h index f1a4d6a65e..68ed152cda 100644 --- a/firmware/export/config-ipodnano.h +++ b/firmware/export/config-ipodnano.h | |||
@@ -60,6 +60,9 @@ | |||
60 | 60 | ||
61 | #define CONFIG_KEYPAD IPOD_4G_PAD | 61 | #define CONFIG_KEYPAD IPOD_4G_PAD |
62 | 62 | ||
63 | /* Define this to enable morse code input */ | ||
64 | #define HAVE_MORSE_INPUT | ||
65 | |||
63 | /* Define this if you do software codec */ | 66 | /* Define this if you do software codec */ |
64 | #define CONFIG_CODEC SWCODEC | 67 | #define CONFIG_CODEC SWCODEC |
65 | 68 | ||
diff --git a/firmware/export/config-ipodnano2g.h b/firmware/export/config-ipodnano2g.h index bcc98e0da3..2e044335da 100644 --- a/firmware/export/config-ipodnano2g.h +++ b/firmware/export/config-ipodnano2g.h | |||
@@ -94,6 +94,9 @@ | |||
94 | //#define AB_REPEAT_ENABLE 1 | 94 | //#define AB_REPEAT_ENABLE 1 |
95 | //#define ACTION_WPSAB_SINGLE ACTION_WPS_BROWSE | 95 | //#define ACTION_WPSAB_SINGLE ACTION_WPS_BROWSE |
96 | 96 | ||
97 | /* Define this to enable morse code input */ | ||
98 | #define HAVE_MORSE_INPUT | ||
99 | |||
97 | /* Define this if you do software codec */ | 100 | /* Define this if you do software codec */ |
98 | #define CONFIG_CODEC SWCODEC | 101 | #define CONFIG_CODEC SWCODEC |
99 | 102 | ||
diff --git a/firmware/export/config-ipodvideo.h b/firmware/export/config-ipodvideo.h index 9762e71a73..f00de9cbfd 100644 --- a/firmware/export/config-ipodvideo.h +++ b/firmware/export/config-ipodvideo.h | |||
@@ -62,6 +62,9 @@ | |||
62 | 62 | ||
63 | #define CONFIG_KEYPAD IPOD_4G_PAD | 63 | #define CONFIG_KEYPAD IPOD_4G_PAD |
64 | 64 | ||
65 | /* Define this to enable morse code input */ | ||
66 | #define HAVE_MORSE_INPUT | ||
67 | |||
65 | /* Define this if you do software codec */ | 68 | /* Define this if you do software codec */ |
66 | #define CONFIG_CODEC SWCODEC | 69 | #define CONFIG_CODEC SWCODEC |
67 | 70 | ||
diff --git a/firmware/export/config-m200.h b/firmware/export/config-m200.h index 59f5ad7cfb..0f071e18ab 100644 --- a/firmware/export/config-m200.h +++ b/firmware/export/config-m200.h | |||
@@ -58,6 +58,9 @@ | |||
58 | /* define this to indicate your device's keypad */ | 58 | /* define this to indicate your device's keypad */ |
59 | #define CONFIG_KEYPAD SANSA_M200_PAD | 59 | #define CONFIG_KEYPAD SANSA_M200_PAD |
60 | 60 | ||
61 | /* Define this to enable morse code input */ | ||
62 | #define HAVE_MORSE_INPUT | ||
63 | |||
61 | /* define this if you have a real-time clock */ | 64 | /* define this if you have a real-time clock */ |
62 | #define CONFIG_RTC RTC_TCC77X | 65 | #define CONFIG_RTC RTC_TCC77X |
63 | 66 | ||
diff --git a/firmware/export/config-m200v4.h b/firmware/export/config-m200v4.h index 13dcec92ff..af9f1aedc6 100644 --- a/firmware/export/config-m200v4.h +++ b/firmware/export/config-m200v4.h | |||
@@ -61,6 +61,9 @@ | |||
61 | /* define this to indicate your device's keypad */ | 61 | /* define this to indicate your device's keypad */ |
62 | #define CONFIG_KEYPAD SANSA_M200_PAD | 62 | #define CONFIG_KEYPAD SANSA_M200_PAD |
63 | 63 | ||
64 | /* Define this to enable morse code input */ | ||
65 | #define HAVE_MORSE_INPUT | ||
66 | |||
64 | /* define this if you have a real-time clock */ | 67 | /* define this if you have a real-time clock */ |
65 | #ifndef BOOTLOADER | 68 | #ifndef BOOTLOADER |
66 | #define CONFIG_RTC RTC_AS3514 | 69 | #define CONFIG_RTC RTC_AS3514 |
diff --git a/firmware/export/config-mrobe100.h b/firmware/export/config-mrobe100.h index 5a2790062d..90419914b2 100644 --- a/firmware/export/config-mrobe100.h +++ b/firmware/export/config-mrobe100.h | |||
@@ -64,6 +64,9 @@ | |||
64 | #define CONFIG_KEYPAD MROBE100_PAD | 64 | #define CONFIG_KEYPAD MROBE100_PAD |
65 | #define CONFIG_REMOTE_KEYPAD MROBE_REMOTE | 65 | #define CONFIG_REMOTE_KEYPAD MROBE_REMOTE |
66 | 66 | ||
67 | /* Define this to enable morse code input */ | ||
68 | #define HAVE_MORSE_INPUT | ||
69 | |||
67 | /* Define this if you do software codec */ | 70 | /* Define this if you do software codec */ |
68 | #define CONFIG_CODEC SWCODEC | 71 | #define CONFIG_CODEC SWCODEC |
69 | 72 | ||
diff --git a/firmware/export/config-mrobe500.h b/firmware/export/config-mrobe500.h index 82ba8a8e83..96e25c9247 100644 --- a/firmware/export/config-mrobe500.h +++ b/firmware/export/config-mrobe500.h | |||
@@ -138,6 +138,9 @@ | |||
138 | #define HAVE_TOUCHSCREEN | 138 | #define HAVE_TOUCHSCREEN |
139 | #define HAVE_BUTTON_DATA | 139 | #define HAVE_BUTTON_DATA |
140 | 140 | ||
141 | /* Define this to enable morse code input */ | ||
142 | #define HAVE_MORSE_INPUT | ||
143 | |||
141 | /* define this if the target has volume keys which can be used in the lists */ | 144 | /* define this if the target has volume keys which can be used in the lists */ |
142 | #define HAVE_VOLUME_IN_LIST | 145 | #define HAVE_VOLUME_IN_LIST |
143 | 146 | ||
diff --git a/firmware/export/config-recorder.h b/firmware/export/config-recorder.h index 88ff2c2006..ef9f523c49 100644 --- a/firmware/export/config-recorder.h +++ b/firmware/export/config-recorder.h | |||
@@ -48,6 +48,9 @@ | |||
48 | /* define this if you have the Recorder's 10-key keyboard */ | 48 | /* define this if you have the Recorder's 10-key keyboard */ |
49 | #define CONFIG_KEYPAD RECORDER_PAD | 49 | #define CONFIG_KEYPAD RECORDER_PAD |
50 | 50 | ||
51 | /* Define this to enable morse code input */ | ||
52 | #define HAVE_MORSE_INPUT | ||
53 | |||
51 | /* define this if you have a real-time clock */ | 54 | /* define this if you have a real-time clock */ |
52 | #define CONFIG_RTC RTC_M41ST84W | 55 | #define CONFIG_RTC RTC_M41ST84W |
53 | 56 | ||
diff --git a/firmware/export/config-recorderv2.h b/firmware/export/config-recorderv2.h index 6a5564487e..c530fa5815 100644 --- a/firmware/export/config-recorderv2.h +++ b/firmware/export/config-recorderv2.h | |||
@@ -48,6 +48,9 @@ | |||
48 | /* define this if you have a Recorder style 10-key keyboard */ | 48 | /* define this if you have a Recorder style 10-key keyboard */ |
49 | #define CONFIG_KEYPAD RECORDER_PAD | 49 | #define CONFIG_KEYPAD RECORDER_PAD |
50 | 50 | ||
51 | /* Define this to enable morse code input */ | ||
52 | #define HAVE_MORSE_INPUT | ||
53 | |||
51 | /* define this if you have a real-time clock */ | 54 | /* define this if you have a real-time clock */ |
52 | #define CONFIG_RTC RTC_M41ST84W | 55 | #define CONFIG_RTC RTC_M41ST84W |
53 | 56 | ||
diff --git a/firmware/export/config-sa9200.h b/firmware/export/config-sa9200.h index ce233184cb..d9b9462880 100644 --- a/firmware/export/config-sa9200.h +++ b/firmware/export/config-sa9200.h | |||
@@ -62,6 +62,9 @@ | |||
62 | 62 | ||
63 | #define CONFIG_KEYPAD PHILIPS_SA9200_PAD | 63 | #define CONFIG_KEYPAD PHILIPS_SA9200_PAD |
64 | 64 | ||
65 | /* Define this to enable morse code input */ | ||
66 | #define HAVE_MORSE_INPUT | ||
67 | |||
65 | /* define this if the target has volume keys which can be used in the lists */ | 68 | /* define this if the target has volume keys which can be used in the lists */ |
66 | #define HAVE_VOLUME_IN_LIST | 69 | #define HAVE_VOLUME_IN_LIST |
67 | 70 | ||
diff --git a/firmware/export/config-view.h b/firmware/export/config-view.h index 7b13bf74ba..4111b8380a 100644 --- a/firmware/export/config-view.h +++ b/firmware/export/config-view.h | |||
@@ -74,6 +74,9 @@ | |||
74 | /* The only difference is that the power/hold is on the left instead of right on Fuze */ | 74 | /* The only difference is that the power/hold is on the left instead of right on Fuze */ |
75 | #define CONFIG_KEYPAD SANSA_FUZE_PAD | 75 | #define CONFIG_KEYPAD SANSA_FUZE_PAD |
76 | 76 | ||
77 | /* Define this to enable morse code input */ | ||
78 | #define HAVE_MORSE_INPUT | ||
79 | |||
77 | /* Define this if you do software codec */ | 80 | /* Define this if you do software codec */ |
78 | #define CONFIG_CODEC SWCODEC | 81 | #define CONFIG_CODEC SWCODEC |
79 | /* There is no hardware tone control */ | 82 | /* There is no hardware tone control */ |