ualex73 / slide

Slide Component for Home Assistant
Apache License 2.0
25 stars 8 forks source link

Slide integration fails #18

Open iAmRenzo opened 2 months ago

iAmRenzo commented 2 months ago

I tried to add one of my slides, with:

cover:
  - platform: slide
    host: 192.168.1.69
    password: ****
    api_version: 1

I've checked the ip-addres. I've tried firmware version 1 and 2. Entered the code on de slide as password Slide is in local mode. Slide works via HomeKit, which already was connected.

It doesn't show up.

ualex73 commented 2 months ago

What does the logging say?

iAmRenzo commented 2 months ago

What does the logging say?

When using version v2: nothing, but it also doesn't show up on my integrations. When using version v1:

This error originated from a custom integration.

Logger: goslideapi.goslideapi
Source: custom_components/slide/cover.py:111
integration: Slide
First occurred: 14:00:30 (1 occurrences)
Last logged: 14:00:30

Failed request with Local API v1. Received HTTPCode=200, expected HTTPCode=401. Maybe try switching to api version 2?

I own tree Slides. I do not know exactly which Slide has which IP-address and what 'code'. I've tried one Slide (with the correct code) for each of the three known IP-adresses. I loaded the other two with version 2 API with the other IP-address each time.

cover:
  - platform: slide
    host: 192.168.1.200
    password: ********
    api_version: 1
  - platform: slide
    host: 192.168.1.69
    password: x
    api_version: 2
  - platform: slide
    host: 192.168.1.107
    password: x
    api_version: 2
ualex73 commented 2 months ago

Can you configure your logging as follows, but keep all of them on "api_version: 2":

logs: goslideapi: debug homeassistant.components.slide: debug custom_components.slide: debug

And then supply the logging? We need to see what requests goes there and comes back.

ualex73 commented 2 months ago

To test if it works, you can do as follows (replace the IP with yours): curl -X GET http://192.168.1.1/rpc/Slide.GetInfo

Output should look like: {"slide_id": "slide_840D8EA0C8F9", "mac": "840D8Ea0C8F9", "board_rev": 1, "device_name": "Slide", "zone_name": "", "curtain_type": 0, "calib_time": 35613, "pos": 0.02, "touch_go": true}

iAmRenzo commented 1 month ago

They do work after all! I was waiting to see the Slide integration pop-up in my Integrations view (but they don't). By chance I was browsing the original-states dashboard to look up something and there I saw them: three slides.

Is there a reason the integration doesn't show up?

ualex73 commented 1 month ago

Correct, it does not show up in the integration list ... but you see the cover entities in the list.

iAmRenzo commented 1 month ago

Correct, it does not show up in the integration list ... but you see the cover entities in the list.

Did not know that! Why is this? I'm curious. Because I renamed my entities with a name, but it made copies and the ones with the ip-address are 'unreachable'. Also there is no options. Like swapping state 0 and 100.

ualex73 commented 1 month ago

The Slide needs to be configured via yaml, so it does not show up in the integration list (only the ones you can configure via GUI).

If you change the name in the yaml, it is seen as a different device. If you change it in the GUI, possible you need to refresh?

iAmRenzo commented 1 month ago

Check! Thanks! There are no more configurations like swapping the 0% and 100%?

ualex73 commented 1 month ago

you can try "invert_position" it is documented in the README.