codetheweb / homebridge-tuya-outlet

A plugin for Homebridge for Tuya-based outlets
15 stars 11 forks source link

Add uid param to configuration #6

Closed francisco-navarro closed 6 years ago

francisco-navarro commented 6 years ago

This field is needed to work with tuya api.

codetheweb commented 6 years ago

Thanks for your work; but the UID is not actually necessary. Does your device work without it?

francisco-navarro commented 6 years ago

My device cannot connect without this field (I don't know why 😓). And with uid, it works perfectly.

/node/node-v7.9.0/lib/node_modules/homebridge-tuya-outlet/node_modules/tuyapi/index.js:282
      client.write(buffer);
            ^

TypeError: Cannot read property 'write' of null
    at retryConnect.to (/node/node-v7.9.0/lib/node_modules/homebridge-tuya-outlet/node_modules/tuyapi/index.js:282:13)
    at Socket.handleError (/node/node-v7.9.0/lib/node_modules/homebridge-tuya-outlet/node_modules/net-retry-connect/index.js:21:13)
codetheweb commented 6 years ago

Strange. Can you please start Homebridge with DEBUG=* homebridge and post the output here?

francisco-navarro commented 6 years ago

I don't know, but right now, is work. Sometimes is unreachable. I'll try get the error with DEBUG=* homebridge.