From 1c67072fc02c782d2dde5af33129b29ff986482f Mon Sep 17 00:00:00 2001 From: Guglielmo Boi Date: Tue, 21 May 2024 10:01:12 +0200 Subject: [PATCH] feat: added app_data and extended subplots --- proto/app/app_config.proto | 60 ++----------------------------- proto/app/app_data.proto | 74 ++++++++++++++++++++++++++++++++++++++ 2 files changed, 77 insertions(+), 57 deletions(-) create mode 100644 proto/app/app_data.proto diff --git a/proto/app/app_config.proto b/proto/app/app_config.proto index d2320be..bdf2626 100644 --- a/proto/app/app_config.proto +++ b/proto/app/app_config.proto @@ -9,56 +9,6 @@ message Connection string mode = 3; } -message DoubleTrigger -{ - string id = 1; - string message = 2; - string signal = 3; - int32 comparator = 4; - double value = 5; - uint32 color = 6; -} - -message EnumTrigger -{ - string id = 1; - string message = 2; - string signal = 3; - int32 comparator = 4; - uint64 value = 5; - uint32 color = 6; -} - -message BitTrigger -{ - string id = 1; - string message = 2; - string signal = 3; - int32 comparator = 4; - uint64 value = 5; - uint32 color = 6; -} - -message AxisItem -{ - string message = 1; - string signal = 2; - bool isEnum = 3; - uint32 color = 4; -} - -message Axis -{ - string name = 1; - repeated AxisItem items = 3; -} - -message CustomPlot -{ - string name = 1; - map axes = 2; -} - message AppConfig { uint64 loginTimestamp = 1; @@ -67,11 +17,7 @@ message AppConfig Connection connection = 4; map savedConnections = 5; repeated string activeTabs = 6; - repeated DoubleTrigger doubleTriggers = 7; - repeated EnumTrigger enumTriggers = 8; - repeated BitTrigger bitTriggers = 9; - repeated CustomPlot customPlots = 10; - map filesPaths = 11; - map stringCache = 12; - map boolCache = 13; + map filesPaths = 7; + map stringCache = 8; + map boolCache = 9; } \ No newline at end of file diff --git a/proto/app/app_data.proto b/proto/app/app_data.proto new file mode 100644 index 0000000..bcd0255 --- /dev/null +++ b/proto/app/app_data.proto @@ -0,0 +1,74 @@ +syntax = "proto3"; + +package App; + +message DoubleTrigger +{ + string id = 1; + string message = 2; + string signal = 3; + int32 comparator = 4; + double value = 5; + uint32 color = 6; +} + +message EnumTrigger +{ + string id = 1; + string message = 2; + string signal = 3; + int32 comparator = 4; + uint64 value = 5; + uint32 color = 6; +} + +message BitTrigger +{ + string id = 1; + string message = 2; + string signal = 3; + int32 comparator = 4; + uint64 value = 5; + uint32 color = 6; +} + +message CustomPlotItem +{ + string messageAxisX = 1; + string messageAxisY = 2; + string signalAxisX = 3; + string signalAxisY = 4; + bool isEnum = 5; + uint32 color = 6; +} + +message CustomPlotAxis +{ + string label = 1; + repeated CustomPlotItem items = 2; +} + +message CustomPlot +{ + string title = 1; + map axes = 2; +} + +message CustomSubPlots +{ + uint32 rows = 1; + repeated CustomPlot plots = 2; +} + +message CustomPlotsTab +{ + repeated CustomSubPlots subPlots = 1; +} + +message AppData +{ + repeated DoubleTrigger doubleTriggers = 1; + repeated EnumTrigger enumTriggers = 2; + repeated BitTrigger bitTriggers = 3; + map customPlotsTabs = 4; +} \ No newline at end of file