Question-and-Answer Resource for the Building Energy Modeling Community
Get started with the Help page
Ask Your Question
2

what is the key value for built-in variable: ActualDateAndTime, CurrentTime, ActualTime?

asked 2021-02-02 21:48:23 -0600

ep_user's avatar

updated 2021-02-03 07:57:45 -0600

I am trying to get the handle of build-in variables for: ActualDateAndTime, CurrentTime, ActualTime.

I am using:

handle =  self.api.exchange.get_internal_variable_handle(state, CurrentTime, key_value).

Where i can find those key-values? Thanks.

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2021-02-03 07:21:15 -0600

You seem to be confusing built-in variables with internal variables.

Internal variables are specific to an EnergyPlus object and therefore require a variable_type and a variable_key using self.api.exchange.get_internal_variable_handle(state, variable_type, variable_key).

Built-in variables like ActualDateAndTime are unrelated to EnergyPlus objects. The Data Transfer API provides specific methods for each. For example, you'd use self.api.exchange.actual_date_time(state) to get ActualDateAndTime.

You can read more about built-in variables and internal variables in the EMS Application Guide.

edit flag offensive delete link more

Comments

1

thanks! I appreciate that. It looks like the outputs for ActualDateAndTime, CurrentTime, ActualTime are integers. I am looking for some outputs like: 2/1/2020 3:00:00. Is it doable?

ep_user's avatar ep_user  ( 2021-02-03 10:54:14 -0600 )edit

It looks like the outputs for ActualDateAndTime, CurrentTime, ActualTime are all integer values. I am expecting something to be like: 5/1/2020 9:05:00. Is it doable?

ep_user's avatar ep_user  ( 2021-02-03 12:27:57 -0600 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Training Workshops

Careers

Question Tools

1 follower

Stats

Asked: 2021-02-02 21:48:23 -0600

Seen: 188 times

Last updated: Feb 03 '21