-
Notifications
You must be signed in to change notification settings - Fork 15
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
Comments, Questions, open forum (2) #6
Comments
Thanks Bren for your previous responses; looking forward to any IFTTT or SmartThings development to keep these bulbs alive into the future ... |
Hi Bren, Happy New Year! Just curious if you have any thing in the works for IFTTT or SmartThings? Ultimately I'd love to get Google Home to control these bulbs. Regards, |
Hey @merrickw - nothing yet. Smart things requires me to have the Samsung Bridge which I dont have. I did look into the IFTTT. They have an applet for 'Connect Greenwave Systems' which of course doesnt work since it's tied to the Greenwave servers they took down... So I have 'applied' to be a maker: I have been re-writing some of the code, so I can support more than one bridge at a time and control HUE lights too (inc colour). It's not really ready for prime time... Needs some polish, but if you want to experiment it is in the non master branch. Cheers |
Thanks for the update. The IFTTT sounds the most interesting, but I guess it can only work if you have your local web server running... which makes sense, you wouldn't want the cloud turning off your lights, with all the hacking going on .... I haven't bought any Hue lights yet ... my TCP's got me covered ... |
Now that the Greenwave link got sacked, the clock resides in my TCP gateway is drifting away every single day. So over last 6 months or so, mine is now like 20-30 minutes ahead. Sunrise/sunset schedule would be way off also. So, quick questions: Is there a way to correct the clock in gateway via some UI on local web server? Or better yet, get the clock to sync with local web server automatically/periodically? Count this as a feature request. :) Oh BTW, I was talking about the clock inside the gateway. I understand that the scheduler on local web server would trigger just fine. And, great work Bren! I'm excited!! |
@k8gg Hey there - I'm guessing you're looking at the regular branch versus dev? I'll look into time setting. I'm fairly certain it will be possible. Stay tuned... |
Yes, branch. |
@k8gg - Done - pull master, should have 3 updates, index.php, setDateTime.php and a JS file. I have made the new screen to set date and time. I kinda whipped it together... so hope it works. Pretty simple. There appears to be functions to set time zone too, but this should do the trick... I don't use the built in Bridge functions so please let me know. Thanks! |
This date tweak worked awesome for me thanks so much |
@sktaylortrash - Awesome glad to hear it. I just need to find some time to finish the build I have in progress in Dev which has Hue integration and hooks for multiple bridges. Not enough hours in a day :) |
Yup. The date/time update interface worked. Thanks a lot @bren1818 ! |
@bren1818 forgive my asking but what would the use case for multiple bridges be? |
My guess: to have one single web UI that would control not only TCP bulbs
but also Hue or wemo or even zwave bulbs... Yes?
…On Jan 31, 2017 8:21 PM, "sktaylortrash" ***@***.***> wrote:
@bren1818 <https://github.com/bren1818> forgive my asking but what would
the use case for multiple bridges be?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#6 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AYOM2_N5MOeC6QtoLMjkULpEwk4rtE2Nks5rX94ZgaJpZM4LEhw5>
.
|
Oh I get multiple brands I meant multiple TCP bridges |
@sktaylortrash - reason for multiple TCP bridges is two fold. I bought up some of the bridge packs when they were clearing them out. At one point I accidentally messed up my bridge, which required me to re-flash it and downgrade the firmware. Before I got it to work again, I got kind of frustrated and started setting up a second bridge so I could continue development on this project and so I could control my bulbs via a web interface. This meant re-setting up all my existing bulbs on the new bridge. Its a lengthy thing to do, so I was tackling it room by room, every few days. When I eventually got my initial bridge working again, I had half my bulbs on one bridge and the other half on the other bridge. I was going to migrate all the bulbs back to one bridge, however - by having two bridges it offered one advantage, since I use remotes, having one bridge meant I only had 4 buttons to control all the lights in my house, both upstairs and downstairs. By having a second bridge, I could pair half my remotes with the downstairs, and half the remotes with the upstairs, meaning I had 8 buttons to control the house. Not a huge deal, but comes in handy when you're fumbling around in the dark, so you dont turn on the whole house but half of it :) @k8gg is also right. I wanted to extend my project to work with at least Hue since I have some Hue lights, and by having two TCP bridges, it allows me to test code compatibility with multiple hubs. Hope that answers your question 👍 |
@bren1818 so I totally should have thought of the remote thing. I have 3 in a drawer I'll never use for that reason. May need to pickup another bridge or two. It's not like I now have 24 bulbs running or anything :) |
Another way to use 2 remotes and have 8 zones is to keep 4 bulbs off the gateway, and connect to a remote directly. I did this so one remote controls 4 bulbs in my upstairs bedroom, off the gateway. The main floor is on the gateway. This works perfectly since I don't need scheduling or remote access for my bedroom lights, just the handy remote. The support guys at TCP walked me through how to set that up. |
@sktaylortrash haha, I can't say I have that many either... but in the bedroom, we have two lamps on either side of the bed and 3 bulbs acting as one appliance in the ceiling fan, so it's nice to have the remote to turn on/off and dim the lights that way. I stuck some Velcro on the back of the remotes (I have 5 of them) and stuck them to the wall to use as a switch too. They're handy but at the same time, remotes... remotes everywhere haha @merrickw makes a very good point too. You don't necessarily need to bridges to accomplish this. It just sorta worked out that way for me. |
Hi Bren, Thanks |
Hi @vijimaini - shouldn't be an issue, I'm pretty sure my bridges have the latest firmware. The more likely issue is you're using IIS. - I cant say I have tested with IIS. In your IIS folder, could you create a simple php file like: I recommend you download XAMPP and try the project in there first. Let me know if that helps. Cheers! |
Bren, I installed XAMPP and it works perfectly. |
@vijimaini Glad to hear that. When you use IIS, you'd likely have needed to enable some php extensions which come pre-enabled on xampp. Fortunately you can use Apache and IIS simultaneously. Cheers, Bren |
Hi Bren, |
@shrms - Sure, its pretty straightforward and you wont need any development experience. You will however need to have a bit of knowledge about home networking. So first things first, download yourself XAMPP: https://www.apachefriends.org/index.html its free. I suggest getting the version with PHP 5.6.3 Install the application, if you use the defaults, it will set you up an htdocs folder in: C:\xampp\htdocs this is the folder you want to download this project into. So download the zip and extract its contents into the folder, the htdocs folder should look something like this: now the tricky part, using a text editor of your choice, (I suggest Notepad++) and edit the include.php file. You can leave pretty much everything as is, with one exception - edit LINE 8, and replace the IP address with the local IP address of your lighting bridge. You can usually find this in your routers DHCP/client listing. Once you have the IP in there, save the file,. Press the Sync button on your bridge, and then open up localhost. (go to a browser and type: http://localhost) In theory, that's it, it should display your pre-setup bulbs and allow you to control them. Let me know if you have any problems. There should also be some documentation here: Best of luck! |
Hi Bren, 'If you are seeing this, you haven't generated your token yet. Regards |
@shrms - are you sure you pressed the sync button and have the correct IP of your bridge? As for the token file, did a "tcp.token" file get generated in the htdocs folder? If you have the right IP for you bridge, in theory you can navigate to: https://{BRIDGE-IP}/gwr/ If you get a "privacy error" (this is from the Bridge, not my code) just allow it and see if the page resolves. If the request times out, you likely have the wrong IP. You can also try changing the LIGHTING_PORT (line 9) to 80 instead of 443, but most bridges will be on 443. |
Hi @bren1818 - is there a way to setup sunset and sunrise time. This feature using IOS app does not work. The tcp device must have been getting this information from the Gwr server, before it shutdown. The feature to adjust time is great. The time on my device was out by 35 minutes. Thanks |
@vijimaini I haven't developed code yet to work with the sunrise/sunset natively, but I did develop a scheduler which triggers the lights at programmed times using the underlying API for this app. I'll have a look to see if I can emulate or develop that function, but I never used it. Cheers |
@bren1818 Ok, I was wondering if the sunset / sunrise values were stored on device that was updated daily from cloud. The API test script shows value to be sunset, which means it may be stored somewhere on device. Thanks |
Ok making tons of progress. Now I'm just trying to figure out how to properly use Apache directives to stop any ol' person from controlling the lights. According to the apache docs, it sounds like I should try and make the changes within the apache.conf file rather than using a .htaccess file.. So here is what I currently have:
If I uncomment that the block above, I can still access the page within the local LAN, and I get a 403 error if I try to access from outside the LAN (great!)- BUT it seems that api.php becomes inaccessible as well and breaks the IFTTT web hook. (boo!). Any idea on how to properly format the directives to keep api.php accessible by all? As always- thanks! |
Sounds like you've made excellent progress and only have a little road bump
up to cross at this point.
Given we are on the same Raspbian Apache version, the sample . htaccess I
provided should have worked, but you can migrate it's contents into the
apache.conf.
Once you do, try performing a config test:
*apachectl configtest*
To see if that yeilds any further information. It's possible that when you
altered the config you introduced a hidden character which is causing
problems. This can come from copying between windows/linux depending on how
you're doing it.
…On Sun, Apr 26, 2020, 8:45 AM crutchre-source ***@***.***> wrote:
Ok making tons of progress.
Removing .htaccess allows me to control the lights using Alexa via IFTTT.
Hurray!!!
Now I'm just trying to figure out how to properly use Apache directives to
stop any ol' person from controlling the lights.
According to the apache docs, it sounds like I should try and make the
changes within the apache.conf file rather than using a .htaccess file.. So
here is what I currently have:
`
Options FollowSymLinks
AllowOverride None
Require all denied
<Directory /usr/share>
AllowOverride None
Require all granted
<Directory /var/www/>
Options Indexes FollowSymLinks
AllowOverride All
Require all granted
#<Directory /var/www/html>
Options -Indexes RewriteEngine On Order deny,allow Deny from all Allow
from 192.168.1.0/24
#
<Files /var/www/html/api.php>
Allow from all
`
If I uncomment that the block above, I can still access the page within
the local LAN, and I get a 403 error if I try to access from outside the
LAN (great!)- BUT it seems that api.php becomes inaccessible as well and
breaks the IFTTT web hook. (boo!).
Any idea on how to properly format the directives to keep api.php
accessible by all?
As always- thanks!
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#6 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAQMEH73GT7BCWQOZ5QSUR3ROQUHJANCNFSM4CYSDQ4Q>
.
|
Ok all done! Thanks for all the help!! @sktaylortrash The thing that I ended up doing different from the Wiki besides PHP 7.3 was using Bren's posted .htaccess file here:
This .htacess file which is included in the download doesn't work for me:
The only other watch-out was that I had to make the query that was automatically generated a secure one: Thanks again! I finally don't have to search around in the dark for wherever the kids left the TCP lighting remote.... |
Congratulations that's awesome! Glad you got it all setup. Thanks for
noting the changes.
Cheers!
…On Sun, Apr 26, 2020, 6:04 PM crutchre-source ***@***.***> wrote:
Ok all done! Thanks for all the help!!
@sktaylortrash <https://github.com/sktaylortrash> The thing that I ended
up doing different from the Wiki besides PHP 7.3 was using Bren's posted
.htaccess file here:
Options -Indexes
RewriteEngine On
Order deny,allow
Deny from all
Allow from 192.168.1.0/24
<Files api.php>
Allow from all
</Files>
This .htacess file which is included in the download doesn't work for me:
Options -Indexes
Order deny,allow
Deny from all
Allow from 127.0.0.1 #localhost
Allow from ::1 #localhost
Allow from 192.168.1.1/24 #Local Network
<Files api.php>
Order deny,allow
deny from all
allow from all
</Files>
The only other watch-out was that I had to make the query that was
automatically generated a secure one:
http://{myurl}/api.php?fx=toggle&type=room&uid=0&val=1&password={pw}
needed to be:
https://{myurl}/api.php?fx=toggle&type=room&uid=0&val=1&password={pw}
Thanks again! I finally don't have to search around in the dark for
wherever the kids left the TCP lighting remote....
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#6 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAQMEHZUR4QOERF7C2T7GITROSVVRANCNFSM4CYSDQ4Q>
.
|
Hi Bren, Just want to say your interface is still working like a charm 3 years in. Plus, I have a question. I've renewed my interest on getting SmartThings to recognize these bulbs. So here's my question, I followed your Word doc on downgrading the firmware, and I get the result of seeing the Python console handling the firmware update. Any idea why it's not downgrading? It appears to be pulling from my laptop file. I'm stumped. Regards, |
Hey there, unfortunately the down grading technique has always been a
little hit and miss. I should probably nuke the repository as I think (but
haven't proven yet) that a silent update was pushed which prevents this
method from working.
I had the downgrade work at one point but then I accidentally refreshed my
network settings and the bridge auto updated and I've not yet tried
re-downgrading.
Sorry about that, but I'm glad the interface is still working :)
…On Fri., Oct. 30, 2020, 12:54 p.m. Merrick Weintraub, < ***@***.***> wrote:
Hi Bren,
Just want to say your interface is still working like a charm 3 years in.
Plus, I have a question. I've renewed my interest on getting SmartThings
to recognize these bulbs.
There's a custom SmartThings app and device handler written by the
community.
The catch is the bridge needs downgraded firmware to 2.47.
So here's my question, I followed your Word doc on downgrading the
firmware, and I get the result of seeing the Python console handling the
firmware update.
When I check the version (in the TCP Lighting app) , it still says 3.80.
Any idea why it's not downgrading? It appears to be pulling from my laptop
file. I'm stumped.
Regards,
Merrick
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#6 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAQMEH6ZUDJWCGPJNNOO6GTSNLVULANCNFSM4CYSDQ4Q>
.
|
Oh well. I'm surprised they would still bother to push that firmware.
The message boards at SmartThings community point to your project for downgrading... It must be working somewhat as the SmartThings app seems to still work for some.
Just bought some Lutron Caseta switches, trying to make everything smart...
Regards,
Merrick
-------- Original message --------
From: Bren <[email protected]>
Date: 10/30/20 1:01 PM (GMT-05:00)
To: bren1818/TCPLightingWebInterface <[email protected]>
Cc: Merrick Weintraub <[email protected]>, Mention <[email protected]>
Subject: Re: [bren1818/TCPLightingWebInterface] Comments, Questions, open forum (2) (#6)
Hey there, unfortunately the down grading technique has always been a
little hit and miss. I should probably nuke the repository as I think (but
haven't proven yet) that a silent update was pushed which prevents this
method from working.
I had the downgrade work at one point but then I accidentally refreshed my
network settings and the bridge auto updated and I've not yet tried
re-downgrading.
Sorry about that, but I'm glad the interface is still working :)
On Fri., Oct. 30, 2020, 12:54 p.m. Merrick Weintraub, < ***@***.***> wrote:
Hi Bren,
Just want to say your interface is still working like a charm 3 years in.
Plus, I have a question. I've renewed my interest on getting SmartThings
to recognize these bulbs.
There's a custom SmartThings app and device handler written by the
community.
The catch is the bridge needs downgraded firmware to 2.47.
So here's my question, I followed your Word doc on downgrading the
firmware, and I get the result of seeing the Python console handling the
firmware update.
When I check the version (in the TCP Lighting app) , it still says 3.80.
Any idea why it's not downgrading? It appears to be pulling from my laptop
file. I'm stumped.
Regards,
Merrick
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#6 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAQMEH6ZUDJWCGPJNNOO6GTSNLVULANCNFSM4CYSDQ4Q>
.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub<#6 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AFSPAJC74JVNQC46JBGKZU3SNLWPZANCNFSM4CYSDQ4Q>.
|
@merrickw if you can't get the downgrade working. I never could and I tried on all 4 of my hubs. |
Hey Paul, thanks for the suggestion. Can this run in parallel to the main branch or is it a replacement?
I'm wondering if I need to reconfigure my setup.
Regards,
Merrick
…-------- Original message --------
From: Paul <[email protected]>
Date: 10/30/20 1:35 PM (GMT-05:00)
To: bren1818/TCPLightingWebInterface <[email protected]>
Cc: Merrick Weintraub <[email protected]>, Mention <[email protected]>
Subject: Re: [bren1818/TCPLightingWebInterface] Comments, Questions, open forum (2) (#6)
@merrickw<https://github.com/merrickw> if you can't get the downgrade working. I never could and I tried on all 4 of my hubs.
I have forked to project to include MQTT support - https://github.com/sktaylortrash/TCPLightingWebInterface-MQTT
This allows integration with pretty much anything that supports MQTT. It's been tested heavily with Node-Red and Home Assitant but there's no reason it shouldn't work with Smartthings using the MQTT Bridge https://github.com/sgupta999/mqtt-bridge-smartthings
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub<#6 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AFSPAJH5HO7HNXRBFJ4SZSTSNL2MXANCNFSM4CYSDQ4Q>.
|
Technically you should be able to run it in parallel. But I set it up a direct drop-in replacement. So if you never configure the MQTT stuff it works exactly like the main branch |
Niiceee. I'll let you know how it goes.
Regards,
Merrick
…-------- Original message --------
From: Paul <[email protected]>
Date: 10/30/20 1:43 PM (GMT-05:00)
To: bren1818/TCPLightingWebInterface <[email protected]>
Cc: Merrick Weintraub <[email protected]>, Mention <[email protected]>
Subject: Re: [bren1818/TCPLightingWebInterface] Comments, Questions, open forum (2) (#6)
Technically you should be able to run it in parallel. But I set it up a direct drop-in replacement. So if you never configure the MQTT stuff it works exactly like the main branch
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub<#6 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AFSPAJAAU23CJZ72QPCXMT3SNL3LPANCNFSM4CYSDQ4Q>.
|
Another suggestion: I set up a Raspberry Pi as a simple proxy to convert the HTTPS calls from the Smartthings plugin to HTTP ones the TCPConnected hub understands. It's been working happily for many months. The Rpi also runs Homebridge and Domoticz so I have quite a lot of options! James |
Oh that's an elegant solution as well if you just need smartthings |
James - that sounds great.
Now how do I do that?
I have Raspberry Pi running with Bren's code.
I have the SmartThings custom app for TCP installed.
Do you have instructions to do the proxy? (I'm a novice with networking, I stumble through)
Regards,
Merrick
…________________________________
From: jadakin <[email protected]>
Sent: Friday, October 30, 2020 1:50 PM
To: bren1818/TCPLightingWebInterface <[email protected]>
Cc: Merrick Weintraub <[email protected]>; Mention <[email protected]>
Subject: Re: [bren1818/TCPLightingWebInterface] Comments, Questions, open forum (2) (#6)
Another suggestion: I set up a Raspberry Pi as a simple proxy to convert the HTTPS calls from the Smartthings plugin to HTTP ones the TCPConnected hub understands. It's been working happily for many months. The Rpi also runs Homebridge and Domoticz so I have quite a lot of options!
James
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub<#6 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AFSPAJC6XCNULWW7QG2W2XDSNL4F3ANCNFSM4CYSDQ4Q>.
|
I was afraid you'd ask me that! I'm not an expert either and after I set it up quite a while ago it has run unattended ever since, so basically, I've forgotten. I know it involved installing Apache and then the configuration of the proxy was pretty simple. I'll have a root around this evening and try and jog my memory. James |
Actually nginx is basically designed for this. There are a million tutorials on setting it up as a reverse proxy which is what James is describing. |
Happy to believe you. I was stabbing in the dark a bit, as going through my bash history for the time shows. It's been on my mind for a while that I might have to rebuild this sometime, and I should really work out what I did in the end. I will look into nginx myself next time! James |
Having looked back at this, I think the relevant parts of what I did were apt-get installing apache2 and apache2-utils then editing (or creating) an 000-default.conf file in /etc/apache2/sites_available to look like this: NameVirtualHost *:80 Sorry this is not much of a "Howto" but it may save you some work. I would certainly look into Paul's suggestion of nginx, though. James |
Thanks James.
I've been tinkering with this, but now I'm confused.
My tcp bridge is 192.168.0.80
My Raspberry Pi with Apache, is 192.168.0.90
So, I'm not sure how I am redirecting traffic from the SmartThings app to use Apache on the Pi for the Proxy.
I assume all this traffic is internal, so I'm not clear on how to configure this.
This sounds like a good idea, but I'm missing some concepts here.
Regards,
Merrick
…________________________________
From: jadakin <[email protected]>
Sent: Friday, October 30, 2020 4:59 PM
To: bren1818/TCPLightingWebInterface <[email protected]>
Cc: Merrick Weintraub <[email protected]>; Mention <[email protected]>
Subject: Re: [bren1818/TCPLightingWebInterface] Comments, Questions, open forum (2) (#6)
Having looked back at this, I think the relevant parts of what I did were apt-get installing apache2 and apache2-utils then editing (or creating) an 000-default.conf file in /etc/apache2/sites_available to look like this:
NameVirtualHost *:80
<VirtualHost :80>
ServerName gwproxy.com
SSLProxyEngine On
SSLProxyCheckPeerName off
SSLProxyCheckPeerExpire off
RequestHeader set Front-End-Https "On"
CacheDisable /
ProxyPass /gwr https://192.168.1.29:443/gwr
ProxyPassReverse /gwr https://192.168.1.29:443/gwr
RedirectMatch ^/$ http://gwproxy.com/gwr
Sorry this is not much of a "Howto" but it may save you some work. I would certainly look into Paul's suggestion of nginx, though.
James
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub<#6 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AFSPAJGOW6LMG4NG4YYFATLSNMSKFANCNFSM4CYSDQ4Q>.
|
Well, as a Hail Mary, I found a way to add a Virtual Switch to SmartThings, and that can be used as a trigger in IFTTT, which then can call the URL's to control the bulbs.
It's not exactly having SmartThings recognize the bulbs directly, but I can now include them in events that handle multiple light/switch brands.
This guy demonstrated how to add the Virtual Switch and use it in IFTTT, in case anyone is interested:
…________________________________
From: jadakin <[email protected]>
Sent: Friday, October 30, 2020 4:59 PM
To: bren1818/TCPLightingWebInterface <[email protected]>
Cc: Merrick Weintraub <[email protected]>; Mention <[email protected]>
Subject: Re: [bren1818/TCPLightingWebInterface] Comments, Questions, open forum (2) (#6)
Having looked back at this, I think the relevant parts of what I did were apt-get installing apache2 and apache2-utils then editing (or creating) an 000-default.conf file in /etc/apache2/sites_available to look like this:
NameVirtualHost *:80
<VirtualHost :80>
ServerName gwproxy.com
SSLProxyEngine On
SSLProxyCheckPeerName off
SSLProxyCheckPeerExpire off
RequestHeader set Front-End-Https "On"
CacheDisable /
ProxyPass /gwr https://192.168.1.29:443/gwr
ProxyPassReverse /gwr https://192.168.1.29:443/gwr
RedirectMatch ^/$ http://gwproxy.com/gwr
Sorry this is not much of a "Howto" but it may save you some work. I would certainly look into Paul's suggestion of nginx, though.
James
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub<#6 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AFSPAJGOW6LMG4NG4YYFATLSNMSKFANCNFSM4CYSDQ4Q>.
|
https://www.youtube.com/watch?v=Ys5vQdr_1WA
[https://www.bing.com/th?id=OVP.eJK2pVSBEOOaE7HQfbZLGwEsDh&pid=Api]<https://www.youtube.com/watch?v=Ys5vQdr_1WA>
SmartThings Hack: Virtual Switch for any IFTTT Device<https://www.youtube.com/watch?v=Ys5vQdr_1WA>
Here's a cool hack. Even if your smart home tech doesn't work with SmartThings, you can use IFTTT to automate it in the SmartThings app. We show you how to set up a virtual switch to get any IFTTT smart home device working in SmartThings. Detailed instructions for creating virtual switches using a browser: http://thingsthataresmart.wiki/index ...
www.youtube.com
…________________________________
From: Merrick W <[email protected]>
Sent: Friday, October 30, 2020 10:46 PM
To: bren1818/TCPLightingWebInterface <[email protected]>; bren1818/TCPLightingWebInterface <[email protected]>
Cc: Mention <[email protected]>
Subject: Re: [bren1818/TCPLightingWebInterface] Comments, Questions, open forum (2) (#6)
Well, as a Hail Mary, I found a way to add a Virtual Switch to SmartThings, and that can be used as a trigger in IFTTT, which then can call the URL's to control the bulbs.
It's not exactly having SmartThings recognize the bulbs directly, but I can now include them in events that handle multiple light/switch brands.
This guy demonstrated how to add the Virtual Switch and use it in IFTTT, in case anyone is interested:
________________________________
From: jadakin <[email protected]>
Sent: Friday, October 30, 2020 4:59 PM
To: bren1818/TCPLightingWebInterface <[email protected]>
Cc: Merrick Weintraub <[email protected]>; Mention <[email protected]>
Subject: Re: [bren1818/TCPLightingWebInterface] Comments, Questions, open forum (2) (#6)
Having looked back at this, I think the relevant parts of what I did were apt-get installing apache2 and apache2-utils then editing (or creating) an 000-default.conf file in /etc/apache2/sites_available to look like this:
NameVirtualHost *:80
<VirtualHost :80>
ServerName gwproxy.com
SSLProxyEngine On
SSLProxyCheckPeerName off
SSLProxyCheckPeerExpire off
RequestHeader set Front-End-Https "On"
CacheDisable /
ProxyPass /gwr https://192.168.1.29:443/gwr
ProxyPassReverse /gwr https://192.168.1.29:443/gwr
RedirectMatch ^/$ http://gwproxy.com/gwr
Sorry this is not much of a "Howto" but it may save you some work. I would certainly look into Paul's suggestion of nginx, though.
James
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub<#6 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AFSPAJGOW6LMG4NG4YYFATLSNMSKFANCNFSM4CYSDQ4Q>.
|
Yes, all internal. My broadband speed is woeful so I avoid external traffic as much as possible (which is why I can't practically use IFTT, sadly). It would be beneficial for me to set this up again from scratch. I might try if we (UK) are in lockdown again soon, as threatened! James |
That makes sense, I was thinking that the Pi address would need to be the new destination for this to work.
I'm not getting it to work, is it definitely the conf in the sites-available folder?
Could I see your full .conf file? I'm wondering if mine is structured correctly.
Regards,
Merrick
…________________________________
From: jadakin <[email protected]>
Sent: Saturday, October 31, 2020 4:41 AM
To: bren1818/TCPLightingWebInterface <[email protected]>
Cc: Merrick Weintraub <[email protected]>; Mention <[email protected]>
Subject: Re: [bren1818/TCPLightingWebInterface] Comments, Questions, open forum (2) (#6)
Thanks James. I've been tinkering with this, but now I'm confused. My tcp bridge is 192.168.0.80 My Raspberry Pi with Apache, is 192.168.0.90 So, I'm not sure how I am redirecting traffic from the SmartThings app to use Apache on the Pi for the Proxy. I assume all this traffic is internal, so I'm not clear on how to configure this. This sounds like a good idea, but I'm missing some concepts here. Regards, Merrick
…
Yes, all internal. My broadband speed is woeful so I avoid external traffic as much as possible (which is why I can't practically use IFTT, sadly).
Once the proxy is working it's just a question of using the pi's address as the "TCP Gateway ID" when setting up the "TCP Bulbs (Connect)" smartapp in the Smarthings app. The actual address of the TCP hub goes in the proxy configuration, as above. Smarthings talks to the Pi, thinking it's the real hub, but the Pi is actually just relaying traffic to the real hub (and vice-versa).
It would be beneficial for me to set this up again from scratch. I might try if we (UK) are in lockdown again soon, as threatened!
James
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub<#6 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AFSPAJFZJX7NOVQX3KYIUNLSNPEUZANCNFSM4CYSDQ4Q>.
|
Also, what does the gwproxy.com represent?
…-------- Original message --------
From: jadakin <[email protected]>
Date: 10/30/20 4:59 PM (GMT-05:00)
To: bren1818/TCPLightingWebInterface <[email protected]>
Cc: Merrick Weintraub <[email protected]>, Mention <[email protected]>
Subject: Re: [bren1818/TCPLightingWebInterface] Comments, Questions, open forum (2) (#6)
Having looked back at this, I think the relevant parts of what I did were apt-get installing apache2 and apache2-utils then editing (or creating) an 000-default.conf file in /etc/apache2/sites_available to look like this:
NameVirtualHost *:80
<VirtualHost :80>
ServerName gwproxy.com
SSLProxyEngine On
SSLProxyCheckPeerName off
SSLProxyCheckPeerExpire off
RequestHeader set Front-End-Https "On"
CacheDisable /
ProxyPass /gwr https://192.168.1.29:443/gwr
ProxyPassReverse /gwr https://192.168.1.29:443/gwr
RedirectMatch ^/$ http://gwproxy.com/gwr
Sorry this is not much of a "Howto" but it may save you some work. I would certainly look into Paul's suggestion of nginx, though.
James
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub<#6 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AFSPAJGOW6LMG4NG4YYFATLSNMSKFANCNFSM4CYSDQ4Q>.
|
|
''' <VirtualHost *:85>
NameVirtualHost *:80 ''' James |
Well that went even more wrong than I thought!! Sorry :) James |
What went wrong?
I see I need to install mod_proxy for this to work.
I'll check out the tutorials.
(I think your link was broken. No big deal, job for Google).
…-------- Original message --------
From: jadakin <[email protected]>
Date: 10/31/20 3:20 PM (GMT-05:00)
To: bren1818/TCPLightingWebInterface <[email protected]>
Cc: Merrick Weintraub <[email protected]>, Mention <[email protected]>
Subject: Re: [bren1818/TCPLightingWebInterface] Comments, Questions, open forum (2) (#6)
Also, what does the gwproxy.com represent?
…
As Paul says, it's not necessary, just use the the IP address.
This might be helpful:
[https://www.digitalocean.com/community/tutorials/how-to-use-apache-as-a-reverse-proxy-with-mod_proxy-on-debian-8(url)
You can ignore the bits about load balancing setup, but ISTR enabling the mod_proxy and mod_proxy_http modules as it describes - that may be what you're missing?
The rest of my conf files relates to running Bren's TCP control on port 85. I can't see it will help, but for what it's worth: (sorry, also not an expert at Git - don't know why it's formatting it oddly!)
'''
<VirtualHost *:85>
# The ServerName directive sets the request scheme, hostname and port that
# the server uses to identify itself. This is used when creating
# redirection URLs. In the context of virtual hosts, the ServerName
# specifies what hostname must appear in the request's Host: header to
# match this virtual host. For the default virtual host (this file) this
# value is not decisive as it is used as a last resort host regardless.
# However, you must set it for any further virtual host explicitly.
#ServerName www.example.com<http://www.example.com>
ServerAdmin webmaster@localhost
DocumentRoot /var/www/html
# Available loglevels: trace8, ..., trace1, debug, info, notice, warn,
# error, crit, alert, emerg.
# It is also possible to configure the loglevel for particular
# modules, e.g.
#LogLevel info ssl:warn
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
# For most configuration files from conf-available/, which are
# enabled or disabled at a global level, it is possible to
# include a line for only one particular virtual host. For example the
# following line enables the CGI configuration for this host only
# after it has been globally disabled with "a2disconf".
#Include conf-available/serve-cgi-bin.conf
NameVirtualHost *:80
<VirtualHost :80>
ServerName gwproxy.com
SSLProxyEngine On
SSLProxyCheckPeerName off
SSLProxyCheckPeerExpire off
RequestHeader set Front-End-Https "On"
CacheDisable /
ProxyPass /gwr https://192.168.1.29:443/gwr
ProxyPassReverse /gwr https://192.168.1.29:443/gwr
RedirectMatch ^/$ http://gwproxy.com/gwr
'''
James
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub<#6 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AFSPAJADFXAUP43PWHHBWI3SNRPOPANCNFSM4CYSDQ4Q>.
|
The quoting and formatting got all screwed up, but you've got the gist. James |
Enable Home Assistant Birth Message
Closed the last topic as it had gotten really lengthy. Opening this one for more questions
The text was updated successfully, but these errors were encountered: