motorcortex-rust 0.5.0

Motorcortex Rust: a Rust client for the Motorcortex Core real-time control system (async + blocking).
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
use crate::msg::Hash;
// This file is @generated by prost-build.
/// *
///
/// ParameterOffset description.
///
/// An offset can be applied when setting a new value of the parameter array
///
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct ParameterOffset {
    /// Type of the offset.
    #[prost(
        enumeration = "OffsetType",
        required,
        tag = "1",
        default = "OffsetElements"
    )]
    pub r#type: i32,
    /// Starting point.
    #[prost(uint32, required, tag = "2")]
    pub offset: u32,
    /// Length from starting point.
    #[prost(uint32, required, tag = "3")]
    pub length: u32,
}
/// *
///
/// Error description.
///
/// System type, which describes an error.
///
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct Error {
    /// System time, when error occurred.
    #[prost(fixed64, required, tag = "1")]
    pub timestamp: u64,
    /// Error code.
    #[prost(fixed32, required, tag = "2")]
    pub error_number: u32,
    /// Error level.
    #[prost(fixed32, required, tag = "3")]
    pub error_level: u32,
    /// Subsystem, for example 1 is 1st actuator of the system.
    #[prost(fixed32, required, tag = "4")]
    pub subsystem: u32,
    /// Additional error code, provided by hardware.
    #[prost(fixed32, required, tag = "5")]
    pub info: u32,
}
/// *
///
///
/// List of errors.
///
/// Error messages are sent to the client as a list of N active errors.
///
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct ErrorList {
    /// List of active errors.
    #[prost(message, repeated, tag = "1")]
    pub errors: ::prost::alloc::vec::Vec<Error>,
    /// Number of errors in the list.
    #[prost(fixed32, required, tag = "2")]
    pub number_of_errors: u32,
    /// An update couter changes everytime the list of active errors is updated.
    #[prost(fixed32, required, tag = "3")]
    pub update_counter: u32,
}
/// *
///
/// Parameter information fields.
///
/// Active state of the parameter in the tree, including its name, size, data type, io type and active flags.
///
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct ParameterInfo {
    /// Unique id, assigned by parameter server.
    #[prost(uint32, required, tag = "1")]
    pub id: u32,
    /// Tag of the data type.
    #[prost(uint32, required, tag = "2")]
    pub data_type: u32,
    /// Size of one data element.
    #[prost(uint32, required, tag = "3")]
    pub data_size: u32,
    /// Number of the elements.
    #[prost(uint32, required, tag = "4")]
    pub number_of_elements: u32,
    /// Parameter flags (overwrite, link etc...).
    #[prost(uint32, required, tag = "5")]
    pub flags: u32,
    /// Access permissions.
    #[prost(uint32, required, tag = "6")]
    pub permissions: u32,
    /// I/O type of the parameter.
    #[prost(enumeration = "ParameterType", required, tag = "7")]
    pub param_type: i32,
    /// Group ID of the owner.
    #[prost(enumeration = "UserGroup", required, tag = "8")]
    pub group_id: i32,
    /// SI unit of the parameter.
    #[prost(enumeration = "Unit", required, tag = "9")]
    pub unit: i32,
    /// Path (including name) of the parameter.
    #[prost(string, required, tag = "10")]
    pub path: ::prost::alloc::string::String,
}
/// *
///
/// Parameters' group information.
///
/// This data type represents the subscription information, required to decode parameters from the group message.
///
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct GroupParameterInfo {
    /// Index of the subscribed parameter.
    #[prost(uint32, required, tag = "1")]
    pub index: u32,
    /// Offset in the group message.
    #[prost(uint32, required, tag = "2")]
    pub offset: u32,
    /// Size of the parameter.
    #[prost(uint32, required, tag = "3")]
    pub size: u32,
    /// Parameter information.
    #[prost(message, required, tag = "4")]
    pub info: ParameterInfo,
    /// Status code.
    #[prost(enumeration = "StatusCode", required, tag = "5")]
    pub status: i32,
}
/// *
///
/// Generic message header, included in the request/reply messages.
///
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct Header {
    /// Frame counter counts number of parameter updates.
    #[prost(fixed32, required, tag = "1")]
    pub frame_counter: u32,
    /// Current server time in the format: microseconds from 1 Jan 2000.
    #[prost(fixed64, required, tag = "2")]
    pub timestamp: u64,
}
/// *
///
/// Group message, used by the publisher. (Note: currently is not used, since publisher is not using protobuf)
///
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct GroupMsg {
    /// Frame counter and actual time.
    #[prost(message, optional, tag = "1")]
    pub header: ::core::option::Option<Header>,
    /// List of published parameters.
    #[prost(message, repeated, tag = "2")]
    pub params: ::prost::alloc::vec::Vec<ParameterMsg>,
}
/// *
///
/// Status code message.
///
/// Reply with a status code for various request messages.
///
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct StatusMsg {
    /// Frame counter and actual time.
    #[prost(message, optional, tag = "1")]
    pub header: ::core::option::Option<Header>,
    /// Return status of the request.
    #[prost(enumeration = "StatusCode", required, tag = "2")]
    pub status: i32,
}
/// *
///
/// Login request.
///
/// User request to get access to the parameter tree.
///
/// Server's reply: StatusMsg, with following status codes:
///
/// StatusCode::OK - user is logged in,
///
/// StatusCode::READ_ONLY_MODE - user is logged in, read only mode,
///
/// StatusCode::WRONG_PASSWORD - login failed, wrong login or password.
///
/// StatusCode::FAILED_TO_DECODE - failed to decode request message.
///
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct LoginMsg {
    /// Frame counter and actual time.
    #[prost(message, optional, tag = "1")]
    pub header: ::core::option::Option<Header>,
    /// User's login.
    #[prost(string, required, tag = "2")]
    pub login: ::prost::alloc::string::String,
    /// User's password.
    #[prost(string, required, tag = "3")]
    pub password: ::prost::alloc::string::String,
}
/// *
///
/// Request a session token.
///
/// After user is logged-in it can request a session token for re-login.
///
/// Server's reply: SessionTokenMsg with the token status code.
///
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct GetSessionTokenMsg {
    /// Frame counter and actual time.
    #[prost(message, optional, tag = "1")]
    pub header: ::core::option::Option<Header>,
}
/// *
///
/// Session token.
///
/// A token with current session id. The toke is used for re-logging if
/// the connection is lost.
///
/// Server's reply: SessionTokenmsg with the token and one of the following
/// status codes:
///
/// StatusCode::OK - token is granted,
///
/// StatusCode::PERMISSION_DENIED - user has no permission,
///
/// StatusCode::FAILED - operation failed,
///
/// StatusCode::FAILED_TO_DECODE - failed to decode request message.
///
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct SessionTokenMsg {
    /// Frame counter and actual time.
    #[prost(message, optional, tag = "1")]
    pub header: ::core::option::Option<Header>,
    /// Session token.
    #[prost(string, required, tag = "2")]
    pub token: ::prost::alloc::string::String,
    /// Status code.
    #[prost(enumeration = "StatusCode", required, tag = "3")]
    pub status: i32,
}
/// *
///
/// Restore session request.
///
/// User request to restore the old session to access to the parameter tree.
///
/// Server's reply: StatusMsg, with following status codes:
///
/// StatusCode::OK - user is logged in,
///
/// StatusCode::READ_ONLY_MODE - user is logged in, read only mode,
///
/// StatusCode::PERMISSION_DENIED - login failed, token expired,
///
/// StatusCode::FAILED - operation failed,
///
/// StatusCode::FAILED_TO_DECODE - failed to decode request message.
///
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct RestoreSessionMsg {
    /// Frame counter and actual time.
    #[prost(message, optional, tag = "1")]
    pub header: ::core::option::Option<Header>,
    /// Session token.
    #[prost(string, required, tag = "2")]
    pub token: ::prost::alloc::string::String,
}
/// *
///
/// Logout request.
///
/// User request to exit. Logout will happen automatically if user is disconnected.
///
/// Server's reply: StatusMsg, with following status codes:
///
/// StatusCode::OK - user is logged out,
///
/// StatusCode::FAILED - operation failed,
///
/// StatusCode::FAILED_TO_DECODE - failed to decode request message.
///
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct LogoutMsg {
    /// Frame counter and actual time.
    #[prost(message, optional, tag = "1")]
    pub header: ::core::option::Option<Header>,
}
/// *
///
/// Request to get a parameter tree message
///
/// Server's reply: ParameterTreeMsg, with following status codes:
///
/// StatusCode::OK - user is logged out,
///
/// StatusCode::FAILED - operation failed.
///
/// StatusCode::FAILED_TO_DECODE - failed to decode request message.
///
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct GetParameterTreeMsg {
    /// Frame counter and actual time.
    #[prost(message, optional, tag = "1")]
    pub header: ::core::option::Option<Header>,
}
/// *
///
/// Parameter tree data, which contains information about tree structure and available parameters.
/// Message can have following status codes:
///
/// StatusCode::OK - operation successful,
///
/// StatusCode::FAILED - operation failed.
///
/// StatusCode::FAILED_TO_DECODE - failed to decode request message.
///
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct ParameterTreeMsg {
    /// Frame counter and actual time.
    #[prost(message, optional, tag = "1")]
    pub header: ::core::option::Option<Header>,
    /// Array with available parameters.
    #[prost(message, repeated, tag = "2")]
    pub params: ::prost::alloc::vec::Vec<ParameterInfo>,
    /// Hash value of the parameter tree stored in 'repeated ParameterInfo params'.
    #[prost(uint32, required, tag = "3")]
    pub hash: u32,
    /// Status code.
    #[prost(enumeration = "StatusCode", required, tag = "4")]
    pub status: i32,
}
/// *
///
/// Request to get a parameter tree hash.
///
/// Instead of requesting a complete parameter tree, a client might request only a tree hash to compare it
/// against the cached tree to detect if the tree on the server has been changed. The difference between hashes
/// indicates the changes in the tree structure.
/// Note: Changes in parameter values do not result in a different tree hash.
///
/// Server's reply: ParameterTreeHashMsg, with following status codes:
///
/// StatusCode::OK - operation successful,
///
/// StatusCode::FAILED - operation failed.
///
/// StatusCode::FAILED_TO_DECODE - failed to decode request message.
///
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct GetParameterTreeHashMsg {
    /// Frame counter and actual time.
    #[prost(message, optional, tag = "1")]
    pub header: ::core::option::Option<Header>,
}
/// *
///
/// Parameter tree hash.
///
/// Hash of the parameter tree.
///
/// Message can have following status codes:
///
/// StatusCode::OK - operation successful,
///
/// StatusCode::FAILED - operation failed.
///
/// StatusCode::FAILED_TO_DECODE - failed to decode request message.
///
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct ParameterTreeHashMsg {
    /// Frame counter and actual time.
    #[prost(message, optional, tag = "1")]
    pub header: ::core::option::Option<Header>,
    /// Hash of the tree.
    #[prost(uint32, required, tag = "2")]
    pub hash: u32,
    /// Status code.
    #[prost(enumeration = "StatusCode", required, tag = "3")]
    pub status: i32,
}
/// *
///
/// Request to create a publisher group.
///
/// User's request to start publishing specified parameters. Several users may subscribe to
/// the same group. This mechanism reduces the load on the server and allows more clients to get
/// frequent updates.
///
/// User may choose a scale factor for the publishing rate of the group.
///
/// Server's reply: GroupStatusMsg, with following status codes:
///
/// StatusCode::OK - operation successful.
///
/// StatusCode::FAILED - operation failed.
///
/// StatusCode::PERMISSION_DENIED - Permission denied because the user has no access rights.
///
/// StatusCode::FAILED_TO_SET_REQUESTED_FRQ - operation successful, but failed to change publisher's frequency, because the group has already existed.
///
/// StatusCode::FAILED_TO_DECODE - failed to decode request message.
///
/// StatusCode::SUB_LIST_IS_FULL - failed to subscribe for a parameter, because subscription list is full. Create new parameter group.
///
/// StatusCode::WRONG_PARAMETER_PATH - failed to find parameter, because requested path is wrong.
///
/// StatusCode::GROUP_LIST_IS_FULL - failed to create new group, because the group list is full. Release at least one group.
///
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct CreateGroupMsg {
    /// Frame counter and actual time.
    #[prost(message, optional, tag = "1")]
    pub header: ::core::option::Option<Header>,
    /// Requested frequency divider, to scale down publisher rate.
    #[prost(uint32, required, tag = "2")]
    pub frq_divider: u32,
    /// Name of the group.
    #[prost(string, required, tag = "3")]
    pub alias: ::prost::alloc::string::String,
    /// List of the parameters.
    #[prost(string, repeated, tag = "4")]
    pub paths: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
}
/// *
///
/// Group package description.
///
/// Reply for 'CreateGroupMsg', with the package structure.
///
/// Message can have following status codes:
///
/// StatusCode::OK - operation successful,
///
/// StatusCode::FAILED - operation failed,
///
/// StatusCode::PERMISSION_DENIED - Permission denied because user has no access rights.
///
/// StatusCode::FAILED_TO_SET_REQUESTED_FRQ - operation successful, but failed to change publisher's frequency, because the group has already existed.
///
/// StatusCode::FAILED_TO_DECODE - failed to decode request message.
///
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct GroupStatusMsg {
    /// Frame counter and actual time.
    #[prost(message, optional, tag = "1")]
    pub header: ::core::option::Option<Header>,
    /// Unique id of the group.
    #[prost(uint32, required, tag = "2")]
    pub id: u32,
    /// Name of the group.
    #[prost(string, required, tag = "3")]
    pub alias: ::prost::alloc::string::String,
    /// List of parameters' info.
    #[prost(message, repeated, tag = "4")]
    pub params: ::prost::alloc::vec::Vec<GroupParameterInfo>,
    /// Status code.
    #[prost(enumeration = "StatusCode", required, tag = "5")]
    pub status: i32,
}
/// *
///
/// Request to remove a publisher group.
///
/// User's request to unsubscribe from the group.
///
/// Server's reply: StatusMsg, with following status codes:
///
/// StatusCode::OK - operation successful,
///
/// StatusCode::FAILED - operation failed,
///
/// StatusCode::PERMISSION_DENIED - Permission denied because user has no access rights.
///
/// StatusCode::FAILED_TO_DECODE - failed to decode request message.
///
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct RemoveGroupMsg {
    /// Frame counter and actual time.
    #[prost(message, optional, tag = "1")]
    pub header: ::core::option::Option<Header>,
    /// Name of the group.
    #[prost(string, required, tag = "2")]
    pub alias: ::prost::alloc::string::String,
}
/// *
///
/// Request to get a parameter info and its value.
///
/// Server's reply: ParameterMsg, with following status codes:
///
/// StatusCode::OK - operation successful,
///
/// StatusCode::FAILED - operation failed.
///
/// StatusCode::PERMISSION_DENIED - Permission denied because user has no access rights.
///
/// StatusCode::FAILED_TO_DECODE - failed to decode request message.
///
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct GetParameterMsg {
    /// Frame counter and actual time.
    #[prost(message, optional, tag = "1")]
    pub header: ::core::option::Option<Header>,
    /// Path of the requested parameter.
    #[prost(string, required, tag = "2")]
    pub path: ::prost::alloc::string::String,
}
/// *
///
/// Parameter info and its value.
///
/// Reply for 'GetParameterMsg', with the parameter info and a value.
///
/// Message can have following status codes:
///
/// StatusCode::OK - operation successful,
///
/// StatusCode::FAILED - operation failed.
///
/// StatusCode::PERMISSION_DENIED - Permission denied because user has no access rights.
///
/// StatusCode::FAILED_TO_DECODE - failed to decode request message.
///
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct ParameterMsg {
    /// Parameter value.
    #[prost(bytes = "vec", required, tag = "1")]
    pub value: ::prost::alloc::vec::Vec<u8>,
    /// Frame counter and actual time.
    #[prost(message, optional, tag = "2")]
    pub header: ::core::option::Option<Header>,
    /// Parameter information.
    #[prost(message, optional, tag = "3")]
    pub info: ::core::option::Option<ParameterInfo>,
    /// Status code.
    #[prost(enumeration = "StatusCode", required, tag = "4")]
    pub status: i32,
}
/// *
///
/// Request to get a list of parameters with info and values.
///
/// Server's reply: ParameterListMsg, with following status codes:
///
/// StatusCode::OK - operation successful,
///
/// StatusCode::FAILED - operation failed.
///
/// StatusCode::PERMISSION_DENIED - Permission denied because user has no access rights.
///
/// StatusCode::FAILED_TO_DECODE - failed to decode request message.
///
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct GetParameterListMsg {
    /// Frame counter and actual time.
    #[prost(message, optional, tag = "1")]
    pub header: ::core::option::Option<Header>,
    /// List of requested parameter.
    #[prost(message, repeated, tag = "2")]
    pub params: ::prost::alloc::vec::Vec<GetParameterMsg>,
}
/// *
///
/// List of parameters with info values.
///
/// Reply for 'GetParameterListMsg', with the list of parameters info and values.
///
/// Message can have following status codes:
///
/// StatusCode::OK - operation successful,
///
/// StatusCode::FAILED - operation failed.
///
/// StatusCode::PERMISSION_DENIED - Permission denied because user has no access rights.
///
/// StatusCode::FAILED_TO_DECODE - failed to decode request message.
///
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct ParameterListMsg {
    /// Frame counter and actual time.
    #[prost(message, optional, tag = "1")]
    pub header: ::core::option::Option<Header>,
    /// List of parameters.
    #[prost(message, repeated, tag = "2")]
    pub params: ::prost::alloc::vec::Vec<ParameterMsg>,
    /// Status code.
    #[prost(enumeration = "StatusCode", required, tag = "3")]
    pub status: i32,
}
/// *
///
/// Request to set a parameter value.
///
/// User's request to update a parameter value.
///
/// Server's reply: StatusMsg, with following status codes:
///
/// StatusCode::OK - operation successful,
///
/// StatusCode::FAILED - operation failed.
///
/// StatusCode::PERMISSION_DENIED - Permission denied because user has no access rights.
///
/// StatusCode::USER_LOGGED_IN_NO_CONTROL - User is in read-only mode.
///
/// StatusCode::WRONG_PARAMETER_PATH - Wrong parameter path.
///
/// StatusCode::FAILED_TO_DECODE - failed to decode request message.
///
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct SetParameterMsg {
    /// Frame counter and actual time.
    #[prost(message, optional, tag = "1")]
    pub header: ::core::option::Option<Header>,
    /// Offset of the parameter value.
    #[prost(message, optional, tag = "2")]
    pub offset: ::core::option::Option<ParameterOffset>,
    /// Path of the requested parameter.
    #[prost(string, required, tag = "3")]
    pub path: ::prost::alloc::string::String,
    /// New values has to be encoded according to the data type, which is provided in the parameter info.
    #[prost(bytes = "vec", required, tag = "4")]
    pub value: ::prost::alloc::vec::Vec<u8>,
}
/// *
///
/// Request to set a list of parameters values.
///
/// User's request to update a list of parameters values.
///
/// Server's reply: StatusMsg, with following status codes:
///
/// StatusCode::OK - operation successful,
///
/// StatusCode::FAILED - operation failed.
///
/// StatusCode::PERMISSION_DENIED - Permission denied because user has no access rights.
///
/// StatusCode::USER_LOGGED_IN_NO_CONTROL - User is in read-only mode.
///
/// StatusCode::WRONG_PARAMETER_PATH - Wrong parameter path.
///
/// StatusCode::FAILED_TO_DECODE - failed to decode request message.
///
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct SetParameterListMsg {
    /// Frame counter and actual time.
    #[prost(message, optional, tag = "1")]
    pub header: ::core::option::Option<Header>,
    /// List of parameter set messages.
    #[prost(message, repeated, tag = "2")]
    pub params: ::prost::alloc::vec::Vec<SetParameterMsg>,
}
/// *
///
/// Request to overwrite/force a parameter value.
///
/// User's request to force a parameter value. For the Input and Parameter types the input value will be overwritten,
/// for the Output type, the output value will be overwritten.
///
/// By enabling flag 'activate', overwrite value will be active until the flag is disabled, by ether commanding
/// ReleaseParameterMsg or OverwriteParameterMsg with 'activate' - false.
///
/// Server's reply: StatusMsg, with following status codes:
///
/// StatusCode::OK - operation successful,
///
/// StatusCode::FAILED - operation failed.
///
/// StatusCode::PERMISSION_DENIED - Permission denied because user has no access rights.
///
/// StatusCode::USER_LOGGED_IN_NO_CONTROL - User is in read-only mode.
///
/// StatusCode::WRONG_PARAMETER_PATH - Wrong parameter path.
///
/// StatusCode::FAILED_TO_DECODE - failed to decode request message.
///
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct OverwriteParameterMsg {
    /// Frame counter and actual time.
    #[prost(message, optional, tag = "1")]
    pub header: ::core::option::Option<Header>,
    /// Offset of the parameter value.
    #[prost(message, optional, tag = "2")]
    pub offset: ::core::option::Option<ParameterOffset>,
    /// Flag to enable/disable permanent overwrite.
    #[prost(bool, required, tag = "3")]
    pub activate: bool,
    /// Path of the requested parameter.
    #[prost(string, required, tag = "4")]
    pub path: ::prost::alloc::string::String,
    /// New values.
    #[prost(bytes = "vec", required, tag = "5")]
    pub value: ::prost::alloc::vec::Vec<u8>,
}
/// *
///
/// Request to release an overwrite/force.
///
/// User's request to cancel overwrite of a parameter value.
///
/// Server's reply: StatusMsg, with following status codes:
///
/// StatusCode::OK - operation successful,
///
/// StatusCode::FAILED - operation failed.
///
/// StatusCode::PERMISSION_DENIED - Permission denied because user has no access rights.
///
/// StatusCode::USER_LOGGED_IN_NO_CONTROL - User is in read-only mode.
///
/// StatusCode::WRONG_PARAMETER_PATH - Wrong parameter path.
///
/// StatusCode::FAILED_TO_DECODE - failed to decode request message.
///
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct ReleaseParameterMsg {
    /// Frame counter and actual time.
    #[prost(message, optional, tag = "1")]
    pub header: ::core::option::Option<Header>,
    /// Path of the requested parameter.
    #[prost(string, required, tag = "2")]
    pub path: ::prost::alloc::string::String,
}
/// *
///
/// Request to save parameter values to the disk.
///
/// User's request to save parameter values to XML file.
///
/// Server's reply: StatusMsg, with following status codes:
///
/// StatusCode::OK - operation successful,
///
/// StatusCode::FAILED - operation failed.
///
/// StatusCode::PERMISSION_DENIED - Permission denied because user has no access rights.
///
/// StatusCode::USER_LOGGED_IN_NO_CONTROL - User is in read-only mode.
///
/// StatusCode::FAILED_TO_OPEN - Failed to create/open a file.
///
/// StatusCode::FAILED_TO_DECODE - failed to decode request message.
///
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct SaveMsg {
    /// Frame counter and actual time.
    #[prost(message, optional, tag = "1")]
    pub header: ::core::option::Option<Header>,
    /// Path to a config file.
    #[prost(string, required, tag = "2")]
    pub path: ::prost::alloc::string::String,
    /// File name.i
    #[prost(string, required, tag = "3")]
    pub file_name: ::prost::alloc::string::String,
}
/// *
///
/// Request to load parameter values from the disk.
///
/// User's request to load parameter values from XML file.
///
/// Server's reply: StatusMsg, with following status codes:
///
/// StatusCode::OK - operation successful,
///
/// StatusCode::FAILED - operation failed.
///
/// StatusCode::PERMISSION_DENIED - Permission denied because user has no access rights.
///
/// StatusCode::USER_LOGGED_IN_NO_CONTROL - User is in read-only mode.
///
/// StatusCode::FAILED_TO_OPEN - Failed to create/open a file.
///
/// StatusCode::FAILED_TO_DECODE - failed to decode request message.
///
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct LoadMsg {
    /// Frame counter and actual time.
    #[prost(message, optional, tag = "1")]
    pub header: ::core::option::Option<Header>,
    /// Path to config file.
    #[prost(string, required, tag = "2")]
    pub path: ::prost::alloc::string::String,
    /// File name.
    #[prost(string, required, tag = "3")]
    pub file_name: ::prost::alloc::string::String,
}
/// *
///
/// Request to execute command on the server.
///
/// User's request to execute a command on the server (console mode).
///
/// Server's reply: StatusMsg, with following status codes:
///
/// StatusCode::OK - operation successful,
///
/// StatusCode::FAILED - operation failed.
///
/// (Note: Currently not implemented).
///
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct ConsoleCmdMsg {
    /// Frame counter and actual time.
    #[prost(message, optional, tag = "1")]
    pub header: ::core::option::Option<Header>,
    /// Console command
    #[prost(string, required, tag = "2")]
    pub value: ::prost::alloc::string::String,
}
/// *
///
/// Request to execute a list of commands on the server.
///
/// User's request to execute a list of commands on the server (console mode).
///
/// Server's reply: StatusMsg, with following status codes:
///
/// StatusCode::OK - operation successful,
///
/// StatusCode::FAILED - operation failed.
///
/// (Note: Currently not implemented).
///
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct ConsoleCmdListMsg {
    /// Frame counter and actual time.
    #[prost(message, optional, tag = "1")]
    pub header: ::core::option::Option<Header>,
    /// List of commands
    #[prost(message, repeated, tag = "2")]
    pub cmds: ::prost::alloc::vec::Vec<ConsoleCmdMsg>,
}
/// *
///
/// Some SI units.
///
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum Unit {
    Undefined = 0,
    /// Length mask 0xf
    Length = 15,
    /// millimeters 0x1
    Mm = 1,
    /// meters 0x2
    M = 2,
    /// Angle mask 0xf1
    Angle = 241,
    /// radians 0x31
    Rad = 49,
    /// degrees 0x41
    Deg = 65,
    /// Time mask 0xf2
    Time = 242,
    /// nanoseconds 0x12
    Nanosec = 18,
    /// microseconds 0x22
    Microsec = 34,
    /// milliseconds 0x32
    Millisec = 50,
    /// seconds 0x42
    Sec = 66,
    /// Weight mask 0xf3
    Weight = 243,
    /// grams 0x13
    Gram = 19,
    /// kilograms 0x23
    Kg = 35,
    /// Velocity mask 0xf4
    Velocity = 244,
    /// linear velocity, meters per second 0x14
    MSec = 20,
    /// angular velocity, radians per second 0x24
    RadSec = 36,
    /// Acceleration mask 0xf5
    Acceleration = 245,
    /// linear acceleration meters per second^2 0x15
    MSec2 = 21,
    /// angular acceleration radians per second^2 0x25
    RadSec2 = 37,
    /// Force mask 0xf6
    Force = 246,
    /// force, newtons 0x16
    N = 22,
    /// torque, newton-metres 0x26
    Nm = 38,
    /// percentages 0x17
    Percent = 23,
}
impl Unit {
    /// String value of the enum field names used in the ProtoBuf definition.
    ///
    /// The values are not transformed in any way and thus are considered stable
    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
    pub fn as_str_name(&self) -> &'static str {
        match self {
            Self::Undefined => "unit_undefined",
            Self::Length => "Length",
            Self::Mm => "mm",
            Self::M => "m",
            Self::Angle => "Angle",
            Self::Rad => "rad",
            Self::Deg => "deg",
            Self::Time => "Time",
            Self::Nanosec => "nanosec",
            Self::Microsec => "microsec",
            Self::Millisec => "millisec",
            Self::Sec => "sec",
            Self::Weight => "Weight",
            Self::Gram => "gram",
            Self::Kg => "kg",
            Self::Velocity => "Velocity",
            Self::MSec => "m_sec",
            Self::RadSec => "rad_sec",
            Self::Acceleration => "Acceleration",
            Self::MSec2 => "m_sec2",
            Self::RadSec2 => "rad_sec2",
            Self::Force => "Force",
            Self::N => "N",
            Self::Nm => "Nm",
            Self::Percent => "percent",
        }
    }
    /// Creates an enum from field names used in the ProtoBuf definition.
    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
        match value {
            "unit_undefined" => Some(Self::Undefined),
            "Length" => Some(Self::Length),
            "mm" => Some(Self::Mm),
            "m" => Some(Self::M),
            "Angle" => Some(Self::Angle),
            "rad" => Some(Self::Rad),
            "deg" => Some(Self::Deg),
            "Time" => Some(Self::Time),
            "nanosec" => Some(Self::Nanosec),
            "microsec" => Some(Self::Microsec),
            "millisec" => Some(Self::Millisec),
            "sec" => Some(Self::Sec),
            "Weight" => Some(Self::Weight),
            "gram" => Some(Self::Gram),
            "kg" => Some(Self::Kg),
            "Velocity" => Some(Self::Velocity),
            "m_sec" => Some(Self::MSec),
            "rad_sec" => Some(Self::RadSec),
            "Acceleration" => Some(Self::Acceleration),
            "m_sec2" => Some(Self::MSec2),
            "rad_sec2" => Some(Self::RadSec2),
            "Force" => Some(Self::Force),
            "N" => Some(Self::N),
            "Nm" => Some(Self::Nm),
            "percent" => Some(Self::Percent),
            _ => None,
        }
    }
}
/// *
///
/// Available user groups.
///
/// Group determines an access level of the user. Users can belong to one group: Administrator, Operator or Guest.
/// System is reserved for internal motorcortex-core use.
/// By default Operator cannot read or write Administrator's related parameters. The administrator has a full access
/// to the Operator's data.
///
/// Group access can be reconfigured in C++ server code or in the server configuration file. Furthermore, parameterization
/// of the access can be done by setting permission level (Permission) of the parameter.
///
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum UserGroup {
    Undefined = 0,
    /// System group has full access. It is not available for the users.
    System = 1,
    /// Administrator group has full access, except for system-level parameters.
    Administrator = 3,
    /// Operator has limited write access and read access.
    Operator = 7,
    /// Guest has read access.
    Guest = 2147483647,
}
impl UserGroup {
    /// String value of the enum field names used in the ProtoBuf definition.
    ///
    /// The values are not transformed in any way and thus are considered stable
    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
    pub fn as_str_name(&self) -> &'static str {
        match self {
            Self::Undefined => "user_group_undefined",
            Self::System => "SYSTEM",
            Self::Administrator => "ADMINISTRATOR",
            Self::Operator => "OPERATOR",
            Self::Guest => "GUEST",
        }
    }
    /// Creates an enum from field names used in the ProtoBuf definition.
    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
        match value {
            "user_group_undefined" => Some(Self::Undefined),
            "SYSTEM" => Some(Self::System),
            "ADMINISTRATOR" => Some(Self::Administrator),
            "OPERATOR" => Some(Self::Operator),
            "GUEST" => Some(Self::Guest),
            _ => None,
        }
    }
}
/// *
///
/// Available parameters' permissions. Different users/groups may require access to different and/or protected parts of
/// the parameter tree. Permission flags allow fine-tuning access levels of the groups.
///
/// The Motorcortex permissions structure is similar to that of Unix file permissions. Permissions are represented
/// either in symbolic notation or in octal notation. (Note: User rights are not yet implemented, instead use Group rights)
///
/// For example:
///
/// ---------- (0000): no permission
///
/// -rwx------ (0700): read, write, & execute only for owner (Note: currently not implemented, user group flags instead)
///
/// -rwxrwx--- (0770): read, write, & execute for owner and group (Note: execute flag is used as a permission to open folders)
///
/// -rwxrwxr-x (0775): read, write, & execute for owner and group, read & execute for all others.
///
/// -rwxrwxrwx (0777): full access
///
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum Permission {
    Undefined = 0,
    /// owner user read -r--------
    UserRead = 256,
    /// owner user write --w-------
    UserWrite = 128,
    /// owner user execute ---e------
    UserExecute = 64,
    /// owner group read ----r-----
    GroupRead = 32,
    /// owner group write -----w----
    GroupWrite = 16,
    /// owner group execute ------e---
    GroupExecute = 8,
    /// other users read -------r--
    OthersRead = 4,
    /// other users write --------w-
    OthersWrite = 2,
    /// other users ---------e
    OthersExecute = 1,
}
impl Permission {
    /// String value of the enum field names used in the ProtoBuf definition.
    ///
    /// The values are not transformed in any way and thus are considered stable
    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
    pub fn as_str_name(&self) -> &'static str {
        match self {
            Self::Undefined => "permission_undefined",
            Self::UserRead => "USER_READ",
            Self::UserWrite => "USER_WRITE",
            Self::UserExecute => "USER_EXECUTE",
            Self::GroupRead => "GROUP_READ",
            Self::GroupWrite => "GROUP_WRITE",
            Self::GroupExecute => "GROUP_EXECUTE",
            Self::OthersRead => "OTHERS_READ",
            Self::OthersWrite => "OTHERS_WRITE",
            Self::OthersExecute => "OTHERS_EXECUTE",
        }
    }
    /// Creates an enum from field names used in the ProtoBuf definition.
    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
        match value {
            "permission_undefined" => Some(Self::Undefined),
            "USER_READ" => Some(Self::UserRead),
            "USER_WRITE" => Some(Self::UserWrite),
            "USER_EXECUTE" => Some(Self::UserExecute),
            "GROUP_READ" => Some(Self::GroupRead),
            "GROUP_WRITE" => Some(Self::GroupWrite),
            "GROUP_EXECUTE" => Some(Self::GroupExecute),
            "OTHERS_READ" => Some(Self::OthersRead),
            "OTHERS_WRITE" => Some(Self::OthersWrite),
            "OTHERS_EXECUTE" => Some(Self::OthersExecute),
            _ => None,
        }
    }
}
/// *
///
/// Available data types.
///
/// Data types supported by a parameter server.
///
/// User data types can be added after the tag USER_TYPE.
///
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum DataType {
    Undefined = 0,
    /// integer 1 byte
    Int8 = 1,
    /// unsigned integer 1 byte
    Uint8 = 2,
    /// short int
    Int16 = 3,
    /// unsigned short int
    Uint16 = 4,
    /// int
    Int32 = 5,
    /// unsigned int
    Uint32 = 6,
    /// long
    Int64 = 7,
    /// unsigned long
    Uint64 = 8,
    /// boolean
    Bool = 9,
    /// float
    Float = 257,
    /// double
    Double = 258,
    /// char
    Char = 513,
    /// C-string
    String = 514,
    /// bytes array
    Bytes = 1177,
    /// end of the system types
    UserType = 1280,
}
impl DataType {
    /// String value of the enum field names used in the ProtoBuf definition.
    ///
    /// The values are not transformed in any way and thus are considered stable
    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
    pub fn as_str_name(&self) -> &'static str {
        match self {
            Self::Undefined => "data_type_undefined",
            Self::Int8 => "INT8",
            Self::Uint8 => "UINT8",
            Self::Int16 => "INT16",
            Self::Uint16 => "UINT16",
            Self::Int32 => "INT32",
            Self::Uint32 => "UINT32",
            Self::Int64 => "INT64",
            Self::Uint64 => "UINT64",
            Self::Bool => "BOOL",
            Self::Float => "FLOAT",
            Self::Double => "DOUBLE",
            Self::Char => "CHAR",
            Self::String => "STRING",
            Self::Bytes => "BYTES",
            Self::UserType => "USER_TYPE",
        }
    }
    /// Creates an enum from field names used in the ProtoBuf definition.
    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
        match value {
            "data_type_undefined" => Some(Self::Undefined),
            "INT8" => Some(Self::Int8),
            "UINT8" => Some(Self::Uint8),
            "INT16" => Some(Self::Int16),
            "UINT16" => Some(Self::Uint16),
            "INT32" => Some(Self::Int32),
            "UINT32" => Some(Self::Uint32),
            "INT64" => Some(Self::Int64),
            "UINT64" => Some(Self::Uint64),
            "BOOL" => Some(Self::Bool),
            "FLOAT" => Some(Self::Float),
            "DOUBLE" => Some(Self::Double),
            "CHAR" => Some(Self::Char),
            "STRING" => Some(Self::String),
            "BYTES" => Some(Self::Bytes),
            "USER_TYPE" => Some(Self::UserType),
            _ => None,
        }
    }
}
/// *
///
/// Parameter's IO types.
///
/// Each parameter in the tree can be an INPUT, an OUTPUT or a PARAMETER.
///
/// PARAMETER type is both an input and output, it can be saved and loaded from the disk.
///
/// Value of a parameter with OUTPUT type cannot be set, but can be overwritten (forced). Force operation
/// on the OUTPUT will only change the parameter value on everything that is linked to it. It will
/// NOT change the internal value of the block to which the output belongs.
///
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum ParameterType {
    ParamTypeUndefined = 0,
    /// Input parameter.
    Input = 1,
    /// Output parameter.
    Output = 16,
    /// Input/output parameter, which is saved and loaded from the disk on request.
    Parameter = 256,
    /// Input/output parameter, which is valotile, not saved or loaded from the disk.
    ParameterVolatile = 257,
    /// Input/output parameter, which is persistent, continuously saved and loaded from the disk.
    ParameterPersistent = 258,
}
impl ParameterType {
    /// String value of the enum field names used in the ProtoBuf definition.
    ///
    /// The values are not transformed in any way and thus are considered stable
    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
    pub fn as_str_name(&self) -> &'static str {
        match self {
            Self::ParamTypeUndefined => "param_type_undefined",
            Self::Input => "INPUT",
            Self::Output => "OUTPUT",
            Self::Parameter => "PARAMETER",
            Self::ParameterVolatile => "PARAMETER_VOLATILE",
            Self::ParameterPersistent => "PARAMETER_PERSISTENT",
        }
    }
    /// Creates an enum from field names used in the ProtoBuf definition.
    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
        match value {
            "param_type_undefined" => Some(Self::ParamTypeUndefined),
            "INPUT" => Some(Self::Input),
            "OUTPUT" => Some(Self::Output),
            "PARAMETER" => Some(Self::Parameter),
            "PARAMETER_VOLATILE" => Some(Self::ParameterVolatile),
            "PARAMETER_PERSISTENT" => Some(Self::ParameterPersistent),
            _ => None,
        }
    }
}
/// *
///
/// Return status codes.
///
/// Return status codes are included in the reply for every user's request. Using these
/// codes user can verify if request was successful or there was a failure.
///
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum StatusCode {
    /// Request was processed successfully.
    Ok = 0,
    /// Login is successful, but user has read-only right.
    ReadOnlyMode = 1,
    /// Generic failure mask.
    Failed = 65280,
    /// Failed to decode request message.
    FailedToDecode = 4096,
    /// Failed to subscribe for a parameter, because subscription list is full. Create new parameter group.
    SubListIsFull = 4352,
    /// Failed to find parameter, because requested path is wrong.
    WrongParameterPath = 4608,
    /// When several clients share the same publisher's group, original publishing frequency is preserved.
    FailedToSetRequestedFrq = 4864,
    /// Failed to open/save/load a file.
    FailedToOpenFile = 5120,
    /// Failed to create new group, because the group list is full. Release at least one group.
    GroupListIsFull = 5376,
    /// Login failed, wrong login or password.
    WrongPassword = 8448,
    /// Operation not permitted, because user is not logged in.
    UserNotLoggedIn = 8704,
    /// Permission denied because user has no access rights.
    PermissionDenied = 8960,
}
impl StatusCode {
    /// String value of the enum field names used in the ProtoBuf definition.
    ///
    /// The values are not transformed in any way and thus are considered stable
    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
    pub fn as_str_name(&self) -> &'static str {
        match self {
            Self::Ok => "OK",
            Self::ReadOnlyMode => "READ_ONLY_MODE",
            Self::Failed => "FAILED",
            Self::FailedToDecode => "FAILED_TO_DECODE",
            Self::SubListIsFull => "SUB_LIST_IS_FULL",
            Self::WrongParameterPath => "WRONG_PARAMETER_PATH",
            Self::FailedToSetRequestedFrq => "FAILED_TO_SET_REQUESTED_FRQ",
            Self::FailedToOpenFile => "FAILED_TO_OPEN_FILE",
            Self::GroupListIsFull => "GROUP_LIST_IS_FULL",
            Self::WrongPassword => "WRONG_PASSWORD",
            Self::UserNotLoggedIn => "USER_NOT_LOGGED_IN",
            Self::PermissionDenied => "PERMISSION_DENIED",
        }
    }
    /// Creates an enum from field names used in the ProtoBuf definition.
    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
        match value {
            "OK" => Some(Self::Ok),
            "READ_ONLY_MODE" => Some(Self::ReadOnlyMode),
            "FAILED" => Some(Self::Failed),
            "FAILED_TO_DECODE" => Some(Self::FailedToDecode),
            "SUB_LIST_IS_FULL" => Some(Self::SubListIsFull),
            "WRONG_PARAMETER_PATH" => Some(Self::WrongParameterPath),
            "FAILED_TO_SET_REQUESTED_FRQ" => Some(Self::FailedToSetRequestedFrq),
            "FAILED_TO_OPEN_FILE" => Some(Self::FailedToOpenFile),
            "GROUP_LIST_IS_FULL" => Some(Self::GroupListIsFull),
            "WRONG_PASSWORD" => Some(Self::WrongPassword),
            "USER_NOT_LOGGED_IN" => Some(Self::UserNotLoggedIn),
            "PERMISSION_DENIED" => Some(Self::PermissionDenied),
            _ => None,
        }
    }
}
/// *
///
/// Available error levels.
///
/// Generic user levels generated by the logic. (Note: Check examples of the state machine.)
///
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum ErrorLevel {
    Undefined = 0,
    /// Information message.
    Info = 1,
    /// Warning message.
    Warning = 2,
    /// Graceful software stop, caused by a hardware malfunction or a wrong user actions.
    ForcedDisengage = 3,
    /// More abrupt software stop, caused by a hardware malfunction.
    Shutdown = 4,
    /// Abrupt software and hardware stop, caused by a hardware malfunction.
    EmergencyStop = 5,
}
impl ErrorLevel {
    /// String value of the enum field names used in the ProtoBuf definition.
    ///
    /// The values are not transformed in any way and thus are considered stable
    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
    pub fn as_str_name(&self) -> &'static str {
        match self {
            Self::Undefined => "error_level_undefined",
            Self::Info => "INFO",
            Self::Warning => "WARNING",
            Self::ForcedDisengage => "FORCED_DISENGAGE",
            Self::Shutdown => "SHUTDOWN",
            Self::EmergencyStop => "EMERGENCY_STOP",
        }
    }
    /// Creates an enum from field names used in the ProtoBuf definition.
    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
        match value {
            "error_level_undefined" => Some(Self::Undefined),
            "INFO" => Some(Self::Info),
            "WARNING" => Some(Self::Warning),
            "FORCED_DISENGAGE" => Some(Self::ForcedDisengage),
            "SHUTDOWN" => Some(Self::Shutdown),
            "EMERGENCY_STOP" => Some(Self::EmergencyStop),
            _ => None,
        }
    }
}
/// *
///
/// Avaliable offset types.
///
/// When setting a parameter value user can specify an offset and length
///
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum OffsetType {
    Undefined = 0,
    /// Offset and length is calculated in the elements. For example update an array starting from the element number 3.
    OffsetElements = 1,
    /// Offset and length is calculated in bytes.
    OffsetBytes = 2,
    /// Offset and length is calculated in bits.
    OffsetBits = 3,
}
impl OffsetType {
    /// String value of the enum field names used in the ProtoBuf definition.
    ///
    /// The values are not transformed in any way and thus are considered stable
    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
    pub fn as_str_name(&self) -> &'static str {
        match self {
            Self::Undefined => "offset_type_undefined",
            Self::OffsetElements => "OFFSET_ELEMENTS",
            Self::OffsetBytes => "OFFSET_BYTES",
            Self::OffsetBits => "OFFSET_BITS",
        }
    }
    /// Creates an enum from field names used in the ProtoBuf definition.
    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
        match value {
            "offset_type_undefined" => Some(Self::Undefined),
            "OFFSET_ELEMENTS" => Some(Self::OffsetElements),
            "OFFSET_BYTES" => Some(Self::OffsetBytes),
            "OFFSET_BITS" => Some(Self::OffsetBits),
            _ => None,
        }
    }
}
/// *
///
/// System parameter's flag
///
/// Parameter can have various system flags, which shows that it is been overwritten or linked.
/// (Note: This list will grow in future)
///
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum ParameterFlag {
    /// Parameter is linked to another parameter.
    LinkIsActive = 1,
    /// Parameter is being overwritten.
    OverwriteIsActive = 2,
}
impl ParameterFlag {
    /// String value of the enum field names used in the ProtoBuf definition.
    ///
    /// The values are not transformed in any way and thus are considered stable
    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
    pub fn as_str_name(&self) -> &'static str {
        match self {
            Self::LinkIsActive => "LINK_IS_ACTIVE",
            Self::OverwriteIsActive => "OVERWRITE_IS_ACTIVE",
        }
    }
    /// Creates an enum from field names used in the ProtoBuf definition.
    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
        match value {
            "LINK_IS_ACTIVE" => Some(Self::LinkIsActive),
            "OVERWRITE_IS_ACTIVE" => Some(Self::OverwriteIsActive),
            _ => None,
        }
    }
}

impl Hash for RemoveGroupMsg {
    const HASH: u32 = 0x7614c1ac;
}

impl Hash for ParameterTreeHashMsg {
    const HASH: u32 = 0xc8cef26b;
}

impl Hash for OverwriteParameterMsg {
    const HASH: u32 = 0x98505467;
}

impl Hash for ParameterOffset {
    const HASH: u32 = 0x37d97249;
}

impl Hash for SetParameterMsg {
    const HASH: u32 = 0xa78d07b6;
}

impl Hash for GroupStatusMsg {
    const HASH: u32 = 0x67aafaff;
}

impl Hash for StatusMsg {
    const HASH: u32 = 0xb2b3b41b;
}

impl Hash for Error {
    const HASH: u32 = 0xcb54b842;
}

impl Hash for DataType {
    const HASH: u32 = 0x62923b3a;
}

impl Hash for SaveMsg {
    const HASH: u32 = 0xc965b56a;
}

impl Hash for LogoutMsg {
    const HASH: u32 = 0xd796dcd5;
}

impl Hash for SessionTokenMsg {
    const HASH: u32 = 0x7c3e91ab;
}

impl Hash for GroupParameterInfo {
    const HASH: u32 = 0x1d5d6a0a;
}

impl Hash for LoginMsg {
    const HASH: u32 = 0x0630d225;
}

impl Hash for Unit {
    const HASH: u32 = 0x1f444f39;
}

impl Hash for ConsoleCmdMsg {
    const HASH: u32 = 0x4efc6762;
}

impl Hash for ErrorList {
    const HASH: u32 = 0xa63be891;
}

impl Hash for CreateGroupMsg {
    const HASH: u32 = 0x9eab1b83;
}

impl Hash for SetParameterListMsg {
    const HASH: u32 = 0xe1bd5231;
}

impl Hash for ParameterType {
    const HASH: u32 = 0x2927648b;
}

impl Hash for ConsoleCmdListMsg {
    const HASH: u32 = 0x96e4c2b0;
}

impl Hash for UserGroup {
    const HASH: u32 = 0x651cf623;
}

impl Hash for ParameterMsg {
    const HASH: u32 = 0x5815f142;
}

impl Hash for Header {
    const HASH: u32 = 0x52e24278;
}

impl Hash for ReleaseParameterMsg {
    const HASH: u32 = 0xbb43acc2;
}

impl Hash for GetParameterTreeMsg {
    const HASH: u32 = 0x61d73753;
}

impl Hash for GetParameterMsg {
    const HASH: u32 = 0x985f2c2f;
}

impl Hash for ParameterFlag {
    const HASH: u32 = 0xbcb0202c;
}

impl Hash for GetParameterTreeHashMsg {
    const HASH: u32 = 0x01711b24;
}

impl Hash for LoadMsg {
    const HASH: u32 = 0xf173d6cc;
}

impl Hash for StatusCode {
    const HASH: u32 = 0xd785e9fa;
}

impl Hash for GetSessionTokenMsg {
    const HASH: u32 = 0x4ff6b6f7;
}

impl Hash for OffsetType {
    const HASH: u32 = 0x74cbd84c;
}

impl Hash for ParameterListMsg {
    const HASH: u32 = 0xadd954d9;
}

impl Hash for ParameterInfo {
    const HASH: u32 = 0x52f7c2b8;
}

impl Hash for Permission {
    const HASH: u32 = 0xbfdf653b;
}

impl Hash for RestoreSessionMsg {
    const HASH: u32 = 0x8aef888a;
}

impl Hash for GroupMsg {
    const HASH: u32 = 0xfe8efea8;
}

impl Hash for ParameterTreeMsg {
    const HASH: u32 = 0xd31979bf;
}

impl Hash for ErrorLevel {
    const HASH: u32 = 0x14838051;
}

impl Hash for GetParameterListMsg {
    const HASH: u32 = 0x520608a5;
}