operating a fan with delayed turnoff

Discussion in 'C-Touch/HomeGate/SchedulePlus/PICED Software' started by Neil C, Nov 7, 2007.

  1. Neil C

    Neil C

    Joined:
    Jun 27, 2007
    Messages:
    46
    Likes Received:
    0
    I need to provide a function using C-bus, which is probably a common requirement, in that I need to power on a bathroom fan when a light is switched on. Then when the bathroom lights are extinguished, the fan needs to run for several minutes before it is turned off. The lights will be connected to a c-bus dimmer, and the fan to a c-bus relay.

    As there is a PAC on this installation, I thought that one way around this might be to write some custom code using this. Does anybody have any ideas or examples on how to go about this?

    Alternatively, can anybody suggest another way around this problem? There isn't a touch screen on this system, but if one was installed, could this be somehow programmed to provide the function necessary?

    Thanks
     
    Neil C, Nov 7, 2007
    #1
  2. Neil C

    amberelectrics

    Joined:
    Aug 29, 2007
    Messages:
    114
    Likes Received:
    0
    There is example code included in toolkit 1.7.2

    Its really easy to implement on a PAC and the example code should give you a good start, just customise the delays to suit.
     
    amberelectrics, Nov 7, 2007
    #2
  3. Neil C

    Custom

    Joined:
    Apr 7, 2005
    Messages:
    39
    Likes Received:
    0
    Example Logic

    There is a good example in Piced 4 > Projects > Examples > Logic > Toilet Fan.

    Cheers
     
    Custom, Nov 7, 2007
    #3
  4. Neil C

    znelbok

    Joined:
    Aug 3, 2004
    Messages:
    1,151
    Likes Received:
    17
    This was covered in the old V2 manual (run on timer). It has been requested a few times here since toolkit has been introduced. A PAC is not required

    Please do a search for more info

    Mick
     
    znelbok, Nov 7, 2007
    #4
  5. Neil C

    NickD Moderator

    Joined:
    Nov 1, 2004
    Messages:
    1,427
    Likes Received:
    64
    Location:
    Adelaide
    As Mick points out, you can achieve this with just the switch, and there is an example in the Toolkit help which explains this (search on "Bathroom Service").

    However.. I have tried using this at home, and most people that have used it have commented that the 2 second the delay between pushing the light button and the light going off is quite disconcerting. You can't reduce this much, because it's hitting the limits of the timer resolution in the switch (Don may correct me here), and it can have unpredictable results (sometimes the light will turn itself back on).

    It sounds a bit like overkill, but using the PAC may give you better results.

    If you go the logic route, it would be pretty simple... the pseudo-code would be something like

    once {bathroom light on}
    {turn bathroom fan on}

    once {bathroom light off}
    {pulse fan group on for 5 minutes}

    Nick
     
    NickD, Nov 8, 2007
    #5
  6. Neil C

    BookMaker

    Joined:
    Jun 23, 2006
    Messages:
    3
    Likes Received:
    0
    An example exists in Toolkit Help

    There is an example of what you want to program in Toolkit. Follow the steps to get to the example:
    Click F1 to view Toolkit Help
    Click on the Help Topics button, the Contents page appears in the Contents tab
    Click on the Tutorials book
    Click on 'Using timers within key input units'
    Click on 'Control of lights and fans with timers'

    Alternatively, use the Index tab and type: 'Control of lights and fans with timers'

    Let me know if you can't find it.
     
    BookMaker, Nov 8, 2007
    #6
  7. Neil C

    TSI-Michael

    Joined:
    Oct 18, 2007
    Messages:
    1
    Likes Received:
    0
    CTC Logic to do the job ...

    I did the following a few months ago and have been using it very successfully since then. Create a Module (give it some meaningful name) and fill in your Tag names and times.

    It turns the fan (Relay - R19_18) on if the lights (Dimmer - D18_17) stay above 75% for more than 2.5 minutes and then turns the fan off when the light goes off. The light is controlled by a PIR with a 2 minute off timer after last movement.

    1 once (GetLightingLevel("Guest Bath D18_017") > 75%) then
    2 begin
    3 Delay("0:02:30");
    4 if (GetLightingLevel("Guest Bath D18_017") > 75%) then
    5 begin
    6 SetLightingState("Guest Bath R19_018", ON);
    7 end;
    8 end;
    9
    10 once (GetLightingLevel("Guest Bath D18_017") = 0%) then
    11 begin
    12 SetLightingState("Guest Bath R19_018", OFF);
    13 end;

    I put lines 1 to 8 in one module and lines 10 to 13 in another.

    I don't know for sure but I guess something similar would work in the PAC too.

    Regards,
    Michael
     
    TSI-Michael, Nov 29, 2007
    #7
  8. Neil C

    znelbok

    Joined:
    Aug 3, 2004
    Messages:
    1,151
    Likes Received:
    17
    I had this going for a while and never had any delay that I can remember, not did the light come back on.

    I will have to dig out the old manual and set it up again.

    I still believe the PAC is an overkill.

    Mick
     
    znelbok, Nov 29, 2007
    #8
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.