Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Representing alternate sampling conventions #7

Open
tguild opened this issue Oct 30, 2023 · 2 comments
Open

Representing alternate sampling conventions #7

tguild opened this issue Oct 30, 2023 · 2 comments

Comments

@tguild
Copy link
Collaborator

tguild commented Oct 30, 2023

The recommended signals list will have two sampling guidelines, curve based with error threshold parameter and event/time/distance based. Variation of vehicle architectures will likely lead to even different sampling conventions used, for instance the accuracy of a sensor may be lower than a measurable threshold or broadcast rate lower than desired sampling frequency for time based.

This suggests we need to be able to represent the alternatives in both the guidelines and the collected data results as metadata.

In the guidelines we can either have two or more different directives

Example:

We want Vehicle.Powertrain.CombusitionEngine.Speed (RPM) ideally collected with some smart (curve logic) to detect and notify about significant change in data point or every 30 seconds.

In an overlay for this signal we can add either one or two name/value parameters.

Vehicle.Powertrain.CombusitionEngine.Speed:
datatype: uint16
type: sensor
unit: rpm
description: Engine speed measured as rotations per minute.
sampling: +-1500; 0.033Hz

Semi-colon separation can be used similar to language and content negotiation HTTP headers (text/html; text/plain) where the client's preferred order is given and the system responds based with what it has as content or capability.

Alternately we can split over multiple lines.

curve-sampling: +-1500
sampling: 0.033Hz

Knowing how the data was collected should be relayed back to the cloud server, at least once - the first time the vehicle sends a sample to that server or upon change. YAML, JSON or other representation of VSS less uncessary metadata not expected to vary from the VSS definition such as type, unit, description, datatype can be relayed to the server.

@tguild
Copy link
Collaborator Author

tguild commented Nov 20, 2024

Achim suggests the preference comes from the client side - desired request of how to sample.

@erikbosch
Copy link

VSS-tools also supports hierarchical attributes like below. Could be relevant if some sampling method require multiple arguments.

Vehicle.Powertrain.CombusitionEngine.Speed:
datatype: uint16
type: sensor
unit: rpm
description: Engine speed measured as rotations per minute.
sampling: // If multiple ones defined, use OR logic, i.e. sample as soon as one of them are fulfilled
  curve: 1500 // If always symmetric diff there is no need to include +-
                     // But do we need to support asymmetric like -300 +500
  interval: 30000 // Millisecond interval could be an alternative to hertz

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants