Closed MichaelVetter1979 closed 1 year ago
Bump! +1 for me
+1
+1 π
+1
+1
+1
+1
+1
+1
+1 Please
+1
+1
+1
+1
+1
+1
news?
+1
+1
+1
@MichaelVetter1979 are you printing the unmapped_state? If not:
import asyncio
from plugp100 import TapoApiClient, TapoApiClientConfig
async def main():
# create generic tapo api
config = TapoApiClientConfig("<ip>", "<email>", "<passwd>")
sw = TapoApiClient.from_config(config)
await sw.login()
state = await sw.get_state()
print(state.get_unmapped_state())
Ci sono novitΓ ?
+1 for supporting this device :)
+1 supporting P300 needed like air π
+1
+1
Hi guys, unfortunately, I don't have the p300 locally, so I can't test it. I've just released an experimental version of plugp100
(my library used by this integration). I need some one test it by following this:
pip install plugp100==3.2.0
import asyncio
from plugp100.api.power_strip_device import PowerStripDevice from plugp100.api.tapo_client import TapoClient
async def main():
username = '<tapo_email>'
password = '<tapo_password>'
client = TapoClient(username, password)
power_strip = PowerStripDevice(client, "<tapo_device_ip>")
print(await power_strip.login())
print(await power_strip.get_state_as_json())
print(await power_strip.get_children())
if name == "main": loop = asyncio.new_event_loop() loop.run_until_complete(main()) loop.run_until_complete(asyncio.sleep(0.1)) loop.close()
Hi Andrea, I want make this test but i'm not very expert. I have a raspberry with HA OS I've installed Pyscript on this I've created a file P300.py in the folder pyscript I've restart HA But i don't know how i can install plugp100 experimental because the pip command is unknown in my terminal and i don't know how i can launch the script P300.py when the install is ok.
i test with my windows computer
i use Edupython and i install the plugp100 3.2.0
when i run, i've this message :
Traceback (most recent call last):
File "C:\Users\steph\Documents\P300.py", line 4, in
I need certainly an other library ?
Hi Andrea, I fixed the problem and I was able to run the script with the experimental version of plugp100 I have this return (one for each plug in the powerstrip, the label "position" indicate the plug) : {'fw_ver': '1.0.7 Build 220715 Rel.200458', 'hw_ver': '1.0', 'type': 'SMART.TAPOPLUG', 'model': 'P300', 'mac': 'xxxxxxxxxxxxx', 'hw_id': 'xxxxxxxxxxxxxxxx', 'fw_id': 'xxxxxxxxxxxxxxxxxxxxxxx', 'oem_id': 'xxxxxxxxxxxxxxxxxxxxxxx', 'category': 'plug.powerstrip.sub-plug', 'status_follow_edge': True, 'device_id': 'xxxxxxxxxxxxxxxxxxxxxxx', 'original_device_id': 'xxxxxxxxxxxxxxxxxxxxxxx', 'overheat_status': 'normal', 'bind_count': 1, 'on_time': 0, 'slot_number': 3, 'position': 2, 'nickname': 'xxxxxxxxxxxxxxxxxxxxxxx', 'avatar': 'tape_lights', 'device_on': False, 'default_states': {'type': 'last_states'}, 'region': 'Europe/Paris', 'latitude': 48xxxxx, 'longitude': 75xxxx, 'has_set_location_info': True}
Will be available on 2.6.0 release, this is a preview:
Available on v2.6.0
Hi, Work fine, good job. Thank's for the time spare on this evolution.
Wonderful πππππ
Is your feature request related to a problem? Please describe. It would be great to mange the new Tapo P300 Power Strip with this home assistant integration. The Tapo-Integration can already acces the device, but only shows entity "overheated". The plugs or switches are nt shown.
Describe the solution you'd like It would be realy nice, if the Integration would detect all entities of these devices.
Describe alternatives you've considered The Device also supports Homekit, but I have trouble reconnectiong with Homekit after an accidental device reset, since Homekit is not unpaired!
Device Info The results of this script are as follows:
loop = asyncio.get_event_loop() {'device_id': '802204A73CFCA2C07C85D342BA968DD120977015', 'fw_ver': '1.0.7 Build 220715 Rel.200458', 'hw_ver': '1.0', 'type': 'SMART.TAPOPLUG', 'model': 'P300', 'mac': 'AC-15-A2-F2-11-DB', 'hw_id': '553C7AE42A568240BEA222D090B68EF4', 'fw_id': '00000000000000000000000000000000', 'oem_id': 'BCA35E01AEBC6BD91465057372DDAB74', 'ip': '192.168.178.21', 'time_diff': 60, 'ssid': 'aGVhdmVu', 'rssi': -22, 'signal_level': 3, 'latitude': 515464, 'longitude': 68618, 'lang': 'de_DE', 'avatar': '', 'region': 'Europe/Berlin', 'specs': '', 'nickname': '', 'has_set_location_info': True} Unclosed client session client_session: <aiohttp.client.ClientSession object at 0x000001F1992CF1C0> C:\Users\micha\main.py:22: RuntimeWarning: coroutine 'main' was never awaited main() RuntimeWarning: Enable tracemalloc to get the object allocation traceback