Temperature display

Discussion in 'C-Bus Wiser 1 Controller' started by jdriver, Feb 19, 2014.

  1. jdriver

    jdriver

    Joined:
    Oct 24, 2013
    Messages:
    4
    Likes Received:
    0
    Location:
    UK
    Sorry if i'm being a bit dim here, but I'm struggling to find a way of displaying temperatures from 8 thermocouples spread around the building. Each of the thermocouples has a group and a zone ID through HVAC manager, and each of these can be seen dutifully plodding out a temperature in toolkit log. What I want to do is create a widget for each thermocouple which will display on the Android app.

    I've searched the widget form for a simple display but can only find the 'Climate Control' widget, which is too big and complex. Is that all there is, or am I missing something?
     
    jdriver, Feb 19, 2014
    #1
  2. jdriver

    Roosta

    Joined:
    Nov 22, 2011
    Messages:
    560
    Likes Received:
    1
    Location:
    Australia
    Last edited by a moderator: Feb 19, 2014
    Roosta, Feb 19, 2014
    #2
  3. jdriver

    djaggar

    Joined:
    Jul 18, 2009
    Messages:
    66
    Likes Received:
    0
    Location:
    New Zealand
    If you define a string variable called TempString in Logic then this code in a module (perhaps with a delay statement as well to update it every second or so)

    Code:
      format(TempString,(GetLightingLevel("ACRoomTemp") * 0.1):2:1,' ?C');
      SetStringSystemIO("AC Room Temp", TempString);
    will set the IO variable called "AC Room Temp" to one tenth of the value of the Lighting Group "ACRoomTemp" i.e. ACRoomTemp holds a value with is ten times the temperature, so needs to be formatted to one decimal place for corrent display. Display that value with a SystemIOInteger widget which allows you to title the value ...
     
    djaggar, Feb 20, 2014
    #3
  4. jdriver

    bmerrick

    Joined:
    Jun 13, 2007
    Messages:
    434
    Likes Received:
    34
    Location:
    Sydney
    Hi Jdriver,

    To display temps on my Wiser GUI, I use a small bit of logic code in the Wiser, (mostly modified from an earlier NickD post).


    Power Temp Module
    Code:
    once (Second = 59) then // IMPORTANT - don't run this code every cycle - once a minute is ample
      begin
        r_temp := GetRealIBSystemIO("Measurement App Real Value", 254, 4, 1);
        Format(s_temp, r_temp:2:1);
        Append(s_temp, ' C');
        SetStringSystemIO("Pool Temp Display", s_temp);
        r_temp1 := GetRealIBSystemIO("Measurement App Real Value", 254, 4, 2);
        Format(s_temp1, r_temp1:2:1);
        Append(s_temp1, ' C');
        SetStringSystemIO("Pool Solar Feedwater Display", s_temp1);
        r_temp2 := GetRealIBSystemIO("Measurement App Real Value", 254, 4, 3);
        Format(s_temp2, r_temp2:2:1);
        Append(s_temp2, ' C');
        SetStringSystemIO("Pool Solar Reservoir Display", s_temp2);
      end;
    

    Don't forget to define the variables in Global Variables in the logic engine:

    r_temp : real;
    s_temp : string;
    r_temp1 : real;
    s_temp1 : string;
    r_temp2 : real;
    s_temp2 : string;


    You also need to create the System IOs (under Project - Edit System IOs) and widgets (under Project - Widget Manager) seen in the 2 attached JPGs.

    This gives you text based output on the Wiser GUI, whatever the client (PC, iPhone, Android etc). See JPG 3.

    You will need to read the HVAC group temps into the variables in logic rather than just the measurement manager temps I am using but you can plug any information into the SystemIOs that you want.

    Good Luck with that,

    Brad
     

    Attached Files:

    Last edited by a moderator: Feb 20, 2014
    bmerrick, Feb 20, 2014
    #4
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.