SimTX API/Packets/WeatherMapResponse
Appearance
| Frame | ServerFrame, field 33
|
|---|---|
| Member | weather_map
|
| Direction | Server → client |
| Session | Control |
| Roles | ROLE_CONTROL.
|
| Permission | None |
| Answers | WeatherMapRequest |
| Defined in | control.proto
|
WeatherMapResponse returns the raster requested by a WeatherMapRequest, with a summary of the weather at the centre of the area.
Definition[edit | edit source]
message WeatherMapResponse {
int64 request_id = 1;
int64 valid_time_ms = 2;
string type = 3; // weather type (string enum, common.proto)
double south_latitude_deg = 4;
double north_latitude_deg = 5;
double west_longitude_deg = 6;
double east_longitude_deg = 7;
int32 width = 8;
int32 height = 9;
repeated float values = 10;
float surface_temperature_celsius = 11;
float surface_pressure_hpa = 12;
float surface_relative_humidity_percent = 13;
float surface_wind_meters_per_second = 14;
float maximum_rain_rate_millimeters_per_hour = 15;
float maximum_cloud_water_grams_per_cubic_meter = 16;
float cape_joules_per_kilogram = 17;
float lightning_flashes_per_minute = 18;
string duct_type = 19; // duct type (string enum, common.proto)
float duct_base_meters = 20;
float duct_top_meters = 21;
float duct_strength_m_units = 22;
float duct_gradient_m_units_per_kilometer = 23;
}
Fields[edit | edit source]
| # | Field | Type | Description |
|---|---|---|---|
| 1 | request_id |
int64 |
The request this answers. |
| 2 | valid_time_ms |
int64 |
Simulated time the data is valid for, Unix ms. |
| 3 | type |
string |
Map type, as requested. |
| 4 | south_latitude_deg |
double |
Southern edge. |
| 5 | north_latitude_deg |
double |
Northern edge. |
| 6 | west_longitude_deg |
double |
Western edge, normalised to (−180, 180]. |
| 7 | east_longitude_deg |
double |
Eastern edge, normalised to (−180, 180]. |
| 8 | width |
int32 |
Raster columns. |
| 9 | height |
int32 |
Raster rows. |
| 10 | values |
repeated float |
width × height values in the unit of the map type, row-major. Always finite.
|
| 11 | surface_temperature_celsius |
float |
At the centre: surface temperature, °C. |
| 12 | surface_pressure_hpa |
float |
At the centre: surface pressure, hPa. |
| 13 | surface_relative_humidity_percent |
float |
At the centre: relative humidity, percent. |
| 14 | surface_wind_meters_per_second |
float |
At the centre: wind speed, m/s. |
| 15 | maximum_rain_rate_millimeters_per_hour |
float |
At the centre: highest rain rate in the column, mm/h. |
| 16 | maximum_cloud_water_grams_per_cubic_meter |
float |
At the centre: highest cloud water content in the column, g/m³. |
| 17 | cape_joules_per_kilogram |
float |
At the centre: convective available potential energy, J/kg. |
| 18 | lightning_flashes_per_minute |
float |
At the centre: lightning rate, flashes/min. |
| 19 | duct_type |
string |
Duct type of the strongest duct at the centre, or NONE.
|
| 20 | duct_base_meters |
float |
Duct base height, m. NaN without a duct. |
| 21 | duct_top_meters |
float |
Duct top height, m. NaN without a duct. |
| 22 | duct_strength_m_units |
float |
Duct strength, M-units. 0 without a duct. |
| 23 | duct_gradient_m_units_per_kilometer |
float |
Steepest modified-refractivity gradient in the duct, M-units/km. NaN without a duct. |
Raster layout[edit | edit source]
Values are stored row-major (index = row × width + column) and sampled at grid nodes that include the edges of the area:
latitude = north − (north − south) × row / (height − 1)
longitude = west + (east − west ) × column / (width − 1)
Row 0 is the northern edge and the last row the southern edge; columns run west to east. North and south are clamped to ±90°. When the area crosses the antimeridian, west_longitude_deg is greater than east_longitude_deg; add 360° to the eastern edge before interpolating. For a 360° span the two edges are equal.
Raster values are always finite. The duct summary fields may be NaN as described in the field table.