Skip to content

Commit

Permalink
Add head and eye signals for driver
Browse files Browse the repository at this point in the history
Signed-off-by: Erik Jaegervall <[email protected]>
  • Loading branch information
erikbosch committed Feb 29, 2024
1 parent 1c7995d commit 48f00aa
Show file tree
Hide file tree
Showing 4 changed files with 185 additions and 0 deletions.
16 changes: 16 additions & 0 deletions spec/Driver/Driver.vspec
Original file line number Diff line number Diff line change
Expand Up @@ -52,3 +52,19 @@ HeartRate:
type: sensor
unit: bpm
description: Heart rate of the driver.

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

MidEyePosition:
type: branch
description: Mid eye position on vehicle axis according to ISO 8855.
Mid eye position refers to the center of a line drawn between the center of the drivers eyes.
#include MidEyePosition.vspec MidEyePosition

MidEyeGaze:
type: branch
description: Direction from mid eye position to object driver is looking at
#include MidEyeGaze.vspec MidEyeGaze
75 changes: 75 additions & 0 deletions spec/Driver/HeadPosition.vspec
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
# 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.
# It uses axis definition from ISO 8855, where origin is at center of (first) rear axle.
# Definition of "head center" is implementation dependent.
#
# 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)
#

X:
datatype: int16
type: sensor
unit: mm
description: Longitudinal position of head center on vehicle X-axis.
Axis definitions according to ISO 8855. Origin at center of (first) rear axle.
Positive values = forward of rear axle. Negative values = backward of rear axle.

Y:
datatype: int16
type: sensor
unit: mm
description: Lateral position of head center on vehicle Y-axis.
Axis definitions according to ISO 8855. Origin at center of (first) rear axle.
Positive values = left of origin. Negative values = right of origin.

Z:
datatype: int16
type: sensor
unit: mm
description: Height position of head center on vehicle Z-axis.
Axis definitions according to ISO 8855. Origin at center of (first) rear axle.
Positive values = above center of rear axle. Negative values = below center of rear axle.

Roll:
datatype: float
type: sensor
unit: degrees
min: -180
max: 180
description: Head roll (right-hand rule) on vehicle X-axis.
Axis definitions according to ISO 8855.
0 = Head in normal position.
Positive values = head leaned to the right. Negative values = head leaned to the left.

Pitch:
datatype: float
type: sensor
unit: degrees
min: -180
max: 180
description: Head pitch (right-hand rule) on vehicle Y-axis.
Axis definitions according to ISO 8855.
0 = Head in normal position.
Positive values = head leaning down. Negative values = head leaning up.

Yaw:
datatype: float
type: sensor
unit: degrees
min: -180
max: 180
description: Head yaw (right-hand rule) on vehicle Z-axis.
Axis definitions according to ISO 8855.
0 = Head in normal position.
Positive values = head turned left. Negative values = head turned right.
46 changes: 46 additions & 0 deletions spec/Driver/MidEyeGaze.vspec
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
# 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.
# Mid eye position refers to the center of a line drawn between the center of the drivers eyes.
# Gaze refers to the direction to the object the driver is looking at measured from
# mid eye position.
# Axis definitions according to ISO 8855.
#
# 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 Z-axis.
Axis definitions according to ISO 8855.
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 X/Y plane at driver mid eye position and object.
Axis definitions according to ISO 8855.
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.
48 changes: 48 additions & 0 deletions spec/Driver/MidEyePosition.vspec
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
# 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 position.
# Mid eye position refers to the center of a line drawn between the center of the drivers eyes.
# It uses axis definition from ISO 8855, where origin is at center of (first) rear axle.
# Definition of mid eye position for one-eyed drivers is implementation dependent.
# It may be the position of the only existing eye, or the hypothetical mid eye position
# if the driver would have had two eyes.
#
# 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)
#

X:
datatype: int16
type: sensor
unit: mm
description: Longitudinal mid eye position on vehicle X-axis.
Mid eye position refers to the center of a line drawn between the center of the drivers eyes.
Axis definitions according to ISO 8855. Origin at center of (first) rear axle.
Positive values = forward of rear axle. Negative values = backward of rear axle.

Y:
datatype: int16
type: sensor
unit: mm
description: Lateral mid eye position on vehicle Y-axis.
Mid eye position refers to the center of a line drawn between the center of the drivers eyes.
Axis definitions according to ISO 8855. Origin at center of (first) rear axle.
Positive values = left of origin. Negative values = right of origin.

Z:
datatype: int16
type: sensor
unit: mm
description: Lateral mid eye position on vehicle Z-axis.
Mid eye position refers to the center of a line drawn between the center of the drivers eyes.
Axis definitions according to ISO 8855. Origin at center of (first) rear axle.
Positive values = above center of rear axle. Negative values = below center of rear axle.

0 comments on commit 48f00aa

Please sign in to comment.