diff options
author | Nikolay Minaylov <nm29719@gmail.com> | 2022-06-28 13:48:25 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-06-28 13:48:25 +0300 |
commit | e3d9cdb66ce789f84f6f8e0bdd6d022187964425 (patch) | |
tree | 416097563b784ecbc6e24816fc26e00539d47864 | |
parent | ffa62429f3c678537e0e883a3a8c3ae5f1398ed4 (diff) |
[FL-2598] App control commands (#31)0.8
* App control commands and statuses
* Github: pin dependenciew versions
Co-authored-by: Aleksandr Kutuzov <alleteam@gmail.com>
-rw-r--r-- | .github/workflows/generate.yml | 4 | ||||
-rw-r--r-- | Changelog | 4 | ||||
-rw-r--r-- | application.options | 3 | ||||
-rw-r--r-- | application.proto | 14 | ||||
-rw-r--r-- | flipper.proto | 6 |
5 files changed, 28 insertions, 3 deletions
diff --git a/.github/workflows/generate.yml b/.github/workflows/generate.yml index 788c35c..7cb0185 100644 --- a/.github/workflows/generate.yml +++ b/.github/workflows/generate.yml @@ -20,7 +20,7 @@ jobs: uses: actions/setup-python@v2 - name: Setup protobuf - run: sudo apt-get -y install protobuf-compiler && python -m pip install --upgrade protobuf + run: sudo apt-get -y install protobuf-compiler && python -m pip install --upgrade python3-protobuf==2.5.0 protobuf==3.20.1 grpcio-tools==1.47.0 grpcio==1.47.0 - name: Generate sources - run: python3 nanopb/generator/nanopb_generator.py -q -I . -D /tmp *.proto
\ No newline at end of file + run: python3 nanopb/generator/nanopb_generator.py -q -I . -D /tmp *.proto @@ -1,5 +1,9 @@ # Changelog +## [0.8] +### Added +- App messages: AppExitRequest, AppLoadFileRequest, AppButtonPressRequest, AppButtonReleaseRequest + ## [0.7] ### Added - System message: UpdateResponse: passing update preparation detailed status diff --git a/application.options b/application.options index 72dcc29..e0b57f0 100644 --- a/application.options +++ b/application.options @@ -2,4 +2,5 @@ PB_App.StartRequest.args type:FT_POINTER PB_App.StartRequest.args max_length:512 PB_App.StartRequest.name type:FT_POINTER PB_App.StartRequest.name max_length:512 - +PB_App.AppLoadFileRequest.path max_length:512 +PB_App.AppButtonPressRequest.args max_length:512 diff --git a/application.proto b/application.proto index 225c864..eda9471 100644 --- a/application.proto +++ b/application.proto @@ -15,3 +15,17 @@ message LockStatusResponse { bool locked = 1; } +message AppExitRequest { +} + +message AppLoadFileRequest { + string path = 1; +} + +message AppButtonPressRequest { + string args = 1; +} + +message AppButtonReleaseRequest { +} + diff --git a/flipper.proto b/flipper.proto index ea848f4..10fdac0 100644 --- a/flipper.proto +++ b/flipper.proto @@ -33,6 +33,8 @@ enum CommandStatus { /**< Application Errors */ ERROR_APP_CANT_START = 16; /**< Can't start app - internal error */ ERROR_APP_SYSTEM_LOCKED = 17; /**< Another app is running */ + ERROR_APP_NOT_RUNNING = 21; /**< App is not running or doesn't support RPC commands */ + ERROR_APP_CMD_ERROR = 22; /**< Command execution error */ /**< Virtual Display Errors */ ERROR_VIRTUAL_DISPLAY_ALREADY_STARTED = 19; /**< Virtual Display session can't be started twice */ @@ -91,6 +93,10 @@ message Main { .PB_App.StartRequest app_start_request = 16; .PB_App.LockStatusRequest app_lock_status_request = 17; .PB_App.LockStatusResponse app_lock_status_response = 18; + .PB_App.AppExitRequest app_exit_request = 47; + .PB_App.AppLoadFileRequest app_load_file_request = 48; + .PB_App.AppButtonPressRequest app_button_press_request = 49; + .PB_App.AppButtonReleaseRequest app_button_release_request = 50; .PB_Gui.StartScreenStreamRequest gui_start_screen_stream_request = 20; .PB_Gui.StopScreenStreamRequest gui_stop_screen_stream_request = 21; .PB_Gui.ScreenFrame gui_screen_frame = 22; |