soma-ctrl icon indicating copy to clipboard operation
soma-ctrl copied to clipboard

trying to make this work for HomeBridge...

Open thncode opened this issue 6 years ago • 3 comments
trafficstars

Hi! I do hope you can help me with trying to get this working as a homebridge plugin, although my knowledge about JS is a bit limited. I wrote a test module like bildschirmfoto 2019-02-27 um 22 44 12 but got a result like bildschirmfoto 2019-02-27 um 22 40 20 any idea what I am missing here?

all the best Thomas

thncode avatar Feb 27 '19 21:02 thncode

Nice idea, I considered making this as a Homebridge plugin at first; ended up going with MQTT targeted specifically at home-assistant compatibility in the end, and I'm using Homebridge-homeassistant to get them added to HomeKit... home-assistant has native HomeKit integration now too, but I've yet to try it.

Anyway... Disconnecting and reconnecting super quickly like that seems to happen a lot if the signal strength is too low between the computer running this and the Soma device. Are they quite far apart? Possible interference? The other thing that's worth mentioning (though you may have already figured it out), is that you have to call connect() before any of the other actions will actually do anything.

andersonshatch avatar Mar 03 '19 20:03 andersonshatch

Out of interest, have you tried out running somactrl by itself? Does that successfully connect? I wonder if there's already a Homebridge plug-in that'll talk MQTT or HTTP allowing you to just wire up a plugin to somactrl (though I can see the benefit of the whole thing being in-process to Homebridge, though it'll probably be more work!)

andersonshatch avatar Mar 03 '19 20:03 andersonshatch

ok - now I am trying to use somactrl via http but after some minutes somactrl logs this: Bildschirmfoto 2019-03-23 um 15 00 33

thncode avatar Mar 24 '19 10:03 thncode