Skip to content

Commit

Permalink
Add CO2 sensor
Browse files Browse the repository at this point in the history
  • Loading branch information
koarlchen committed Dec 23, 2024
1 parent 20e924b commit a422ffa
Show file tree
Hide file tree
Showing 2 changed files with 49 additions and 0 deletions.
48 changes: 48 additions & 0 deletions 15-draft.json
Original file line number Diff line number Diff line change
Expand Up @@ -417,6 +417,54 @@
]
}
},
"carbondioxide": {
"description": "CO2 sensor",
"type": "array",
"items": {
"type": "object",
"properties": {
"value": {
"description": "The sensor value",
"type": "number"
},
"unit": {
"description": "The unit of the sensor value.",
"type": "string",
"enum": [
"ppm",
"vol%"
]
},
"location": {
"description": "The location of your sensor",
"type": "string",
"examples": [
"Outside",
"Inside",
"Ceiling",
"Room 1"
]
},
"name": {
"description": "This field is an additional field to give your sensor a name. This can be useful if you have multiple sensors in the same location.",
"type": "string"
},
"description": {
"description": "An extra field that you can use to attach some additional information to this sensor instance",
"type": "string"
},
"lastchange": {
"description": "The Unix timestamp (in seconds) when the sensor value changed most recently",
"type": "number"
}
},
"required": [
"value",
"unit",
"location"
]
}
},
"door_locked": {
"description": "Sensor type to indicate if a certain door is locked.",
"type": "array",
Expand Down
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ Root level:
`sensors`:

- [added] The `power_generation` sensor was added ([#105])
- [added] The `carbondioxide` sensor was added ([#116])
- [added] The `lastchange` field was added to all sensors ([#97])
- [removed] The deprecated unit `hPA` in `barometer.unit` was removed, use `hPa` instead ([#109])
- [removed] The redundant unit `mW` in `power_consumption.unit` was removed, use `W` instead ([#109])
Expand Down

0 comments on commit a422ffa

Please sign in to comment.