Component: BBC Weather Observation (Comms: IoT/Cloud): Difference between revisions
m Text replacement - "class="wikitable" style="width:60%; background-color:#FFFFFF;"" to "class="mtx-class-macrotable wikitable"" |
m Text replacement - "width="90%" style="background-color:#D8C9D8; color:#4B008D;"" to "width="90%" class="mtx-class-macrohead"" |
||
| (2 intermediate revisions by the same user not shown) | |||
| Line 93: | Line 93: | ||
{| class="mtx-class-macrotable wikitable" | {| class="mtx-class-macrotable wikitable" | ||
|- | |- | ||
| width="10%" align="center" | | width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-comp-macro.png]] | ||
| width="90%" | | width="90%" class="mtx-class-macrohead" | '''GetHumidity''' | ||
|- | |- | ||
| colspan="2" | Reads the reported humidity in Relative Humdity. | | colspan="2" | Reads the reported humidity in Relative Humdity. | ||
| Line 107: | Line 107: | ||
{| class="mtx-class-macrotable wikitable" | {| class="mtx-class-macrotable wikitable" | ||
|- | |- | ||
| width="10%" align="center" | | width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-comp-macro.png]] | ||
| width="90%" | | width="90%" class="mtx-class-macrohead" | '''GetLocationName''' | ||
|- | |- | ||
| colspan="2" | Reads the reported location name as a string. | | colspan="2" | Reads the reported location name as a string. | ||
| Line 121: | Line 121: | ||
{| class="mtx-class-macrotable wikitable" | {| class="mtx-class-macrotable wikitable" | ||
|- | |- | ||
| width="10%" align="center" | | width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-comp-macro.png]] | ||
| width="90%" | | width="90%" class="mtx-class-macrohead" | '''GetPressure''' | ||
|- | |- | ||
| colspan="2" | Reads the reported air pressure in milli bar (mb). Please note this data may not be available for your selected location. | | colspan="2" | Reads the reported air pressure in milli bar (mb). Please note this data may not be available for your selected location. | ||
| Line 135: | Line 135: | ||
{| class="mtx-class-macrotable wikitable" | {| class="mtx-class-macrotable wikitable" | ||
|- | |- | ||
| width="10%" align="center" | | width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-comp-macro.png]] | ||
| width="90%" | | width="90%" class="mtx-class-macrohead" | '''GetTemperature''' | ||
|- | |- | ||
| colspan="2" | Reads the reported temperature in the selected scale. | | colspan="2" | Reads the reported temperature in the selected scale. | ||
| Line 154: | Line 154: | ||
{| class="mtx-class-macrotable wikitable" | {| class="mtx-class-macrotable wikitable" | ||
|- | |- | ||
| width="10%" align="center" | | width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-comp-macro.png]] | ||
| width="90%" | | width="90%" class="mtx-class-macrohead" | '''GetWindDirection''' | ||
|- | |- | ||
| colspan="2" | Reads the reported wind direction as a string. Please note this data may not be available for your selected location. | | colspan="2" | Reads the reported wind direction as a string. Please note this data may not be available for your selected location. | ||
| Line 168: | Line 168: | ||
{| class="mtx-class-macrotable wikitable" | {| class="mtx-class-macrotable wikitable" | ||
|- | |- | ||
| width="10%" align="center" | | width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-comp-macro.png]] | ||
| width="90%" | | width="90%" class="mtx-class-macrohead" | '''GetWindSpeed''' | ||
|- | |- | ||
| colspan="2" | Reads the reported wind speed in MPH. Please note this data may not be available for your selected location. | | colspan="2" | Reads the reported wind speed in MPH. Please note this data may not be available for your selected location. | ||
| Line 182: | Line 182: | ||
{| class="mtx-class-macrotable wikitable" | {| class="mtx-class-macrotable wikitable" | ||
|- | |- | ||
| width="10%" align="center" | | width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-comp-macro.png]] | ||
| width="90%" | | width="90%" class="mtx-class-macrohead" | '''Initialise''' | ||
|- | |- | ||
| colspan="2" | Sets up the component ready to collect weather data. | | colspan="2" | Sets up the component ready to collect weather data. | ||
| Line 196: | Line 196: | ||
{| class="mtx-class-macrotable wikitable" | {| class="mtx-class-macrotable wikitable" | ||
|- | |- | ||
| width="10%" align="center" | | width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-comp-macro.png]] | ||
| width="90%" | | width="90%" class="mtx-class-macrohead" | '''RequestData''' | ||
|- | |- | ||
| colspan="2" | Requests data about your selected location from the BBC weather service. Returns true if the request was successful. Must be called before trying to call any of the GetXXX macros. | | colspan="2" | Requests data about your selected location from the BBC weather service. Returns true if the request was successful. Must be called before trying to call any of the GetXXX macros. | ||
| Line 210: | Line 210: | ||
{| class="mtx-class-macrotable wikitable" | {| class="mtx-class-macrotable wikitable" | ||
|- | |- | ||
| width="10%" align="center" | | width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-comp-macro.png]] | ||
| width="90%" | | width="90%" class="mtx-class-macrohead" | '''SetLocationCode''' | ||
|- | |- | ||
| colspan="2" | Allows the location code to be altered from the default location code set in the component properties. After changing the location the RequestData macro must be called to refresh the forecast variables. | | colspan="2" | Allows the location code to be altered from the default location code set in the component properties. After changing the location the RequestData macro must be called to refresh the forecast variables. | ||
| Line 230: | Line 230: | ||
{| class="mtx-class-macrotable wikitable" | {| class="mtx-class-macrotable wikitable" | ||
|- | |- | ||
| width="10%" align="center" | | width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-prop-icon.png]] | ||
| width="90%" | | width="90%" class="mtx-class-macrohead" | '''Properties''' | ||
|- | |- | ||
|- | |- | ||
Latest revision as of 14:23, 13 July 2026
| Author | MatrixTSL |
| Version | 1.0 |
| Category | Comms: IoT/Cloud |
BBC Weather Observation component
Easily allows you to collect observed weather metrics for your area using the BBC Weather data service. Supports temperature and humidity, pressure, Wind direction etc for your selected area. Also available are Wind Direction, Wind Speed and Air Pressure but please note these are not always available depending on your selected area. This component is used for data gathering from the internet.
Component Source Code
Please click here to download the component source project: FC_Comp_Source_BBCWeatherObservation.fcfx
Please click here to view the component source code (Beta): FC_Comp_Source_BBCWeatherObservation.fcfx
Detailed description
No detailed description exists yet for this component
Examples
Here is a basic example to read the observation data and report the Manchester weather information for today and tomorrow, on a graphical display.
The location can be set by adjusting the BBC Weather location property, see the component property tooltips for more information on how to do this.
On an embedded device you would need a TCP/IP component to allow the communications to the BBC server. This then links to the Network Comms component.
Macro reference
GetHumidity
| GetHumidity | |
| Reads the reported humidity in Relative Humdity. | |
| Return | |
GetLocationName
| GetLocationName | |
| Reads the reported location name as a string. | |
| Return | |
GetPressure
| GetPressure | |
| Reads the reported air pressure in milli bar (mb). Please note this data may not be available for your selected location. | |
| Return | |
GetTemperature
| GetTemperature | |
| Reads the reported temperature in the selected scale. | |
| Scale | |
| 0 = Celcius, 1 = Farenheit | |
| Return | |
GetWindDirection
| GetWindDirection | |
| Reads the reported wind direction as a string. Please note this data may not be available for your selected location. | |
| Return | |
GetWindSpeed
| GetWindSpeed | |
| Reads the reported wind speed in MPH. Please note this data may not be available for your selected location. | |
| Return | |
Initialise
| Initialise | |
| Sets up the component ready to collect weather data. | |
| Return | |
RequestData
SetLocationCode