Apollo  6.0
Open source self driving car software
shift_aux_rpt_328.h
Go to the documentation of this file.
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/proto/chassis_detail.pb.h"
21 
22 namespace apollo {
23 namespace canbus {
24 namespace lexus {
25 
27  ::apollo::canbus::ChassisDetail> {
28  public:
29  static const int32_t ID;
31  void Parse(const std::uint8_t* bytes, int32_t length,
32  ChassisDetail* chassis) const override;
33 
34  private:
35  // config detail: {'name': 'SPEED_INTERLOCK_ACTIVE_IS_VALID', 'offset': 0.0,
36  // 'precision': 1.0, 'len': 1, 'is_signed_var': False, 'physical_range':
37  // '[0|1]', 'bit': 11, 'type': 'bool', 'order': 'motorola', 'physical_unit':
38  // ''}
39  bool speed_interlock_active_is_valid(const std::uint8_t* bytes,
40  const int32_t length) const;
41 
42  // config detail: {'name': 'SPEED_INTERLOCK_ACTIVE', 'offset': 0.0,
43  // 'precision': 1.0, 'len': 1, 'is_signed_var': False, 'physical_range':
44  // '[0|1]', 'bit': 3, 'type': 'bool', 'order': 'motorola', 'physical_unit':
45  // ''}
46  bool speed_interlock_active(const std::uint8_t* bytes,
47  const int32_t length) const;
48 
49  // config detail: {'name': 'BRAKE_INTERLOCK_ACTIVE_IS_VALID', 'offset': 0.0,
50  // 'precision': 1.0, 'len': 1, 'is_signed_var': False, 'physical_range':
51  // '[0|1]', 'bit': 10, 'type': 'bool', 'order': 'motorola', 'physical_unit':
52  // ''}
53  bool brake_interlock_active_is_valid(const std::uint8_t* bytes,
54  const int32_t length) const;
55 
56  // config detail: {'name': 'BRAKE_INTERLOCK_ACTIVE', 'offset': 0.0,
57  // 'precision': 1.0, 'len': 1, 'is_signed_var': False, 'physical_range':
58  // '[0|1]', 'bit': 2, 'type': 'bool', 'order': 'motorola', 'physical_unit':
59  // ''}
60  bool brake_interlock_active(const std::uint8_t* bytes,
61  const int32_t length) const;
62 
63  // config detail: {'name': 'STAY_IN_NEUTRAL_MODE_IS_VALID', 'offset': 0.0,
64  // 'precision': 1.0, 'len': 1, 'is_signed_var': False, 'physical_range':
65  // '[0|1]', 'bit': 9, 'type': 'bool', 'order': 'motorola', 'physical_unit':
66  // ''}
67  bool stay_in_neutral_mode_is_valid(const std::uint8_t* bytes,
68  const int32_t length) const;
69 
70  // config detail: {'name': 'STAY_IN_NEUTRAL_MODE', 'offset': 0.0,
71  // 'precision': 1.0, 'len': 1, 'is_signed_var': False, 'physical_range':
72  // '[0|1]', 'bit': 1, 'type': 'bool', 'order': 'motorola', 'physical_unit':
73  // ''}
74  bool stay_in_neutral_mode(const std::uint8_t* bytes,
75  const int32_t length) const;
76 
77  // config detail: {'name': 'BETWEEN_GEARS_IS_VALID', 'offset': 0.0,
78  // 'precision': 1.0, 'len': 1, 'is_signed_var': False, 'physical_range':
79  // '[0|1]', 'bit': 8, 'type': 'bool', 'order': 'motorola', 'physical_unit':
80  // ''}
81  bool between_gears_is_valid(const std::uint8_t* bytes,
82  const int32_t length) const;
83 
84  // config detail: {'name': 'BETWEEN_GEARS', 'offset': 0.0, 'precision': 1.0,
85  // 'len': 1, 'is_signed_var': False, 'physical_range': '[0|1]', 'bit': 0,
86  // 'type': 'bool', 'order': 'motorola', 'physical_unit': ''}
87  bool between_gears(const std::uint8_t* bytes, const int32_t length) const;
88 };
89 
90 } // namespace lexus
91 } // namespace canbus
92 } // namespace apollo
PlanningContext is the runtime context in planning. It is persistent across multiple frames...
Definition: atomic_hash_map.h:25
This is the base class of protocol data.
Definition: protocol_data.h:44
void Parse(const std::uint8_t *bytes, int32_t length, ChassisDetail *chassis) const override
static const int32_t ID
Definition: shift_aux_rpt_328.h:29
The class of ProtocolData.
Definition: shift_aux_rpt_328.h:26