天气图标可用作普通符号。这些可以通过以下方式直接作为值传递给可视化:
"_weather_ICON"
此时,字符串必须从VISU变量由PLC传递到图像元素。所有OpenWeatherMap接口的符号都直接受支持。
有以下几种计算方式:
| 字符串 | 描述 |
|---|---|
| "_weather_01n" | 返回OpenWeatherMap符号。 |
| "_weather_800" | 高精度的昼夜无关符号。 |
| "_weather_day-800" | 高精度的昼间符号。 |
| "_weather_night-800" | 高精度的夜间符号。 |
下面的示例显示了在PLC中计算符号。如果使用ID而不是符号,可以提高精度。
![]()
翻译表显示了所有符号及其对应的ID。要在可视化中输出一个符号,必须指定完整路径。例如 weather/thunderstorm
| ID | 符号 |
|---|---|
| 200, 201, 202, 230, 231, 232 | thunderstorm |
| 210, 211, 212, 221 | lightning |
| 300, 301, 321, 500 | sprinkle |
| 302, 311, 312, 314, 501, 502, 503, 504 | rain |
| 310, 511, 611, 612, 615, 616, 620 | rain-mix |
| 313, 520, 521, 522 | showers |
| 531, 901 | storm-showers |
| 600, 601, 621, 622 | snow |
| 602 | sleet |
| 701, 741 | fog |
| 711 | smoke |
| 721 | day-haze |
| 731, 761, 762 | dust |
| 771, 801, 802, 803 | cloudy-gusts |
| 800 | day-sunny或night-clear |
| 804 | cloudy |
| 781, 900 | tornado |
| 902 | hurricane |
| 903 | snowflake-cold |
| 904 | hot |
| 905 | windy |
| 906 | hail |
| 957 | strong-wind |