Skip to content

Commit 53720b5

Browse files
authored
Merge pull request #321 from peternewman/e1.20-2025
Add new PID data from E1.20-2025
2 parents 802cd5f + 6073223 commit 53720b5

4 files changed

Lines changed: 344 additions & 44 deletions

File tree

data/pid_data.py

Lines changed: 197 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -4193,8 +4193,16 @@
41934193
(0x1e, 'Items'),
41944194
(0x1f, 'Humidity'),
41954195
(0x20, '16 bit counter'),
4196+
(0x21, "CPU load"),
4197+
(0x22, "Bandwidth"),
4198+
(0x23, "Concentration"),
4199+
(0x24, "Sound pressure level"),
4200+
(0x25, "Solid angle"),
4201+
(0x26, "Log ratio"),
4202+
(0x27, "Log ratio volts"),
4203+
(0x28, "Log ratio watts"),
41964204
(0x7f, 'Other')],
4197-
'range': [(0, 0x20), (0x7f, 0xff)]},
4205+
'range': [(0, 0x28), (0x7f, 0xff)]},
41984206
{'name': 'unit', 'type': 'uint8',
41994207
'labels': [(0x00, 'None'),
42004208
(0x01, 'Centigrade'),
@@ -4224,8 +4232,16 @@
42244232
(0x19, 'Lumens'),
42254233
(0x1a, 'Lux'),
42264234
(0x1b, 'Ire'),
4227-
(0x1c, 'Bytes')],
4228-
'range': [(0, 0x1c), (0x80, 0xff)]},
4235+
(0x1c, 'Bytes'),
4236+
(0x1d, 'Decibel'),
4237+
(0x1e, 'Decibel Volt'),
4238+
(0x1f, 'Decibel Watt'),
4239+
(0x20, 'Decibel Meter'),
4240+
(0x21, 'Percent'),
4241+
(0x22, 'Moles per Meter Cubed'),
4242+
(0x23, 'RPM'),
4243+
(0x24, 'Bytes per Second')],
4244+
'range': [(0, 0x24), (0x80, 0xff)]},
42294245
{'name': 'prefix', 'type': 'uint8',
42304246
'labels': [(0x00, 'None'),
42314247
(0x01, 'Deci'),
@@ -4409,6 +4425,26 @@
44094425
'set_sub_device_range': 1,
44104426
'value': 51},
44114427

4428+
# QUEUED_MESSAGE_SENSOR_SUBSCRIBE
4429+
{'get_request': {'items': []},
4430+
'get_response': {'items': [{'type': 'group',
4431+
'name': 'sensors',
4432+
'items': [{'name': 'sensor_number',
4433+
'type': 'uint8'}],
4434+
}]},
4435+
'get_sub_device_range': 2,
4436+
'name': 'QUEUED_MESSAGE_SENSOR_SUBSCRIBE',
4437+
'set_request': {'items': [{'name': 'action', 'type': 'uint8', 'labels': [
4438+
(0, 'Remove'), (1, 'Add')]},
4439+
{'type': 'group',
4440+
'name': 'sensors',
4441+
'items': [{'name': 'sensor_number',
4442+
'type': 'uint8'}]}
4443+
]},
4444+
'set_response': {'items': []},
4445+
'set_sub_device_range': 1,
4446+
'value': 52},
4447+
44124448
# SENSOR_VALUE
44134449
{'get_request': {'items': [{'name': 'sensor_number', 'type': 'uint8',
44144450
'range': [(0, 0xfe)],
@@ -4500,6 +4536,28 @@
45004536
'set_sub_device_range': 1,
45014537
'value': 4145},
45024538

4539+
# SELFTEST_ENHANCED
4540+
{'get_request': {'items': []},
4541+
'get_response': {'items': [{'name': 'result_code_pid', 'type': 'uint16',
4542+
'labels': [(0, 'Not supported')]},
4543+
{'type': 'group', 'name': 'self_tests',
4544+
'items': [{'name': 'test_number', 'type': 'uint8',
4545+
'labels': [(0xff, 'All')]},
4546+
{'name': 'test_status', 'type': 'uint8',
4547+
'labels': [(0x00, 'Status not supported'),
4548+
(0x01, 'Not run since last power cycle'),
4549+
(0x02, 'Aborted/reset'),
4550+
(0x03, 'Active/running'),
4551+
(0x04, 'Complete - Pass'),
4552+
(0x05, 'Complete - Fail'),
4553+
(0x06, 'Complete - No analysis'),
4554+
(0x07, 'Complete - Result code available'),
4555+
(0xff, 'Other - Manufacturer specific')
4556+
]}]}]},
4557+
'get_sub_device_range': 2,
4558+
'name': 'SELFTEST_ENHANCED',
4559+
'value': 4130},
4560+
45034561
# DMX_PERSONALITY_DESCRIPTION
45044562
{'get_request': {'items': [{'name': 'personality', 'type': 'uint8', 'range': [
45054563
(1, 0xff)]
@@ -4571,6 +4629,12 @@
45714629
(0x0207, 'Additive Color Mixer - Blue'),
45724630
(0x0208, 'Color Temperature Correction'),
45734631
(0x0209, 'Color Scroll'),
4632+
(0x020a, 'Additive Color Mixer - Lime'),
4633+
(0x020b, 'Additive Color Mixer - Indigo'),
4634+
(0x020c, 'Additive Color Mixer - Cyan'),
4635+
(0x020d, 'Additive Color Mixer - Deep Red'),
4636+
(0x020e, 'Additive Color Mixer - Deep Blue'),
4637+
(0x020f, 'Additive Color Mixer - Natural White'),
45744638
(0x0210, 'Color Semaphore'),
45754639
(0x0211, 'Additive Color Mixer - Amber'),
45764640
(0x0212, 'Additive Color Mixer - White'),
@@ -4579,6 +4643,10 @@
45794643
(0x0215, 'Subtractive Color Mixer - UV'),
45804644
(0x0216, 'Hue'),
45814645
(0x0217, 'Saturation'),
4646+
(0x0218, 'Additive Color Mixer - UV'),
4647+
(0x0219, 'CIE X Color Coordinate'),
4648+
(0x021a, 'CIE Y Color Coordinate'),
4649+
(0x021b, 'CCT Magenta-Green Adjustment'),
45824650
(0x0301, 'Static gobo wheel'),
45834651
(0x0302, 'Rotating gobo wheel'),
45844652
(0x0303, 'Prism wheel'),
@@ -4624,14 +4692,24 @@
46244692
{'name': 'data_type', 'type': 'uint8',
46254693
'labels': [(0x00, 'Not defined'),
46264694
(0x01, 'Bit field'),
4627-
(0x02, 'ASCII'),
4695+
(0x02, 'String'),
46284696
(0x03, 'uint8'),
46294697
(0x04, 'int8'),
46304698
(0x05, 'uint16'),
46314699
(0x06, 'int16'),
46324700
(0x07, 'uint32'),
4633-
(0x08, 'int32')],
4634-
'range': [(0x00, 0x08), (0x80, 0xdf)]},
4701+
(0x08, 'int32'),
4702+
(0x09, 'uint64'),
4703+
(0x0a, 'int64'),
4704+
(0x0b, 'Group'),
4705+
(0x0c, 'UID'),
4706+
(0x0d, 'Boolean'),
4707+
(0x0e, 'URL'),
4708+
(0x0f, 'MAC'),
4709+
(0x10, 'IPv4'),
4710+
(0x11, 'IPv6'),
4711+
(0x12, 'Enumeration')],
4712+
'range': [(0x00, 0x12), (0x80, 0xdf)]},
46354713
{'name': 'command_class', 'type': 'uint8',
46364714
'labels': [(1, 'Get'), (2, 'Set'), (3, 'Get and Set')]},
46374715
{'name': 'type', 'type': 'uint8'},
@@ -4664,8 +4742,16 @@
46644742
(0x19, 'Lumens'),
46654743
(0x1a, 'Lux'),
46664744
(0x1b, 'Ire'),
4667-
(0x1c, 'Bytes')],
4668-
'range': [(0, 0x1c), (0x80, 0xff)]},
4745+
(0x1c, 'Bytes'),
4746+
(0x1d, 'Decibel'),
4747+
(0x1e, 'Decibel Volt'),
4748+
(0x1f, 'Decibel Watt'),
4749+
(0x20, 'Decibel Meter'),
4750+
(0x21, 'Percent'),
4751+
(0x22, 'Moles per Meter Cubed'),
4752+
(0x23, 'RPM'),
4753+
(0x24, 'Bytes per Second')],
4754+
'range': [(0, 0x24), (0x80, 0xff)]},
46694755
{'name': 'prefix', 'type': 'uint8',
46704756
'labels': [(0x00, 'None'),
46714757
(0x01, 'Deci'),
@@ -4699,6 +4785,102 @@
46994785
'name': 'PARAMETER_DESCRIPTION',
47004786
'value': 81},
47014787

4788+
# ENUM_LABEL
4789+
# TODO(Peter): There's currently no PID value defined for this in the released E1.20-2025 standard so we can't implement it!
4790+
# {'get_request': {'items': [{'name': 'pid', 'type': 'uint16'}, {'name': 'enumeration_index', 'type': 'uint32'}]},
4791+
# 'get_response': {'items': [{'name': 'pid', 'type': 'uint16'}, {'name': 'enumeration_index', 'type': 'uint32'},
4792+
# {'name': 'max_enumeration_index', 'type': 'uint32'},
4793+
# {'name': 'description',
4794+
# 'max_size': 32,
4795+
# 'type': 'string'}]},
4796+
# 'get_sub_device_range': 2,
4797+
# 'name': 'ENUM_LABEL',
4798+
# 'value': },
4799+
4800+
# SUPPORTED_PARAMETERS_ENHANCED
4801+
{'get_request': {'items': []},
4802+
'get_response': {'items': [{'name': 'params',
4803+
'type': 'group',
4804+
'items': [{'name': 'param_id', 'type': 'uint16'},
4805+
{'name': 'param_id_support', 'type': 'uint16'}],
4806+
}]
4807+
},
4808+
'get_sub_device_range': 2,
4809+
'name': 'SUPPORTED_PARAMETERS_ENHANCED',
4810+
'value': 85},
4811+
4812+
# CONTROLLER_FLAG_SUPPORT
4813+
{'get_request': {'items': []},
4814+
'get_response': {'items': [{'name': 'controller_flags', 'type': 'uint8'}]},
4815+
'get_sub_device_range': 2,
4816+
'name': 'CONTROLLER_FLAG_SUPPORT',
4817+
'value': 86},
4818+
4819+
# NACK_DESCRIPTION
4820+
{'get_request': {'items': [{'name': 'nack_reason_code', 'type': 'uint16'}]},
4821+
'get_response': {'items': [{'name': 'nack_reason_code', 'type': 'uint16'},
4822+
{'name': 'description',
4823+
'max_size': 32,
4824+
'type': 'string'}]},
4825+
'get_sub_device_range': 2,
4826+
'name': 'NACK_DESCRIPTION',
4827+
'value': 87},
4828+
4829+
# PACKED_PID_SUB
4830+
{'get_request': {'items': [{'name': 'pid', 'type': 'uint16'},
4831+
{'name': 'index', 'type': 'uint16'},
4832+
{'name': 'first_device_requested', 'type': 'uint16'},
4833+
{'name': 'number_of_devices_requested', 'type': 'uint16'}]},
4834+
'get_response': {'items': [{'name': 'pid', 'type': 'uint16'},
4835+
{'name': 'index', 'type': 'uint16'},
4836+
{'name': 'packed_results',
4837+
'type': 'group',
4838+
'items': [{'name': 'device', 'type': 'uint16'},
4839+
{'name': 'pdl_size', 'type': 'uint8'},
4840+
{'name': 'param_data', 'type': 'group',
4841+
'items': [{'name': 'data', 'type': 'uint8'}]}]
4842+
}]},
4843+
'get_sub_device_range': 0,
4844+
'set_request': {'items': [{'name': 'pid', 'type': 'uint16'},
4845+
{'name': 'index', 'type': 'uint16'},
4846+
{'name': 'packed_request',
4847+
'type': 'group',
4848+
'items': [{'name': 'device', 'type': 'uint16'},
4849+
{'name': 'pdl_size', 'type': 'uint8'},
4850+
{'name': 'param_data', 'type': 'group',
4851+
'items': [{'name': 'data', 'type': 'uint8'}]}]
4852+
}]},
4853+
'set_response': {'items': []},
4854+
'set_sub_device_range': 0,
4855+
'name': 'PACKED_PID_SUB',
4856+
'value': 88},
4857+
4858+
# PACKED_PID_INDEX
4859+
{'get_request': {'items': [{'name': 'pid', 'type': 'uint16'},
4860+
{'name': 'first_item_requested', 'type': 'uint16'},
4861+
{'name': 'number_of_items_requested', 'type': 'uint16'}]},
4862+
'get_response': {'items': [{'name': 'pid', 'type': 'uint16'},
4863+
{'name': 'packed_results',
4864+
'type': 'group',
4865+
'items': [{'name': 'item', 'type': 'uint16'},
4866+
{'name': 'pdl_size', 'type': 'uint8'},
4867+
{'name': 'param_data', 'type': 'group',
4868+
'items': [{'name': 'data', 'type': 'uint8'}]}]
4869+
}]},
4870+
'get_sub_device_range': 2,
4871+
'set_request': {'items': [{'name': 'pid', 'type': 'uint16'},
4872+
{'name': 'packed_request',
4873+
'type': 'group',
4874+
'items': [{'name': 'item', 'type': 'uint16'},
4875+
{'name': 'pdl_size', 'type': 'uint8'},
4876+
{'name': 'param_data', 'type': 'group',
4877+
'items': [{'name': 'data', 'type': 'uint8'}]}]
4878+
}]},
4879+
'set_response': {'items': []},
4880+
'set_sub_device_range': 2,
4881+
'name': 'PACKED_PID_INDEX',
4882+
'value': 89},
4883+
47024884
# TILT_INVERT
47034885
{'get_request': {'items': []},
47044886
'get_response': {'items': [{'name': 'invert', 'type': 'bool'}]},
@@ -4853,7 +5035,7 @@
48535035
'set_sub_device_range': 1,
48545036
'value': 4112},
48555037

4856-
# PERFORM_SELF_TEST
5038+
# PERFORM_SELFTEST
48575039
{'get_request': {'items': []},
48585040
'get_response': {'items': [{'name': 'tests_active', 'type': 'bool'}]},
48595041
'get_sub_device_range': 2,
@@ -4961,6 +5143,8 @@
49615143
(0x0a00, 'GFI / RCD Device'),
49625144
(0x0a01, 'Battery'),
49635145
(0x0a02, 'Controllable Breaker'),
5146+
(0x0b00, 'Input Device'),
5147+
(0x0b01, 'Sensor Input'),
49645148
(0x7fff, 'Other Device')],
49655149
'range': [(0x0000, 0x0009),
49665150
(0x0100, 0x0108),
@@ -4973,6 +5157,7 @@
49735157
(0x0800, 0x0802),
49745158
(0x0900, 0x0902),
49755159
(0x0a00, 0x0a02),
5160+
(0x0b00, 0x0b01),
49765161
(0x7fff, 0x7fff),
49775162
(0x8000, 0xdfff)]}],
49785163
}]},
@@ -5424,15 +5609,15 @@
54245609
{'name': 'shipping_lock_state', 'type': 'uint8',
54255610
'labels': [(0, 'Unlocked'),
54265611
(1, 'Locked'),
5427-
(2, 'Partially Locked'),]
5612+
(2, 'Partially Locked')]
54285613
},
54295614
]},
54305615
'get_sub_device_range': 0,
54315616
'name': 'SHIPPING_LOCK',
54325617
'set_request': {'items': [
54335618
{'name': 'shipping_lock_state', 'type': 'uint8',
54345619
'labels': [(0, 'Unlocked'),
5435-
(1, 'Locked'),]
5620+
(1, 'Locked')]
54365621
},
54375622
]},
54385623
'set_response': {'items': []},
@@ -5471,9 +5656,7 @@
54715656
'name': 'loopback_data',
54725657
'max_size': 231,
54735658
'min_size': 0,
5474-
'items': [
5475-
{'name': 'data', 'type': 'uint8'}
5476-
]},
5659+
'items': [{'name': 'data', 'type': 'uint8'}]}
54775660
]},
54785661
'set_response': {'items': [
54795662
{'type': 'group', 'name': 'loopback_data', 'items': [

data/sensor_types.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,5 +51,13 @@
5151
0x1e: "Items",
5252
0x1f: "Humidity",
5353
0x20: "16 bit counter",
54+
0x21: "CPU load",
55+
0x22: "Bandwidth",
56+
0x23: "Concentration",
57+
0x24: "Sound pressure level",
58+
0x25: "Solid angle",
59+
0x26: "Log ratio",
60+
0x27: "Log ratio volts",
61+
0x28: "Log ratio watts",
5462
0x7f: "Other",
5563
}

0 commit comments

Comments
 (0)