Latest Threat Research:SANDWORM_MODE: Shai-Hulud-Style npm Worm Hijacks CI Workflows and Poisons AI Toolchains.Details
Socket
Book a DemoSign in
Socket

enocean

Package Overview
Dependencies
Maintainers
2
Versions
18
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

enocean - pypi Package Compare versions

Comparing version
0.50.1
to
0.60.0
+1
-1
enocean.egg-info/PKG-INFO
Metadata-Version: 1.0
Name: enocean
Version: 0.50.1
Version: 0.60.0
Summary: EnOcean serial protocol implementation

@@ -5,0 +5,0 @@ Home-page: https://github.com/kipe/enocean

@@ -100,3 +100,3 @@ # -*- encoding: utf-8 -*-

# We're only interested in responses to the request in question.
if packet.packet_type == PACKET.RESPONSE and packet.response == RETURN_CODE.OK and len(packet.response_data) == 4:
if packet.packet_type == PACKET.RESPONSE and packet.response == RETURN_CODE.OK and len(packet.response_data) == 4: # noqa: E501
# Base ID is set in the response data.

@@ -103,0 +103,0 @@ self._base_id = packet.response_data

@@ -6,2 +6,3 @@ # -*- encoding: utf-8 -*-

def init_logging(level=logging.DEBUG, log_to_file=False, logsize=1024, logcount=5):

@@ -8,0 +9,0 @@ formatter = logging.Formatter('%(asctime)s - %(name)s - %(levelname)s - %(message)s')

@@ -10,3 +10,4 @@ # -*- encoding: utf-8 -*-

import enocean.utils
from enocean.protocol.constants import RORG
# Left as a helper
from enocean.protocol.constants import RORG # noqa: F401

@@ -21,8 +22,9 @@

eep_path = os.path.join(os.path.dirname(os.path.realpath(__file__)), 'EEP.xml')
try:
if version_info[0] > 2:
with open(os.path.join(os.path.dirname(os.path.realpath(__file__)), 'EEP.xml'), 'r', encoding='UTF-8') as xml_file:
with open(eep_path, 'r', encoding='UTF-8') as xml_file:
self.soup = BeautifulSoup(xml_file.read(), "html.parser")
else:
with open(os.path.join(os.path.dirname(os.path.realpath(__file__)), 'EEP.xml'), 'r') as xml_file:
with open(eep_path, 'r') as xml_file:
self.soup = BeautifulSoup(xml_file.read(), "html.parser")

@@ -29,0 +31,0 @@ self.init_ok = True

@@ -10,2 +10,3 @@ <?xml version="1.0" encoding="utf-8"?>

<item description="Pressed" value="1" />
</enum>
</data>

@@ -15,2 +16,28 @@ </profile>

<profiles func="0x02" description="Rocker Switch, 2 Rocker">
<profile type="0x01" description="Light and Blind Control - Application Style 1">
<data>
<enum description="Rocker 1st action" shortcut="R1" offset="0" size="3">
<item description="Button AI" value="0" />
<item description="Button AO" value="1" />
<item description="Button BI" value="2" />
<item description="Button BO" value="3" />
</enum>
<enum description="Energy bow" shortcut="EB" offset="3" size="1">
<item description="released" value="0" />
<item description="pressed" value="1" />
</enum>
<enum description="Rocker 2nd action" shortcut="R2" offset="4" size="3">
<item description="Button AI" value="0" />
<item description="Button AO" value="1" />
<item description="Button BI" value="2" />
<item description="Button BO" value="3" />
</enum>
<enum description="2nd action" shortcut="SA" offset="7" size="1">
<item description="No 2nd action" value="0" />
<item description="2nd action valid" value="1" />
</enum>
<status description="T21" shortcut="T21" offset="2" size="1" />
<status description="NU" shortcut="NU" offset="3" size="1" />
</data>
</profile>
<profile type="0x02" description="Light and Blind Control - Application Style 2">

@@ -55,2 +82,11 @@ <data>

</profile>
<profile type="0x02" description="Smoke Detector">
<data>
<enum description="Status of detection and battery" shortcut="SMO" offset="0" size="8">
<item description="Smoke Alarm OFF" value="0" />
<item description="Smoke Alarm ON" value="16" />
<item description="Energy LOW" value="48" />
</enum>
</data>
</profile>
</profiles>

@@ -466,3 +502,3 @@ <profiles func="0x10" description="Mechanical Handle">

</profile>
<profile type="0x03" description="Range -20°C to +60°C 10bit-measurement and 0% to 100%">
<profile type="0x03" description="Range -20°C to +60°C 10bit-measurement and 0% to 100%">
<data>

@@ -535,2 +571,40 @@ <value description="Rel. Humidity (linear)" shortcut="HUM" offset="0" size="8" unit="%">

</profile>
<profile type="0x02" description="Range 0lx to 1.020lx">
<data>
<value description="Supply voltage (linear)" shortcut="SVC" offset="0" size="8" unit="V">
<range>
<min>0</min>
<max>255</max>
</range>
<scale>
<min>0.000000</min>
<max>5.100000</max>
</scale>
</value>
<value description="Illumination 2 (linear)" shortcut="ILL2" offset="8" size="8" unit="lx">
<range>
<min>0</min>
<max>255</max>
</range>
<scale>
<min>0.000000</min>
<max>510.000000</max>
</scale>
</value>
<value description="Illumination 1 (linear)" shortcut="ILL1" offset="16" size="8" unit="lx">
<range>
<min>0</min>
<max>255</max>
</range>
<scale>
<min>0.000000</min>
<max>1020.000000</max>
</scale>
</value>
<enum description="Range select" shortcut="RS" offset="31" size="1">
<item description="Range acc. to DB_1 (ILL1)" value="0" />
<item description="Range acc. to DB_2 (ILL2)" value="1" />
</enum>
</data>
</profile>
</profiles>

@@ -601,5 +675,84 @@ <profiles func="0x07" description="Occupancy Sensor">

</profiles>
<profiles description="Room Operating Panel" func="0x10">
<profile description="Temperature Sensor and Set Point" type="0x03">
<profiles func="0x09" description="Gas Sensor">
<profile description="CO2 Sensor" type="0x04">
<data>
<value shortcut="HUM" description="Rel. Humidity (linear)" offset="0" size="8" unit="%">
<range>
<min>0</min>
<max>200</max>
</range>
<scale>
<min>0</min>
<max>100</max>
</scale>
</value>
<value shortcut="Conc" description="Concentration (linear)" offset="8" size="8" unit="ppm">
<range>
<min>0</min>
<max>255</max>
</range>
<scale>
<min>0</min>
<max>2550</max>
</scale>
</value>
<value shortcut="TMP" description="Temperature (linear)" offset="16" size="8" unit="°C">
<range>
<min>0</min>
<max>255</max>
</range>
<scale>
<min>0</min>
<max>51</max>
</scale>
</value>
</data>
</profile>
<profile description="VOC Sensor" type="0x05">
<data>
<value shortcut="Conc" description="VOC Concentration" offset="0" size="16" unit="ppb">
<range>
<min>0</min>
<max>65535</max>
</range>
<scale>
<min>0</min>
<max>65535</max>
</scale>
</value>
<enum shortcut="VOC_ID" description="VOC Identification" offset="16" size="8">
<item description="VOCT (total)" value="0" />
<item description="Formaldehyde" value="1" />
<item description="Benzene" value="2" />
<item description="Styrene" value="3" />
<item description="Toluene" value="4" />
<item description="Tetrachloroethylene" value="5" />
<item description="Xylene" value="6" />
<item description="n-Hexane" value="7" />
<item description="n-Octane" value="8" />
<item description="Cyclopentane" value="9" />
<item description="Methanol" value="10" />
<item description="Ethanol" value="11" />
<item description="1-Pentanol" value="12" />
<item description="Acetone" value="13" />
<item description="ethylene Oxide" value="14" />
<item description="Acetaldehyde ue" value="15" />
<item description="Acetic Acid" value="16" />
<item description="Propionice Acid" value="17" />
<item description="ValericAcid" value="18" />
<item description="ButyricAcid" value="19" />
<item description="Ammoniac" value="20" />
<item description="Hydrogen Sulfide" value="22" />
<item description="Dimethylsulfide" value="23" />
<item description="2-Butanol (butyl Alcohol)" value="24" />
<item description="2-Methylpropanol" value="25" />
<item description="Diethyl ether" value="26" />
<item description="ozone" value="255" />
</enum>
</data>
</profile>
</profiles>
<profiles func="0x10" description="Room Operating Panel">
<profile type="0x03" description="Temperature Sensor and Set Point">
<data>
<value shortcut="SP" description="Set Point (linear)" offset="8" size="8" unit="%">

@@ -756,4 +909,4 @@ <range>

</profiles>
<profiles description="Controller Status" func="0x11">
<profile description="Temperature Controller Output" type="0x02">
<profiles func="0x11" description="Controller Status">
<profile type="0x02" description="Temperature Controller Output">
<data>

@@ -816,2 +969,64 @@ <value shortcut="CVAR" description="Actual value of controller" offset="0" size="8" unit="%">

</profile>
<profile type="0x03" description="Blind Status">
<data>
<value shortcut="BSP" description="Blind/shutter position" offset="0" size="8" unit="%">
<range>
<min>0</min>
<max>100</max>
</range>
<scale>
<min>0</min>
<max>100</max>
</scale>
</value>
<enum shortcut="AS" description="Angle sign" offset="8" size="1">
<item description="Positive sign" value="0" />
<item description="Negative sign" value="1" />
</enum>
<value shortcut="AN" description="Angle in 2 degrees steps" offset="9" size="7" unit="degrees">
<range>
<min>0</min>
<max>90</max>
</range>
<scale>
<min>0</min>
<max>180</max>
</scale>
</value>
<enum shortcut="PVF" description="Position value flag" offset="16" size="1">
<item description="No position value available" value="0" />
<item description="Position value available" value="1" />
</enum>
<enum shortcut="AVF" description="Angle value flag" offset="17" size="1">
<item description="No Angle value available" value="0" />
<item description="Angle value available" value="1" />
</enum>
<enum shortcut="ES" description="Error state" offset="18" size="2">
<item description="No error present" value="0" />
<item description="End-positions are not configured" value="1" />
<item description="Internal failure" value="2" />
<item description="Not used" value="3" />
</enum>
<enum shortcut="EP" description="End position" offset="20" size="2">
<item description="No End-position available" value="0" />
<item description="No End-position reached" value="1" />
<item description="Blind fully open" value="2" />
<item description="Blind fully closed" value="3" />
</enum>
<enum shortcut="ST" description="Status" offset="22" size="2">
<item description="No status available" value="0" />
<item description="Blind is stopped" value="1" />
<item description="Blind opens" value="2" />
<item description="Blind closes" value="3" />
</enum>
<enum shortcut="SM" description="Service mode" offset="24" size="1">
<item description="Normal mode" value="0" />
<item description="Service mode activated" value="1" />
</enum>
<enum shortcut="MOTP" description="Mode of the position" offset="25" size="1">
<item description="Normal mode" value="0" />
<item description="Inverse ode" value="1" />
</enum>
</data>
</profile>
</profiles>

@@ -838,4 +1053,4 @@ <profiles func="0x14" description="Multi-Func Sensor">

</profiles>
<profiles description="HVAC Components" func="0x20">
<profile description="Battery Powered Actuator (BI-DIR)" type="0x01">
<profiles func="0x20" description="HVAC Components">
<profile type="0x01" description="Battery Powered Actuator (BI-DIR)">
<data direction="1">

@@ -896,3 +1111,3 @@ <value shortcut="CV" description="Current Value" offset="0" size="8" unit="%">

<data direction="2">
<value shortcut="SP" description="Valve Position" offset="0" size="8" unit="%">
<value shortcut="SP" description="Valve Position or Temperature Setpoint" offset="0" size="8" unit="%">
<range>

@@ -899,0 +1114,0 @@ <min>0</min>

@@ -51,3 +51,7 @@ # -*- encoding: utf-8 -*-

def __str__(self):
return '0x%02X %s %s %s' % (self.packet_type, [hex(o) for o in self.data], [hex(o) for o in self.optional], self.parsed)
return '0x%02X %s %s %s' % (
self.packet_type,
[hex(o) for o in self.data],
[hex(o) for o in self.optional],
self.parsed)

@@ -58,3 +62,4 @@ def __unicode__(self):

def __eq__(self, other):
return self.packet_type == other.packet_type and self.rorg == other.rorg and self.data == other.data and self.optional == other.optional
return self.packet_type == other.packet_type and self.rorg == other.rorg \
and self.data == other.data and self.optional == other.optional

@@ -66,3 +71,4 @@ @property

# Needs the redefinition of Packet.data -> Packet.message.
# Packet.data would then only have the actual, documented data-bytes. Packet.message would contain the whole message.
# Packet.data would then only have the actual, documented data-bytes.
# Packet.message would contain the whole message.
# See discussion in issue #14

@@ -306,3 +312,4 @@ return enocean.utils.to_bitarray(self.data[1:len(self.data) - 5], (len(self.data) - 6) * 8)

destination=None, sender=None, learn=False, **kwargs):
return Packet.create(PACKET.RADIO_ERP1, rorg, rorg_func, rorg_type, direction, command, destination, sender, learn, **kwargs)
return Packet.create(PACKET.RADIO_ERP1, rorg, rorg_func, rorg_type,
direction, command, destination, sender, learn, **kwargs)

@@ -346,3 +353,3 @@ @property

self.rorg_manufacturer = enocean.utils.from_bitarray(self._bit_data[DB2.BIT_2:DB0.BIT_7])
self.logger.debug('learn received, EEP detected, RORG: 0x%02X, FUNC: 0x%02X, TYPE: 0x%02X, Manufacturer: 0x%02X' % (self.rorg, self.rorg_func, self.rorg_type, self.rorg_manufacturer))
self.logger.debug('learn received, EEP detected, RORG: 0x%02X, FUNC: 0x%02X, TYPE: 0x%02X, Manufacturer: 0x%02X' % (self.rorg, self.rorg_func, self.rorg_type, self.rorg_manufacturer)) # noqa: E501

@@ -390,3 +397,3 @@ return super(RadioPacket, self).parse()

self.request_type = enocean.utils.from_bitarray(self._bit_data[DB6.BIT_5:DB6.BIT_3])
self.rorg_manufacturer = enocean.utils.from_bitarray(self._bit_data[DB3.BIT_2:DB2.BIT_7] + self._bit_data[DB4.BIT_7:DB3.BIT_7])
self.rorg_manufacturer = enocean.utils.from_bitarray(self._bit_data[DB3.BIT_2:DB2.BIT_7] + self._bit_data[DB4.BIT_7:DB3.BIT_7]) # noqa: E501
self.channel = self.data[2]

@@ -393,0 +400,0 @@ self.rorg_type = self.data[5]

Metadata-Version: 1.0
Name: enocean
Version: 0.50.1
Version: 0.60.0
Summary: EnOcean serial protocol implementation

@@ -5,0 +5,0 @@ Home-page: https://github.com/kipe/enocean

@@ -9,3 +9,3 @@ #!/usr/bin/env python

name='enocean',
version='0.50.1',
version='0.60.0',
description='EnOcean serial protocol implementation',

@@ -12,0 +12,0 @@ author='Kimmo Huoman',