boneIO 0.3.0.dev4__tar.gz → 0.3.0.dev5__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (65) hide show
  1. {boneio-0.3.0.dev4/boneio.egg-info → boneio-0.3.0.dev5}/PKG-INFO +2 -2
  2. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/cover.py +2 -1
  3. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/helper/exceptions.py +4 -0
  4. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/manager.py +12 -0
  5. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/sensor/modbus/__init__.py +4 -2
  6. boneio-0.3.0.dev5/boneio/version.py +2 -0
  7. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5/boneio.egg-info}/PKG-INFO +2 -2
  8. boneio-0.3.0.dev4/boneio/version.py +0 -2
  9. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/LICENSE +0 -0
  10. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/MANIFEST.in +0 -0
  11. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/README.md +0 -0
  12. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/__init__.py +0 -0
  13. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/bonecli.py +0 -0
  14. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/const.py +0 -0
  15. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/example_config/__init__.py +0 -0
  16. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/example_config/adc.yaml +0 -0
  17. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/example_config/config.yaml +0 -0
  18. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/example_config/cover.yaml +0 -0
  19. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/example_config/input.yaml +0 -0
  20. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/example_config/output24x16A.yaml +0 -0
  21. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/example_config/output32x5A.yaml +0 -0
  22. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/fonts/danube__.ttf +0 -0
  23. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/helper/__init__.py +0 -0
  24. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/helper/config.py +0 -0
  25. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/helper/events.py +0 -0
  26. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/helper/gpio.py +0 -0
  27. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/helper/ha_discovery.py +0 -0
  28. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/helper/loader.py +0 -0
  29. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/helper/logger.py +0 -0
  30. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/helper/mqtt.py +0 -0
  31. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/helper/oled.py +0 -0
  32. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/helper/queue.py +0 -0
  33. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/helper/state_manager.py +0 -0
  34. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/helper/stats.py +0 -0
  35. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/helper/timeperiod.py +0 -0
  36. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/helper/yaml_util.py +0 -0
  37. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/input/__init__.py +0 -0
  38. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/input/gpio.py +0 -0
  39. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/modbus.py +0 -0
  40. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/mqtt_client.py +0 -0
  41. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/oled.py +0 -0
  42. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/relay/__init__.py +0 -0
  43. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/relay/basic.py +0 -0
  44. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/relay/gpio.py +0 -0
  45. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/relay/mcp.py +0 -0
  46. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/runner.py +0 -0
  47. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/schema/actions.yaml +0 -0
  48. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/schema/actions_sensor.yaml +0 -0
  49. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/schema/actions_switch.yaml +0 -0
  50. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/schema/schema.yaml +0 -0
  51. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/sensor/__init__.py +0 -0
  52. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/sensor/adc.py +0 -0
  53. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/sensor/gpio.py +0 -0
  54. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/sensor/modbus/sdm120.json +0 -0
  55. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/sensor/modbus/sdm630.json +0 -0
  56. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/sensor/modbus/sofar.json +0 -0
  57. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio/sensor/temp/__init__.py +0 -0
  58. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio.egg-info/SOURCES.txt +0 -0
  59. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio.egg-info/dependency_links.txt +0 -0
  60. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio.egg-info/entry_points.txt +0 -0
  61. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio.egg-info/requires.txt +0 -0
  62. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/boneio.egg-info/top_level.txt +0 -0
  63. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/requirements.txt +0 -0
  64. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/setup.cfg +0 -0
  65. {boneio-0.3.0.dev4 → boneio-0.3.0.dev5}/setup.py +0 -0
@@ -1,9 +1,9 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: boneio
3
- Version: 0.3.0.dev4
3
+ Version: 0.3.0.dev5
4
4
  Summary: Python App for BoneIO
5
5
  Home-page: https://github.com/boneIO-eu/app_bbb
6
- Download-URL: https://github.com/boneIO-eu/app_bbb/archive/0.3.0.dev4.zip
6
+ Download-URL: https://github.com/boneIO-eu/app_bbb/archive/0.3.0.dev5.zip
7
7
  License: GNU General Public License v3.0
8
8
  Platform: UNKNOWN
9
9
  Classifier: Programming Language :: Python
@@ -4,6 +4,7 @@ import logging
4
4
  from typing import Any, Callable
5
5
  from boneio.const import CLOSE, COVER, IDLE, OPEN, OPENING, CLOSING, CLOSED, STOP
6
6
  from boneio.helper.events import EventBus
7
+ from boneio.helper.exceptions import CoverRelayException
7
8
  from boneio.helper.mqtt import BasicMqtt
8
9
  from boneio.helper.timeperiod import TimePeriod
9
10
  from boneio.relay import MCPRelay
@@ -44,7 +45,7 @@ class Cover(BasicMqtt):
44
45
  def __init__(
45
46
  self,
46
47
  id: str,
47
- open_relay: Any,
48
+ open_relay: MCPRelay,
48
49
  close_relay: MCPRelay,
49
50
  state_save: Callable,
50
51
  open_time: TimePeriod,
@@ -15,3 +15,7 @@ class I2CError(BoneIOException):
15
15
 
16
16
  class ConfigurationException(BoneIOException):
17
17
  """Configuration yaml exception."""
18
+
19
+
20
+ class CoverRelayException(BoneIOException):
21
+ """Cover configuration exception."""
@@ -171,6 +171,18 @@ class Manager:
171
171
  _id = _config[ID].replace(" ", "")
172
172
  open_relay = self._output.get(_config.get("open_relay"))
173
173
  close_relay = self._output.get(_config.get("close_relay"))
174
+ if not open_relay:
175
+ _LOGGER.error(
176
+ "Can't configure cover %s. This relay doesn't exist.",
177
+ _config.get("open_relay"),
178
+ )
179
+ continue
180
+ if not close_relay:
181
+ _LOGGER.error(
182
+ "Can't configure cover %s. This relay doesn't exist.",
183
+ _config.get("close_relay"),
184
+ )
185
+ continue
174
186
  if open_relay.output_type != NONE or close_relay.output_type != NONE:
175
187
  _LOGGER.error(
176
188
  "Can't configure cover %s. %s",
@@ -22,6 +22,8 @@ from boneio.helper import BasicMqtt
22
22
  from boneio.helper.ha_discovery import modbus_sensor_availabilty_message
23
23
  from boneio.helper.timeperiod import TimePeriod
24
24
  from boneio.helper.config import ConfigHelper
25
+ from boneio.modbus import Modbus
26
+
25
27
 
26
28
  _LOGGER = logging.getLogger(__name__)
27
29
 
@@ -92,7 +94,7 @@ class ModbusSensor(BasicMqtt):
92
94
 
93
95
  def __init__(
94
96
  self,
95
- modbus,
97
+ modbus: Modbus,
96
98
  address: str,
97
99
  model: str,
98
100
  config_helper: ConfigHelper,
@@ -104,7 +106,7 @@ class ModbusSensor(BasicMqtt):
104
106
  super().__init__(
105
107
  id=id or address,
106
108
  topic_type=SENSOR,
107
- topic_prefix=self._config_helper.topic_prefix,
109
+ topic_prefix=config_helper.topic_prefix,
108
110
  **kwargs,
109
111
  )
110
112
  self._config_helper = config_helper
@@ -0,0 +1,2 @@
1
+ # flake8: noqa
2
+ __version__ = "0.3.0.dev5"
@@ -1,9 +1,9 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: boneio
3
- Version: 0.3.0.dev4
3
+ Version: 0.3.0.dev5
4
4
  Summary: Python App for BoneIO
5
5
  Home-page: https://github.com/boneIO-eu/app_bbb
6
- Download-URL: https://github.com/boneIO-eu/app_bbb/archive/0.3.0.dev4.zip
6
+ Download-URL: https://github.com/boneIO-eu/app_bbb/archive/0.3.0.dev5.zip
7
7
  License: GNU General Public License v3.0
8
8
  Platform: UNKNOWN
9
9
  Classifier: Programming Language :: Python
@@ -1,2 +0,0 @@
1
- # flake8: noqa
2
- __version__ = "0.3.0.dev4"
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes