Skip to content

Commit 801f133

Browse files
committed
-
1 parent da12840 commit 801f133

File tree

9 files changed

+115
-104
lines changed

9 files changed

+115
-104
lines changed

coderbot.cfg

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
{"move_tr_speed": "75", "move_fw_elapse": "1.5", "show_page_program": "true", "load_at_start": "", "move_tr_elapse": "1", "sound_start": "$startup.mp3", "sound_stop": "$shutdown.mp3", "camera_exposure_mode": "auto", "prog_video_rec": "true", "show_control_move_commands": "true", "prog_level": "std", "prog_scrollbars": "true", "ctrl_fw_speed": "100", "move_fw_speed": "100", "sound_shutter": "$shutter.mp3", "show_page_prefs": "true", "prog_maxblocks": "-1", "ctrl_hud_image": "", "move_motor_mode": "dc", "ctrl_fw_elapse": "-1", "ctrl_tr_elapse": "-1", "show_page_control": "true", "ctrl_tr_speed": "80"}
1+
{"move_tr_speed": "75", "move_fw_elapse": "1.5", "show_page_program": "true", "load_at_start": "", "move_tr_elapse": "1", "sound_start": "$startup.mp3", "sound_stop": "$shutdown.mp3", "camera_exposure_mode": "auto", "prog_video_rec": "true", "show_control_move_commands": "true", "prog_level": "std", "prog_scrollbars": "true", "ctrl_fw_speed": "100", "move_fw_speed": "100", "sound_shutter": "$shutter.mp3", "show_page_prefs": "true", "prog_maxblocks": "-1", "ctrl_hud_image": "", "button_func": "none", "move_motor_mode": "dc", "ctrl_fw_elapse": "-1", "ctrl_tr_elapse": "-1", "show_page_control": "true", "ctrl_tr_speed": "80"}

messages.pot

Lines changed: 41 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ msgid ""
88
msgstr ""
99
"Project-Id-Version: PROJECT VERSION\n"
1010
"Report-Msgid-Bugs-To: EMAIL@ADDRESS\n"
11-
"POT-Creation-Date: 2015-03-07 22:53+0000\n"
11+
"POT-Creation-Date: 2015-03-14 22:00+0000\n"
1212
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
1313
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
1414
"Language-Team: LANGUAGE <[email protected]>\n"
@@ -69,7 +69,7 @@ msgid "Camera"
6969
msgstr ""
7070

7171
#: templates/blocks_adv.xml:234 templates/blocks_std.xml:69
72-
#: templates/config.html:14 templates/config.html:76
72+
#: templates/config.html:14
7373
msgid "Sensor"
7474
msgstr ""
7575

@@ -106,31 +106,31 @@ msgstr ""
106106
msgid "Button"
107107
msgstr ""
108108

109-
#: templates/config.html:18 templates/config.html:105
109+
#: templates/config.html:18 templates/config.html:118
110110
msgid "User Interface"
111111
msgstr ""
112112

113-
#: templates/config.html:23
113+
#: templates/config.html:23 templates/config.html:60
114114
msgid "Movement assisted by vision"
115115
msgstr ""
116116

117117
#: templates/config.html:26
118118
msgid "Step timing | distance / angle"
119119
msgstr ""
120120

121-
#: templates/config.html:27 templates/config.html:81
121+
#: templates/config.html:27 templates/config.html:63
122122
msgid "Forward speed"
123123
msgstr ""
124124

125-
#: templates/config.html:29
125+
#: templates/config.html:29 templates/config.html:65
126126
msgid "Forward elapse / distance"
127127
msgstr ""
128128

129-
#: templates/config.html:31 templates/config.html:85
129+
#: templates/config.html:31 templates/config.html:67
130130
msgid "Turn speed"
131131
msgstr ""
132132

133-
#: templates/config.html:33
133+
#: templates/config.html:33 templates/config.html:69
134134
msgid "Turn elapse / angle"
135135
msgstr ""
136136

@@ -170,125 +170,125 @@ msgstr ""
170170
msgid "Shows Editor scrollbars"
171171
msgstr ""
172172

173-
#: templates/config.html:60
173+
#: templates/config.html:72
174174
msgid "Other program parameters"
175175
msgstr ""
176176

177-
#: templates/config.html:61
177+
#: templates/config.html:73
178178
msgid "Auto record video on program run"
179179
msgstr ""
180180

181-
#: templates/config.html:64
181+
#: templates/config.html:76
182182
msgid "Max number of blocks allowed"
183183
msgstr ""
184184

185-
#: templates/config.html:68
185+
#: templates/config.html:80
186186
msgid "Start sound"
187187
msgstr ""
188188

189-
#: templates/config.html:70
189+
#: templates/config.html:82
190190
msgid "Stop sound"
191191
msgstr ""
192192

193-
#: templates/config.html:72
193+
#: templates/config.html:84
194194
msgid "Shutter sound"
195195
msgstr ""
196196

197-
#: templates/config.html:79
198-
msgid "Motor control mode"
197+
#: templates/config.html:88
198+
msgid "Camera parameters"
199199
msgstr ""
200200

201-
#: templates/config.html:83
202-
msgid "Forward elapse"
201+
#: templates/config.html:89
202+
msgid "Exposure mode"
203203
msgstr ""
204204

205-
#: templates/config.html:87
206-
msgid "Turn elapse"
205+
#: templates/config.html:100
206+
msgid "Motor control mode"
207207
msgstr ""
208208

209-
#: templates/config.html:91
209+
#: templates/config.html:104
210210
msgid "Load at start"
211211
msgstr ""
212212

213-
#: templates/config.html:96
213+
#: templates/config.html:109
214214
msgid "Button function"
215215
msgstr ""
216216

217-
#: templates/config.html:97
217+
#: templates/config.html:110
218218
msgid "None"
219219
msgstr ""
220220

221-
#: templates/config.html:99
221+
#: templates/config.html:112
222222
msgid "Start/Stop current program"
223223
msgstr ""
224224

225-
#: templates/config.html:106
225+
#: templates/config.html:119
226226
msgid "Show Control page"
227227
msgstr ""
228228

229-
#: templates/config.html:108
229+
#: templates/config.html:121
230230
msgid "Show Control movement commands"
231231
msgstr ""
232232

233-
#: templates/config.html:110
233+
#: templates/config.html:123
234234
msgid "Show Program page"
235235
msgstr ""
236236

237-
#: templates/config.html:112
237+
#: templates/config.html:125
238238
msgid "Show Preferences button"
239239
msgstr ""
240240

241-
#: templates/config.html:117
241+
#: templates/config.html:130
242242
msgid "Cancel"
243243
msgstr ""
244244

245-
#: templates/config.html:118 templates/program.html:18
245+
#: templates/config.html:131 templates/program.html:18
246246
#: templates/program.html:26
247247
msgid "Save"
248248
msgstr ""
249249

250-
#: templates/config_params.html:18
250+
#: templates/config_params.html:19
251251
msgid "Say what:"
252252
msgstr ""
253253

254-
#: templates/config_params.html:19
254+
#: templates/config_params.html:20
255255
msgid "Saved"
256256
msgstr ""
257257

258-
#: templates/config_params.html:20
258+
#: templates/config_params.html:21
259259
msgid "Program saved"
260260
msgstr ""
261261

262-
#: templates/config_params.html:21
262+
#: templates/config_params.html:22
263263
msgid "Program name already in use, overwrite?"
264264
msgstr ""
265265

266-
#: templates/config_params.html:22
266+
#: templates/config_params.html:23
267267
msgid "Delete"
268268
msgstr ""
269269

270-
#: templates/config_params.html:23
270+
#: templates/config_params.html:24
271271
msgid "Delete photo"
272272
msgstr ""
273273

274-
#: templates/config_params.html:24
274+
#: templates/config_params.html:25
275275
msgid "Reset move counter?"
276276
msgstr ""
277277

278-
#: templates/config_params.html:25 templates/program.html:40
278+
#: templates/config_params.html:26 templates/program.html:40
279279
msgid "is running"
280280
msgstr ""
281281

282-
#: templates/config_params.html:26
282+
#: templates/config_params.html:27
283283
msgid "stopped"
284284
msgstr ""
285285

286-
#: templates/config_params.html:27 templates/control.html:51
286+
#: templates/config_params.html:28 templates/control.html:51
287287
#: templates/program.html:32
288288
msgid "Stop"
289289
msgstr ""
290290

291-
#: templates/config_params.html:28
291+
#: templates/config_params.html:29
292292
msgid "Close"
293293
msgstr ""
294294

1.84 KB
Loading

static/js/control.js

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,13 @@ Mousetrap.bind(['command+alt+s', 'ctrl+alt+k'], function(e) {
154154
$.mobile.pageContainer.pagecontainer('change', '#page-preferences');
155155
return false;
156156
});
157-
157+
158+
Mousetrap.bind(['command+alt+h', 'ctrl+alt+h'], function(e) {
159+
if(confirm("Shutdown CoderBot?")){
160+
bot.halt();
161+
}
162+
});
163+
158164
botStatus();
159165

160166
function botStatus() {

templates/config.html

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,18 @@ <h1>CoderBot</h1>
5656
<label for="c_prog_scrollbars">{% trans %}Shows Editor scrollbars{% endtrans %}</label>
5757
<input type="checkbox" name="prog_scrollbars" id="c_prog_scrollbars" value="true" {%if config.prog_scrollbars=='true'%}checked="checked"{%endif%}>
5858
</fieldset>
59+
<div class="ui-field-contain">
60+
<label for="i_prog_move_mode">{% trans %}Movement assisted by vision{% endtrans %}</label>
61+
<input type="checkbox" data-role="flipswitch" id="i_prog_move_mode" name="prog_move_motion" value="yes"{%if config.prog_move_motion%} checked{%endif%}>
62+
</div>
63+
<label for="i_move_fw_speed">{% trans %}Forward speed{% endtrans %}</label>
64+
<input type="text" id="i_move_fw_speed" name="move_fw_speed" value="{{config.move_fw_speed}}">
65+
<label for="i_move_fw_elapse">{% trans %}Forward elapse / distance{% endtrans %}</label>
66+
<input type="text" id="i_move_fw_elapse" name="move_fw_elapse" value="{{config.move_fw_elapse}}">
67+
<label for="i_move_tr_speed">{% trans %}Turn speed{% endtrans %}</label>
68+
<input type="text" id="i_move_tr_speed" name="move_tr_speed" value="{{config.move_tr_speed}}">
69+
<label for="i_move_tr_elapse">{% trans %}Turn elapse / angle{% endtrans %}</label>
70+
<input type="text" id="i_move_tr_elapse" name="move_tr_elapse" value="{{config.move_tr_elapse}}">
5971
<fieldset data-role="controlgroup" data-mini="true">
6072
<legend>{% trans %}Other program parameters{% endtrans %}</legend>
6173
<label for="c_prog_video_rec">{% trans %}Auto record video on program run{% endtrans %}</label>
@@ -87,18 +99,6 @@ <h1>CoderBot</h1>
8799
<div id="t_movement" class="ui-body-d ui-content">
88100
<label for="i_move_motor_mode">{% trans %}Motor control mode{% endtrans %}</label>
89101
<input type="text" id="i_move_motor_mode" name="move_motor_mode" value="{{config.move_motor_mode}}">
90-
<div class="ui-field-contain">
91-
<label for="i_prog_move_mode">{% trans %}Movement assisted by vision{% endtrans %}</label>
92-
<input type="checkbox" data-role="flipswitch" id="i_prog_move_mode" name="prog_move_motion" value="yes"{%if config.prog_move_motion%} checked{%endif%}>
93-
</div>
94-
<label for="i_move_fw_speed">{% trans %}Forward speed{% endtrans %}</label>
95-
<input type="text" id="i_move_fw_speed" name="move_fw_speed" value="{{config.move_fw_speed}}">
96-
<label for="i_move_fw_elapse">{% trans %}Forward elapse{% endtrans %}</label>
97-
<input type="text" id="i_move_fw_elapse" name="move_fw_elapse" value="{{config.move_fw_elapse}}">
98-
<label for="i_move_tr_speed">{% trans %}Turn speed{% endtrans %}</label>
99-
<input type="text" id="i_move_tr_speed" name="move_tr_speed" value="{{config.move_tr_speed}}">
100-
<label for="i_move_tr_elapse">{% trans %}Turn elapse{% endtrans %}</label>
101-
<input type="text" id="i_move_tr_elapse" name="move_tr_elapse" value="{{config.move_tr_elapse}}">
102102
</div>
103103
<div id="t_start" class="ui-body-d ui-content">
104104
<label for="i_load_at_start">{% trans %}Load at start{% endtrans %}</label>

templates/control.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,9 @@ <h1>CoderBot</h1>
1515
{%if config.ctrl_counter%}<div class="" style="position:fixed;left:32px;top:80px;">
1616
<button id="b_counter" class="ui-btn ui-btn-inline ui-btn-traslucent" type="button">0</button>
1717
</div>{%endif%}
18-
<div class="" style="position:fixed;right:32px;top:80px;">
18+
{%if config.show_page_prefs%}<div class="" style="position:fixed;right:32px;top:80px;">
1919
<button id="b_halt" class="ui-btn ui-btn-inline ui-icon-power ui-btn-icon-top ui-btn-traslucent" type="button">{% trans %}Halt{% endtrans %}</button>
20-
</div>
20+
</div>{%endif%}
2121
<div class="ui-grid-b" style="position:fixed; width:100%;bottom:0px;">
2222
<div class="ui-block-a" id="ui_control_left">
2323
{% if config.show_control_move_commands%}<fieldset class="ui-grid-solo">

templates/main.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<meta charset="utf-8">
55
<meta name="viewport" content="width=device-width, initial-scale=1">
66
<title>CoderBot</title>
7-
<link rel="icon" type="image/png" href="/images/coderbot_logo_79.png"/>
7+
<link rel="icon" type="image/png" href="/images/icons/coderbot_logo_79.png"/>
88
<link rel="stylesheet" href="../css/jquery.mobile-1.4.5.min.css">
99
<link rel="stylesheet" href="../css/coderbot.css">
1010
{%include "config_params.html"%}
98 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)