DLT with Logic Help

Discussion in 'General Discussion' started by connectedsmart, Feb 24, 2014.

  1. connectedsmart

    connectedsmart

    Joined:
    Oct 10, 2012
    Messages:
    29
    Likes Received:
    1
    Location:
    Queensland
    I have conceded and decided to purchase a Cooler Master to control a VRF system.

    However I want to be able to control the fan speed of the aircon in each zone by a DLT. For example:

    Press Button - Fan Speed Low
    Press Button Again - Fan Speed Medium
    Press Button Again - Fan Speed High
    Press Button Again - (WE ARE BACK TO LOW AGAIN).

    Not only do I want to be able to send the command I want the screen to be able to display the speed that is set (I am not using any feedback from the coolermaster to generate the feedback text).

    I was wondering how you would do this in Logic. I have read the guide on C-Bus labels but still am confused.

    I WILL POST WHAT I HAVE BUT MY LOGIC IS NOT WORKING. AND AM HOPING SOMEONE CAN HELP ME DEBUG

    I know that doing this is possible as the premisis inwhich I am implementing this used to have Switch Automation which provided the same functionality.
     
    connectedsmart, Feb 24, 2014
    #1
  2. connectedsmart

    Roosta

    Joined:
    Nov 22, 2011
    Messages:
    560
    Likes Received:
    1
    Location:
    Australia
    This is code of mine from an install.. Yous hsould be able to adapt to suit..

    global variables:
    CounterFan : integer;


    Initialisation:
    CounterFan := 0;


    Module 'fan control'
    Once (GetLightingState("BBQ Fans")=OFF) THEN
    BEGIN
    CounterFan:=0;
    Setlightinglevel("BBQ Fans",0%,"0s");
    end;

    If (GetLightingLevel("BBQ Fans")= 255) THEN
    BEGIN
    CounterFan:= CounterFan+1;
    CASE CounterFan of
    1:begin
    Setlightinglevel("BBQ Fans",60%,"0s");
    SetstringIBSystemIO("Label Group Text","Network 254","Lighting","BBQ Fans",0,'Fan - Low');
    end;
    2:begin
    Setlightinglevel("BBQ Fans",75%,"0s");
    SetstringIBSystemIO("Label Group Text","Network 254","Lighting","BBQ Fans",0,'Fan - Med');
    end;
    3:begin
    Setlightinglevel("BBQ Fans",99%,"0s");
    SetstringIBSystemIO("Label Group Text","Network 254","Lighting","BBQ Fans",0,'Fan - High');
    end;
    4:begin
    Setlightinglevel("BBQ Fans",0%,"0s");
    SetstringIBSystemIO("Label Group Text","Network 254","Lighting","BBQ Fans",0,'Fan - Off');
    end;
    5:Counterfan:=0;
    End;
    end;

    If CounterFan>=4 then
    begin
    CounterFan:=0;
    Setlightingstate("BBQ Fans",OFF);
    END;

    Cheers..
     
    Roosta, Feb 24, 2014
    #2
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.