Skip to content

Commit

Permalink
Add head and eye position signals for driver (#731)
Browse files Browse the repository at this point in the history
Signed-off-by: Erik Jaegervall <[email protected]>
  • Loading branch information
erikbosch authored May 8, 2024
1 parent 2f45377 commit f274051
Show file tree
Hide file tree
Showing 10 changed files with 229 additions and 19 deletions.
2 changes: 1 addition & 1 deletion spec/Cabin/Cabin.vspec
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ Seat:
- Row[1,2]
- ["DriverSide","Middle","PassengerSide"]
description: All seats.
#include SingleSeat.vspec Seat
#include Seat.vspec Seat

#
# Seat attributes.
Expand Down
16 changes: 0 additions & 16 deletions spec/Cabin/Occupant.vspec

This file was deleted.

2 changes: 1 addition & 1 deletion spec/Cabin/SingleSeat.vspec → spec/Cabin/Seat.vspec
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ Occupant:
# Include the Cabin/Occupant.vspec file and attach all its data under the
# Occupant branch created above.

#include Occupant.vspec Occupant
#include Seat/Occupant.vspec Occupant

IsBelted:
datatype: boolean
Expand Down
28 changes: 28 additions & 0 deletions spec/Cabin/Seat/Occupant.vspec
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# Copyright (c) 2020 Contributors to COVESA
#
# This program and the accompanying materials are made available under the
# terms of the Mozilla Public License 2.0 which is available at
# https://www.mozilla.org/en-US/MPL/2.0/
#
# SPDX-License-Identifier: MPL-2.0

#
# Occupant data
#

Identifier:
deprecation: v5.0 - use data from Vehicle.Occupant.*.*.Identifier.
type: branch
description: Identifier attributes based on OAuth 2.0.

Identifier.Subject:
deprecation: v5.0 - use data from Vehicle.Occupant.*.*.Identifier.
datatype: string
type: sensor
description: Subject for the authentication of the occupant e.g. UserID 7331677.

Identifier.Issuer:
deprecation: v5.0 - use data from Vehicle.Occupant.*.*.Identifier.
datatype: string
type: sensor
description: Unique Issuer for the authentication of the occupant e.g. https://accounts.funcorp.com.
16 changes: 15 additions & 1 deletion spec/Driver/Driver.vspec
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,22 @@
# Driver data
#

Identifier:
deprecation: v5.0 - use data from Vehicle.Occupant.*.*.Identifier.
type: branch
description: Identifier attributes based on OAuth 2.0.

#include ../Cabin/Occupant.vspec
Identifier.Subject:
deprecation: v5.0 - use data from Vehicle.Occupant.*.*.Identifier.
datatype: string
type: sensor
description: Subject for the authentication of the occupant e.g. UserID 7331677.

Identifier.Issuer:
deprecation: v5.0 - use data from Vehicle.Occupant.*.*.Identifier.
datatype: string
type: sensor
description: Unique Issuer for the authentication of the occupant e.g. https://accounts.funcorp.com.

DistractionLevel:
datatype: float
Expand Down
26 changes: 26 additions & 0 deletions spec/Vehicle/Occupant.vspec
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# Copyright (c) 2020 Contributors to COVESA
#
# This program and the accompanying materials are made available under the
# terms of the Mozilla Public License 2.0 which is available at
# https://www.mozilla.org/en-US/MPL/2.0/
#
# SPDX-License-Identifier: MPL-2.0

#
# Occupant data
#

Identifier:
type: branch
description: Identifier attributes based on OAuth 2.0.
#include ../include/Identifier.vspec Identifier

HeadPosition:
type: branch
description: The current position of the driver head on vehicle axis according to ISO 23150:2023.
#include Occupant/HeadPosition.vspec HeadPosition

MidEyeGaze:
type: branch
description: Direction from mid eye position to object driver is looking at.
#include Occupant/MidEyeGaze.vspec MidEyeGaze
95 changes: 95 additions & 0 deletions spec/Vehicle/Occupant/HeadPosition.vspec
Original file line number Diff line number Diff line change
@@ -0,0 +1,95 @@
# Copyright (c) 2024 Contributors to COVESA
#
# This program and the accompanying materials are made available under the
# terms of the Mozilla Public License 2.0 which is available at
# https://www.mozilla.org/en-US/MPL/2.0/
#
# SPDX-License-Identifier: MPL-2.0

# This file intends to provide data related to head position.
#
# As specified in "Euro NCAP - Assessment Protocol - Safety Assist" section 3.5.3.1
# (https://www.euroncap.com/media/80158/euro-ncap-assessment-protocol-sa-safe-driving-v104.pdf)
# Head Movement (Owl) can be used to assess detection of driver distraction.
#
# Head position in this file refers to mid eye position.
# Mid eye position refers to the center of a line drawn between the drivers eyes.
# Absence of an eye does not affect mid eye position, as it shall be calculated as if both eyes were present.
#
# Position is given in the vehicle rear-axle coordinate system as defined by ISO 23150:2023 section 3.7.12
# This coordinate system corresponds to a vehicle coordinate system as defined by ISO 8855:2011 section 2.11
# with the vehicle reference point at centre of the (first) rear axle.
#
# With the definitions given below example values for a regular LHD passenger vehicle
# could be something like
# X = 2000 mm (head position 2 meters in front of rear axle)
# Y = 600 mm (head position 60 cm left of vehicle center)
# Z = 1000 mm (head position 100 cm above center of rear axis)
#
# Head Roll/Pitch/Yaw refers to relationship between head axis system and the vehicle rear-axle coordinate system.
#
# Head axis system is defined as follows
# Head X-axis corresponds to a vector from midway between left and right pre-auricular point and nasion.
# Head Y-axis corresponds to a vector orthogonal to X going left from the head on the plane defined by left and right
# pre-auricular point and nasion.
# Head Z-axis corresponds to vector orthogonal to X and Y going upward.
#

X:
datatype: int16
type: sensor
unit: mm
description: Longitudinal position of head center measured as mid eye position on X-axis
of the vehicle rear-axle coordinate system as defined by ISO 23150:2023 section 3.7.12
Mid eye position refers to the center of a line drawn between the center of the drivers eyes.
Positive values = forward of (first) rear-axle. Negative values = backward of (first) rear-axle.

Y:
datatype: int16
type: sensor
unit: mm
description: Lateral position of head center measured as mid eye position on X-axis
of the vehicle rear-axle coordinate system as defined by ISO 23150:2023 section 3.7.12
Mid eye position refers to the center of a line drawn between the center of the drivers eyes.
Positive values = left of rear-axle center. Negative values = right of rear-axle center.

Z:
datatype: int16
type: sensor
unit: mm
description: Height position of head center measured as mid eye position on X-axis
of the vehicle rear-axle coordinate system as defined by ISO 23150:2023 section 3.7.12
Mid eye position refers to the center of a line drawn between the center of the drivers eyes.
Positive values = above center of rear-axle reference point.
Negative values = below center of rear-axle reference point.

Yaw:
datatype: float
type: sensor
unit: degrees
min: -180
max: 180
description: Head yaw angle, measured from the vehicle sprung mass X-axis as defined by ISO 23150:2023
to the head X-axis, around the vehicle Z-axis (right-hand rule).
0 = Head in normal position.
Positive values = Head turned left. Negative values = Head turned right.

Pitch:
datatype: float
type: sensor
unit: degrees
min: -90
max: 90
description: Head pitch angle, measured as angle from vehicle sprung mass XY-plane as defined by ISO 23150:2023
to the head X-axis.
0 = Head in normal position.
Positive values = Head leaning up. Negative values = Head leaning down.
Roll:
datatype: float
type: sensor
unit: degrees
min: -180
max: 180
description: Head roll angle about the head X-axis (right-hand rule).
0 = Head in normal position.
Positive values = Head leaning to the right. Negative values = Head leaning to the left.
52 changes: 52 additions & 0 deletions spec/Vehicle/Occupant/MidEyeGaze.vspec
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
# Copyright (c) 2024 Contributors to COVESA
#
# This program and the accompanying materials are made available under the
# terms of the Mozilla Public License 2.0 which is available at
# https://www.mozilla.org/en-US/MPL/2.0/
#
# SPDX-License-Identifier: MPL-2.0

# This file intends to provide data related to mid eye gaze.
#
# As specified in "Euro NCAP - Assessment Protocol - Safety Assist" section 3.5.3.1
# (https://www.euroncap.com/media/80158/euro-ncap-assessment-protocol-sa-safe-driving-v104.pdf)
# Eye Movement (Lizard) can be used to assess detection of driver distraction.
#
# Mid eye position refers to the center of a line drawn between the drivers eyes.
# Absence of an eye does not affect mid eye position, as it shall be calculated as if both eyes were present.
#
# Gaze refers to the direction to the object the driver is looking at measured from
# mid eye position.
# Axis definitions correspond to the vehicle rear-axle coordinate system as defined by ISO 23150:2023 section 3.7.12
#
# Some examples (at long distance from vehicle)
# Object in front of vehicle (at far distance) - Azimuth==0, Elevation == 0
# Object to the left of vehicle (at far distance) - Azimuth==90, Elevation == 0
# Object to the right of vehicle (at far distance)- Azimuth==-90, Elevation == 0
# Object behind the vehicle (at far distance) - Azimuth==180 or -180, Elevation == 0
# Object right above the vehicle (at height) - Azimuth==<any>, Elevation == 90
# Object deep down below the vehicle - Azimuth==<any>, Elevation == -90

Azimuth:
datatype: float
type: sensor
unit: degrees
min: -180
max: 180
description: Mid eye azimuth gaze (right-hand rule) on vehicle sprung mass Z-axis as defined by ISO 23150:2023
0 = Driver looking forward.
Positive values = Driver looking at something on the left side of driver.
Negative values = Driver looking at something on the right side of driver.

Elevation:
datatype: float
type: sensor
unit: degrees
min: -90
max: 90
description: Elevation to observed object measured
as angle between vehicle sprung mass XY-plane as defined by ISO 23150:2023
at driver mid eye position and object.
0 = Driver looking at something at same height as mid eye position.
Positive values = Driver looking at something above mid eye position.
Negative values = Driver looking at something below mid eye position.
11 changes: 11 additions & 0 deletions spec/VehicleSignalSpecification.vspec
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,17 @@ Vehicle.Driver:

#include Driver/Driver.vspec Vehicle.Driver

#
# Occupant Data
#

Vehicle.Occupant:
type: branch
instances:
- Row[1,2]
- ["DriverSide","Middle","PassengerSide"]
description: Occupant (Driver or Passenger) data.
#include Vehicle/Occupant.vspec Vehicle.Occupant

#
# Exterior information
Expand Down
File renamed without changes.

0 comments on commit f274051

Please sign in to comment.