gmorell / libnexturn

Control library for Yifang SH201 Lightbulbs (Nexturn)
3 stars 1 forks source link

brighness and toggle on/off? #1

Open frostworx opened 9 years ago

frostworx commented 9 years ago

hello! some days ago I bought one of those bulps in the hope I can controll it with my linux homeautomation. fortunately I found your great project (looks like it is the only one of its kind) and controlling the colors works like a charm. In the hope that you did not abandon libnexturn yet, I'd like to ask you if you are also going to implement brightness control and a toggle on/off switch? Thank you very much for a great project! :)

gmorell commented 9 years ago

Hey there, I'm glad you've found this project useful.

There aren't exactly any bluetooth characteristics for those, as the control is rather raw. But if you're in the Hue mode, you can play with the Value (--value) and Saturation (--saturation) flags which currently are defaulting to full brightness of the LEDs in the bulb.

IIRC, setting the value lower will dim the bulb, and setting it to zero will turn it off entirely.

frostworx commented 9 years ago

hi there! thanks a lot for your quick reply! hmm, sounds promising. looks like I need to play a bit more with the options :) today I visited the shop where I bought the bulp and fortunately I was able to buy the last two remaining ones (15€ each). yay :)

gmorell commented 9 years ago

Yeah, worst case I'll take a pull / do it myself. The code is pretty simple. That's also a fantastic price for those :+1:

frostworx commented 9 years ago

yeah cool, just tried again: "-i 0 -v 255 -s 0" turns the bulp on in white and "-i 0 -v 0 -s 0" turns it off looks like everything I need is scriptable and I could even add the scripts f.e. into my ati-remotes which can be controlled perfectly with domoticz. I already have some milight bulps, which can be integrated into domoticz directly, but I like the idea of bulps without extra hubs in the network. thanks once again for your great work!