Apollo
10.0
自动驾驶开放平台
scu_2_302.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/ge3/proto/ge3.pb.h"
20
#include "
modules/drivers/canbus/can_comm/protocol_data.h
"
21
22
namespace
apollo
{
23
namespace
canbus {
24
namespace
ge3 {
25
26
class
Scu2302
:
public
::apollo::drivers::canbus::ProtocolData
<
27
::apollo::canbus::Ge3> {
28
public
:
29
static
const
int32_t
ID
;
30
Scu2302
();
31
void
Parse
(
const
std::uint8_t* bytes, int32_t length,
32
Ge3
* chassis)
const override
;
33
34
private
:
35
// config detail: {'description': 'VIN string character 07', 'offset': 0.0,
36
// 'precision': 1.0, 'len': 8, 'name': 'VIN07', 'is_signed_var': False,
37
// 'physical_range': '[0|255]', 'bit': 63, 'type': 'int', 'order': 'motorola',
38
// 'physical_unit': '-'}
39
int
vin07(
const
std::uint8_t* bytes,
const
int32_t length)
const
;
40
41
// config detail: {'description': 'VIN string character 06', 'offset': 0.0,
42
// 'precision': 1.0, 'len': 8, 'name': 'VIN06', 'is_signed_var': False,
43
// 'physical_range': '[0|255]', 'bit': 55, 'type': 'int', 'order': 'motorola',
44
// 'physical_unit': '-'}
45
int
vin06(
const
std::uint8_t* bytes,
const
int32_t length)
const
;
46
47
// config detail: {'description': 'VIN string character 05', 'offset': 0.0,
48
// 'precision': 1.0, 'len': 8, 'name': 'VIN05', 'is_signed_var': False,
49
// 'physical_range': '[0|255]', 'bit': 47, 'type': 'int', 'order': 'motorola',
50
// 'physical_unit': '-'}
51
int
vin05(
const
std::uint8_t* bytes,
const
int32_t length)
const
;
52
53
// config detail: {'description': 'VIN string character 04', 'offset': 0.0,
54
// 'precision': 1.0, 'len': 8, 'name': 'VIN04', 'is_signed_var': False,
55
// 'physical_range': '[0|255]', 'bit': 39, 'type': 'int', 'order': 'motorola',
56
// 'physical_unit': '-'}
57
int
vin04(
const
std::uint8_t* bytes,
const
int32_t length)
const
;
58
59
// config detail: {'description': 'VIN string character 03', 'offset': 0.0,
60
// 'precision': 1.0, 'len': 8, 'name': 'VIN03', 'is_signed_var': False,
61
// 'physical_range': '[0|255]', 'bit': 31, 'type': 'int', 'order': 'motorola',
62
// 'physical_unit': '-'}
63
int
vin03(
const
std::uint8_t* bytes,
const
int32_t length)
const
;
64
65
// config detail: {'description': 'VIN string character 02', 'offset': 0.0,
66
// 'precision': 1.0, 'len': 8, 'name': 'VIN02', 'is_signed_var': False,
67
// 'physical_range': '[0|255]', 'bit': 23, 'type': 'int', 'order': 'motorola',
68
// 'physical_unit': '-'}
69
int
vin02(
const
std::uint8_t* bytes,
const
int32_t length)
const
;
70
71
// config detail: {'description': 'VIN string character 01', 'offset': 0.0,
72
// 'precision': 1.0, 'len': 8, 'name': 'VIN01', 'is_signed_var': False,
73
// 'physical_range': '[0|255]', 'bit': 15, 'type': 'int', 'order': 'motorola',
74
// 'physical_unit': '-'}
75
int
vin01(
const
std::uint8_t* bytes,
const
int32_t length)
const
;
76
77
// config detail: {'description': 'VIN string character 00', 'offset': 0.0,
78
// 'precision': 1.0, 'len': 8, 'name': 'VIN00', 'is_signed_var': False,
79
// 'physical_range': '[0|255]', 'bit': 7, 'type': 'int', 'order': 'motorola',
80
// 'physical_unit': '-'}
81
int
vin00(
const
std::uint8_t* bytes,
const
int32_t length)
const
;
82
};
83
84
}
// namespace ge3
85
}
// namespace canbus
86
}
// namespace apollo
apollo::canbus::ge3::Scu2302
Definition
scu_2_302.h:27
apollo::canbus::ge3::Scu2302::Scu2302
Scu2302()
Definition
scu_2_302.cc:28
apollo::canbus::ge3::Scu2302::Parse
void Parse(const std::uint8_t *bytes, int32_t length, Ge3 *chassis) const override
Definition
scu_2_302.cc:31
apollo::canbus::ge3::Scu2302::ID
static const int32_t ID
Definition
scu_2_302.h:29
apollo::drivers::canbus::ProtocolData
This is the base class of protocol data.
Definition
protocol_data.h:44
apollo
class register implement
Definition
arena_queue.h:37
protocol_data.h
The class of ProtocolData
apollo::canbus::Ge3
Definition
ge3.proto:615
modules
canbus_vehicle
ge3
protocol
scu_2_302.h