ARCHIVED FORUM -- March 2012 to February 2022READ ONLY FORUM
This is the second Archived Forum which was active between 1st March 2012 and 23rd February 2022
Hi,
I'm keen to start controlling my B&O system through a MLG using Domoticz running on a raspberry Pi. While the MLG is not currently supported natively by the Domoticz software (and I suspect never will due to its rarity), I'd like to control it via the ethernet interface. Is there anywhere I can find documentation as to how to go about this?
Regards to all
Hello,
3rd party hardware can be controlled via "custom strings". Customs strings enable controlling 3rd party hardware via HTML commands or any kind of command line interface.
If the "Domoticz" software is capable of being controlled in such way, it should be no problem to integrate it in the B&O configuration.
Best regards
Thanks. That could be useful for one direction, but I really wanted to have the Domoticz software control the MLGW. Is there a way to do this? Also is there any documentation that would help?
I don`t know the Domoticz system, but maybe this will help:
http://mlgw.bang-olufsen.dk/doc.html
I`m using a KNX system with visualisation software called Xhome. Works great with MLGW.
Stefan
Yes, thanks - that is what I'm looking for. It seems that you can send commands and get status via a telnet interface - I guess I need to use a TCP socket to communicate with it. Not sure all the commands there are documented, but with the logger hopefully I can work out what corresponds to what.
Forgot to update that I got his working. A python script interprets commands to and from the MLGW and the raspberry running Domoticz via JSON calls. Now I can assign commands to the Beo4 and control lights etc. Easy to add functionality too.
Just for reference - to connect try this code:
s = socket.socket(socket.AF_INET, socket.SOCK_STREAM) # Create a socket object
try:
host = socket.gethostbyname(hostname) # Connect to Mlgw.local
port = 9000 # Connect to MLGW Port
if debug:
print "Connecting to: ",host, port
except socket.gaierror,err:
print "cannot resolve hostname: ",hostname,err
s.connect((hostname, port))
Dear Stefan, I cannot access the documentation link - I get a 403 unauthorised access error in my browser. Is the technical documentation available elsewhere? Many thanks, Luke
Luke Spadavecchia : Dear Stefan, I cannot access the documentation link - I get a 403 unauthorised access error in my browser. Is the technical documentation available elsewhere? Many thanks, Luke
Luke, I'm seeing the same error although I've looked at that site plenty of times in the past without issues so I suspect it is a temporary issue. It might be worth contacting beocare to let them know there is an issue with the site.
Kind Regards,
Martin.
Thanks Martin, I emailed beocord today so hopefully the resource will be back up and running soon. Fingers crossed, although I note the MLGW is conspicuously absent from the customer support page (which includes the beovision mx series in the list of products). I do hope they haven't cut us loose!
Sorry, beocare not beocord. My trusty tape player was no help at all.
Luke Spadavecchia : Thanks Martin, I emailed beocord today so hopefully the resource will be back up and running soon. Fingers crossed, although I note the MLGW is conspicuously absent from the customer support page (which includes the beovision mx series in the list of products). I do hope they haven't cut us loose!
Good stuff. Thanks for doing that. I also hope it's not a deliberate move. Certainly they will need to restore access to the Open source software section as access to that it is a requirement of the GNU licence.
The page is now back up and running🎉
Is there a guide available or would it be possible to ask you to give a more step by step guide on how to setup the usage of scripts to have MLGW to control devices via Domoticz?
I don't have a guide, but here is the python script that I use. Not up to my usual level of documentation, but you should be able to pick up the key points of connecting to th mlgw socket and switching on and off a light etc. using the device's idx.
https://dl.dropboxusercontent.com/u/6824073/mlgw_client.py
Check out the domoticz wiki on json calls for explanation of the statements used to interact with the devices in domoticz
Good luck .
Excellent and Big Thanks! I'll start to play around with and provide feedback on how it goes here on my side.
An idea could be to start a specific thread for this topic which would be a good ref point for others to subsvribe to to follow it.
I suggest switching on the Debug and sniff options to see what is coming and going from the Mlgw. Also don't forget to set up the idx addresses for your domoticz controlled devices.
On a slightly different manner, I want to control the on/off controls of a LG tv via rs232 - I have the protocol, but am unsure how to do this (apart from hooking the serial cable to the TV and MLGW. I suspect it would be via macros, but the documentation is sparse.
Can an anyone point me in the right direction on how to send a byte sequence via rs232 from the MLGW?
Quick follow-up to check whether you've made any updates of the python script before making use of it as I never came around last time to play around with it?
No, nothing new - haven't changed it as it is working fine.
One thing to be careful of - from looking at the list of equipment that you provided, is that not all B&O kit can recognise or be recognised by the ML Gateway. Suggest you check this out before committing to automate the system.
Check out http://mlgw.bang-olufsen.dk/source/documents/ for info
Playmaker can NOT work with MLGW!Beovision 8 is supported. Depending on the version it could be that it must be updated. You'll find a MS-Word-Document in the firmware directory called MLGW-compatibility where all devices are listed.
Hi Frog,
Thinking about getting a MLGW with the idea of integrating with my homeseer home automation set-up (lights etc), and also be able to control my chromecast playback on A.Aux with Play, Next & Prev button presses on the beo4 over masterlink.. do you know if it's possible to capture these beo4 commands on the MLGW? Homeseer can control the chromecast via http posts, so I ideally would like to get the MLGW to fire the http url whenever the relevant buttons are pressed on the beo4 while on the A.Aux source. Can it be done?
Many thanks,
Rob.
I have tried to access my Beosound 5 on A.AUX (using the AUX_A key through MLGW) but with no success yet. The N.Music and N.Radio work fine.
My Beocentre 2 shows A.Aux, but doesn't activate the Beosound 5. I suspect that if you can switch on the A.Aux from your BEO4, then you'll get it working OK. I probably have a mismatch between the Beocentre 2 and Beosound 5 as to which A.Aux is accessed!
I use custom strings to connect to a program I wrote which receives the button press and sends a http post. I suspect using the homeseer plugin, you'd be able to do the same.
Thanks for the reply.
Yes i can access the correct aux source using the beo4 on my setup from any room, so with your MLGW and script can you capture any remote button key press on any source and trigger a custom string http post or is it limited to Light commands only?
regarding your issue, it sounds like the beocenter is taking precedence on the masterlink network being a source centre. You might be able to select beosound 5's aux using Link + A.Aux.
Yes, I only tried it to check what you wanted to do. I’ll just have to try something else.
As as far as the buttons are concerned over Mlgw ; yes, no problem in accessing all the Beo4 keys.
Much appreciated. It sounds like the MLGW might fit the bill then with the addition of scripts! You mentioned custom strings are send to your script which then makes the http post.. is the MLGW configured to trigger your script with all ML notifications, or do you need a custom string entered for each trigger/button press? Am I right in thinking the python script connects to the MLGW over telnet?
Homeseer can receive http get requests with query strings for triggering events or changing device status, or via more complex http posts with JSON. Because homeseer can trigger events with a simple URL I wonder whether I can simply call the URL in a custom string? I'd be grateful if I could download a copy of your python script to get a better understanding of how it's working if you are still happy to share it - the drop box link you posted a couple of years back's unfortunately broken!
Also does the MLGW include the more recent Philips Hue driver like the BLGW?
Many thanks.
Ah, now I understand - sorry. I can GENERATE key presses by the scripts which connect over port 9000 using sockets. The limitation in receiving keystrokes is - as you have said, limited to LIGHT commands (as far as I remember).
The way I handle what you want to do is via the receipt of the IR signal in a raspberry using LIRC. That can receive the IR and send out a http post.
See here for the IR receiving hardware (or use an IR Puck - which I did eventually)
https://archivedforum2.beoworld.org/forums/t/22757.aspx
Ah that's a shame!! I do have a spare IR puck and a pi so might try it out, only snag is I'd need one in each room!
Thanks for all your help.
I am trying to link my MLGW to my domoticz system (raspberry pi + rfxcom) in order to control my window blinds using my TV remote.
At the moment, the MLGW is working fine and interconnects a Lutron Grafik Eye unit to a BV7.
I guess I will have to use the MLGW custom strings to send commands to domoticz. Have any of you succeeded? If so, would you have any tips to help me? I have tried the links provided here but they no longer work.
Thanks in advance.
Regards,
Christian
Living room Avant 55 MK1 - BL5 x2 - BL6000 x2 - BS3200 - Core - NL/ML Converter - Thorens turntable Bedroom BV7-40 MK6 - BL4 x2 - BL8000 x2 - BL11 - MLGW - Lutron GFX - RaspberryPi DomoticzBathroom BL2000 on BLC1611 with Chromecast audioKitchen Core - BL3 x2Garden Core - Beolink Passive on 2x Bose Freespace 51
Hi Frog, would you be willing to re-share the script - the link above is no longer working.
Thanks!
Luke
here’s an updated link
https://rapidgator.net/file/f97262f9dfabca44aae57c59c829ca1d/mlgw_client.py.html
Many thanks for sharing!