Skip to content

Commit 34b49f6

Browse files
committed
Consolidate driver assist into a single message
With optional ways of customising to allow more flexibility but also common features.
1 parent 25378e9 commit 34b49f6

File tree

1 file changed

+91
-77
lines changed

1 file changed

+91
-77
lines changed

osi_object.proto

Lines changed: 91 additions & 77 deletions
Original file line numberDiff line numberDiff line change
@@ -703,7 +703,7 @@ message MovingObject
703703
// - warnings raised by the vehicle, for example, forward collision warning
704704
// - corrective action taken by the vehicle, for example, auto emergency braking
705705
//
706-
optional DriverAssistState driver_assist_state = 5;
706+
repeated DriverAssistState driver_assist_state = 5;
707707

708708
// Definition of vehicle types.
709709
//
@@ -928,108 +928,122 @@ message MovingObject
928928
}
929929

930930
//
931-
// \brief The state of driver assistance features.
931+
// The driver assist state specifically relating to recognised
932+
// Advanced Driver Assistance Systems.
932933
//
933934
message DriverAssistState
934935
{
935-
// State of recognised ADAS features.
936+
// The particular feature being reported about.
936937
//
937-
repeated ADASState adas_state = 1;
938+
optional AssistFeature assist_feature = 1;
938939

939-
// Custom driver assist state.
940+
// Custom feature name.
940941
//
941-
repeated CustomAssistState custom_assist_state = 2;
942+
// Only used if assist_feature is set to CUSTOM_FEATURE.
943+
//
944+
optional string custom_name = 2;
945+
946+
// The activation state of the feature.
947+
//
948+
// This is whether the feature has actually been triggered, for
949+
// example, a warning has been raised, or additional braking is
950+
// in effect.
951+
//
952+
optional ActivationState activation_state = 3;
942953

954+
// Custom activation state.
955+
//
956+
// Only used if the activation_state is set to CUSTOM_STATE.
943957
//
944-
// The driver assist state specifically relating to recognised
945-
// Advanced Driver Assistance Systems.
958+
optional string custom_activation_state = 4;
959+
960+
// Custom detail.
946961
//
947-
message ADASState
962+
// An opaque set of key-value pairs which capture any user specific
963+
// details that may be relevant. This could include details about
964+
// how a warning was raised (dashboard, audible, etc.) or it could
965+
// be about settings which would influence evaluation, such as
966+
// sensitivity settings.
967+
//
968+
repeated CustomDetail custom_detail = 5;
969+
970+
// ADAS feature that is raising the notification.
971+
//
972+
// \note The naming convention is taken from the SAE guidance on ADAS
973+
// nomenclature:
974+
// https://www.sae.org/binaries/content/assets/cm/content/miscellaneous/adas-nomenclature.pdf
975+
//
976+
enum AssistFeature
948977
{
949-
// The particular feature being reported about.
950-
//
951-
optional ADASFeature adas_feature = 1;
978+
CUSTOM_FEATURE = 1;
979+
BLIND_SPOT_WARNING = 2;
980+
FORWARD_COLLISION_WARNING = 3;
981+
LANE_DEPARTURE_WARNING = 4;
982+
PARKING_COLLISION_WARNING = 5;
983+
REAR_CROSS_TRAFFIC_WARNING = 6;
984+
AUTOMATIC_EMERGENCY_BRAKING = 7;
985+
AUTOMATIC_EMERGENCY_STEERING = 8;
986+
REVERSE_AUTOMATIC_EMERGENCY_BRAKING = 9;
987+
ADAPTIVE_CRUISE_CONTROL = 10;
988+
LANE_KEEPING_ASSIST = 11;
989+
ACTIVE_DRIVING_ASSISTANCE = 12;
990+
BACKUP_CAMERA = 13;
991+
SURROUND_VIEW_CAMERA = 14;
992+
ACTIVE_PARKING_ASSISTANCE = 15;
993+
REMOTE_PARKING_ASSISTANCE = 16;
994+
TRAILER_ASSISTANCE = 17;
995+
AUTOMATIC_HIGH_BEAMS = 18;
996+
DRIVER_MONITORING = 19;
997+
HEAD_UP_DISPLAY = 20;
998+
NIGHT_VISION = 21;
999+
}
9521000

953-
// Whether this particular feature is enabled or not.
1001+
// The activation state of a feature.
1002+
//
1003+
// \note Not all of these will be applicable for all vehicles
1004+
// and features.
1005+
//
1006+
enum ActivationState
1007+
{
1008+
// Used for custom states not covered by the definitions below.
9541009
//
955-
// For example, the Forward Collision Warning feature may
956-
// be enabled, even if it isn't active, because there are no
957-
// vehicles in front.
1010+
// A string state can be specified in custom_activation_state.
9581011
//
959-
optional bool enabled = 2;
1012+
CUSTOM_STATE = 1;
9601013

961-
// The activation state of the feature.
962-
//
963-
// This is whether the feature has actually been triggered, for
964-
// example, a warning has been raised, or additional braking is
965-
// in effect.
1014+
// The feature has been disabled.
9661015
//
967-
optional ActivationState activation_state = 3;
1016+
TURNED_OFF = 2;
9681017

969-
// Custom detail.
970-
//
971-
// An opaque field to distinguish user-specific details, such as
972-
// whether the notification was raised via an audio warning, or
973-
// the dashboard.
1018+
// The feature has errored in some way that renders it ineffective.
9741019
//
975-
optional string custom_detail = 4;
1020+
ERRORED = 3;
9761021

977-
// ADAS feature that is raising the notification.
1022+
// The feature is enabled but conditions have not caused it to be
1023+
// triggered, for example, no vehicles in front to trigger a FCW.
9781024
//
979-
// \note The naming convention is taken from the SAE guidance on ADAS
980-
// nomenclature:
981-
// https://www.sae.org/binaries/content/assets/cm/content/miscellaneous/adas-nomenclature.pdf
982-
//
983-
enum ADASFeature
984-
{
985-
BLIND_SPOT_WARNING = 1;
986-
FORWARD_COLLISION_WARNING = 2;
987-
LANE_DEPARTURE_WARNING = 3;
988-
PARKING_COLLISION_WARNING = 4;
989-
REAR_CROSS_TRAFFIC_WARNING = 5;
990-
AUTOMATIC_EMERGENCY_BRAKING = 6;
991-
AUTOMATIC_EMERGENCY_STEERING = 7;
992-
REVERSE_AUTOMATIC_EMERGENCY_BRAKING = 8;
993-
ADAPTIVE_CRUISE_CONTROL = 9;
994-
LANE_KEEPING_ASSIST = 10;
995-
ACTIVE_DRIVING_ASSISTANCE = 11;
996-
BACKUP_CAMERA = 12;
997-
SURROUND_VIEW_CAMERA = 13;
998-
ACTIVE_PARKING_ASSISTANCE = 14;
999-
REMOTE_PARKING_ASSISTANCE = 15;
1000-
TRAILER_ASSISTANCE = 16;
1001-
AUTOMATIC_HIGH_BEAMS = 17;
1002-
DRIVER_MONITORING = 18;
1003-
HEAD_UP_DISPLAY = 19;
1004-
NIGHT_VISION = 20;
1005-
}
1006-
1007-
// The activation state of a feature.
1025+
STANDBY = 4;
1026+
1027+
// The feature is currently active, for example, a warning is being
1028+
// shown to the driver, or emergency braking is being applied/
10081029
//
1009-
// \note Not all of these will be applicable for all vehicles
1010-
// and features.
1030+
ACTIVE = 5;
1031+
1032+
// The feature would be ACTIVE, but the user has show sufficient
1033+
// input to override, for example, by applying throttle or steering
1034+
// input.
10111035
//
1012-
enum ActivationState
1013-
{
1014-
INACTIVE = 1;
1015-
ACTIVE = 2;
1016-
ACTIVE_DRIVER_OVERRIDE = 3;
1017-
}
1036+
ACTIVE_DRIVER_OVERRIDE = 6;
10181037
}
10191038

1039+
// Custom detail.
10201040
//
1021-
// The driver assist state relating to anything not formally
1022-
// recognised. This could be proprietary assistance features
1023-
// that are available for a particular vehicle.
1041+
// Structure to hold custom key-value pair details.
10241042
//
1025-
message CustomAssistState
1043+
message CustomDetail
10261044
{
1027-
// An identifier for the assistance feature.
1028-
//
1029-
optional string identifier = 1;
1030-
1031-
// A string indicating any relevant information about the feature.
1032-
optional string state = 2;
1045+
optional string key = 1;
1046+
optional string value = 2;
10331047
}
10341048
}
10351049
}

0 commit comments

Comments
 (0)