From df46400d6d6a0e7f225ab2fa8e7209f7b0b7bd24 Mon Sep 17 00:00:00 2001 From: Vehicle Researcher Date: Mon, 9 Sep 2019 23:00:19 +0000 Subject: [PATCH] Squashed 'cereal/' changes from bb94ed98a..ea14abe4b ea14abe4b add gm passive safety model 78d3e3123 allow to specify a passive safety model in CarParams 8a4f891b6 Add lane change events 44ee5a949 Add lane change states to pathPlan 39e31397a Add dashcamOnly flag 32685f4b2 angleModelBias is deprecated be719979c move desire to pathplan 82cd0ed1b add desire to controlsState 5b40840a6 add lqr output to LQRState 5a5b9ac28 addtimes git-subtree-dir: cereal git-subtree-split: ea14abe4bd57563b8a15419ec0bc1c1de711063f --- car.capnp | 6 ++++++ log.capnp | 33 ++++++++++++++++++++++++++++++++- 2 files changed, 38 insertions(+), 1 deletion(-) diff --git a/car.capnp b/car.capnp index 68d2176508..21d3951c4f 100644 --- a/car.capnp +++ b/car.capnp @@ -79,6 +79,9 @@ struct CarEvent @0x9b1657f34caf3ad3 { tooDistracted @54; posenetInvalid @55; soundsUnavailable @56; + preLaneChangeLeft @57; + preLaneChangeRight @58; + laneChange @59; } } @@ -300,6 +303,7 @@ struct CarParams { minEnableSpeed @7 :Float32; minSteerSpeed @8 :Float32; safetyModel @9 :SafetyModel; + safetyModelPassive @42 :SafetyModel = noOutput; safetyParam @10 :Int16; steerMaxBP @11 :List(Float32); @@ -343,6 +347,7 @@ struct CarParams { openpilotLongitudinalControl @37 :Bool; # is openpilot doing the longitudinal control? carVin @38 :Text; # VIN number queried during fingerprinting isPandaBlack @39: Bool; + dashcamOnly @41: Bool; struct LateralPIDTuning { kpBP @0 :List(Float32); @@ -398,6 +403,7 @@ struct CarParams { chrysler @9; tesla @10; subaru @11; + gmPassive @12; } enum SteerControlType { diff --git a/log.capnp b/log.capnp index 479e5ec642..cc17deebc4 100644 --- a/log.capnp +++ b/log.capnp @@ -442,7 +442,7 @@ struct ControlsState @0x97ff69c53601abf1 { alertSoundDEPRECATED @45 :Text; alertSound @56 :Car.CarControl.HUDControl.AudibleAlert; awarenessStatus @26 :Float32; - angleModelBias @27 :Float32; + angleModelBiasDEPRECATED @27 :Float32; gpsPlannerActive @40 :Bool; engageable @41 :Bool; # can OP be engaged? driverMonitoringOn @43 :Bool; @@ -516,8 +516,10 @@ struct ControlsState @0x97ff69c53601abf1 { steerAngle @1 :Float32; i @2 :Float32; output @3 :Float32; + lqrOutput @4 :Float32; } + } struct LiveEventData { @@ -527,6 +529,7 @@ struct LiveEventData { struct ModelData { frameId @0 :UInt32; + timestampEof @9 :UInt64; path @1 :PathData; leftLane @2 :PathData; @@ -697,6 +700,32 @@ struct PathPlan { sensorValid @14 :Bool; commIssue @15 :Bool; posenetValid @16 :Bool; + desire @17 :Desire; + laneChangeState @18 :LaneChangeState; + laneChangeDirection @19 :LaneChangeDirection; + + enum Desire { + none @0; + turnLeft @1; + turnRight @2; + laneChangeLeft @3; + laneChangeRight @4; + keepLeft @5; + keepRight @6; + } + + enum LaneChangeState { + off @0; + preLaneChange @1; + laneChangeStarting @2; + laneChangeFinishing @3; + } + + enum LaneChangeDirection { + none @0; + left @1; + right @2; + } } struct LiveLocationData { @@ -1726,6 +1755,8 @@ struct LiveMapData { } struct CameraOdometry { + frameId @4 :UInt32; + timestampEof @5 :UInt64; trans @0 :List(Float32); # m/s in device frame rot @1 :List(Float32); # rad/s in device frame transStd @2 :List(Float32); # std m/s in device frame