Skip to content

Commit e4148e7

Browse files
committed
Add error handling
1 parent 4ad16fd commit e4148e7

3 files changed

Lines changed: 170 additions & 55 deletions

File tree

src/displayapp/screens/Pawn.cpp

Lines changed: 111 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,17 @@ extern "C" {
1010

1111
using namespace Pinetime::Applications::Screens;
1212

13-
#define AMX_ERR_PARAMCOUNT 32
13+
enum {
14+
PAWN_ERR_PARAMCOUNT = 100,
15+
PAWN_ERR_MISSINGHANDLER,
16+
PAWN_ERR_INVALIDSTRING,
17+
18+
PAWN_ERR_FIRST = PAWN_ERR_PARAMCOUNT,
19+
};
1420

1521
#define ASSERT_PARAMS(n) \
1622
if (params[0] != n * sizeof(cell)) { \
17-
amx_RaiseError(amx, AMX_ERR_PARAMCOUNT); \
23+
amx_RaiseError(amx, PAWN_ERR_PARAMCOUNT); \
1824
return 0; \
1925
}
2026

@@ -25,11 +31,17 @@ using namespace Pinetime::Applications::Screens;
2531
constexpr int max_overlay_size = 512;
2632

2733
static void event_handler(lv_obj_t* obj, lv_event_t event) {
34+
if (event == LV_EVENT_DELETE)
35+
return;
36+
2837
AMX* amx = (AMX*) lv_obj_get_user_data(lv_scr_act());
2938
int handler_index = (int) lv_obj_get_user_data(obj);
3039

3140
amx_Push(amx, event);
32-
amx_Exec(amx, nullptr, handler_index);
41+
int result = amx_Exec(amx, nullptr, handler_index);
42+
if (result != AMX_ERR_NONE) {
43+
PAWN_INST->QueueError(result);
44+
}
3345
}
3446

3547
static cell AMX_NATIVE_CALL F_lv_scr_act(AMX* amx, const cell* params) {
@@ -76,6 +88,8 @@ static cell AMX_NATIVE_CALL F_lv_obj_set_event_cb(AMX* amx, const cell* params)
7688
if (amx_FindPublic(amx, name, &index) == AMX_ERR_NONE) {
7789
lv_obj_set_user_data(obj, (void*) index);
7890
lv_obj_set_event_cb(obj, event_handler);
91+
} else {
92+
amx_RaiseError(amx, PAWN_ERR_MISSINGHANDLER);
7993
}
8094
}
8195

@@ -92,7 +106,7 @@ static cell AMX_NATIVE_CALL F_lv_label_set_text(AMX* amx, const cell* params) {
92106
if (text != NULL)
93107
lv_label_set_text(label, text);
94108
else
95-
lv_label_set_text_static(label, "<invalid>");
109+
amx_RaiseError(amx, PAWN_ERR_INVALIDSTRING);
96110

97111
return 0;
98112
}
@@ -179,7 +193,7 @@ static cell AMX_NATIVE_CALL F_sprintf(AMX* amx, const cell* params) {
179193
// param[0] is the number of total parameter bytes, divide it by cell size to get the parameter count
180194
int args_count = params[0] / sizeof(cell);
181195
if (args_count < 4) {
182-
amx_RaiseError(amx, AMX_ERR_PARAMCOUNT);
196+
amx_RaiseError(amx, PAWN_ERR_PARAMCOUNT);
183197
return 0;
184198
}
185199

@@ -193,8 +207,10 @@ static cell AMX_NATIVE_CALL F_sprintf(AMX* amx, const cell* params) {
193207

194208
char* fmt;
195209
amx_StrParam_Type(amx, params[3], fmt, char*);
196-
if (fmt == NULL)
210+
if (fmt == NULL) {
211+
amx_RaiseError(amx, PAWN_ERR_INVALIDSTRING);
197212
return 0;
213+
}
198214

199215
size_t paramc = 4;
200216

@@ -315,7 +331,9 @@ static cell AMX_NATIVE_CALL F_status_icons_create(AMX* amx, const cell*) {
315331
Pawn* pawn = PAWN_INST;
316332

317333
if (pawn->statusIcons == nullptr) {
318-
pawn->statusIcons = new Pinetime::Applications::Widgets::StatusIcons(pawn->controllers.batteryController, pawn->controllers.bleController, pawn->controllers.alarmController);
334+
pawn->statusIcons = new Pinetime::Applications::Widgets::StatusIcons(pawn->controllers.batteryController,
335+
pawn->controllers.bleController,
336+
pawn->controllers.alarmController);
319337
pawn->statusIcons->Create();
320338
}
321339

@@ -331,6 +349,14 @@ static cell AMX_NATIVE_CALL F_status_icons_update(AMX* amx, const cell*) {
331349
return 0;
332350
}
333351

352+
static cell AMX_NATIVE_CALL F_raise_error(AMX* amx, const cell* params) {
353+
ASSERT_PARAMS(1);
354+
355+
amx_RaiseError(amx, params[1]);
356+
357+
return 0;
358+
}
359+
334360
static int AMXAPI prun_Overlay(AMX* amx, int index) {
335361
AMX_HEADER* hdr;
336362
AMX_OVERLAYINFO* tbl;
@@ -433,10 +459,15 @@ extern "C" const AMX_NATIVE pawn_natives[] = {
433459
F_get_datetime_short_str,
434460
F_status_icons_create,
435461
F_status_icons_update,
462+
F_raise_error,
436463
};
437464

438465
Pawn::Pawn(AppControllers& controllers) : controllers(controllers) {
439-
LoadProgram();
466+
int result = LoadProgram();
467+
if (result != AMX_ERR_NONE) {
468+
ShowError(result);
469+
return;
470+
}
440471

441472
amx.userdata[0] = this;
442473

@@ -446,22 +477,34 @@ Pawn::Pawn(AppControllers& controllers) : controllers(controllers) {
446477
if (amx_FindPubVar(&amx, "font_jmec", &font) == AMX_ERR_NONE)
447478
*font = (cell) &jetbrains_mono_extrabold_compressed;
448479

449-
amx_Exec(&amx, NULL, AMX_EXEC_MAIN);
480+
result = amx_Exec(&amx, NULL, AMX_EXEC_MAIN);
481+
if (result != AMX_ERR_NONE) {
482+
ShowError(result);
483+
return;
484+
}
450485

451486
if (amx_FindPublic(&amx, "@refresh", &refresh_index) == AMX_ERR_NONE) {
452487
taskRefresh = lv_task_create(RefreshTaskCallback, LV_DISP_DEF_REFR_PERIOD, LV_TASK_PRIO_MID, this);
453488
Refresh();
454489
}
455490
}
456491

457-
Pawn::~Pawn() {
458-
if (taskRefresh)
492+
void Pawn::CleanUI() {
493+
if (taskRefresh) {
459494
lv_task_del(taskRefresh);
495+
taskRefresh = nullptr;
496+
}
460497

461-
if (statusIcons)
498+
if (statusIcons) {
462499
delete statusIcons;
500+
statusIcons = nullptr;
501+
}
463502

464503
lv_obj_clean(lv_scr_act());
504+
}
505+
506+
Pawn::~Pawn() {
507+
CleanUI();
465508

466509
amx_Cleanup(&amx);
467510

@@ -474,5 +517,60 @@ Pawn::~Pawn() {
474517
}
475518

476519
void Pawn::Refresh() {
477-
amx_Exec(&amx, NULL, refresh_index);
520+
int result = amx_Exec(&amx, NULL, refresh_index);
521+
if (result != AMX_ERR_NONE) {
522+
ShowError(result);
523+
}
524+
}
525+
526+
void Pawn::ShowError(unsigned int amx_err) {
527+
static const char* amx_err_msgs[] = {
528+
nullptr, "EXIT", "ASSERT", "STACKERR", "BOUNDS", "MEMACCESS", "INVINSTR", "STACKLOW", "HEAPLOW", "CALLBACK",
529+
"NATIVE", "DIVIDE", "SLEEP", "INVSTATE", nullptr, nullptr, "MEMORY", "FORMAT", "VERSION", "NOTFOUND",
530+
"INDEX", "DEBUG", "INIT", "USERDATA", "INIT_JIT", "PARAMS", "DOMAIN", "GENERAL", "OVERLAY",
531+
};
532+
static const char* pawn_err_msgs[] = {
533+
"invalid parameter count", // PAWN_ERR_PARAMCOUNT
534+
"missing event handler", // PAWN_ERR_MISSINGHANDLER
535+
};
536+
537+
if (amx_err == AMX_ERR_EXIT) {
538+
running = false;
539+
return;
540+
}
541+
542+
if (amx_err > 0 && amx_err < PAWN_ERR_FIRST && amx_err < sizeof(amx_err_msgs) / sizeof(*amx_err_msgs)) {
543+
ShowError(amx_err_msgs[amx_err]);
544+
} else if (amx_err >= PAWN_ERR_FIRST && amx_err - PAWN_ERR_FIRST < sizeof(pawn_err_msgs) / sizeof(*amx_err_msgs)) {
545+
ShowError(pawn_err_msgs[amx_err - PAWN_ERR_FIRST]);
546+
} else {
547+
char msg[25];
548+
snprintf(msg, sizeof(msg), "unknown error %d", amx_err);
549+
ShowError(msg);
550+
}
551+
}
552+
553+
void Pawn::ShowError(const char* msg) {
554+
CleanUI();
555+
556+
lv_obj_t* msglbl = lv_label_create(lv_scr_act(), nullptr);
557+
lv_obj_set_style_local_text_color(msglbl, LV_LABEL_PART_MAIN, LV_STATE_DEFAULT, lv_color_make(255, 0, 0));
558+
lv_label_set_long_mode(msglbl, LV_LABEL_LONG_BREAK);
559+
lv_label_set_text_fmt(msglbl, "Execution aborted:\n%s\n\nCIP: 0x%X", msg, amx.cip);
560+
lv_obj_set_width(msglbl, 240);
561+
lv_label_set_align(msglbl, LV_LABEL_ALIGN_CENTER);
562+
lv_obj_align(msglbl, NULL, LV_ALIGN_CENTER, 0, 0);
563+
}
564+
565+
void Pawn::QueueError(unsigned int amx_err) {
566+
if (this->queued_error != 0)
567+
return;
568+
569+
this->queued_error = amx_err;
570+
lv_async_call(
571+
[](void* user_data) {
572+
Pawn* pawn = static_cast<Pawn*>(user_data);
573+
pawn->ShowError(pawn->queued_error);
574+
},
575+
this);
478576
}

src/displayapp/screens/Pawn.h

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,10 @@ namespace Pinetime {
2121

2222
void Refresh() override;
2323

24+
void QueueError(unsigned int amx_err);
25+
void ShowError(unsigned int amx_err);
26+
void ShowError(const char* msg);
27+
2428
Utility::DirtyValue<std::chrono::time_point<std::chrono::system_clock, std::chrono::minutes>> currentDateTime {};
2529
AppControllers& controllers;
2630

@@ -30,10 +34,12 @@ namespace Pinetime {
3034
AMX amx;
3135
int refresh_index;
3236
lv_task_t* taskRefresh = 0;
37+
unsigned int queued_error = 0;
3338

3439
void *header = nullptr, *datablock = nullptr, *overlaypool = nullptr;
3540

3641
int LoadProgram();
42+
void CleanUI();
3743
};
3844
}
3945

src/displayapp/screens/program.h

Lines changed: 53 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -1,57 +1,68 @@
11
const unsigned char program[] = {
2-
0xc8, 0x02, 0x00, 0x00, 0xe0, 0xf1, 0x0b, 0x0b, 0x04, 0x00, 0x08, 0x00,
3-
0x64, 0x00, 0x00, 0x00, 0x64, 0x02, 0x00, 0x00, 0xc8, 0x02, 0x00, 0x00,
4-
0x90, 0x03, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00,
5-
0x44, 0x00, 0x00, 0x00, 0x44, 0x00, 0x00, 0x00, 0x44, 0x00, 0x00, 0x00,
2+
0x4c, 0x03, 0x00, 0x00, 0xe0, 0xf1, 0x0b, 0x0b, 0x04, 0x00, 0x08, 0x00,
3+
0x74, 0x00, 0x00, 0x00, 0xdc, 0x02, 0x00, 0x00, 0x4c, 0x03, 0x00, 0x00,
4+
0x14, 0x04, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00,
65
0x4c, 0x00, 0x00, 0x00, 0x4c, 0x00, 0x00, 0x00, 0x4c, 0x00, 0x00, 0x00,
7-
0x14, 0x01, 0x00, 0x00, 0x4e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
8-
0x57, 0x00, 0x00, 0x00, 0x1f, 0x00, 0x40, 0x72, 0x65, 0x66, 0x72, 0x65,
9-
0x73, 0x68, 0x00, 0x66, 0x6f, 0x6e, 0x74, 0x5f, 0x6a, 0x6d, 0x65, 0x63,
10-
0x00, 0x00, 0x00, 0x00, 0xad, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00,
11-
0x70, 0x00, 0x00, 0x00, 0xef, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00,
12-
0x8e, 0x00, 0x00, 0x00, 0x8e, 0x00, 0x00, 0x00, 0x70, 0x00, 0x00, 0x00,
13-
0xfd, 0xff, 0xff, 0xff, 0x08, 0x00, 0x00, 0x00, 0x87, 0x00, 0x08, 0x00,
14-
0x92, 0x00, 0x0c, 0x00, 0x8f, 0x00, 0x08, 0x00, 0x70, 0x00, 0x00, 0x00,
15-
0xf6, 0xff, 0xff, 0xff, 0x08, 0x00, 0x00, 0x00, 0x8e, 0x00, 0x3c, 0x00,
16-
0x8e, 0x00, 0x00, 0x00, 0x8e, 0x00, 0x00, 0x00, 0x70, 0x00, 0x00, 0x00,
17-
0xfe, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00,
18-
0x8f, 0x00, 0x08, 0x00, 0x70, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0xff,
19-
0x14, 0x00, 0x00, 0x00, 0x8e, 0x00, 0x00, 0x00, 0x8e, 0x00, 0x00, 0x00,
20-
0x95, 0x00, 0x02, 0x00, 0x99, 0x99, 0x99, 0x00, 0x89, 0x80, 0x00, 0x00,
21-
0x8f, 0x00, 0x08, 0x00, 0x70, 0x00, 0x00, 0x00, 0xf4, 0xff, 0xff, 0xff,
22-
0x14, 0x00, 0x00, 0x00, 0x8e, 0x00, 0x00, 0x00, 0x8e, 0x00, 0x00, 0x00,
6+
0x54, 0x00, 0x00, 0x00, 0x54, 0x00, 0x00, 0x00, 0x54, 0x00, 0x00, 0x00,
7+
0x60, 0x01, 0x00, 0x00, 0x56, 0x00, 0x00, 0x00, 0x7c, 0x01, 0x00, 0x00,
8+
0x61, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x6a, 0x00, 0x00, 0x00,
9+
0x1f, 0x00, 0x40, 0x62, 0x74, 0x6e, 0x5f, 0x65, 0x72, 0x72, 0x6f, 0x72,
10+
0x00, 0x40, 0x72, 0x65, 0x66, 0x72, 0x65, 0x73, 0x68, 0x00, 0x66, 0x6f,
11+
0x6e, 0x74, 0x5f, 0x6a, 0x6d, 0x65, 0x63, 0x00, 0xad, 0x00, 0x00, 0x00,
12+
0x1e, 0x00, 0x00, 0x00, 0x70, 0x00, 0x00, 0x00, 0xef, 0xff, 0xff, 0xff,
13+
0x00, 0x00, 0x00, 0x00, 0x8e, 0x00, 0x00, 0x00, 0x8e, 0x00, 0x00, 0x00,
2314
0x70, 0x00, 0x00, 0x00, 0xfd, 0xff, 0xff, 0xff, 0x08, 0x00, 0x00, 0x00,
24-
0x87, 0x00, 0x04, 0x00, 0x8e, 0x00, 0x00, 0x00, 0x8e, 0x00, 0x00, 0x00,
25-
0x8f, 0x00, 0x00, 0x00, 0x55, 0x00, 0x00, 0x00, 0x8e, 0x80, 0x00, 0x00,
26-
0x8f, 0x00, 0x04, 0x00, 0x70, 0x00, 0x00, 0x00, 0xf2, 0xff, 0xff, 0xff,
27-
0x14, 0x00, 0x00, 0x00, 0x92, 0x00, 0x10, 0x00, 0x8f, 0x00, 0x04, 0x00,
15+
0x87, 0x00, 0x08, 0x00, 0x92, 0x00, 0x0c, 0x00, 0x8f, 0x00, 0x08, 0x00,
2816
0x70, 0x00, 0x00, 0x00, 0xf6, 0xff, 0xff, 0xff, 0x08, 0x00, 0x00, 0x00,
29-
0x8e, 0x00, 0x00, 0x00, 0x8e, 0x00, 0x00, 0x00, 0x8e, 0x00, 0x08, 0x00,
17+
0x8e, 0x00, 0x3c, 0x00, 0x8e, 0x00, 0x00, 0x00, 0x8e, 0x00, 0x00, 0x00,
3018
0x70, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00,
31-
0x16, 0x00, 0x00, 0x00, 0x8f, 0x00, 0x04, 0x00, 0x70, 0x00, 0x00, 0x00,
32-
0xf8, 0xff, 0xff, 0xff, 0x14, 0x00, 0x00, 0x00, 0x66, 0x00, 0x00, 0x00,
19+
0x16, 0x00, 0x00, 0x00, 0x8f, 0x00, 0x08, 0x00, 0x70, 0x00, 0x00, 0x00,
20+
0xf8, 0xff, 0xff, 0xff, 0x14, 0x00, 0x00, 0x00, 0x8e, 0x00, 0x00, 0x00,
21+
0x8e, 0x00, 0x00, 0x00, 0x95, 0x00, 0x02, 0x00, 0x99, 0x99, 0x99, 0x00,
22+
0x89, 0x80, 0x00, 0x00, 0x8f, 0x00, 0x08, 0x00, 0x70, 0x00, 0x00, 0x00,
23+
0xf4, 0xff, 0xff, 0xff, 0x14, 0x00, 0x00, 0x00, 0x8e, 0x00, 0x00, 0x00,
24+
0x8e, 0x00, 0x00, 0x00, 0x70, 0x00, 0x00, 0x00, 0xfd, 0xff, 0xff, 0xff,
25+
0x08, 0x00, 0x00, 0x00, 0x87, 0x00, 0x04, 0x00, 0x8e, 0x00, 0x00, 0x00,
26+
0x8e, 0x00, 0x00, 0x00, 0x8f, 0x00, 0x00, 0x00, 0x55, 0x00, 0x00, 0x00,
27+
0x8e, 0x80, 0x00, 0x00, 0x8f, 0x00, 0x04, 0x00, 0x70, 0x00, 0x00, 0x00,
28+
0xf2, 0xff, 0xff, 0xff, 0x14, 0x00, 0x00, 0x00, 0x92, 0x00, 0x10, 0x00,
29+
0x8f, 0x00, 0x04, 0x00, 0x70, 0x00, 0x00, 0x00, 0xf6, 0xff, 0xff, 0xff,
30+
0x08, 0x00, 0x00, 0x00, 0x8e, 0x00, 0x00, 0x00, 0x8e, 0x00, 0x00, 0x00,
31+
0x8e, 0x00, 0x08, 0x00, 0x70, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff,
32+
0x00, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, 0x8f, 0x00, 0x04, 0x00,
33+
0x70, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0xff, 0x14, 0x00, 0x00, 0x00,
34+
0x9c, 0x00, 0xfc, 0xff, 0x8e, 0x00, 0x00, 0x00, 0x8e, 0x00, 0x00, 0x00,
35+
0x70, 0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, 0xff, 0x08, 0x00, 0x00, 0x00,
36+
0x88, 0x00, 0xfc, 0xff, 0x8e, 0x00, 0x1e, 0x00, 0x8e, 0x00, 0x28, 0x00,
37+
0x90, 0x00, 0xfc, 0xff, 0x70, 0x00, 0x00, 0x00, 0xfa, 0xff, 0xff, 0xff,
38+
0x0c, 0x00, 0x00, 0x00, 0x92, 0x00, 0x18, 0x00, 0x90, 0x00, 0xfc, 0xff,
39+
0x70, 0x00, 0x00, 0x00, 0xf9, 0xff, 0xff, 0xff, 0x08, 0x00, 0x00, 0x00,
40+
0x9c, 0x00, 0x04, 0x00, 0x66, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00,
41+
0x1e, 0x00, 0x00, 0x00, 0x8e, 0x00, 0x03, 0x00, 0x70, 0x00, 0x00, 0x00,
42+
0xed, 0xff, 0xff, 0xff, 0x04, 0x00, 0x00, 0x00, 0x66, 0x00, 0x00, 0x00,
3343
0x20, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00, 0x70, 0x00, 0x00, 0x00,
34-
0xee, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x92, 0x00, 0x18, 0x00,
44+
0xee, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x92, 0x00, 0x24, 0x00,
3545
0x70, 0x00, 0x00, 0x00, 0xf1, 0xff, 0xff, 0xff, 0x04, 0x00, 0x00, 0x00,
36-
0x83, 0x00, 0x18, 0x00, 0x07, 0x00, 0x00, 0x00, 0x23, 0x00, 0x00, 0x00,
37-
0xbc, 0x00, 0x00, 0x00, 0x83, 0x00, 0x18, 0x00, 0xa0, 0x00, 0x08, 0x00,
38-
0x18, 0x00, 0x00, 0x00, 0x83, 0x00, 0x18, 0x00, 0xa0, 0x00, 0x0c, 0x00,
39-
0x18, 0x00, 0x00, 0x00, 0x92, 0x00, 0x44, 0x00, 0x8e, 0x00, 0x05, 0x00,
40-
0x92, 0x00, 0x30, 0x00, 0x70, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff,
41-
0x14, 0x00, 0x00, 0x00, 0x92, 0x00, 0x30, 0x00, 0x8f, 0x00, 0x04, 0x00,
46+
0x83, 0x00, 0x24, 0x00, 0x07, 0x00, 0x00, 0x00, 0x23, 0x00, 0x00, 0x00,
47+
0xbc, 0x00, 0x00, 0x00, 0x83, 0x00, 0x24, 0x00, 0xa0, 0x00, 0x08, 0x00,
48+
0x18, 0x00, 0x00, 0x00, 0x83, 0x00, 0x24, 0x00, 0xa0, 0x00, 0x0c, 0x00,
49+
0x18, 0x00, 0x00, 0x00, 0x92, 0x00, 0x50, 0x00, 0x8e, 0x00, 0x05, 0x00,
50+
0x92, 0x00, 0x3c, 0x00, 0x70, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff,
51+
0x14, 0x00, 0x00, 0x00, 0x92, 0x00, 0x3c, 0x00, 0x8f, 0x00, 0x04, 0x00,
4252
0x70, 0x00, 0x00, 0x00, 0xf6, 0xff, 0xff, 0xff, 0x08, 0x00, 0x00, 0x00,
43-
0x92, 0x00, 0x54, 0x00, 0x92, 0x00, 0x50, 0x00, 0x70, 0x00, 0x00, 0x00,
44-
0xf0, 0xff, 0xff, 0xff, 0x08, 0x00, 0x00, 0x00, 0x83, 0x00, 0x18, 0x00,
45-
0xa0, 0x00, 0x14, 0x00, 0x18, 0x00, 0x00, 0x00, 0x92, 0x00, 0x54, 0x00,
46-
0x83, 0x00, 0x18, 0x00, 0xa0, 0x00, 0x10, 0x00, 0x18, 0x00, 0x00, 0x00,
47-
0x92, 0x00, 0x50, 0x00, 0x92, 0x00, 0x58, 0x00, 0x8e, 0x00, 0x05, 0x00,
48-
0x92, 0x00, 0x30, 0x00, 0x70, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff,
49-
0x1c, 0x00, 0x00, 0x00, 0x92, 0x00, 0x30, 0x00, 0x8f, 0x00, 0x08, 0x00,
53+
0x92, 0x00, 0x60, 0x00, 0x92, 0x00, 0x5c, 0x00, 0x70, 0x00, 0x00, 0x00,
54+
0xf0, 0xff, 0xff, 0xff, 0x08, 0x00, 0x00, 0x00, 0x83, 0x00, 0x24, 0x00,
55+
0xa0, 0x00, 0x14, 0x00, 0x18, 0x00, 0x00, 0x00, 0x92, 0x00, 0x60, 0x00,
56+
0x83, 0x00, 0x24, 0x00, 0xa0, 0x00, 0x10, 0x00, 0x18, 0x00, 0x00, 0x00,
57+
0x92, 0x00, 0x5c, 0x00, 0x92, 0x00, 0x64, 0x00, 0x8e, 0x00, 0x05, 0x00,
58+
0x92, 0x00, 0x3c, 0x00, 0x70, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff,
59+
0x1c, 0x00, 0x00, 0x00, 0x92, 0x00, 0x3c, 0x00, 0x8f, 0x00, 0x08, 0x00,
5060
0x70, 0x00, 0x00, 0x00, 0xf6, 0xff, 0xff, 0xff, 0x08, 0x00, 0x00, 0x00,
5161
0x8f, 0x00, 0x08, 0x00, 0x70, 0x00, 0x00, 0x00, 0xf7, 0xff, 0xff, 0xff,
5262
0x04, 0x00, 0x00, 0x00, 0x66, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00,
5363
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
5464
0x00, 0x00, 0x3f, 0x3f, 0x30, 0x3a, 0x30, 0x30, 0x00, 0x00, 0x00, 0x30,
65+
0x6e, 0x74, 0x62, 0x40, 0x72, 0x72, 0x65, 0x5f, 0x00, 0x00, 0x72, 0x6f,
5566
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
5667
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
5768
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
@@ -60,4 +71,4 @@ const unsigned char program[] = {
6071
0x00, 0x00, 0x00, 0x00, 0x25, 0x20, 0x73, 0x25, 0x73, 0x25, 0x20, 0x64,
6172
0x00, 0x64, 0x25, 0x20
6273
};
63-
unsigned int program_len = 712;
74+
unsigned int program_len = 844;

0 commit comments

Comments
 (0)