Apollo 10.0
自动驾驶开放平台
ecu_status_3_517.h
浏览该文件的文档.
1/******************************************************************************
2 * Copyright 2019 The Apollo Authors. All Rights Reserved.
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 *****************************************************************************/
16
17#pragma once
18
19#include "modules/canbus_vehicle/ch/proto/ch.pb.h"
21
22namespace apollo {
23namespace canbus {
24namespace ch {
25
27 ::apollo::canbus::Ch> {
28 public:
29 static const int32_t ID;
31 void Parse(const std::uint8_t* bytes, int32_t length,
32 Ch* chassis) const override;
33
34 private:
35 // config detail: {'bit': 0, 'description': 'Ultrasonic detection distance 1
36 // (Ultrasound status)', 'is_signed_var': False, 'len': 8, 'name':
37 // 'ULTRASOUND_DIST_1', 'offset': 0.0, 'order': 'intel', 'physical_range':
38 // '[0|500]', 'physical_unit': 'cm', 'precision': 2.0, 'type': 'double'}
39 double ultrasound_dist_1(const std::uint8_t* bytes,
40 const int32_t length) const;
41
42 // config detail: {'bit': 8, 'description': 'Ultrasonic detection distance 2
43 // (Ultrasound status)', 'is_signed_var': False, 'len': 8, 'name':
44 // 'ULTRASOUND_DIST_2', 'offset': 0.0, 'order': 'intel', 'physical_range':
45 // '[0|500]', 'physical_unit': 'cm', 'precision': 2.0, 'type': 'double'}
46 double ultrasound_dist_2(const std::uint8_t* bytes,
47 const int32_t length) const;
48
49 // config detail: {'bit': 16, 'description': 'Ultrasonic detection distance 3
50 // (Ultrasound status)', 'is_signed_var': False, 'len': 8, 'name':
51 // 'ULTRASOUND_DIST_3', 'offset': 0.0, 'order': 'intel', 'physical_range':
52 // '[0|500]', 'physical_unit': 'cm', 'precision': 2.0, 'type': 'double'}
53 double ultrasound_dist_3(const std::uint8_t* bytes,
54 const int32_t length) const;
55
56 // config detail: {'bit': 24, 'description': 'Ultrasonic detection distance 4
57 // (Ultrasound status)', 'is_signed_var': False, 'len': 8, 'name':
58 // 'ULTRASOUND_DIST_4', 'offset': 0.0, 'order': 'intel', 'physical_range':
59 // '[0|500]', 'physical_unit': 'cm', 'precision': 2.0, 'type': 'double'}
60 double ultrasound_dist_4(const std::uint8_t* bytes,
61 const int32_t length) const;
62
63 // config detail: {'bit': 32, 'description': 'Ultrasonic detection distance 5
64 // (Ultrasound status)', 'is_signed_var': False, 'len': 8, 'name':
65 // 'ULTRASOUND_DIST_5', 'offset': 0.0, 'order': 'intel', 'physical_range':
66 // '[0|500]', 'physical_unit': 'cm', 'precision': 2.0, 'type': 'double'}
67 double ultrasound_dist_5(const std::uint8_t* bytes,
68 const int32_t length) const;
69
70 // config detail: {'bit': 40, 'description': 'Ultrasonic detection distance 6
71 // (Ultrasound status)', 'is_signed_var': False, 'len': 8, 'name':
72 // 'ULTRASOUND_DIST_6', 'offset': 0.0, 'order': 'intel', 'physical_range':
73 // '[0|500]', 'physical_unit': 'cm', 'precision': 2.0, 'type': 'double'}
74 double ultrasound_dist_6(const std::uint8_t* bytes,
75 const int32_t length) const;
76
77 // config detail: {'bit': 48, 'description': 'Ultrasonic detection distance 7
78 // (Ultrasound status)', 'is_signed_var': False, 'len': 8, 'name':
79 // 'ULTRASOUND_DIST_7', 'offset': 0.0, 'order': 'intel', 'physical_range':
80 // '[0|500]', 'physical_unit': 'cm', 'precision': 2.0, 'type': 'double'}
81 double ultrasound_dist_7(const std::uint8_t* bytes,
82 const int32_t length) const;
83
84 // config detail: {'bit': 56, 'description': 'Ultrasonic detection distance 8
85 // (Ultrasound status)', 'is_signed_var': False, 'len': 8, 'name':
86 // 'ULTRASOUND_DIST_8', 'offset': 0.0, 'order': 'intel', 'physical_range':
87 // '[0|500]', 'physical_unit': 'cm', 'precision': 2.0, 'type': 'double'}
88 double ultrasound_dist_8(const std::uint8_t* bytes,
89 const int32_t length) const;
90};
91
92} // namespace ch
93} // namespace canbus
94} // namespace apollo
void Parse(const std::uint8_t *bytes, int32_t length, Ch *chassis) const override
This is the base class of protocol data.
class register implement
Definition arena_queue.h:37
The class of ProtocolData