Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

The example player_recorder.glm doesn't work

stan
2013-01-16
2013-03-16
  • stan
    stan
    2013-01-16

    Hi,
      I have installed the trunk code in svn and tried to run the example player_recorder.glm in course/demo. The glm is like:

    module residential;
    module tape;

    clock {
    timezone PST+8PDT;
    timestamp '2001-01-01 0:00:00';
    }

    module residential;
    module tape;

    object house:1 {
    heating_setpoint 40degF;
    cooling_setpoint 90degF;
    }
    object player {
    parent house:1;
    property cooling_setpoint;
    file theat.csv;
    loop 100; //loop for 100 days but does not move the time stamp
    }
    object recorder{
    parent house:1;
    property air_temperature,cooling_setpoint;
    file theat_record.csv;
    interval 7200;
    limit 48;
    }
    .

    When I run this, I got like:

    stan@stan-PC:~/Downloads/gridlabd courses/Demo/2.2$ gridlabd player_recorder.glm
    WARNING   : house_e:0 has no parent triplex_meter defined; using static voltages
    stan@stan-PC:~/Downloads/gridlabd courses/Demo/2.2$

    And there is no output file related with it. 
    But when I change the clock block above to

    clock {
    timezone PST+8PDT;
    timestamp '2000-01-01 0:00:00';
    }
    it can run and gives the output file.  Can someone explain to me why this happens?

    Thanks

     
  • As a general rule, the course material is designed for the current stable release (V2.2).  Trunk is not supported by the course material yet.  Whatever the problem is, it is likely to be addressed when the validation process for V3.0 is completed.

     
  • Jason Fuller
    Jason Fuller
    2013-01-16

    Stan,

    I imagine <a bit of a guess, here> that this might have to do with some of the tinkering we've been doing with the clock in v3.0.  We did a little re-defining of some of the clock variables to be more inline with what was originally intended.

    Try changing the "timestamp" variable to "starttime", and I believe you will see better results.

    The reason for this is that in v2.3 and previous, "timestamp" and "starttime" were used synonymously, however, they were originally intended to mean two different things."starttime" is now the correct way to kick off your clock.

     
  • stan
    stan
    2013-01-16

    Thank you so all your replies!