The "new" Milight IBox and milight binding

milight
binding
Tags: #<Tag:0x00007f0147bc3de8> #<Tag:0x00007f0147bc37a8>

(Filippo Burgassi) #142

Hello,
I’m new to OpenHub and looking for hints to bind MiLight stuff to OH2.

I have an iBox wifi bridge (software version 1.0.08) with 3 Mi Light wifi 2.4 GHz controller connected to three white led strips.

Everything (night mode, on/off switching, brightness…) works like a charm from the Android app.

I’ve read this thread and I’m tryiing to use binding.milight_2.1.0.ref-rc1 to connect the IBox to OH2. Discovery from PaperUI doesn’t find the iBox. I configured it manually and i’m now able to interact properly with iBox integrated RGB light, but I don’t know how to control the strips.

Is it possible?

Thanks and keep up the good work!

Filippo


(David Graeff) #143

Hey @Filippo_Burgassi,

rc1 is quite old. Please use the newest version from the pull request on github:

Try the RGBWW and RGBW bulb type for the respective zone. For white strips it is probably RGBWW. If possible please report any misbehavior in github.

Cheers, David


(David C.) #144

Hi David,

First of all thank you and all the testers so much for all the hard work. These are impressive results for such a short period of time. I am probably doing something wrong myself but I wanted to check. I am testing the binding in the rc8 version. I am able to do the discovery and add the ibox to the list of things with no issue, however, once I add it, it keeps switching from ONLINE to OFFLINE all the time:

2017-02-22 07:54:45.774 [hingStatusInfoChangedEvent] - ‘milight:bridgeV6:F0FE6B1690E4’ changed from OFFLINE to ONLINE (CONFIGURATION_PENDING): SESSION_WAIT_FOR_BRIDGE_SID
2017-02-22 07:54:47.789 [hingStatusInfoChangedEvent] - ‘milight:bridgeV6:F0FE6B1690E4’ changed from ONLINE (CONFIGURATION_PENDING): SESSION_WAIT_FOR_BRIDGE_SID to OFFLINE
2017-02-22 07:54:47.930 [hingStatusInfoChangedEvent] - ‘milight:bridgeV6:F0FE6B1690E4’ changed from OFFLINE to ONLINE (CONFIGURATION_PENDING): SESSION_WAIT_FOR_BRIDGE_SID
2017-02-22 07:54:49.946 [hingStatusInfoChangedEvent] - ‘milight:bridgeV6:F0FE6B1690E4’ changed from ONLINE (CONFIGURATION_PENDING): SESSION_WAIT_FOR_BRIDGE_SID to OFFLINE
2017-02-22 07:54:50.065 [hingStatusInfoChangedEvent] - ‘milight:bridgeV6:F0FE6B1690E4’ changed from OFFLINE to ONLINE (CONFIGURATION_PENDING): SESSION_WAIT_FOR_BRIDGE_SID

Here is th config, I don’t know if it tells you anything…

Thanks a lot.


(Colin Frei) #145

I’m seeing the same behavior - the bridge switches from online to offline all the time.

Any bulbs I add also don’t seem to work, but I’m not sure if that’s related or me just setting them up incorrectly.
They’re showing up with a status of ‘UNINITIALIZED - HANDLER_INITIALIZING_ERROR’


(Duncan Pullen) #146

Hi @colin and @dcabanero,

I’ve experienced the same issues. I subsequently installed the PC software from milight and found the commands did not work on my iBox. The PC Software recognised the ibox, bud didn’t control any lights. I’m at a stall as a result.

PC Software from LimitlessLED… http://www.limitlessled.com/download/LimitlessLEDv6.zip

The Android App registered and functioned fine.

I’d be interested if those who have no control of their bulbs have the same problem. I’m thinking there may be some differences in firmware.

The milight binding did discover my ibox and control the iBox light.

Duncan


(David Graeff) #147

The initializing code is apparently screwed at the moment I’m sorry for that. As soon as I have some time I investigate that. If someone else wanna do this I’m happy for patches.

Cheers David


(m3ta) #148

I bought an iBox2 and got the same problems. Sometimes the connection is lost and beside that i cant control any of my bulbs / RGB Controller.


(michele leone) #149

Hello everyone, I’m new here on openHAB and I have a question from beginner. I am realizing my college thesis on openHAB and among objects that I’m using (along with Raspberry) there is the Mi-Light iBox 1 https://www.amazon.com/Milight-Controller-Wireless-Downight-Compatible/dp/B01M5JY7A9/ref=sr_1_2?ie=UTF8&qid=1487806872&sr=8-2&keywords=milight+ibox , but I’m not able to add it to the binding of Mi-Light. I saw that David Graeff has developed a new version, I downloaded it, but given my lack of experience I do not understand how to add it to openHAB. Does anyone know if there is some manual or some other discussions that explains how to insert updates bindings. Thank you.


(m3ta) #150

@m.leone you have to add this version to /usr/share/openhab2/addons


(Duncan Pullen) #151

Ok, so I feel pretty dumb. But can someone point me to a tutorial on how to download from the tree (I’ve found the tree and have downloaded the zip) and then turn that into a .jar to put in /addons?
Thanks Duncan


(John McMillan) #152

Hey Duncan,

Click this link, scroll to the very bottom and hit the link for the RC8 PDF. From there it is the same change PDF to JAR and drop in addons.

I’m back. Had to take some time away for work, was sick and couldn’t access the site for awhile…

Hey @David_Graeff - I have been using RC4 since it came out and everything has been working like a champ. I say that, I haven’t tried to control my iBox LED directly, but I have full control on my bulbs, which is what I wanted. Got it working with HomeKit and am a happy camper. What was wrong with RC4?

JMac


(michele leone) #153

Hello, after having had access to the Karaf console with the command

ssh openhab@localhost -p 8101

and the password: habopen, I tried to insert the command

sudo cp /tmp/org.openhab.binding.milight_2.1.0.ref-beta12.jar /usr/share/openhab2/addons/

, but the program asks me the password. I tried to insert: habopen, openhab, raspberry, pi, etc. but nothing happens, every time I get the message “Error executing command: login failed”. I can not understand what password want, until now I have never had this problem, could you help me? Thank you


(John McMillan) #154

If you are doing it locally from wherever openhab is installed (which it appears you are since you are logging into Karaf using @localhost), you do not need to be in Karaf to do this.

Just open terminal and retry your sudo cp command without ssh-ing into openhab.


(David Graeff) #155

It is essential that you remove the old add on version before moving in the new one. This has to be done while oh is running so that all references get removed by the framework.

@JMacIV: the repeat and delay configuration wasn’t working. That’s the reason for the new rc. But I have broken something apparently so the latest rc doesn’t really work unfortunately.


(John McMillan) #156

Ahh I gotcha. Sounds like I will continue to stick with the RC4 for now then. If there is anything I can do to help with testing the new RCs again, just let me know. Thanks for your continued hard work. You are the man!


(Nauttor) #157

Hi David,

I installed yesterday on my Pre-production system, a brand new openhab2 2.1.0 snapshot, your RC8 to test within my old V3 bridge and gu10 rgbww bulbs.

Apparently the bridge is detected by the paper UI but it never change to Online. It always appears to be offline, so I can´t complete the setup process to add things and items.

On the same OH2 when I try with the milight binding 2.0 from the repository at least it detect the bridge and I can add thinghs and items, with the limitations the old binding have.

I don´t know if you are aware of this bug or if it´s previously reported.

If I can help let me know what you need.


(Robp2175) #158

I just received my iBox and download the latest RC. The Bridge shows up in my Inbox, but when I go to add it I get this message.
2017-02-24 08:44:15.689 [ERROR] [home.core.thing.binding.ThingFactory] - Thing factory (class org.openhab.binding.milight.internal.MilightHandlerFactory) returned null on create thing when it reports to support the thing type (milight:bridgeV6).
2017-02-24 08:44:15.690 [WARN ] [g.discovery.internal.PersistentInbox] - Cannot create thing. No binding found that supports creating a thing of type milight:bridgeV6.

@David_Graeff - Thank you for all your hard work. It is truly appreciated.


(David C.) #159

Hi guys,

I reverted the last commit and built the package again. It works pretty nicely now. I will check to see if I can spot the issue in the very last version.

Thanks!


(michele leone) #160

Hi guys,
I’m still me, sorry but I have not managed yet to add the .jar file. After uninstalling the binding of Mi-Light from Paper UI and with the commands:

apt-get remove openhab-addon-binding-milight
apt-get remove openhab-addon-binding-milight1 - 1.9.0
apt-get remove openhab-addon-binding-milight - 2.0.0

I tried in every way to put the .jar file with the commands:

sudo cp /tmp/org.openhab.binding.milight_2.1.0.ref-beta12.jar /usr/share/openhab2/addons/
sudo mv /tmp/org.openhab.binding.milight_2.1.0.ref-beta12.jar /usr/share/openhab2/addons/
sudo chmod openhab.openhab /usr/share/openhab2/addons/org.openhab.binding.milight_2.1.0.ref-beta12.jar

but I got the following answers:

cp: cannot stat ' /tmp/org.openhab.binding.milight_2.1.0.ref-beta12.jar' : No such file or directory

mv: cannot stat ' /tmp/org.openhab.binding.milight_2.1.0.ref-beta12.jar' : No such file or directory

chmod: invalid mode: 'openhab.openhab'

As you have noticed I have very low level of knowledge of codes, but I urgently need to install and control the iBox to get on with my university thesis, I looked for the solution to a lot of sites but found nothing, so I hope someone can write the exact code, word for word.
I know that for you are very simple codes, but I hope you have patience with me.
Thank you and I really appreciate the work you are doing. :slight_smile:

Michele


(John McMillan) #161

Michele,

I am not the most knowledgable on Linux, but it appears to me that the file path of /tmp/org.openhab… does not exist. Are you sure that is where the file is contained?

If you can change directory to wherever the org.openhab… file is, then you can just use “sudo mv org.openhab(rest of filename) /usr/share/openhab2/addons/”

If you are in the directory where the file is located, you can just move the file from there without the full path of the item to be moved.

JMac