Closed dudusandi closed 6 years ago
Hey @dudusandi ,
Currently the plugin doesn't support discovering of devices. But Yes we can discover connected MagicHome devices.
I will work on this implementation in my free time.
Expect this feature to be in upcoming v1.2.0
Maybe we can use MAC Address instead of IP to reference to lights.
Thanks
Using MAC would solve the problem, thank you very much.
Hey @dudusandi ,
I have updated the plugin. You can use MAC instead of IP. MAC should be in format of XXXXXXXXXXXX
.
Due to lack of time, i was not able to test it thoroughly.
Would love if you can test v1.2.0
version and provide your feedback/suggestions.
Thanks
Fixed in v1.2.0
Do note when using MAC instead of IP : The plugin discovers lights every 30 seconds and map their IP to their corresponding MAC.
It can take upto 60-120s to discover and map all lights. Once discovered and mapped, rediscovery will take place every 30s and update IPs of lights.
Hey @dudusandi , I have updated the plugin. You can use MAC instead of IP. MAC should be in format of
XXXXXXXXXXXX
.Due to lack of time, i was not able to test it thoroughly. Would love if you can test
v1.2.0
version and provide your feedback/suggestions.Thanks
I tested and it works perfectly with MAC, Thanks. Does this search every 30s use a lot of resources or not?
I noticed this problem in the log, but I do not understand what it is
@dudusandi I am glad that new version of the plugin fixed your issue.
The logs you are seeing is because of node-persist
plugin. We use this plugin to cache IP:MAC Address mapping in case homebridge restarts or breaks.
I will debug this issue and you can expect a fix in upcoming version. Meanwhile you can ignore the logs, since they are not a blocker and does not interfere with fundamental features of the plugin.
To answer your earlier question, yes the plugin rediscovers and refreshes IP addresses every 30 seconds. It doesnt take lot of resources, just open a socket, advertise broadcast and listens for connected lights. In future version, i can add a configuration key for custom pollingInterval.
@dudusandi
I have added a potential fix for Unhandled Rejection
logs occuring due to node-persist
.
Please try updating the plugin to 1.2.3
.
The issue should be fixed, and you should not see any error logs. Enjoy your Lights Thanks
@dudusandi
I have added a potential fix for
Unhandled Rejection
logs occuring due tonode-persist
. Please try updating the plugin to1.2.3
.The issue should be fixed, and you should not see any error logs. Enjoy your Lights Thanks
Hey @dudusandi
Looks like you need to install git
on your raspberry pi.
Nevermind, looks like node-persist
is causing lots of issues.
I will try to refactor the code and optimize this dependency.
Hey @dudusandi Looks like you need to install
git
on your raspberry pi. Nevermind, looks likenode-persist
is causing lots of issues. I will try to refactor the code and optimize this dependency.
If I can help with anything, just ask. I have git, but does't work
@dudusandi Thanks for your support.
You can test version 1.2.4
.
Hope it resolves your issue.
@dudusandi Thanks for your support. You can test version
1.2.4
. Hope it resolves your issue.
Testing here, apparently perfect.
Glad to hear that.
Any way to auto discovery or set by hostname ? My router doesn't have mode to keep same ip devices and I can't set static ip on controllers led.