-
Notifications
You must be signed in to change notification settings - Fork 10
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
IPSO Temperature Object using sdfChoice and OMA IDs #58
Open
akeranen
wants to merge
2
commits into
one-data-model:master
Choose a base branch
from
akeranen:master
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
149 changes: 149 additions & 0 deletions
149
sdfObject/sdfobject-ipso-temperature-sdfchoice.sdf.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,149 @@ | ||
{ | ||
"info": { | ||
"title": "OMA LwM2M Temperature (Object ID 3303)", | ||
"version": "2023-03-25", | ||
"copyright": "Copyright 2019 Open Mobile Alliance.", | ||
"license": "BSD-3-Clause" | ||
}, | ||
"namespace": { | ||
"oma": "https://onedm.org/ecosystem/oma" | ||
}, | ||
"defaultNamespace": "oma", | ||
"sdfObject": { | ||
"Temperature": { | ||
"label": "Temperature", | ||
"description": "This IPSO object should be used with a temperature sensor to report a temperature measurement. It also provides resources for minimum/maximum measured values and the minimum/maximum range that can be measured by the temperature sensor. An example measurement unit is degrees Celsius.", | ||
"oma:id": "3303", | ||
"sdfProperty": { | ||
"Sensor_Value": { | ||
"label": "Sensor Value", | ||
"description": "Last or Current Measured Value from the Sensor.", | ||
"oma:id": 5700, | ||
"writable": false, | ||
"type": "number" | ||
}, | ||
"Min_Measured_Value": { | ||
"label": "Min Measured Value", | ||
"description": "The minimum value measured by the sensor since power ON or reset.", | ||
"oma:id": 5601, | ||
"writable": false, | ||
"type": "number" | ||
}, | ||
"Max_Measured_Value": { | ||
"label": "Max Measured Value", | ||
"description": "The maximum value measured by the sensor since power ON or reset.", | ||
"oma:id": 5602, | ||
"writable": false, | ||
"type": "number" | ||
}, | ||
"Min_Range_Value": { | ||
"label": "Min Range Value", | ||
"description": "The minimum value that can be measured by the sensor.", | ||
"oma:id": 5603, | ||
"writable": false, | ||
"type": "number" | ||
}, | ||
"Max_Range_Value": { | ||
"label": "Max Range Value", | ||
"description": "The maximum value that can be measured by the sensor.", | ||
"oma:id": 5604, | ||
"writable": false, | ||
"type": "number" | ||
}, | ||
"Sensor_Units": { | ||
"label": "Sensor Units", | ||
"description": "Measurement Units Definition.", | ||
"oma:id": 5701, | ||
"writable": false, | ||
"type": "string" | ||
}, | ||
"Application_Type": { | ||
"label": "Application Type", | ||
"description": "The application type of the sensor or actuator as a string depending on the use case.", | ||
"oma:id": 5750, | ||
"type": "string" | ||
}, | ||
"Timestamp": { | ||
"label": "Timestamp", | ||
"description": "The timestamp of when the measurement was performed.", | ||
"oma:id": 5518, | ||
"writable": false, | ||
"type": "number", | ||
"sdfType": "unix-time" | ||
}, | ||
"Fractional_Timestamp": { | ||
"label": "Fractional Timestamp", | ||
"description": "Fractional part of the timestamp when sub-second precision is used (e.g., 0.23 for 230 ms).", | ||
"oma:id": 6050, | ||
"writable": false, | ||
"type": "number", | ||
"unit": "s", | ||
"minimum": 0, | ||
"maximum": 1 | ||
}, | ||
"Measurement_Quality_Indicator": { | ||
"label": "Measurement Quality Indicator", | ||
"description": "Measurement quality indicator reported by a smart sensor.", | ||
"oma:id": 6042, | ||
"writable": false, | ||
"type": "integer", | ||
"minimum": 0, | ||
"maximum": 23, | ||
"sdfChoice": { | ||
"UNCHECKED": { | ||
"description": "No quality checks were done because they do not exist or can not be applied.", | ||
"const": 0 | ||
}, | ||
"REJECTED WITH CERTAINTY": { | ||
"description": "The measured value is invalid.", | ||
"const": 1 | ||
}, | ||
"REJECTED WITH PROBABILITY": { | ||
"description": "The measured value is likely invalid.", | ||
"const": 2 | ||
}, | ||
"ACCEPTED BUT SUSPICIOUS": { | ||
"description": "The measured value is likely OK.", | ||
"const": 3 | ||
}, | ||
"ACCEPTED": { | ||
"description": "The measured value is OK.", | ||
"const": 4 | ||
}, | ||
"option6": { | ||
"description": "Reserved for future extensions.", | ||
"minimum": 5, | ||
"maximum": 15, | ||
"type": "integer" | ||
}, | ||
"option7": { | ||
"description": "Vendor specific measurement quality.", | ||
"minimum": 16, | ||
"maximum": 23, | ||
"type": "integer" | ||
} | ||
} | ||
}, | ||
"Measurement_Quality_Level": { | ||
"label": "Measurement Quality Level", | ||
"description": "Measurement quality level reported by a smart sensor. Quality level 100 means that the measurement has fully passed quality check algorithms. Smaller quality levels mean that quality has decreased and the measurement has only partially passed quality check algorithms. The smaller the quality level, the more caution should be used by the application when using the measurement. When the quality level is 0 it means that the measurement should certainly be rejected.", | ||
"oma:id": 6049, | ||
"writable": false, | ||
"type": "integer", | ||
"minimum": 0, | ||
"maximum": 100 | ||
} | ||
}, | ||
"sdfAction": { | ||
"Reset_Min_and_Max_Measured_Values": { | ||
"label": "Reset Min and Max Measured Values", | ||
"description": "Reset the Min and Max Measured Values to Current Value.", | ||
"oma:id": 5605 | ||
} | ||
}, | ||
"sdfRequired": [ | ||
"#/sdfObject/Temperature/sdfProperty/Sensor_Value" | ||
] | ||
} | ||
} | ||
} |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is probably just me, but I can't find mentions of such namespace-specific qualities in draft-13.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The possibility to use namespace'd quality extensions is mentioned in section 2.3.3 but we still need to finalise the spec on this and add IANA registry for the namespaces (this is a different namespace than the definition namespace).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Usually in SDF models you would leave ecosystem specific details (like OMA IDs) to the mapping file, but I happened to run the conversion tool with ID in-lining mode in this case.