more G-Labs products

Author Topic: Advanced Smart Lights  (Read 20539 times)

November 22, 2015, 01:21:40 AM
Reply #60

bkenobi

  • *****
  • Information
  • Global Moderator
  • Posts: 1525
ASL works with r501.  There was a change to HG in 1.1 that caused asynchronous tasks to not work correctly with X10 (and other systems in the future).  Either way, if you use r496 through r500 ASL won't work correctly.

December 18, 2015, 04:18:43 PM
Reply #61

[email protected]

  • *****
  • Information
  • Hero Member
  • Posts: 271
Meant to ask, is it possible to use multiple sensors to control one light, or maybe have any sensor in a group turn on all lights within a group?

Thinking outside lighting :)

December 18, 2015, 05:14:57 PM
Reply #62

bkenobi

  • *****
  • Information
  • Global Moderator
  • Posts: 1525
Sure can.  I use 2 motion sensors to control the same light.  There are 2 ways to do that (with X10 anyway). 

  • Set motion sensor to the same address
  • Set motion sensor names to same base name

If you set both/all motion sensors to the same HC/UC then any motion will be reported as the same motion sensor in HG and will operate the light(s) as though it was a single motion sensor.

Or, if you set the linked motion sensors to the same base name, then the code will be able to use them all and you get to see them as separate sensors in HG (e.g., "south motion 1", "south motion 2", "south motion 3", etc.).  I use this approach.

If you use either approach, make sure you set the code to "motion triggers on ON" so that OFF signals from an area you moved out of do not cause the lights to go out on you when you are in a different sensors zone.

If you want to have multiple lights controlled by the same sensors, just use the same setup on multiple light modules.  You will have to duplicate the settings, but it works just fine.

December 20, 2015, 02:20:41 PM
Reply #63

[email protected]

  • *****
  • Information
  • Hero Member
  • Posts: 271
I'm not using x10, just using GPIO on the raspberry pi.

December 20, 2015, 04:31:32 PM
Reply #64

bkenobi

  • *****
  • Information
  • Global Moderator
  • Posts: 1525
I use X10 and RPi GPIO.  I have not tested other systems.  The ASL code *SHOULD* work on every type of system, but it hasn't been tested.  I used the HG name to reference components so you should be able to mix and match what you use as you want.  If you find something that does/doesn't work, you could post here and I (or someone experienced with that tech) could try to fix it.

December 21, 2015, 11:19:11 AM
Reply #65

[email protected]

  • *****
  • Information
  • Hero Member
  • Posts: 271
Ok, will have a bit of a read of the code and work out how I can do it and give it a test :)

January 04, 2017, 05:08:14 AM
Reply #66

texasaggie97

  • *
  • Information
  • Newbie
  • Posts: 11
My situation is slightly different so I have made a couple of modifications to ASL. I don't know if you are still maintaining this or not.

They can be found on https://github.com/texasaggie97/advanced-smart-lights.

In particular the changes I made were:
  • Module selection now uses HG feature to pick from list of appropriate modules
  • Allow using a module of type switch to control the light (I am using a ZWave switch)
  • Allow the "motion detection" module be a Zone Sensor. This change is not actually zone sensor specific. Since ZWave modules can be renamed, additionally check for match based on Domain + Address

I did not fix use of obsoleted functions (at least not yet).

I know this thread hasn't had any activity in a while but I didn't see a better place to put this and it didn't seem like it deserved it's own post.

January 04, 2017, 05:14:03 AM
Reply #67

bkenobi

  • *****
  • Information
  • Global Moderator
  • Posts: 1525
I'm not exactly maintaining it, so your updates are much appreciated. I plan on updating my HG installation for testing soon so I'll try your updates.

January 04, 2017, 05:46:39 AM
Reply #68

texasaggie97

  • *
  • Information
  • Newbie
  • Posts: 11
Thank you for Advanced Smart Lights. It was almost exactly what I needed.

If you put this on GitHub somewhere I can send you a pull request.

January 04, 2017, 06:00:39 AM
Reply #69

bkenobi

  • *****
  • Information
  • Global Moderator
  • Posts: 1525
I have a github.com account and will put it on there with my other codes. it may take a little bit, but I'll get it up there.

January 06, 2017, 05:44:15 PM
Reply #70

bkenobi

  • *****
  • Information
  • Global Moderator
  • Posts: 1525
My laptop crashed last summer and apparently I didn't set up Github again.   I had it all working with my other stuff (Arduino based projects) but something changed in the new application where I can't figure it out now.  I can create a repository but can't upload files or see my other repos.  If/when I get that figured out, I'll upload all of my scripts and make them public.

January 12, 2017, 01:38:39 PM
Reply #71

[email protected]

  • *****
  • Information
  • Hero Member
  • Posts: 271
I've had similar issues with the github desktop app.. I ended up dragging the files into the repo in a web browser..

I hate the github desktop app! visual studio's integration is better..

January 12, 2017, 04:44:56 PM
Reply #72

bkenobi

  • *****
  • Information
  • Global Moderator
  • Posts: 1525
I tried to use the web interface but I wasn't able to figure out how to edit the repo that way.  That's when I installed the desktop app...which was worse!  I used both in the past and didn't have issues so maybe I got dumb over the last year.   :o

January 15, 2017, 03:07:39 AM
Reply #73

bkenobi

  • *****
  • Information
  • Global Moderator
  • Posts: 1525
I don't know why Github is so complicated now, but I was able to get the web interface to allow me to upload my scripts.  I still can't figure out the new Windows app.  It worked GREAT last time I tried it but now it's just a steaming pile of garbage.  Anyway, the scripts are all located in my signature.

January 15, 2017, 11:35:55 AM
Reply #74

raptorjr

  • ***
  • Information
  • Full Member
  • Posts: 78
You have made some good things bkenobi.

I wonder if there is any place to collect all good user HG scripts? Even if you are a active poster and your signature show up in many places, many good scripts are hidden and forgotten in old threads. Hard for new users to start digging around to find them.