blob: c10fbce65d82ba02ff1c86ad8f13f6d81a637e63 [file] [log] [blame]
Rashmica Guptae23af562021-07-29 15:12:16 +10001{
2 "$schema": "http://json-schema.org/draft-07/schema#",
Patrick Williams7d6080d2024-09-04 12:54:45 -04003 "$defs": {
Rashmica Guptae23af562021-07-29 15:12:16 +10004 "VirtualSensor": {
Alexander Hansencb68f362025-04-16 17:18:13 +02005 "additionalProperties": false,
Rashmica Guptae23af562021-07-29 15:12:16 +10006 "title": "phosphor-virtual-sensor configuration",
Andrew Jefferybb8aa372024-03-20 11:24:32 +10307 "description": "The configuration used by the virtual-sensor daemon in the phosphor-virtual-sensor repository. Virtual sensors are xyz.openbmc_project.Sensor.Value D-Bus objects that have sensor values calculated from the D-Bus sensors listed here.",
Rashmica Guptae23af562021-07-29 15:12:16 +10008 "type": "object",
9 "properties": {
10 "MaxValidInput": {
Andrew Jefferybb8aa372024-03-20 11:24:32 +103011 "description": "Maximum valid value of an input sensor",
Rashmica Guptae23af562021-07-29 15:12:16 +100012 "type": "number"
13 },
14 "MaxValue": {
Andrew Jefferybb8aa372024-03-20 11:24:32 +103015 "description": "Maximum sensor value",
Patrick Williams7d6080d2024-09-04 12:54:45 -040016 "$ref": "legacy.json#/$defs/Types/MaxValue"
Rashmica Guptae23af562021-07-29 15:12:16 +100017 },
18 "MinValidInput": {
Andrew Jefferybb8aa372024-03-20 11:24:32 +103019 "description": "Miniumum valid value of an input sensor",
Rashmica Guptae23af562021-07-29 15:12:16 +100020 "type": "number"
21 },
22 "MinValue": {
Andrew Jefferybb8aa372024-03-20 11:24:32 +103023 "description": "Minimum sensor value",
Patrick Williams7d6080d2024-09-04 12:54:45 -040024 "$ref": "legacy.json#/$defs/Types/MinValue"
Rashmica Guptae23af562021-07-29 15:12:16 +100025 },
26 "Name": {
27 "type": "string"
28 },
Alexander Hansencb68f362025-04-16 17:18:13 +020029 "PowerState": {
30 "$ref": "legacy.json#/$defs/Types/PowerState"
31 },
32 "EntityId": {
33 "$ref": "legacy.json#/$defs/Types/EntityId"
34 },
35 "EntityInstance": {
36 "$ref": "legacy.json#/$defs/Types/EntityInstance"
37 },
Rashmica Guptae23af562021-07-29 15:12:16 +100038 "Sensors": {
Andrew Jefferybb8aa372024-03-20 11:24:32 +103039 "description": "Any DBus sensors whose values are used to determine the value of the virtual sensor.",
Rashmica Guptae23af562021-07-29 15:12:16 +100040 "items": {
41 "type": "string"
42 },
43 "type": "array"
44 },
45 "Thresholds": {
Andrew Jefferybb8aa372024-03-20 11:24:32 +103046 "description": "Threshold values used to set and clear alarms",
Patrick Williams7d6080d2024-09-04 12:54:45 -040047 "$ref": "legacy.json#/$defs/Types/Thresholds"
Rashmica Guptae23af562021-07-29 15:12:16 +100048 },
49 "Type": {
Andrew Jefferybb8aa372024-03-20 11:24:32 +103050 "description": "The type of calculation this sensor uses.",
Rashmica Guptae23af562021-07-29 15:12:16 +100051 "type": "string",
George Liuae36f5e2024-09-19 15:43:04 +080052 "enum": [
53 "Average",
54 "Maximum",
55 "Minimum",
56 "Sum",
57 "ModifiedMedian"
58 ]
Rashmica Guptae23af562021-07-29 15:12:16 +100059 },
60 "Units": {
Andrew Jefferybb8aa372024-03-20 11:24:32 +103061 "description": "The sensor type, as it shows up in the D-Bus object name.",
Patrick Williams7d6080d2024-09-04 12:54:45 -040062 "$ref": "legacy.json#/$defs/Types/Units"
Rashmica Guptae23af562021-07-29 15:12:16 +100063 }
64 },
Patrick Williamsfa8ee872022-12-07 07:00:42 -060065 "required": ["Name", "Sensors", "Type", "Units"]
Rashmica Guptae23af562021-07-29 15:12:16 +100066 }
67 }
68}