PAC Stops Running

Discussion in 'C-Bus Wired Hardware' started by Andy1967, Oct 8, 2017.

  1. Andy1967

    Andy1967

    Joined:
    Apr 22, 2017
    Messages:
    15
    Likes Received:
    0
    Location:
    Wigan
    I have set up a dimmer channel to 3 different levels, 2 by DLT buttons and 1 by Multi Sensor.
    I have created a pseudo group 200 in the PAC which is activated with any of the DLT buttons to disable the PIR when the dimmer is enabled by any of the DLT buttons.
    The logic works for several cycles i.e. push one of the buttons group 200 PIR disable appears in the application log and the lights stay at the desired level when walking below the sensor.
    However after a while the sensor disable appears to stop. i.e. push one of the buttons and the lights ramp to the desired level but walk below the sensor and the light level changes to match the level setpoint desired by PIR activity and the disable group 200 stops appearing in the application log.
    Its as if the PAC has stopped running soon after logging off it.
    Powering down and back up also allows the logic to work for several cycles but
    the problem returns shortly after.
    Any help appreciated, Cheers .
     
    Andy1967, Oct 8, 2017
    #1
  2. Andy1967

    Ashley

    Joined:
    Dec 1, 2005
    Messages:
    1,548
    Likes Received:
    178
    Location:
    Adelaide, Australia
    We may have some chance of helping if you post the actual logic :)
     
    Ashley, Oct 8, 2017
    #2
  3. Andy1967

    NickD Moderator

    Joined:
    Nov 1, 2004
    Messages:
    1,427
    Likes Received:
    64
    Location:
    Adelaide
    As well as Ashley's suggestion..

    If you have a spare interface, download the Diagnostic utility and see what you see going on on the bus.

    My guess is that you may be using if statements instead of once statements and your queue is filling up.

    Nick
     
    NickD, Oct 9, 2017
    #3
  4. Andy1967

    Andy1967

    Joined:
    Apr 22, 2017
    Messages:
    15
    Likes Received:
    0
    Location:
    Wigan
    Thanks for your replies.
    I didn't put the logic on as I was trying to keep the post brief.
    I will check for if statements and try the diagnostic utility and post any results I see and the logic.
    Cheers.
     
    Andy1967, Oct 10, 2017
    #4
  5. Andy1967

    Andy1967

    Joined:
    Apr 22, 2017
    Messages:
    15
    Likes Received:
    0
    Location:
    Wigan
    I haven't had chance to run the diagnostics yet but please see logic below for any ideas
    I have created 2 modules.
    Module 1. to disable the PIR by switching a group address 200 (kitchen PIR
    disable "ON" when the kitchen lights are at 20% or 60% which are the 2 levels that can be set by the DLT.

    once(Get Lighting Level("Kitchen Ceiling")=20% or
    (Get Lighting Level("Kitchen Ceiling")=60% then
    begin
    Set Lighting State ("Kitchen PIR Disable",ON);
    end;

    The other switches the group address 200(kitchen PIR disable "OFF" when the kitchen lights are at 0% or 25% which is the level set by the multi sensor.

    once(Get Lighting Level("Kitchen Ceiling")=0% or
    (Get Lighting Level("Kitchen Ceiling")=25% then
    begin
    Set Lighting State ("Kitchen PIR Disable",OFF);
    end;
    The group address is then used in the disable setting of the multi sensor.
    As I said earlier the logic seems to work fine for a short while then stops and only restarts when I log on and off or power down/up.
    Hope this is clear.
    Many Thanks !
     
    Andy1967, Oct 11, 2017
    #5
  6. Andy1967

    NickD Moderator

    Joined:
    Nov 1, 2004
    Messages:
    1,427
    Likes Received:
    64
    Location:
    Adelaide
    I don't follow the logic..

    Once you operate the DLT, the PAC disables the Multisensor....

    In order to re-enable the Multisensor, the PAC needs to see one of the levels from the Mutlisensor... but it's disabled?

    How can the latter ever happen?

    Nick
     
    NickD, Oct 12, 2017
    #6
  7. Andy1967

    Andy1967

    Joined:
    Apr 22, 2017
    Messages:
    15
    Likes Received:
    0
    Location:
    Wigan
    Hello Nick.
    Thanks for your reply.
    I think my wording may have mislead you.
    The 0% comes when the DLT times out or is turned off then the multi sensor should enable ready for the next movement.

    The problem I am having is also not with the multi sensor failing to enable but the opposite i.e. enabling when it shouldn't and driving the lights to 25% when the DLT has driven them to 60% or 20%.
    Cheers !
     
    Last edited by a moderator: Oct 12, 2017
    Andy1967, Oct 12, 2017
    #7
  8. Andy1967

    Andy1967

    Joined:
    Apr 22, 2017
    Messages:
    15
    Likes Received:
    0
    Location:
    Wigan
    Does anyone have any more ideas on this one. I've checked the traffic and its quite low with the thing causing much activity is the multi sensor which sends frequent messages when activated. The problem disappears when I log on with the following sequence of events.

    1:Starts with the logic not working.
    2:Open Piced and check the log which includes the following messages (in order but some missed for clarity): Start Log. Log TX C Bus Yes (in red). Log RX C bus Yes (in blue). Start Power Fail recovery. End Power Fail Recovery. Logic Engine Started.
    At this point the logic still doesn't work and there are no messages from C Bus.
    3:Close the log. Click Options then Connect to C Bus.
    4: Recheck logs which read Connect to C Bus. Time Mastering Start Up. And and various messages from C Bus including any GA's I enable via DLT buttons or PIR and the Disable PIR GA when appropriate. The logic also starts to work and the lighting works correctly for quite a while with many events happening i.e button presses, PIR movements etc.
    5: I close down Piced and the logic and lights stop working correctly.

    Any help appreciated.
    Regards.
     
    Andy1967, Oct 23, 2017
    #8
  9. Andy1967

    NickD Moderator

    Joined:
    Nov 1, 2004
    Messages:
    1,427
    Likes Received:
    64
    Location:
    Adelaide
    The only 2 things I can think of are

    1) Something is causing the PAC to stop. Does the status indicator keep flashing? Perhaps you can put some code in to drive the other (user) indicator to help debug?

    2) The PIR is being retriggered in between the DLT sending the level that the PAC received to disable the PIR and the PAC actually sending the message to disable the PIR. I can't remember the exact details but I recall some issues where the PIR gets disabled while its timer is still running. It doesn't seem like this should be the problem but you never know.

    It might help to separate the group controlling the light itself and the groups used by the DLT and the PIR. This does introduce a dependency on the PAC running to make the light actually turn on, but it's probably going to be easier to get working how you want.

    Use one group for the DLT, another for the PIR, and another for the actual light.

    In the logic, when the DLT group gets set, disable the PIR, turn the PIR's group off, and set the light to the right level.

    When the DLT group gets turned off, enable the PIR, set the light to the level you want, and then let the PIR take over when it's triggered.

    Rinse, repeat.

    Nick
     
    NickD, Oct 24, 2017
    #9
  10. Andy1967

    Ashley

    Joined:
    Dec 1, 2005
    Messages:
    1,548
    Likes Received:
    178
    Location:
    Adelaide, Australia
    You seem to be saying that it runs fine when you have PICED running. I assume this means you also have the PAC logic running in PICED at the same time which is a bad ides as both will compete with each other. Make sure you turn off the logic in PICED if you want to test to PAC. Whenever you test logic in PICED, turn off the PAC. Rather than use the PICED logs, use the CBUS diagnostic. You can filter out just the gas you are interested in and then just let it run until it fails and see what is going on.

    As an aside, you don't really need the PAC at all. Just use the logic in the output unit. I'm assuming you are using 20% and 25% just so you can tell them apart in logic rather than for the tiny light level difference. Set up the DLT as normal to control the light and make sure it works. Set up the sensor on a different ga and remove the enable ga (so it's permanently enabled). Set it's level to 20% the same as the DLT.
    In the output unit, go to the logic tab and enter the sensor ga on the first line, click the channel the light is on and select MAX for dimmers or OR for relays. If the DLT is on it will control the light, if it's off the sensor will control the light.
     
    Ashley, Oct 24, 2017
    #10
  11. Andy1967

    Andy1967

    Joined:
    Apr 22, 2017
    Messages:
    15
    Likes Received:
    0
    Location:
    Wigan
    Thanks a lot to you both for those ideas. I'll give them a try and let you know any results.
    Cheers.
     
    Andy1967, Oct 24, 2017
    #11
  12. Andy1967

    Andy1967

    Joined:
    Apr 22, 2017
    Messages:
    15
    Likes Received:
    0
    Location:
    Wigan
    I think this one is resolved, Thanks for your help.
    It seems the programme hadn't transferred properly.
    Your comment on the logic running partly in PICED led me to the solution.
    I transferred the project again and its run correctly for almost a week.
    Thanks Again.
    Andy.
     
    Andy1967, Oct 29, 2017
    #12
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.