-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
98ef373
commit 038db5e
Showing
2 changed files
with
51 additions
and
19 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,40 +1,71 @@ | ||
#include "../app_user.h" | ||
|
||
/* | ||
This the menu of OBDII SCANNER | ||
IN A FUTURE WE WILL ADD FEATURES AS: | ||
- SCAN PID CODES | ||
- HACKING PID CODES | ||
- SCAN AND ERASE DTC ERRORS | ||
- ALL THE FUNCTIONALITIES AS OBDII SCANNER HAS | ||
*/ | ||
|
||
void obdii_menu_callback(void* context, uint32_t index) { | ||
App* app = context; | ||
UNUSED(app); | ||
switch(index) { | ||
App* app = context; | ||
UNUSED(app); | ||
switch (index) { | ||
case 0: | ||
// | ||
break; | ||
// | ||
break; | ||
|
||
default: | ||
break; | ||
} | ||
break; | ||
} | ||
} | ||
|
||
void app_scene_obdii_menu_on_enter(void* context) { | ||
App* app = context; | ||
App* app = context; | ||
|
||
submenu_reset(app->submenu); | ||
submenu_reset(app->submenu); | ||
|
||
submenu_set_header(app->submenu, "OBDII SCANNER"); | ||
submenu_set_header(app->submenu, "OBDII SCANNER"); | ||
|
||
// Example | ||
submenu_add_item(app->submenu, "Engine Speed", 0, obdii_menu_callback, app); | ||
// Example | ||
submenu_add_item(app->submenu, "Engine Speed", 0, obdii_menu_callback, app); | ||
|
||
submenu_set_selected_item(app->submenu, 0); | ||
submenu_set_selected_item(app->submenu, 0); | ||
|
||
view_dispatcher_switch_to_view(app->view_dispatcher, SubmenuView); | ||
view_dispatcher_switch_to_view(app->view_dispatcher, SubmenuView); | ||
} | ||
|
||
bool app_scene_obdii_menu_on_event(void* context, SceneManagerEvent event) { | ||
UNUSED(context); | ||
UNUSED(event); | ||
return false; | ||
UNUSED(context); | ||
UNUSED(event); | ||
return false; | ||
} | ||
|
||
void app_scene_obdii_menu_on_exit(void* context) { | ||
App* app = context; | ||
submenu_reset(app->submenu); | ||
App* app = context; | ||
submenu_reset(app->submenu); | ||
} | ||
|
||
/* | ||
EXAMPLE WITH A ENGINE SPEED | ||
*/ | ||
|
||
void app_scene_engine_rpm_speed_on_enter(void* context) { | ||
App* app = context; | ||
|
||
UNUSED(app); | ||
} | ||
|
||
bool app_scene_engine_rpm_speed_on_event(void* context, | ||
SceneManagerEvent event) { | ||
UNUSED(context); | ||
UNUSED(event); | ||
return false; | ||
} | ||
|
||
void app_scene_engine_rpm_speed_on_exit(void* context) { | ||
App* app = context; | ||
submenu_reset(app->submenu); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters