steve228uk / homebridge-magichome

A Homebridge plugin for Magic Wifi devices
MIT License
82 stars 47 forks source link

Error: Unable to parse color from string: rgb(192,168,0,73,238,210,54) #47

Open stefantitu opened 6 years ago

stefantitu commented 6 years ago

Hello,

I am getting this error while I run homebridge and homebridge closes.

/usr/local/lib/node_modules/homebridge-magichome2/node_modules/color/index.js:53 throw new Error('Unable to parse color from string: ' + obj); ^

Error: Unable to parse color from string: rgb(192,168,0,73,238,210,54) at new Color (/usr/local/lib/node_modules/homebridge-magichome2/node_modules/color/index.js:53:10) at Color (/usr/local/lib/node_modules/homebridge-magichome2/node_modules/color/index.js:28:10) at /usr/local/lib/node_modules/homebridge-magichome2/index.js:93:30 at ChildProcess.exithandler (child_process.js:267:7) at emitTwo (events.js:126:13) at ChildProcess.emit (events.js:214:7) at maybeClose (internal/child_process.js:925:16) at Socket.stream.socket.on (internal/child_process.js:346:11) at emitOne (events.js:116:13) at Socket.emit (events.js:211:7) at Pipe._handle.close [as _onclose] (net.js:557:12)

My config file looks like this:

{ "accessory": "MagicHome", "name": "TV Lights", "ip": "192.168.0.73", "setup": "RGBW", "purewhite": false }

I am using this led controller: 200735665_2_1000x700_amazon-alexa-amazon-echo-smart-home-wifi-led-controller-telecomanda-fotografii

What could be the problem? I tried also as setup: RGB, RGBW, RGBWW and none of them works.

hornerr commented 6 years ago

I'm having the same exact issue... if anyone can help please do! Btw, in the ''ip'' section am I supposed to type in the IP of the LED-controller? Because that's what I have been doing.

stefantitu commented 6 years ago

Yes, there should be the IP of the led controller.

toshibochan commented 6 years ago

Make sure the IP address on your controller never change in your router.

toshibochan commented 6 years ago

If have RGB controller setup as RGBW and purewhite to false, if have RGBW controller setup as RGBW and purewhite to true.

stefantitu commented 6 years ago

I’ve tried all the possible combinations: RGB - pure white false/true; RGBW - pure white false/true; RGBWW - pure white false/true; also the IP of the controller is fixed. I tried also to reset the router. The controller works very well from Magic Home Pro app.

hornerr commented 6 years ago

Do you have homebridge-magichome2 installed? I got mine working by deleting homebridge-magichome2 and installing only homebridge-magichome. Here is my config.json: `{ "bridge": { "name": "Homebridge", "username": "DC:14:3D:F9:CE:19", "port": 51801, "pin": "031-57-192" },

"description": "An example Homebridge config for MagicHome.",

"accessories": [
   {
       "accessory": "MagicHome",
       "name": "Taulu 1",
       "ip": "192.168.1.101",
       "setup": "RGBW",
       "purewhite": false
   },

   {
       "accessory": "MagicHome",
       "name": "Taulu 2",
       "ip": "192.168.1.106",
       "setup": "RGBW",
       "purewhite": false
   },

   {
       "accessory": "MagicHome",
       "name": "Olohuone katto",
       "ip": "192.168.1.115",
       "setup": "RGBW",
       "purewhite": false
   }
]

} `

stefantitu commented 6 years ago

Yes, I have magichome2 installed. I’ll try to uninstall magichome2 and install magichome.

stefantitu commented 6 years ago

Finally, after I removed magichome2 and install magichome, I managed to make it work. Setup: RGBW, pure white: false.