ics_2000_python 0.1.0__tar.gz → 0.1.1__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 (23) hide show
  1. ics_2000_python-0.1.1/PKG-INFO +30 -0
  2. ics_2000_python-0.1.1/README.md +14 -0
  3. {ics_2000_python-0.1.0 → ics_2000_python-0.1.1}/ics_2000/hub.py +2 -2
  4. {ics_2000_python-0.1.0 → ics_2000_python-0.1.1}/pyproject.toml +3 -1
  5. ics_2000_python-0.1.0/PKG-INFO +0 -14
  6. ics_2000_python-0.1.0/README.md +0 -0
  7. {ics_2000_python-0.1.0 → ics_2000_python-0.1.1}/LICENSE +0 -0
  8. {ics_2000_python-0.1.0 → ics_2000_python-0.1.1}/ics_2000/__init__.py +0 -0
  9. {ics_2000_python-0.1.0 → ics_2000_python-0.1.1}/ics_2000/command.py +0 -0
  10. {ics_2000_python-0.1.0 → ics_2000_python-0.1.1}/ics_2000/config.py +0 -0
  11. {ics_2000_python-0.1.0 → ics_2000_python-0.1.1}/ics_2000/encryption.py +0 -0
  12. {ics_2000_python-0.1.0 → ics_2000_python-0.1.1}/ics_2000/entities/__init__.py +0 -0
  13. {ics_2000_python-0.1.0 → ics_2000_python-0.1.1}/ics_2000/entities/color_temperature_device.py +0 -0
  14. {ics_2000_python-0.1.0 → ics_2000_python-0.1.1}/ics_2000/entities/device.py +0 -0
  15. {ics_2000_python-0.1.0 → ics_2000_python-0.1.1}/ics_2000/entities/dim_device.py +0 -0
  16. {ics_2000_python-0.1.0 → ics_2000_python-0.1.1}/ics_2000/entities/entity.py +0 -0
  17. {ics_2000_python-0.1.0 → ics_2000_python-0.1.1}/ics_2000/entities/switch_device.py +0 -0
  18. {ics_2000_python-0.1.0 → ics_2000_python-0.1.1}/ics_2000/model/__init__.py +0 -0
  19. {ics_2000_python-0.1.0 → ics_2000_python-0.1.1}/ics_2000/model/device_config.py +0 -0
  20. {ics_2000_python-0.1.0 → ics_2000_python-0.1.1}/ics_2000/model/device_data.py +0 -0
  21. {ics_2000_python-0.1.0 → ics_2000_python-0.1.1}/ics_2000/model/entity_type.py +0 -0
  22. {ics_2000_python-0.1.0 → ics_2000_python-0.1.1}/ics_2000/model/smart_meter_data.py +0 -0
  23. {ics_2000_python-0.1.0 → ics_2000_python-0.1.1}/ics_2000/model/smart_meter_data_current.py +0 -0
@@ -0,0 +1,30 @@
1
+ Metadata-Version: 2.1
2
+ Name: ics_2000_python
3
+ Version: 0.1.1
4
+ Summary:
5
+ Home-page: https://github.com/zefanjajobse/ics_2000_python
6
+ Keywords: ics_2000,ics-2000,klikaanklikuit
7
+ Author: iiTzArcur
8
+ Author-email: zefanjaj@gmail.com
9
+ Requires-Python: >=3.12,<4.0
10
+ Classifier: Programming Language :: Python :: 3
11
+ Classifier: Programming Language :: Python :: 3.12
12
+ Requires-Dist: pycryptodome (>=3.21.0,<4.0.0)
13
+ Requires-Dist: requests (>=2.32.3,<3.0.0)
14
+ Project-URL: Repository, https://github.com/zefanjajobse/ics_2000_python
15
+ Description-Content-Type: text/markdown
16
+
17
+ # Python KlikAanKlikUit ICS-2000 library
18
+ This library gives methods to control a ICS-2000 from KlikAanKlikUit. It is made to add support for this device within Home assistant, which implementation is available in [this](https://github.com/zefanjajobse/ics-2000-home-assistant) repository.
19
+
20
+ ## Usage example:
21
+ ```py
22
+ hub = Hub("example@email.com", "password")
23
+ hub.login() # Authenticate
24
+ hub.get_devices() # request devices
25
+ for device in hub.devices:
26
+ if type(device) is SwitchDevice or type(device) is DimDevice:
27
+ print(device.name)
28
+ if device.get_on_status(): # returns bool
29
+ device.turn_off(False) # turn a device off
30
+ ```
@@ -0,0 +1,14 @@
1
+ # Python KlikAanKlikUit ICS-2000 library
2
+ This library gives methods to control a ICS-2000 from KlikAanKlikUit. It is made to add support for this device within Home assistant, which implementation is available in [this](https://github.com/zefanjajobse/ics-2000-home-assistant) repository.
3
+
4
+ ## Usage example:
5
+ ```py
6
+ hub = Hub("example@email.com", "password")
7
+ hub.login() # Authenticate
8
+ hub.get_devices() # request devices
9
+ for device in hub.devices:
10
+ if type(device) is SwitchDevice or type(device) is DimDevice:
11
+ print(device.name)
12
+ if device.get_on_status(): # returns bool
13
+ device.turn_off(False) # turn a device off
14
+ ```
@@ -24,7 +24,7 @@ class Hub:
24
24
  self.home_id: str | None = None
25
25
  self.email = email
26
26
  self.password = password
27
- self.local_address = ""
27
+ self.local_address: str | None = None
28
28
  self.device_statuses: dict[int, list[int]] = {}
29
29
  self.update_date = datetime.min
30
30
 
@@ -175,7 +175,7 @@ class Hub:
175
175
 
176
176
  def send_command_to_hub(self, command: Command, port):
177
177
  if self.local_address is None:
178
- raise ValueError("Local address is undefined")
178
+ raise ValueError("Local address is not set")
179
179
 
180
180
  if not isinstance(port, int):
181
181
  raise ValueError("Port needs to be an integer")
@@ -1,10 +1,12 @@
1
1
  [tool.poetry]
2
2
  name = "ics_2000_python"
3
- version = "0.1.0"
3
+ version = "0.1.1"
4
4
  description = ""
5
5
  authors = ["iiTzArcur <zefanjaj@gmail.com>"]
6
6
  readme = "README.md"
7
7
  packages = [{include = "ics_2000"}]
8
+ keywords = ["ics_2000", "ics-2000", "klikaanklikuit"]
9
+ repository = "https://github.com/zefanjajobse/ics_2000_python"
8
10
 
9
11
  [tool.poetry.dependencies]
10
12
  python = "^3.12"
@@ -1,14 +0,0 @@
1
- Metadata-Version: 2.1
2
- Name: ics_2000_python
3
- Version: 0.1.0
4
- Summary:
5
- Author: iiTzArcur
6
- Author-email: zefanjaj@gmail.com
7
- Requires-Python: >=3.12,<4.0
8
- Classifier: Programming Language :: Python :: 3
9
- Classifier: Programming Language :: Python :: 3.12
10
- Requires-Dist: pycryptodome (>=3.21.0,<4.0.0)
11
- Requires-Dist: requests (>=2.32.3,<3.0.0)
12
- Description-Content-Type: text/markdown
13
-
14
-
File without changes
File without changes