Vera - Smarter Home Control Forum

General => AV Control => Topic started by: ojovilla on December 02, 2016, 02:15:27 pm

Title: IP to Serial Control (HTD Lync 6)
Post by: ojovilla on December 02, 2016, 02:15:27 pm
Hello,

I have an HTD whole house audio lync 6 system , it uses a IP to serial gateway (GW-SL1 Smart Gateway) which has a mobile app that can control zones and also via a key pad.

I am trying to figure out how to send serial commands to this device using vera . I have done some research but having no luck . Any help would be great! . It should be quite similar to the Russound RNET

 Here is a link to the manual .

http://board.homeseer.com/attachment.php?attachmentid=51412&d=1453083555
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: jamestee on December 05, 2016, 02:28:44 pm
I would be interested to know this as well... I have a Lync12 system and am thinking of purchasing the gateway if Vera can control the HTD audio system....
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: ojovilla on December 09, 2016, 10:47:57 am
I would be interested to know this as well... I have a Lync12 system and am thinking of purchasing the gateway if Vera can control the HTD audio system....

Maybe we can put heads together and figure this out, I have tried a couple things but no luck.
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: JimWingard on December 11, 2016, 03:34:37 pm
I also have the HTD gateway with a lynx6. I think that the boys over at HTD would be glad to assist in this endevor, since it would have a chance increase their market share. I don't code, but I can help troubleshoot!
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: Newzwaver on December 11, 2016, 04:31:13 pm
Hi All,

I have one as well and the API, they advised me a few weeks ago that they are starting on a plugin.  Its all web based using http, so hopefully an easy intergerated solution, keep your fingers crossed.

T
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: racarter on December 12, 2016, 06:33:25 am
You could possibly do this using a Raspberry Pi running ser2net.
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: Newzwaver on December 12, 2016, 09:33:50 pm
Ok, very interest. How would that work?
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: ojovilla on December 13, 2016, 10:15:16 pm
Hi All,

I have one as well and the API, they advised me a few weeks ago that they are starting on a plugin.  Its all web based using http, so hopefully an easy intergerated solution, keep your fingers crossed.

T

That is good news, or at least I hope. I didn't think to contact them,hacking it seemed more of a fun quest  :)

The most ideal would simply be to have a plugin that performs the basic functions of turning off/on zones, as well as setting volume level such as a dimmer switch. Ultimately, I want this in turn to be integrated with Alexa /Home kit ( already running a raspberry pi bridge). Would be really nice to say "Alexa turn on zone 1" or "hey "siri, set zone 1 to 50". Just need to figure out what commands are sent by the valet home/Irule App.
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: Newzwaver on December 20, 2016, 10:36:31 pm
Happy to report I have all zones coming on and all zones turning off using the GW-SL1.  I have taken parts from SharpTV, MySensors and the Russsound plugins and should have it all up and running over the next few days.  Keep you posted.
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: ojovilla on December 21, 2016, 06:11:43 pm
Happy to report I have all zones coming on and all zones turning off using the GW-SL1.  I have taken parts from SharpTV, MySensors and the Russsound plugins and should have it all up and running over the next few days.  Keep you posted.

This is awesome! I cannot wait! Great job!
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: Newzwaver on December 22, 2016, 03:35:35 pm
Hi

Not sure how much more i will get completed before Xmas however i do have one zone almost fully controllable, power On, No off still working on it, mute working, volume up and volume down working and you can select one of the 6 sources.  Hope to fix the off part and move onto the next zone.  All on and All off is currently working.

Have a great xmas and keep your finger crossed.

Title: Re: IP to Serial Control (HTD Lync 6)
Post by: Newzwaver on January 07, 2017, 03:56:34 pm
Hi All,

I have a working plugin that works with the MC-66 and MCA-66.  It includes volume up/down, mute, on/off each zone and all zones as well as source selection and party mode.  I have also setup scenes in Alexa and she controls it was well.  If you are interested i can send them to you.

No worry because i am also completing the Lync6/12 and should have it in a few days.  It will start with the basic functions as above. 

Regards,
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: ojovilla on January 07, 2017, 05:03:21 pm
Happy new year to you! Thanks for work on this , how do I go about downloading and testing?

Hi All,

I have a working plugin that works with the MC-66 and MCA-66.  It includes volume up/down, mute, on/off each zone and all zones as well as source selection and party mode.  I have also setup scenes in Alexa and she controls it was well.  If you are interested i can send them to you.

No worry because i am also completing the Lync6/12 and should have it in a few days.  It will start with the basic functions as above. 

Regards,
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: Newzwaver on January 07, 2017, 10:45:02 pm
What system are you running MC66?
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: ojovilla on January 08, 2017, 10:04:56 am
Yes!
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: Newzwaver on January 08, 2017, 11:24:17 am
I will upload it tonight with instructions on how to install.
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: Newzwaver on January 08, 2017, 01:07:11 pm
Hi All,

You will find attached files, they will create the plugin for vera, save them in a directory on your computer that you can find.

Instructions
1) Go to apps in Vera menu, located on the left side of the screen.
2) Select development apps, under development apps you will select Luup files. 
3) Go back to the directory on your computer and select the files you downloaded.  Select them and drop them into the upload selection (you can't miss it).  Once files are all uploaded, you will see each labeled as done.
4) Under the same menu development apps select create a device.  Under the section Upnp Device Filename enter HTD.xml.  Then press the button on the screen create device, wait for a minute or two.
5) Go to Settings from the menu on the left, select Z-Wave settings, advanced and reload engine.  After a few minutes this will make the first device the HTD Controller.  If it doesn't then you need to refresh your screen.
6) Select the HTD Controller device enter the advanced settings and type in the IP address of your GW-SL1.  Make sure the IP address is correct, go out of the device and back in making sure the IP address was saved.
7)  Go to Settings from the menu on the left, select Z-Wave settings, advanced and reload engine.  After a few minutes this will create the six zones.
8) You will have to rename the zones to what you have them named in your app. 
9) When you have confirmed that everything is fully functioning, you may have an error on the controller.  No worry enter the HTD Controller device, select advanced, variables and change the CommFailure to 0.  It should be 1.
10)  Go to Settings from the menu on the left, select Z-Wave settings, advanced and reload engine.  After a few minutes the error will be gone.

This creates a fully functioning plugin with 6 zones.  You can also get this to work with your Alexa if you have one. To do so  you need to setup a scene, the scene is what Alexa will operate.  It can turn zone on/off, volume up/down, mute and etc. 
Once completed you will ask Alexa to discover devices and your scene will be totally functioning

I hope this works well for you and give me an update on how you find it.
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: ojovilla on January 09, 2017, 10:24:10 am
Great work Newzwaver, ....are you sure you are a new zwaver?

Besides there being no attachment to the post , I am currently not in a position to test being away form the controller :(

I will return soon enough.
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: Newzwaver on January 10, 2017, 02:27:23 pm
See I am very new, lol.  I will post when I land back home.  Very sorry.
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: Newzwaver on January 10, 2017, 08:14:06 pm
As promised please find attached the files required for the MC-66 and MCA-66 via GW-SL1.  Good luck and follow the instructions above, if you need help no problem. 


COMMING SOON LYNC6 AND 12.
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: Newzwaver on January 10, 2017, 08:15:03 pm
Hi All,

You will find attached files, they will create the plugin for vera, save them in a directory on your computer that you can find.

Instructions
1) Go to apps in Vera menu, located on the left side of the screen.
2) Select development apps, under development apps you will select Luup files. 
3) Go back to the directory on your computer and select the files you downloaded.  Select them and drop them into the upload selection (you can't miss it).  Once files are all uploaded, you will see each labeled as done.
4) Under the same menu development apps select create a device.  Under the section Upnp Device Filename enter HTD.xml.  Then press the button on the screen create device, wait for a minute or two.
5) Go to Settings from the menu on the left, select Z-Wave settings, advanced and reload engine.  After a few minutes this will make the first device the HTD Controller.  If it doesn't then you need to refresh your screen.
6) Select the HTD Controller device enter the advanced settings and type in the IP address of your GW-SL1.  Make sure the IP address is correct, go out of the device and back in making sure the IP address was saved.
7)  Go to Settings from the menu on the left, select Z-Wave settings, advanced and reload engine.  After a few minutes this will create the six zones.
8) You will have to rename the zones to what you have them named in your app. 
9) When you have confirmed that everything is fully functioning, you may have an error on the controller.  No worry enter the HTD Controller device, select advanced, variables and change the CommFailure to 0.  It should be 1.
10)  Go to Settings from the menu on the left, select Z-Wave settings, advanced and reload engine.  After a few minutes the error will be gone.

This creates a fully functioning plugin with 6 zones.  You can also get this to work with your Alexa if you have one. To do so  you need to setup a scene, the scene is what Alexa will operate.  It can turn zone on/off, volume up/down, mute and etc. 
Once completed you will ask Alexa to discover devices and your scene will be totally functioning

I hope this works well for you and give me an update on how you find it.
Modify message
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: ojovilla on January 20, 2017, 12:20:36 am
I will be returning home from a business trip this weekend and will be all over this when I get home. Excited!
Hi All,

You will find attached files, they will create the plugin for vera, save them in a directory on your computer that you can find.....
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: ojovilla on January 20, 2017, 03:53:41 pm
Hello Newzwaver,

I was able to successfully upload to the files to the development screen , but I run into a problem when trying to create the device it says

Code: [Select]
System error : Device: 86. Fail to load implementation file HTD.xml
I am guessing maybe it should have been called "D_HTD.xml" but even with that I still get the error and its not going away.

Please help.
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: Newzwaver on January 20, 2017, 04:18:10 pm
Hi

Sorry, I have been using mine for the last few weeks no issue.  Make sure it's D_HTD.xml, it could be something went wrong when I uploaded.  If you have an Alexa it works great.  Setup scenes and you can control volume, mute, on/off and zones. 

So if the file name doesn't work I will reload it for you.  Keep me posted.
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: ojovilla on January 20, 2017, 04:34:00 pm
Hello,

Thanks for the response. When I used the  D_HTD.xml the device was created successfully. Will finish the set up of this later.


Your instructions have the wrong file name , so I believe it tried to create a device using the wrong xml file name. The problem now is the error wont go away because its still trying to create the device . Do you know how to clear this? like delete devices , it does not show up on the device list so not exactly sure how to clear the error message.
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: Newzwaver on January 20, 2017, 04:56:40 pm
Hi

Yes, try this
http://<local_Vera_IP>:3480/data_request?id=device&action=delete&device=<device_ID>

Replace it with the device with the number of the device that was created and the Ip with your Vera ip.

If you have an issue finding the ip I can sent the list command.

Good luck and give me some feed back as I would like to post this once it has been fully tested.
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: ojovilla on January 20, 2017, 04:59:43 pm
Great , will try that. Travelling still so give me a day.

Thanks for the help .
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: Newzwaver on January 20, 2017, 05:05:23 pm
Make sure you delete the right device sir list them first.

http://ip_address:3480/data_request?id=user_data&output_format=xml

Title: Re: IP to Serial Control (HTD Lync 6)
Post by: ojovilla on January 21, 2017, 11:39:06 am
I was able to finish configure it works great! Thanks again for all the help. Was also able to get rid of the ghost device . In reality the entire set up really takes like 2 mins. Now trying to set up scenes for Alexa, I have had a problem in the past for on and off scenes with Alexa, she seems to understand on but never off.
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: Newzwaver on January 21, 2017, 12:09:49 pm
Excellent, if you need some help on the Alexa and HTD send me a note.   If you see functions you want added i can try that as well. 
I have my Alexa turning on and off zones, increasing/decreasing volume, turing all on/all off and mute on/off for zones and all. 
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: jugernaat on February 04, 2017, 12:19:17 am
Hey I love the app so far, one thing that would be of great help would be a slider bar for volume so you could create preset volume in a scene, I use my onkyo receiver and HTD system as an alarm clock with pandora and would be awesome to be able to preset the volume! also being able to select a source would be nice as well.this was the last link in my home theater automation so thanks so much for building this!
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: Newzwaver on February 04, 2017, 11:37:10 pm
Hey, i will give it a shot later, I have it working on another plugin so will see.  Keep your finger crossed.
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: Newzwaver on March 06, 2017, 06:51:27 am
Hi All,

The files below will let you set volume up by X and down by X,  good luck and yes i am still working on a slider.

Title: Re: IP to Serial Control (HTD Lync 6)
Post by: sbbcarl on March 06, 2017, 04:55:56 pm
@Newzwaver - Do you know if the gateway is able to receive commands over HTTP directly?
I am trying to do something similar to this without having to use the local web socket on the gateway it self.

My goal is to be able to port forward the serial gateway to make it web accessible and then send a command to it via a REST API hooked up to ALEXA.

I was able to make one work by using the existing socket (ws://gatewayIP:8000) and send HEX commands to it but looking for a method to send a POST/GET command over HTTP directly and I am curious if you have come across this in your development of this plugin.
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: Newzwaver on March 07, 2017, 10:14:11 pm
Hey

The only other control I have tried is a scene, the volume is a little tricky,

local socket = require("socket")
host = "192.168.2.88"
c = assert(socket.connect(host, 10006))
c:settimeout(5)

local sres, serr = c:send(string.char(0x02,0x00,0x01,0x04,0x57,0x5E))-- testing
print("Send:", sres, serr)

local data, rerr = c:receive(300)
luup.log (data)
print ("Receive:", data, rerr)

Be interested in the code if you figure it out.  I am working on Bell TV next.
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: Bigvs79 on March 08, 2017, 11:36:29 pm
Hi can i have the plugin and instructions too ?
I have mc66 with gswl network component
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: raghunath on March 18, 2017, 04:13:38 pm
couple of issues:

1) After installing all the files, setting up the gateway IP, I see 6 zones showing up, but HTD controller keeps showing "device not detected"? And looks like buttons don't work.

2) I have a HTD Lync 12 device? Is that the reason?

3) How can I make it work for 12 zones?

Thanks.
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: Newzwaver on March 20, 2017, 06:49:00 am
HI

Yes that is the reason and i also have the plug in for the lync 12, send me your email address and i will send it over, dont post it send it via message.  The lync plugin will create 12 zones.

Title: Re: IP to Serial Control (HTD Lync 6)
Post by: drewsky on April 19, 2017, 12:07:42 am
Hi,
Just came across this thread because I have am MC-66 and would like to integrate with my VeraPlus. Downloaded the files, followed the instructions to install and voila... it worked. THANK YOU NEWZWAVER!!!
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: Newzwaver on April 19, 2017, 02:35:24 pm
No problem I have a few updates coming soon as well so keep an eye.

Title: Re: IP to Serial Control (HTD Lync 6)
Post by: Newzwaver on April 30, 2017, 10:41:17 am
Ok, so I have the feedback from the unit showing the volume on a slider.  All I need is to write some code that uses this to allow the slider to work.  Keep you posted.  If you want the feed back files send me a note.
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: jugernaat on April 30, 2017, 04:55:19 pm
Sweet let me know if you need help testing
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: ojovilla on May 01, 2017, 12:35:26 pm
Ok, so I have the feedback from the unit showing the volume on a slider.  All I need is to write some code that uses this to allow the slider to work.  Keep you posted.  If you want the feed back files send me a note.

Awesome!
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: drewsky on May 02, 2017, 06:05:54 pm
We're anxiously waiting!  ;D
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: drewsky on May 26, 2017, 07:58:41 pm
Checking in to see if there are any updates.... :P
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: Newzwaver on May 27, 2017, 12:35:56 pm
Sorry, work has been crazy.  I have the slider working but having issues with it going past the limits (i.e 0 to 60).  When it goes past the volume limit it locks the keypad. You would think this would be a simple thing, but no it's not for some reason.  I will try to look at it over the next few weeks. 

Question to all, is the plugin working for everything else?  The feedback is that working showing the source and volume set/amount?  Anything else that might need a little fixing?

Regards,
T
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: drewsky on June 03, 2017, 12:04:10 am
Thanks for continuing to work on this on your limited free time, Newzwaver!

All the buttons work well enough through the web interface, but they don't show up at all in the Vera Mobile android app, so neither the main controller nor any of the zones can be controlled via the app. When using the ImperiHome app, the controller and zone devices don't show up at all (though I realize 3rd party functionality is beyond your control, I only mention it here in case it might help shed some light into some aspect of troubleshooting).

For whatever that's worth...
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: Newzwaver on June 07, 2017, 11:10:53 pm
Hi

I know under the vera app and the veramate i can use them but will check with vera tech to see if i can add anything to get this to work.  I have the two way communication and the slider working, the slider has a few bugs but almost done.  I also have the sources being named to the same as the source on the HTD unit.  Should be able to get you all a test files soon.
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: Newzwaver on July 14, 2017, 07:46:20 am
HI Everyone,

The HTD MC66 and MCA66 was not created with a slide option, the way commands are sent to the unit are just up/down one at a time.   I have created the attached files that use a slide but move up 4 volumes per slide, that is the only way to prevent the unit from locking.  If the unit do lock just turn it off for a few seconds and back on.  I will continue to try and add things (i.e. source names, trying to add internet radio and etc).

If you have any comments, please feel free.
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: drewsky on July 19, 2017, 08:18:37 pm
Great, I will try and let you know my experience with it. Thank you for all the work!
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: drewsky on July 21, 2017, 12:40:30 pm
HI Everyone,

The HTD MC66 and MCA66 was not created with a slide option, the way commands are sent to the unit are just up/down one at a time.   I have created the attached files that use a slide but move up 4 volumes per slide, that is the only way to prevent the unit from locking.  If the unit do lock just turn it off for a few seconds and back on.  I will continue to try and add things (i.e. source names, trying to add internet radio and etc).

If you have any comments, please feel free.

I've installed the replacement files to test it, and ON/OFF and Mute buttons work, but the volume slider doesn't seem to do anything... Also, it seems the slider will only go up to 60%. Not sure what that tells you. Let me know if you there's any diagnostic info you need to help troubleshoot. Thansks!
Title: Re: IP to Serial Control (HTD Lync 6)
Post by: Newzwaver on July 21, 2017, 02:40:33 pm
I will resend the files something must of uploaded wrong.  The volume will only go to 60 on the system, that is actually 100%.  I will try to do this later tonight when i get home.