Added protoMetadata and trying to fix sub and unsub
This commit is contained in:
@@ -40,6 +40,7 @@
|
|||||||
"svelte-check": "^4.3.3",
|
"svelte-check": "^4.3.3",
|
||||||
"svelte-focus-trap": "^1.2.0",
|
"svelte-focus-trap": "^1.2.0",
|
||||||
"tailwindcss": "^4.1.14",
|
"tailwindcss": "^4.1.14",
|
||||||
|
"ts-proto-descriptors": "^2.1.0",
|
||||||
"tslib": "^2.8.1",
|
"tslib": "^2.8.1",
|
||||||
"typescript": "^5.9.3",
|
"typescript": "^5.9.3",
|
||||||
"typescript-eslint": "^8.51.0",
|
"typescript-eslint": "^8.51.0",
|
||||||
|
|||||||
Generated
+3
@@ -132,6 +132,9 @@ importers:
|
|||||||
tailwindcss:
|
tailwindcss:
|
||||||
specifier: ^4.1.14
|
specifier: ^4.1.14
|
||||||
version: 4.1.14
|
version: 4.1.14
|
||||||
|
ts-proto-descriptors:
|
||||||
|
specifier: ^2.1.0
|
||||||
|
version: 2.1.0
|
||||||
tslib:
|
tslib:
|
||||||
specifier: ^2.8.1
|
specifier: ^2.8.1
|
||||||
version: 2.8.1
|
version: 2.8.1
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
+1
-1
@@ -3,7 +3,7 @@ This file is temporary, just to show how ot compile the proto files
|
|||||||
Make sure to actually create the output directories before executing the commands
|
Make sure to actually create the output directories before executing the commands
|
||||||
|
|
||||||
TS:
|
TS:
|
||||||
protoc --plugin="protoc-gen-ts_proto=$(Resolve-Path app\node_modules\.bin\protoc-gen-ts_proto.CMD)" --ts_proto_out="./app/src/lib" "platform_shared\example.proto"
|
rotoc --plugin="protoc-gen-ts_proto=$(Resolve-Path app\node_modules\.bin\protoc-gen-ts_proto.CMD)" --ts_proto_out="./app/src/lib" --ts_proto_opt=outputSchema=true ".\platform_shared\websocket_message.proto"
|
||||||
|
|
||||||
NEW TS (USING PROTOBUFJS):
|
NEW TS (USING PROTOBUFJS):
|
||||||
cd app
|
cd app
|
||||||
|
|||||||
@@ -24,26 +24,31 @@ message WifiSettingsData {}
|
|||||||
message SonarData {}
|
message SonarData {}
|
||||||
message RSSIData { int32 rssi = 1; }
|
message RSSIData { int32 rssi = 1; }
|
||||||
|
|
||||||
|
message SubscribeNotification {}
|
||||||
|
message UnsubscribeNotification {}
|
||||||
|
|
||||||
|
|
||||||
// WebSocket message wrapper
|
// WebSocket message wrapper
|
||||||
// Only ONE field will be set at a time (oneof ensures this)
|
// Only ONE field will be set at a time (oneof ensures this)
|
||||||
message WebsocketMessage {
|
message WebsocketMessage {
|
||||||
oneof message {
|
oneof message {
|
||||||
IMUData imu = 10;
|
SubscribeNotification sub_notif = 20;
|
||||||
IMUCalibrateData imu_calibrate = 20;
|
UnsubscribeNotification unsub_notif = 21;
|
||||||
ModeData mode = 30;
|
IMUData imu = 110;
|
||||||
InputData input = 40;
|
IMUCalibrateData imu_calibrate = 120;
|
||||||
AnalyticsData analytics = 50;
|
ModeData mode = 130;
|
||||||
PositionData position = 60;
|
InputData input = 140;
|
||||||
AnglesData angles = 70;
|
AnalyticsData analytics = 150;
|
||||||
I2CScanData i2c_scan = 80;
|
PositionData position = 160;
|
||||||
PeripheralSettingsData peripheral_settings = 90;
|
AnglesData angles = 170;
|
||||||
OTAStatusData ota_status = 100;
|
I2CScanData i2c_scan = 180;
|
||||||
GaitData gait = 110;
|
PeripheralSettingsData peripheral_settings = 190;
|
||||||
ServoStateData servo_state = 120;
|
OTAStatusData ota_status = 200;
|
||||||
ServoPWMData servo_pwm = 130;
|
GaitData gait = 210;
|
||||||
WifiSettingsData wifi_settings = 140;
|
ServoStateData servo_state = 220;
|
||||||
SonarData sonar = 150;
|
ServoPWMData servo_pwm = 230;
|
||||||
RSSIData rssi = 160;
|
WifiSettingsData wifi_settings = 240;
|
||||||
|
SonarData sonar = 250;
|
||||||
|
RSSIData rssi = 260;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user