Anyway to rescan or retrigger sensor sunset function?

Discussion in 'C-Bus Toolkit and C-Gate Software' started by hh75, Apr 3, 2009.

  1. hh75

    hh75

    Joined:
    Jan 18, 2009
    Messages:
    11
    Likes Received:
    0
    I use one switch button by the Master bedside to ramp off all lights in the house at bedtime by issuing a shutter close command to a logic Group which is assigned to the Area field of each lighting relay. It works great but there are two circuits I'd like to keep going through the night. At the moment these lights come on at sunset by control of an outside PIR and should go off again at sunrise.

    The problem with how I've done this is that the Master off command turns off the relays for these outside lights regardless of what the outside sensor thinks the sun is doing. Then because it is still dark outside, the sensor holds its state and doesn't retrigger the relay back on.

    It wouldn't be trivial to rewire both lights to a separate relay which I didn't control with the Area field. Therefore I'm wondering if anyone knows more detail on how the sunset/sunrise function in the sensors works, and if there is a way to rescan or retrigger the sensor to check if it is dark again and restart the relay channels for just my 2 lights?
     
    hh75, Apr 3, 2009
    #1
    1. Advertisements

  2. hh75

    Lucky555

    Joined:
    Aug 13, 2007
    Messages:
    229
    Likes Received:
    0
    hh,

    RampOff commands to an area address is (by today's standards) a pretty coarse way to get multi channel (scene style) control.

    It sounds like you do not have a unit in your system that is capable of a scene. The cheapest way of achieving a scene would be to but an advanced key input unit like a neo, saturn etc. If you are thinking of dishing out for an additional relay unit use the money for a scene capable key input or better still lash out and buy a B&W touch screen and you will be introduced to the "real world" / real power of C-Bus. If you really want to treat yourself buy a unit that includes the world acclaimed logic engine. Then the only challenge will be dreaming up convenient functions to set up.

    I have been lobbying Government to pass a law to make it illegal to have a house full of C-Bus without unleashing its true power via a touch screen or logic module. - Stay tuned... ;)
     
    Lucky555, Apr 4, 2009
    #2
    1. Advertisements

  3. hh75

    hh75

    Joined:
    Jan 18, 2009
    Messages:
    11
    Likes Received:
    0
    thanks for the reply.

    Actually house is a couple years old but in last few weeks I have installed a MKI B&W screen and a PACA. So, this being the case, and seeing you are such a stalwart promoter of the logic engine ;-) are you able to give me a quick explanation of a basic easy way of setting up a bedside switch as a master off function (where I exclude my two sunset lights from the master off)?

    Cheers
     
    hh75, Apr 4, 2009
    #3
  4. hh75

    znelbok

    Joined:
    Aug 3, 2004
    Messages:
    1,104
    Likes Received:
    8
    I would have said the opposite.

    Lets say you want to turn off all your lights just like the OP does and you have 60 lights in the house, thats 60 friggin' groups you have to add to a scene.

    Assigning them to an era and ramping the area off is much faster and simpler.

    I would have thought that ramping and area would also reduce the traffic on the network.

    I personally would like to see channels being assigned to an area as opposed to a whole module.

    Mick
     
    znelbok, Apr 4, 2009
    #4
  5. hh75

    hh75

    Joined:
    Jan 18, 2009
    Messages:
    11
    Likes Received:
    0
    Thanks Mick - I'm certainly a believer in less is more myself.

    Would you have any knowledge on how the sunset/sunrise function in the sensors works, and if there is a way to rescan or retrigger the sensor to check if it is dark again and restart the relay channels for just my 2 lights?
     
    hh75, Apr 4, 2009
    #5
  6. hh75

    filpee

    Joined:
    May 31, 2006
    Messages:
    204
    Likes Received:
    0
    Location:
    Western Australia
    Just curious but would this work if you assigned the sunset group address to OR logic in the relay/dimmer rather then the output channel? Will the Area address override this?

    You could do something like this in logic.

    Once (sunsetGA AND MasterOff) then
    begin
    setLightingState(myRelayChannels,ON)
    end;

    (note: dont trust my syntax)

    You may need a wait in there.

    Or the touch panel supports large scenes so you use your bed switch to fire a scene (in the tp) to turn off everything. Combine the Area and individual GA's to reduce the amount of traffic on the network.

    Being able to map channels to an Area would be alot more useful though.
     
    filpee, Apr 4, 2009
    #6
  7. hh75

    Lucky555

    Joined:
    Aug 13, 2007
    Messages:
    229
    Likes Received:
    0
    Once you get under the hood on the C-Bus protocol you will find that ramping off area addresses is a quick way to do things but as I said by today's standard is a pretty coarse way to do things - the original reason for this thread is may case in point. In my place I have a relay unit in the garage and other relay units upstairs. One channel of the relay unit in the garage does an outside porch light while another unit upstairs does another porch light directly above the first. The two output channels have the same group address to make the two porch lights switch as one. There are two key input units with the same group address, again up and down stairs. Now if I was to ramp off the area address of the garage relay unit the lights would go off including the downstairs porch light however after 3 x MMI periods (won't go into MMI's here) the channel on the garage relay corresponding to the porch light would come back on. SO,,, ramping area addresses is coarse in its control and can produce what appears to be funky behavior.

    For a residential application where you have a scene capable unit, stick to scenes for multi channel control. You can see what is / going to happen and you have a better resolution of control.

    Here is how I would do it.

    Set up the button you want as your Goodnight with a GA like "Trig_GoodNight". Now here is the clever bit ,,,,,,,, make the button a 15 second timer.

    Teamed with the code below you will have a convenient 10 second delay between pushing the button and all the lights going off. Allows you to jump into bed, pull the covers up nice and high then all the lights ramp off slowly.

    If you press the button by mistake (or in my case the kids press the button with the rest) you can simply press it again inside the 10 seconds and every thing stays where it is.

    Set up the associated scene to ramp off the groups you want off. If you really must ramp off area addresses then they can be in the scene as well, you will have to leave the area address off the unit with your outside lights and add the rest of the GA's.

    I am pretty sure the boys of the brains trust (CIS) would steer you down this path. Happy programming...

    Code:
    if ConditionStaysTrue(GetLightingState("Trig_GoodNight") = ON, 10 ) then
    begin
      SetScene("Goodnight");
      SetLightingState("Trig_GoodNight", OFF);
    end;
    P.S. Forget mucking around with the outdoor LL/PIR sensor, the solution above fixes your issue.

    P.S #2 That "ConditionStaysTrue" feature is nothing short of bloody brilliant ! ;)
     
    Last edited by a moderator: Apr 5, 2009
    Lucky555, Apr 5, 2009
    #7
  8. hh75

    Lucky555

    Joined:
    Aug 13, 2007
    Messages:
    229
    Likes Received:
    0
    That's a "friggin" big house...:p

    And as the original post shows, in residential you don't usually want to drop the whole place (outside and in) into darkness in one hit...
     
    Last edited by a moderator: Apr 5, 2009
    Lucky555, Apr 5, 2009
    #8
  9. hh75

    Lucky555

    Joined:
    Aug 13, 2007
    Messages:
    229
    Likes Received:
    0
    I am pretty sure scenes use concatenated messages - so don't worry about reducing traffic when using scenes...
     
    Lucky555, Apr 5, 2009
    #9
  10. hh75

    Lucky555

    Joined:
    Aug 13, 2007
    Messages:
    229
    Likes Received:
    0
    Come on guys, I make up a bit of technical mumbo jumbo about MMI's and concatenated messages and you all go quiet.
    You will give me a reputation as a thread killer :(

    BTW - you are welcome :rolleyes:
     
    Lucky555, Apr 9, 2009
    #10
  11. hh75

    hh75

    Joined:
    Jan 18, 2009
    Messages:
    11
    Likes Received:
    0
    Lucky555 - sorry - thank you for your posts and work. Very elegant slim code that I'm looking forward to trying out next time I can get some 'home' time.

    Cheers
     
    hh75, Apr 10, 2009
    #11
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.