Apollo 10.0
自动驾驶开放平台
lincoln.proto
浏览该文件的文档.
1syntax = "proto2";
2
3package apollo.canbus;
4
8
9message Lincoln {
10 enum Type {
11 QIRUI_EQ_15 = 0;
12 CHANGAN_RUICHENG = 1;
13 }
14 optional Type car_type = 1; // car type
15 optional BasicInfo basic = 2; // basic info
16 optional Safety safety = 3; // safety
17 optional Gear gear = 4; // gear
18 optional Ems ems = 5; // engine manager system
19 optional Esp esp = 6; // Electronic Stability Program
20 optional Gas gas = 7; // gas pedal
21 optional Epb epb = 8; // Electronic parking brake
22 optional Brake brake = 9; // brake pedal
23 optional Deceleration deceleration = 10; // deceleration
24 optional VehicleSpd vehicle_spd = 11; // vehicle speed
25 optional Eps eps = 12; // Electronic Power Steering
26 optional Light light = 13; // Light
27 optional Battery battery = 14; // Battery info
28 optional CheckResponseSignal check_response = 15;
29 optional Surround surround = 17; // Surround information
30 // Reserve fields for other vehicles
31 optional apollo.common.VehicleID vehicle_id = 101;
32}
33
34// CheckResponseSignal
36 optional bool is_eps_online = 1 [default = false]; // byd:0x34C qirui:0x505
37 optional bool is_epb_online = 2 [default = false]; // byd:0x218
38 optional bool is_esp_online = 3 [default = false]; // byd:0x122 qirui:0x451
39 optional bool is_vtog_online = 4 [default = false]; // byd:0x242
40 optional bool is_scu_online = 5 [default = false]; // byd:0x35C
41 optional bool is_switch_online = 6 [default = false]; // byd:0x133
42 optional bool is_vcu_online = 7 [default = false]; // qirui:0x400
43}
44
45// Battery
46message Battery {
47 optional double battery_percent = 1; // unit:%, battery percentage left
48 // lincoln fuellevel 72
49 optional double fuel_level = 2;
50}
51
52// light
53message Light {
55 TURN_LIGHT_OFF = 0;
56 TURN_LEFT_ON = 1;
57 TURN_RIGHT_ON = 2;
58 TURN_LIGHT_ON = 3;
59 }
61 BEAM_OFF = 0;
62 HIGH_BEAM_ON = 1;
63 LOW_BEAM_ON = 2;
64 }
66 BEAM_NULL = 0;
67 BEAM_FLASH_TO_PASS = 1;
68 BEAM_HIGH = 2;
69 BEAM_INVALID = 3;
70 }
72 WIPER_OFF = 0;
73 WIPER_AUTO_OFF = 1;
74 WIPER_OFF_MOVING = 2;
75 WIPER_MANUAL_OFF = 3;
76 WIPER_MANUAL_ON = 4;
77 WIPER_MANUAL_LOW = 5;
78 WIPER_MANUAL_HIGH = 6;
79 WIPER_MIST_FLICK = 7;
80 WIPER_WASH = 8;
81 WIPER_AUTO_LOW = 9;
82 WIPER_AUTO_HIGH = 10;
83 WIPER_COURTESY_WIPE = 11;
84 WIPER_AUTO_ADJUST = 12;
85 WIPER_RESERVED = 13;
86 WIPER_STALLED = 14;
87 WIPER_NO_DATA = 15;
88 }
90 AMBIENT_DARK = 0;
91 AMBIENT_LIGHT = 1;
92 AMBIENT_TWILIGHT = 2;
93 AMBIENT_TUNNEL_ON = 3;
94 AMBIENT_TUNNEL_OFF = 4;
95 AMBIENT_INVALID = 5;
96 AMBIENT_NO_DATA = 7;
97 }
98
99 optional TurnLightType turn_light_type = 1;
100 optional BeamLampType beam_lamp_type = 2;
101 optional bool is_brake_lamp_on = 3;
102 // byd switch 133
103 optional bool is_auto_light = 4;
104 optional int32 wiper_gear = 5;
105 optional int32 lotion_gear = 6;
106 optional bool is_horn_on = 7;
107
108 // lincoln misc 69
109 optional LincolnLampType lincoln_lamp_type = 8;
110 optional LincolnWiperType lincoln_wiper = 9;
111 optional LincolnAmbientType lincoln_ambient = 10;
112}
113
114// Electrical Power Steering
115message Eps {
116 enum Type {
117 NOT_AVAILABLE = 0;
118 READY = 1;
119 ACTIVE = 2;
120 INVALID = 3;
121 }
122 // changan: eps 2a0
123 optional bool is_eps_fail = 1;
124 // eps 2a0
125 optional Type eps_control_state = 2; // for changan to control steering
126 optional double eps_driver_hand_torq = 3; // unit:Nm
127
128 optional bool is_steering_angle_valid = 4;
129 optional double steering_angle = 5; // unit:degree
130 optional double steering_angle_spd = 6; // unit:degree/s
131
132 // byd sas 11f
133 optional bool is_trimming_status = 7;
134 optional bool is_calibration_status = 8;
135 optional bool is_failure_status = 9;
136 optional int32 allow_enter_autonomous_mode = 10;
137 optional int32 current_driving_mode = 11;
138
139 // lincoln steering 65
140 optional double steering_angle_cmd = 12;
141 optional double vehicle_speed = 13;
142 optional double epas_torque = 14;
143 optional bool steering_enabled = 15;
144 optional bool driver_override = 16;
145 optional bool driver_activity = 17;
146 optional bool watchdog_fault = 18;
147 optional bool channel_1_fault = 19;
148 optional bool channel_2_fault = 20;
149 optional bool calibration_fault = 21;
150 optional bool connector_fault = 22;
151
152 optional double timestamp_65 = 23;
153
154 // lincoln version 7f
155 optional int32 major_version = 24;
156 optional int32 minor_version = 25;
157 optional int32 build_number = 26;
158}
159
160message VehicleSpd {
161 // esp 277
162 optional bool is_vehicle_standstill = 1;
163 // esp 218
164 optional bool is_vehicle_spd_valid = 2;
165 optional double vehicle_spd = 3 [default = 0]; // unit:m/s
166 // esp 208
167 optional bool is_wheel_spd_rr_valid = 4;
168 optional WheelSpeed.WheelSpeedType wheel_direction_rr = 5;
169 optional double wheel_spd_rr = 6;
170 optional bool is_wheel_spd_rl_valid = 7;
171 optional WheelSpeed.WheelSpeedType wheel_direction_rl = 8;
172 optional double wheel_spd_rl = 9;
173 optional bool is_wheel_spd_fr_valid = 10;
174 optional WheelSpeed.WheelSpeedType wheel_direction_fr = 11;
175 optional double wheel_spd_fr = 12;
176 optional bool is_wheel_spd_fl_valid = 13;
177 optional WheelSpeed.WheelSpeedType wheel_direction_fl = 14;
178 optional double wheel_spd_fl = 15;
179
180 // byd esp 222
181 optional bool is_yaw_rate_valid = 16;
182 optional double yaw_rate = 17;
183 optional double yaw_rate_offset = 18;
184
185 // byd esp 223
186 optional bool is_ax_valid = 19;
187 optional double ax = 20;
188 optional double ax_offset = 21;
189 optional bool is_ay_valid = 22;
190 optional double ay = 23;
191 optional double ay_offset = 24;
192
193 // lincoln accel 6b
194 optional double lat_acc = 25;
195 optional double long_acc = 26;
196 optional double vert_acc = 27;
197
198 // lincoln gyro 6c
199 optional double roll_rate = 28;
200
201 // lincoln brakeinfo 74
202 optional double acc_est = 29;
203
204 // lincoln wheelspeed 6a
205 optional double timestamp_sec = 30;
206}
207
209 // esp 277
210 optional bool is_deceleration_available =
211 1; // for changan to send deceleration value
212 optional bool is_deceleration_active =
213 2; // for changan to send deceleration value
214
215 optional double deceleration = 3 [default = 0];
217 optional double is_evb_fail = 4;
218 optional double evb_pressure = 5 [default = 0]; // mpa, 0~25.5
220 optional double brake_pressure = 6 [default = 0];
221 optional double brake_pressure_spd = 7 [default = 0];
224message Brake {
226 HSA_INACTIVE = 0;
227 HSA_FINDING_GRADIENT = 1;
228 HSA_ACTIVE_PRESSED = 2;
229 HSA_ACTIVE_RELEASED = 3;
230 HSA_FAST_RELEASE = 4;
231 HSA_SLOW_RELEASE = 5;
232 HSA_FAILED = 6;
233 HSA_UNDEFINED = 7;
236 HSA_OFF = 0;
237 HSA_AUTO = 1;
238 HSA_MANUAL = 2;
239 HSA_MODE_UNDEFINED = 3;
241 // ems 255
242 optional bool is_brake_pedal_pressed = 1
243 [default = false]; // only manual brake
244 // esp 277
245 optional bool is_brake_force_exist =
246 2; // no matter auto mode brake or manual brake
247 optional bool is_brake_over_heat = 3;
248
249 optional bool is_hand_brake_on = 4; // hand brake
250 optional double brake_pedal_position = 5;
251
252 // byd vtog 342
253 optional bool is_brake_valid = 6;
255 // lincoln brake 61
256 optional double brake_input = 7;
257 optional double brake_cmd = 8;
258 optional double brake_output = 9;
259 optional bool boo_input = 10;
260 optional bool boo_cmd = 11;
261 optional bool boo_output = 12;
262 optional bool watchdog_applying_brakes = 13;
263 optional int32 watchdog_source = 14;
264 optional bool brake_enabled = 15;
265 optional bool driver_override = 16;
266 optional bool driver_activity = 17;
267 optional bool watchdog_fault = 18;
268 optional bool channel_1_fault = 19;
269 optional bool channel_2_fault = 20;
270 optional bool boo_fault = 21;
271 optional bool connector_fault = 22;
273 // lincoln brakeinfo 74
274 optional double brake_torque_req = 23;
275 optional HSAStatusType hsa_status = 24;
276 optional double brake_torque_act = 25;
277 optional HSAModeType hsa_mode = 26;
278 optional double wheel_torque_act = 27;
280 // lincoln version 7f
281 optional int32 major_version = 28;
282 optional int32 minor_version = 29;
283 optional int32 build_number = 30;
286// Electrical Parking Brake
287message Epb {
289 PBRAKE_OFF = 0;
290 PBRAKE_TRANSITION = 1;
291 PBRAKE_ON = 2;
292 PBRAKE_FAULT = 3;
293 }
294 // epb 256
295 optional bool is_epb_error = 1;
296 optional bool is_epb_released = 2;
297
298 // byd epb 218
299 optional int32 epb_status = 3;
300
301 // lincoln brakeinfo 74
302 optional PBrakeType parking_brake_status = 4;
304
305message Gas {
306 // ems 255
307 optional bool is_gas_pedal_error = 1;
308 // ems 26a
309 optional bool is_gas_pedal_pressed_more = 2; // more than auto mode gas torq
310 optional double gas_pedal_position = 3 [default = 0]; // manual gas
311 // byd vtog 342
312 optional bool is_gas_valid = 4 [default = false];
314 // lincoln throttle 63
315 optional double throttle_input = 5;
316 optional double throttle_cmd = 6;
317 optional double throttle_output = 7;
318 optional int32 watchdog_source = 8;
319 optional bool throttle_enabled = 9;
320 optional bool driver_override = 10;
321 optional bool driver_activity = 11;
322 optional bool watchdog_fault = 12;
323 optional bool channel_1_fault = 13;
324 optional bool channel_2_fault = 14;
325 optional bool connector_fault = 15;
326
327 // lincoln throttleinfo 75
328 optional double accelerator_pedal = 16;
329 optional double accelerator_pedal_rate = 17;
331 // lincoln version 7f
332 optional int32 major_version = 18;
333 optional int32 minor_version = 19;
334 optional int32 build_number = 20;
335}
337// Electronic Stability Program
338message Esp {
339 // esp 277
340 optional bool is_esp_acc_error = 1; // for changan to control car
342 // esp 218
343 optional bool is_esp_on = 2;
344 optional bool is_esp_active = 3;
345 optional bool is_abs_error = 4;
346 optional bool is_abs_active = 5;
347 optional bool is_tcsvdc_fail = 6;
349 // lincoln brakeinfo 74
350 optional bool is_abs_enabled = 7;
351 optional bool is_stab_active = 8;
352 optional bool is_stab_enabled = 9;
353 optional bool is_trac_active = 10;
354 optional bool is_trac_enabled = 11;
357// Engine Manager System
358message Ems {
359 enum Type {
360 STOP = 0;
361 CRANK = 1;
362 RUNNING = 2;
363 INVALID = 3;
364 }
365 // ems 26a
366 optional bool is_engine_acc_available = 1; // for changan to control car
367 optional bool is_engine_acc_error = 2; // for changan to control car
369 // ems 265
370 optional Type engine_state = 3;
371 optional double max_engine_torq_percent = 4; // for engine torq control, unit:%
372 optional double min_engine_torq_percent = 5; // for engine torq control, unit:%
373 optional int32 base_engine_torq_constant = 6; // for engine torq control, unit:Nm
374
375 // ems 255
376 optional bool is_engine_speed_error = 7;
377 optional double engine_speed = 8;
379 // byd vtog 241
380 optional int32 engine_torque = 9;
381 // byd vtog 242
382 optional bool is_over_engine_torque = 10;
383
384 // lincoln mkz throttleinfo 75
385 optional double engine_rpm = 11;
387
388message Gear {
389 // tcu 268
390 optional bool is_shift_position_valid = 1;
391 // chanan: tcu 268
392 optional Chassis.GearPosition gear_state = 2;
393 // lincoln gear 67
394 optional bool driver_override = 3;
395 optional Chassis.GearPosition gear_cmd = 4;
396 optional bool canbus_fault = 5;
397}
399
400message Safety {
401 // ip 270
402 optional bool is_driver_car_door_close = 1;
403 // sas 50
404 optional bool is_driver_buckled = 2;
405
406 // byd sws 4a8
407 optional int32 emergency_button = 3;
409 // qirui:403
410 // when car chassis error, like system fault, or warning report
411 optional bool has_error = 4 [default = false];
412 optional bool is_motor_invertor_fault = 5;
413 optional bool is_system_fault = 6;
414 optional bool is_power_battery_fault = 7;
415 optional bool is_motor_invertor_over_temperature = 8;
416 optional bool is_small_battery_charge_discharge_fault = 9;
417 optional int32 driving_mode = 10;
419 // lincoln misc 69
420 optional bool is_passenger_door_open = 11;
421 optional bool is_rearleft_door_open = 12;
422 optional bool is_rearright_door_open = 13;
423 optional bool is_hood_open = 14;
424 optional bool is_trunk_open = 15;
425 optional bool is_passenger_detected = 16;
426 optional bool is_passenger_airbag_enabled = 17;
427 optional bool is_passenger_buckled = 18;
429 // lincoln tirepressure 71
430 optional int32 front_left_tire_press = 19;
431 optional int32 front_right_tire_press = 20;
432 optional int32 rear_left_tire_press = 21;
433 optional int32 rear_right_tire_press = 22;
434 optional DrivingMode car_driving_mode = 23;
438 COMPLETE_MANUAL = 0; // human drive
440 AUTO_STEER_ONLY = 2; // only steer
441 AUTO_SPEED_ONLY = 3; // include throttle and brake
442
443 // security mode when manual intervention happens, only response status
447message BasicInfo {
448 enum Type {
449 OFF = 0;
450 ACC = 1;
451 ON = 2;
452 START = 3;
453 INVALID = 4;
456 optional bool is_auto_mode = 1;
457 optional Type power_state = 2;
458 optional bool is_air_bag_deployed = 3;
459 optional double odo_meter = 4; // odo meter, unit:km
460 optional double drive_range =
461 5; // the meter left when drive continuously, unit:km
462 optional bool is_system_error = 6;
463 optional bool is_human_interrupt = 7; // human interrupt
465 // lincoln misc 69
466 optional bool acc_on_button = 8; // acc on button pressed
467 optional bool acc_off_button = 9;
468 optional bool acc_res_button = 10;
469 optional bool acc_cancel_button = 11;
470 optional bool acc_on_off_button = 12;
471 optional bool acc_res_cancel_button = 13;
472 optional bool acc_inc_spd_button = 14;
473 optional bool acc_dec_spd_button = 15;
474 optional bool acc_inc_gap_button = 16;
475 optional bool acc_dec_gap_button = 17;
476 optional bool lka_button = 18;
477 optional bool canbus_fault = 19;
478
479 // lincoln gps 6d
480 optional double latitude = 20;
481 optional double longitude = 21;
482 optional bool gps_valid = 22;
484 // lincoln gps 6e
485 optional int32 year = 23;
486 optional int32 month = 24;
487 optional int32 day = 25;
488 optional int32 hours = 26;
489 optional int32 minutes = 27;
490 optional int32 seconds = 28;
491 optional double compass_direction = 29;
492 optional double pdop = 30;
493 optional bool is_gps_fault = 31;
494 optional bool is_inferred = 32;
496 // lincoln gps 6f
497 optional double altitude = 33;
498 optional double heading = 34;
499 optional double hdop = 35;
500 optional double vdop = 36;
501 optional GpsQuality quality = 37;
502 optional int32 num_satellites = 38;
503 optional double gps_speed = 39;
504}
syntax
Definition lincoln.proto:1
apollo::common
class register implement
Definition arena_queue.h:37