Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

infrared_ac is a supported device type, but homebridge is not recognizing it #489

Open
2 tasks done
Thewansingh opened this issue Aug 17, 2024 · 3 comments
Open
2 tasks done
Labels
bug Something isn't working

Comments

@Thewansingh
Copy link

Prerequisite

  • Yes, I've read the readme completely.

Cache

  • Yes, I've cleaned accessory cache and the issue still exists.

Version

v1.7.0-beta.54

Device Infomation JSON File

},
        {
            "name": "Tuya",
            "options": {
                "projectType": "2",
                "endpoint": "https://openapi.tuyain.com",
                "accessId": "my access id",
                "accessKey": "my access key",
                "countryCode": 91,
                "username": "my email",
                "password": "my password",
                "appSchema": "smartlife",
                "deviceOverrides": [
                    {
                        "id": "d740f23d7c8822d0b1czqs",
                        "category": "infrared_ac"
                    },
                    {
                        "id": "d725509fc070a18c8bx0mn",
                        "category": "infrared_ac"
                    },
                    {
                        "id": "d78ddd2317b4ba7219xjgz",
                        "category": "hidden"
                    }
                ],
                "debug": false
            },
            "platform": "TuyaPlatform"
        }

Device Control Mode

None

Logs

[8/17/2024, 2:01:28 PM] [Tuya] [TuyaDeviceManager] Get device specification failed. devId = d78ddd2317b4ba7219xjgz, code = 2009, msg = not support this device
[8/17/2024, 2:01:28 PM] [Tuya] Fetching scene list.
[8/17/2024, 2:01:28 PM] [Tuya] Override 'Right AC' category from 'infrared_ac' to 'infrared_ac'
[8/17/2024, 2:01:28 PM] [Tuya] Override 'Left AC' category from 'infrared_ac' to 'infrared_ac'
[8/17/2024, 2:01:28 PM] [Tuya] Override 'Left IR' category from 'wnykq' to 'hidden'
[8/17/2024, 2:01:29 PM] [Tuya] Got 4 device(s) and scene(s).
[8/17/2024, 2:01:29 PM] [Tuya] Device list saved at /var/lib/homebridge/persist/TuyaDeviceList.in1723827275635usko2.json
[8/17/2024, 2:01:29 PM] [Tuya] Restoring existing accessory from cache: Right Air Conditioner
[8/17/2024, 2:01:29 PM] [Tuya] Unsupported device: Right AC.
[8/17/2024, 2:01:29 PM] [Tuya] Restoring existing accessory from cache: Air
[8/17/2024, 2:01:29 PM] [Tuya] Unsupported device: Left AC.
[8/17/2024, 2:01:29 PM] [Tuya] Restoring existing accessory from cache: Right IR and Sensor
[8/17/2024, 2:01:29 PM] [Tuya] Hide Accessory: Left IR

Other Infomations

Usually in my old homebridge, it would recognize it as infrared_ac without override, but it doesnt now, so ive had to override it. Any one know whats the issue?

@Thewansingh Thewansingh added the bug Something isn't working label Aug 17, 2024
@fyodorvi
Copy link

fyodorvi commented Sep 8, 2024

I noticed that if you add IR devices while Homebridge is running it messes up with Tuya Platform cached devices (I think it might have to do something with how it gets IR devices only on startup).

Try this:

  1. remove IR hub entirely from your app account (important: use option to wipe the data otherwise device ID won't be reset).
  2. power off your home bridge - so it doesn't get new device through MQTT
  3. add your IR hub back, setup IR remotes
  4. power back homebridge, Tuya Platform should get IR devices and cache them

There's probably an easier way to clean device cache, but that fixed it for me.

@fyodorvi
Copy link

fyodorvi commented Sep 10, 2024

I did a bit more testing with another IR hub I had cached - tried removing it from cache JSON file and re-adding AC device while homebridge was offline and all... Nothing worked until I actually removed and wiped the IR hub entirely from Tuya and re-added it back. I suspect it might be something on the Tuya side, I enabled IR Service after I added the hub, maybe that's the issue.

Either way, different brand of IR hub, different AC controller, still same way to solve as I posted above - remove it completely from Tuya, power off homebridge (just in case), add the hub back, add IR devices, power homebridge back one.

@fyodorvi
Copy link

Alright after spending some extra debugging time I'm pretty sure I figured it out: my problem was setting the IR hub category as hidden to hide it from Homebridge, no need to remove and wipe it and get a new id for it. Getting new id was helpful because it removed my category preset. Seems that you have to live with unsupported hub accessory to have it working.

In other words, the solution:
To get your IR hub working make sure you don't override its category in deviceOverrides

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants