Buildings.Controls.OBC.OutdoorLights
Package with models for outdoor lighting controls
Information
This package contains outdoor lighting controllers.
Extends from Modelica.Icons.Package (Icon for standard packages).
Package Content
Name | Description |
---|---|
DaylightControlled | Controlling the outdoor lighting based on whether the sun is up |
Validation | Collection of models that validate the outdoor lighting controllers |
Buildings.Controls.OBC.OutdoorLights.DaylightControlled
Controlling the outdoor lighting based on whether the sun is up
Information
This block outputs on/off control signals for outdoor lighting devices based on daylight time. The outdoor lights will be automatically turned off during daylight hours, and turned on when there is no daylight.
Validation
A validation can be found at Buildings.Controls.OBC.OutdoorLights.Validation.DaylightControlled.
Parameters
Type | Name | Default | Description |
---|---|---|---|
Real | lat | lat(final quantity="Angle", ... | Latitude [rad] |
Real | lon | lon(final quantity="Angle", ... | Longitude [rad] |
Real | timZon | timZon(final quantity="Time"... | Time zone of location [s] |
Connectors
Type | Name | Description |
---|---|---|
output RealOutput | y | Output true if lights should be on [1] |
Modelica definition
block DaylightControlled "Controlling the outdoor lighting based on whether the sun is up"
parameter Real lat(
final quantity="Angle",
final unit="rad",
displayUnit="deg") "Latitude";
parameter Real lon(
final quantity="Angle",
final unit="rad",
displayUnit="deg") "Longitude";
parameter Real timZon(
final quantity="Time",
final unit="s",
displayUnit="h") "Time zone of location";
CDL.Interfaces.RealOutput y(
final min = 0,
final max = 1,
unit="1") "Output true if lights should be on";
protected
CDL.Utilities.SunRiseSet sunRiseSet(
final lat=lat,
final lon=lon,
final timZon=timZon) "Output next sunrise and sunset time, and whether the sun is up";
CDL.Logical.Not not1 "Logical not";
CDL.Conversions.BooleanToReal booToRea "Boolean to real converter";
equation
connect(sunRiseSet.sunUp, not1.u);
connect(not1.y, booToRea.u);
connect(booToRea.y, y);
end DaylightControlled;