Apollo 10.0
自动驾驶开放平台
global_rpt_10.h
浏览该文件的文档.
1/******************************************************************************
2 * Copyright 2018 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/lexus/proto/lexus.pb.h"
21
22namespace apollo {
23namespace canbus {
24namespace lexus {
25
27 ::apollo::canbus::Lexus> {
28 public:
29 static const int32_t ID;
31 void Parse(const std::uint8_t* bytes, int32_t length,
32 Lexus* chassis) const override;
33
34 private:
35 // config detail: {'name': 'CONFIG_FAULT_ACTIVE', 'offset': 0.0,
36 // 'precision': 1.0, 'len': 1, 'is_signed_var': False, 'physical_range':
37 // '[0|1]', 'bit': 15, 'type': 'bool', 'order': 'motorola', 'physical_unit':
38 // ''}
39 bool config_fault_active(const std::uint8_t* bytes,
40 const int32_t length) const;
41
42 // config detail: {'name': 'PACMOD_SUBSYSTEM_TIMEOUT', 'offset': 0.0,
43 // 'precision': 1.0, 'len': 1, 'is_signed_var': False, 'physical_range':
44 // '[0|1]', 'bit': 5, 'type': 'bool', 'order': 'motorola', 'physical_unit':
45 // ''}
46 bool pacmod_subsystem_timeout(const std::uint8_t* bytes,
47 const int32_t length) const;
48
49 // config detail: {'name': 'PACMOD_SYSTEM_ENABLED', 'enum': {0:
50 // 'PACMOD_SYSTEM_ENABLED_CONTROL_DISABLED', 1:
51 // 'PACMOD_SYSTEM_ENABLED_CONTROL_ENABLED'}, 'precision': 1.0, 'len': 1,
52 // 'is_signed_var': False, 'offset': 0.0, 'physical_range': '[0|1]', 'bit': 0,
53 // 'type': 'enum', 'order': 'motorola', 'physical_unit': ''}
54 Global_rpt_10::Pacmod_system_enabledType pacmod_system_enabled(
55 const std::uint8_t* bytes, const int32_t length) const;
56
57 // config detail: {'name': 'PACMOD_SYSTEM_OVERRIDE_ACTIVE', 'enum': {0:
58 // 'PACMOD_SYSTEM_OVERRIDE_ACTIVE_NOT_OVERRIDDEN', 1:
59 // 'PACMOD_SYSTEM_OVERRIDE_ACTIVE_OVERRIDDEN'}, 'precision': 1.0, 'len': 1,
60 // 'is_signed_var': False, 'offset': 0.0, 'physical_range': '[0|1]', 'bit': 1,
61 // 'type': 'enum', 'order': 'motorola', 'physical_unit': ''}
63 pacmod_system_override_active(const std::uint8_t* bytes,
64 const int32_t length) const;
65
66 // config detail: {'name': 'PACMOD_SYSTEM_FAULT_ACTIVE', 'offset': 0.0,
67 // 'precision': 1.0, 'len': 1, 'is_signed_var': False, 'physical_range':
68 // '[0|1]', 'bit': 7, 'type': 'bool', 'order': 'motorola', 'physical_unit':
69 // ''}
70 bool pacmod_system_fault_active(const std::uint8_t* bytes,
71 const int32_t length) const;
72
73 // config detail: {'name': 'VEH_CAN_TIMEOUT', 'offset': 0.0, 'precision': 1.0,
74 // 'len': 1, 'is_signed_var': False, 'physical_range': '[0|1]', 'bit': 6,
75 // 'type': 'bool', 'order': 'motorola', 'physical_unit': ''}
76 bool veh_can_timeout(const std::uint8_t* bytes, const int32_t length) const;
77
78 // config detail: {'name': 'STR_CAN_TIMEOUT', 'offset': 0.0, 'precision': 1.0,
79 // 'len': 1, 'is_signed_var': False, 'physical_range': '[0|1]', 'bit': 3,
80 // 'type': 'bool', 'order': 'motorola', 'physical_unit': ''}
81 bool str_can_timeout(const std::uint8_t* bytes, const int32_t length) const;
82
83 // config detail: {'name': 'BRK_CAN_TIMEOUT', 'enum': {0:
84 // 'BRK_CAN_TIMEOUT_NO_ACTIVE_CAN_TIMEOUT', 1:
85 // 'BRK_CAN_TIMEOUT_ACTIVE_CAN_TIMEOUT'}, 'precision': 1.0, 'len': 1,
86 // 'is_signed_var': False, 'offset': 0.0, 'physical_range': '[0|1]', 'bit': 4,
87 // 'type': 'enum', 'order': 'motorola', 'physical_unit': ''}
89 const std::uint8_t* bytes, const int32_t length) const;
90
91 // config detail: {'name': 'USR_CAN_TIMEOUT', 'offset': 0.0, 'precision': 1.0,
92 // 'len': 1, 'is_signed_var': False, 'physical_range': '[0|1]', 'bit': 2,
93 // 'type': 'bool', 'order': 'motorola', 'physical_unit': ''}
94 bool usr_can_timeout(const std::uint8_t* bytes, const int32_t length) const;
95
96 // config detail: {'name': 'USR_CAN_READ_ERRORS', 'offset': 0.0,
97 // 'precision': 1.0, 'len': 16, 'is_signed_var': False, 'physical_range':
98 // '[0|65535]', 'bit': 55, 'type': 'int', 'order': 'motorola',
99 // 'physical_unit': ''}
100 int usr_can_read_errors(const std::uint8_t* bytes,
101 const int32_t length) const;
102};
103
104} // namespace lexus
105} // namespace canbus
106} // namespace apollo
void Parse(const std::uint8_t *bytes, int32_t length, Lexus *chassis) const override
This is the base class of protocol data.
class register implement
Definition arena_queue.h:37
The class of ProtocolData