Skip to content

Commit

Permalink
Squashed 'cereal/' changes from 4ea03ba..748002c
Browse files Browse the repository at this point in the history
748002c angle calib desc
27db4a7 add camera rpy angle msg
a71c4fa deprecate old dm model output
6c6ab96 remove hwType from ThermalData. Decided to have health at higher freq instead. This will make last 24H of collected data unreadable. Sorry.
f27249e Add fields for LQR lateral control
654860c add decelForModel
995b558 add longitudinal plan source
222f2de add eye stuff
eebf268 hasGps is a better name than hasGpsAntenna
12da45f Blackpanda (#4)

git-subtree-dir: cereal
git-subtree-split: 748002c
  • Loading branch information
Vehicle Researcher committed Jul 30, 2019
1 parent 813d5b9 commit 4808de1
Show file tree
Hide file tree
Showing 2 changed files with 37 additions and 3 deletions.
16 changes: 16 additions & 0 deletions car.capnp
Original file line number Diff line number Diff line change
Expand Up @@ -324,6 +324,7 @@ struct CarParams {
lateralTuning :union {
pid @26 :LateralPIDTuning;
indi @27 :LateralINDITuning;
lqr @40 :LateralLQRTuning;
}

steerLimitAlert @28 :Bool;
Expand All @@ -339,6 +340,7 @@ struct CarParams {
steerActuatorDelay @36 :Float32; # Steering wheel actuator delay in seconds
openpilotLongitudinalControl @37 :Bool; # is openpilot doing the longitudinal control?
carVin @38 :Text; # VIN number queried during fingerprinting
isPandaBlack @39: Bool;

struct LateralPIDTuning {
kpBP @0 :List(Float32);
Expand All @@ -365,6 +367,20 @@ struct CarParams {
actuatorEffectiveness @3 :Float32;
}

struct LateralLQRTuning {
scale @0 :Float32;
ki @1 :Float32;
dcGain @2 :Float32;

# State space system
a @3 :List(Float32);
b @4 :List(Float32);
c @5 :List(Float32);

k @6 :List(Float32); # LQR gain
l @7 :List(Float32); # Kalman gain
}


enum SafetyModel {
# does NOT match board setting
Expand Down
24 changes: 21 additions & 3 deletions log.capnp
Original file line number Diff line number Diff line change
Expand Up @@ -301,7 +301,7 @@ struct HealthData {
controlsAllowed @3 :Bool;
gasInterceptorDetected @4 :Bool;
startedSignalDetectedDeprecated @5 :Bool;
isGreyPanda @6 :Bool;
hasGps @6 :Bool;
canSendErrs @7 :UInt32;
canFwdErrs @8 :UInt32;
gmlanSendErrs @9 :UInt32;
Expand Down Expand Up @@ -373,6 +373,8 @@ struct LiveCalibrationData {
# view_frame_from_road_frame
# ui's is inversed needs new
extrinsicMatrix @4 :List(Float32);
# the direction of travel vector in device frame
rpyCalib @7 :List(Float32);
}

struct LiveTracks {
Expand Down Expand Up @@ -448,9 +450,12 @@ struct ControlsState @0x97ff69c53601abf1 {
vCurvature @46 :Float32;
decelForTurn @47 :Bool;

decelForModel @54 :Bool;

lateralControlState :union {
indiState @52 :LateralINDIState;
pidState @53 :LateralPIDState;
lqrState @55 :LateralLQRState;
}

enum OpenpilotState @0xdbe58b96d2d1ac61 {
Expand Down Expand Up @@ -505,6 +510,13 @@ struct ControlsState @0x97ff69c53601abf1 {
saturated @8 :Bool;
}

struct LateralLQRState {
active @0 :Bool;
steerAngle @1 :Float32;
i @2 :Float32;
output @3 :Float32;
}

}

struct LiveEventData {
Expand Down Expand Up @@ -660,6 +672,7 @@ struct Plan {
mpc1 @1;
mpc2 @2;
mpc3 @3;
model @4;
}
}

Expand Down Expand Up @@ -1661,8 +1674,13 @@ struct OrbKeyFrame {

struct DriverMonitoring {
frameId @0 :UInt32;
descriptor @1 :List(Float32);
std @2 :Float32;
descriptorDEPRECATED @1 :List(Float32);
stdDEPRECATED @2 :Float32;
faceOrientation @3 :List(Float32);
facePosition @4 :List(Float32);
faceProb @5 :Float32;
leftEyeProb @6 :Float32;
rightEyeProb @7 :Float32;
}

struct Boot {
Expand Down

0 comments on commit 4808de1

Please sign in to comment.