-
Notifications
You must be signed in to change notification settings - Fork 198
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can't get bridge to talk to Netcat to send commands via mochad #458
Comments
The target item should be tcp://192.168.X.X:1099/pl a1 on and the type should be TCP Device. |
Thanks for the response but still no go. Command generates no errors but still no comm to Netcat. If this helps my platform configuration is all on same PC: Request executed success shown when using test button |
I have tested this again and it is working. |
Not sure what the issue is but it doesn't work for me. Anyway, got tired of tweaking on it to no avail so I installed Domoticz and let it be the mediator. Works great and your Domoticz configuration tool works flawlessly and saves a lot of typing too! Thanks for the follow-up and the great application. BTW I'm using my Echo Dot to voice manage the lighting through the bridge and that works great too. |
Yes, tested some more and now it is inconsistent. Will look some more. |
?Thank You
Mark J. Puig
<http://www.cvtc.edu/>
<http://www.cvtc.edu/>
…________________________________
From: BWS Systems <notifications@github.com>
Sent: Wednesday, February 22, 2017 5:53 PM
To: bwssytems/ha-bridge
Cc: Puig, Mark; Author
Subject: Re: [bwssytems/ha-bridge] Can't get bridge to talk to Netcat to send commands via mochad (#458)
Yes, tested some more and now it is inconsistent. Will look some more.
-
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub<#458 (comment)>, or mute the thread<https://github.com/notifications/unsubscribe-auth/AYbfj8LVUa7AerXa7-lOJZLnkljRw2Buks5rfMqBgaJpZM4L97I4>.
|
I have an enhancement that may help in the next release |
Thank you, I just ordered a Raspberry Pi to try this in. I'll give it a go with 4.2.1. |
Well, I have to do some other fixing, it seems mochad needs a \n, \r or \0 for it complete the line read. Unless you send a hex string, i encode those as characters and not to the actual byte value. |
Received the Pi3 yesterday, installed Mochad and Ha-Bridge 4.2.1, used TCP device command as tcp://192.168.1.240:1099/rf a1 on. No error indicted from the Bridge but no comm with Mochad either. Using Netcat command rf a1 remotely to, and locally on the Pi work fine. Any suggestion on how else o test comms between the bridge and mochad? |
You need to put a \n after that command |
Will give that a try tomorrow. Thank You
From: BWS Systems [mailto:notifications@github.com]
Sent: Saturday, March 11, 2017 4:07 PM
To: bwssytems/ha-bridge <ha-bridge@noreply.github.com>
Cc: Puig, Mark <MPUIG@cvtc.edu>; Author <author@noreply.github.com>
Subject: Re: [bwssytems/ha-bridge] Can't get bridge to talk to Netcat to send commands via mochad (#458)
You need to put a \n after that command
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub<#458 (comment)>, or mute the thread<https://github.com/notifications/unsubscribe-auth/AYbfj0dxXpLjrS7IKmKkfCYLab2dR2Dvks5rkxsYgaJpZM4L97I4>.
|
Couldn’t wait but adding the \n did the trick. What is its function? I saw some mention of the \n in the last fix but missed what it does. Thanks for the prompt response and fix.
From: BWS Systems [mailto:notifications@github.com]
Sent: Saturday, March 11, 2017 4:07 PM
To: bwssytems/ha-bridge <ha-bridge@noreply.github.com>
Cc: Puig, Mark <MPUIG@cvtc.edu>; Author <author@noreply.github.com>
Subject: Re: [bwssytems/ha-bridge] Can't get bridge to talk to Netcat to send commands via mochad (#458)
You need to put a \n after that command
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub<#458 (comment)>, or mute the thread<https://github.com/notifications/unsubscribe-auth/AYbfj0dxXpLjrS7IKmKkfCYLab2dR2Dvks5rkxsYgaJpZM4L97I4>.
|
Mochad expects that a CR LF or null to be passed at the end of the string. When using netcat, when you hit the return key it sends the CR or \n character. |
?Makes sense, thank you for the explanation. The fix in 4.2.1 will allow me to take Domoticz out of the mix although the two products have been working well together. I haven't tried 4.2.1 with the Echo yet but I'm optimistic it will be as seamless as the previous releases.
Next task, is X10 dimming possible using the Dim command in place of the on/off options? I have both power-line and RF options available.
Thanks again, great product!
Mark J. Puig
<http://www.cvtc.edu/>
<http://www.cvtc.edu/>
…________________________________
From: BWS Systems <notifications@github.com>
Sent: Saturday, March 11, 2017 7:52 PM
To: bwssytems/ha-bridge
Cc: Puig, Mark; Author
Subject: Re: [bwssytems/ha-bridge] Can't get bridge to talk to Netcat to send commands via mochad (#458)
Mochad expects that a CR LF or null to be passed at the end of the string. When using netcat, when you hit the return key it sends the CR or \n character.
-
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub<#458 (comment)>, or mute the thread<https://github.com/notifications/unsubscribe-auth/AYbfj8M3e03giMuYOfnWEjX2EQFU1NnDks5rk0_LgaJpZM4L97I4>.
|
I wrote a tutorial for X10 that gives X10 dimming examples here: http://coreyswrite.com/electronics/home-automation/amazon-echo-x10-home-control-updated/ |
@audiofreak9 in this write up, is the process involving the ha-bridge still the same as you described? |
Thanks Corey, not using Heyu, sending X10 commands directly from the HA-Bridge via TCP to Netcat to execute in Mochad. Mochad is talking to the X10 transceiver via a USB port. Until the latest update (4.2.1) I couldn't get the bridge to talk to Netcat so I had installed Domoticz as a go between to send the commands from the bridge to Mochad. This worked great but the fix now allows me to send directly from the bridge to Mochad via Netcat using TCP device type. (e.g. tcp://192.168.x.x:1099/rf a1 on) |
@Matt8119 yes, just use the updated ha-bridge v4.2.1, otherwise my tutorial for X10 control is up to date. @instructor1 nice, I'm planning on playing with some TCP myself, so yeah my tutorial uses |
@Matt8119 BTW, I've even bricked an RPi in the past and followed my own tutorial building a new ha-bridge, just to be sure my steps still work. |
@instructor1 Just a thought if the ha-bridge and the USB X10 transceiver are on the same RPi, then you can call the MOCHAD directly on the ha-bridge with the exec type, essentially replacing HEYU with MOCHAD in my tutorial. |
That may be the case but I wasn’t able to get that to work when I first starting playing with this project. Domoticz worked fine to communicate to Mochad but I couldn’t get exec type to work so I left Domoticz in and then used the Ha-Bridge to configure the Domoticz devices once I had the X10 switches setup in Domoticz. Used advise from Bwssystems to configure the TCP connection via Netcat which also didn’t work until the 4.2.1 update as seen of the github thread.
It may have been a configuration issue (user error) early on but I couldn’t seem to find out how to properly apply the settings to make bridge send the commands directly to mochad. And I did spend a lot of time searching for them without luck. In fact you and I had a dialogue back in the early stages when I was switching from the X10 firecracker to a CM19a and Mochad and I was trying to make it work. The TCP solution looks like it’s working OK for me now but I’d still be interested in how to configure the bridge to send exec type commands if you have some doc on that.
From: audiofreak9 [mailto:notifications@github.com]
Sent: Sunday, March 12, 2017 4:48 PM
To: bwssytems/ha-bridge <ha-bridge@noreply.github.com>
Cc: Puig, Mark <MPUIG@cvtc.edu>; Author <author@noreply.github.com>
Subject: Re: [bwssytems/ha-bridge] Can't get bridge to talk to Netcat to send commands via mochad (#458)
@instructor1<https://github.com/instructor1> Just a thought if the ha-bridge and the USB X10 transceiver are on the same RPi, then you can call the MOCHAD directly on the ha-bridge with the exec type, essentially replacing HEYU with MOCHAD in my tutorial.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub<#458 (comment)>, or mute the thread<https://github.com/notifications/unsubscribe-auth/AYbfj5ZG_Zl5N-ZxVHlbfG2xR6Bf8UIwks5rlGgqgaJpZM4L97I4>.
|
I'm gonna have to get my test RPi B+ out, install MOCHAD and test it out. However, using the EXEC type is very straight forward - even in the newest GUI. |
I'll be interested to know how that goes. I just got my first RPi 3 on Friday but haven't had much time to play with it beyond a simple test of 4.2.1 and mochad on it. I'll try some exec commands today.
My current operational configuration is running on an old HP Netbook under Linux 16.4. Works fine but I wanted something smaller that I can physically pair with an X10 CM15a or just the CM19a.
?
<http://www.cvtc.edu/>
<http://www.cvtc.edu/>
…________________________________
From: audiofreak9 <notifications@github.com>
Sent: Sunday, March 12, 2017 6:36 PM
To: bwssytems/ha-bridge
Cc: Puig, Mark; Author
Subject: Re: [bwssytems/ha-bridge] Can't get bridge to talk to Netcat to send commands via mochad (#458)
I'm gonna have to get my test RPi B+ out, install MOCHAD and test it out. However, using the EXEC type is very straight forward - even in the newest GUI.
-
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub<#458 (comment)>, or mute the thread<https://github.com/notifications/unsubscribe-auth/AYbfjy6m2HtutiJ36Y36iOsfN23NEftBks5rlIGYgaJpZM4L97I4>.
|
I got this working on 4.5.6 with the following settings |
Thanks Enis. I didn’t know this question was still out there. I’ve had it working for quite a while now. I was missing the \n in the TCP command to netcad. Are you using any dim commands to X10 via the bridge?
From: Enis Hoca [mailto:notifications@github.com]
Sent: Saturday, October 07, 2017 2:13 PM
To: bwssytems/ha-bridge <ha-bridge@noreply.github.com>
Cc: instructor1 <mp1361@charter.net>; Mention <mention@noreply.github.com>
Subject: Re: [bwssytems/ha-bridge] Can't get bridge to talk to Netcat to send commands via mochad (#458)
I got this working on 4.5.6 with the following settings
Set the Map Type to TCP Device
Set the command type to TCP Device
set the Item field to "tcp://127.0.0.1:1099/rf a1 on \n" without quotes
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub <#458 (comment)> , or mute the thread <https://github.com/notifications/unsubscribe-auth/AYGj_m3w7xMbobSYZXliFVVeRQO5-V4uks5sp80tgaJpZM4L97I4> . <https://github.com/notifications/beacon/AYGj_q5i93lNKDmbVoFhmrNAHR72Io_Cks5sp80tgaJpZM4L97I4.gif>
…---
This email has been checked for viruses by Avast antivirus software.
https://www.avast.com/antivirus
|
sorry for the late reply - sort of, not really. the only way I could get that to work was create another switch and replace the on and off commands with dimmer up and down command.
…________________________________
From: instructor1 <notifications@github.com>
Sent: Monday, October 9, 2017 9:48 AM
To: bwssytems/ha-bridge
Cc: Enis Hoca; Comment
Subject: Re: [bwssytems/ha-bridge] Can't get bridge to talk to Netcat to send commands via mochad (#458)
Thanks Enis. I didn’t know this question was still out there. I’ve had it working for quite a while now. I was missing the \n in the TCP command to netcad. Are you using any dim commands to X10 via the bridge?
From: Enis Hoca [mailto:notifications@github.com]
Sent: Saturday, October 07, 2017 2:13 PM
To: bwssytems/ha-bridge <ha-bridge@noreply.github.com>
Cc: instructor1 <mp1361@charter.net>; Mention <mention@noreply.github.com>
Subject: Re: [bwssytems/ha-bridge] Can't get bridge to talk to Netcat to send commands via mochad (#458)
I got this working on 4.5.6 with the following settings
Set the Map Type to TCP Device
Set the command type to TCP Device
set the Item field to "tcp://127.0.0.1:1099/rf a1 on \n" without quotes
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub <#458 (comment)> , or mute the thread <https://github.com/notifications/unsubscribe-auth/AYGj_m3w7xMbobSYZXliFVVeRQO5-V4uks5sp80tgaJpZM4L97I4> . <https://github.com/notifications/beacon/AYGj_q5i93lNKDmbVoFhmrNAHR72Io_Cks5sp80tgaJpZM4L97I4.gif>
---
This email has been checked for viruses by Avast antivirus software.
https://www.avast.com/antivirus
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub<#458 (comment)>, or mute the thread<https://github.com/notifications/unsubscribe-auth/AKoFjdJxCoA6A7wrpf8EjFZTLhiX9HFMks5sqiQfgaJpZM4L97I4>.
|
Probably not a bridge issue as much as a user issue but I'm trying to get the bridge to send netcat commands via mochad. NC from the terminal works fine as does a remote nc session. Would like examples of the proper command syntax to configure in the bridge GUI. Have used the bridge successfully with windows and Mint 18 via a firecracker module but can't figure out the proper command structure to get it to communicate via Netcat to a CM19A X10 module.
Searched the forums to no avail, any assistance appreciated.
The text was updated successfully, but these errors were encountered: