Current Date:17 June, 2021

How to configure Home Assistant to use Bureau of Meteorology (BOM) data

Home assistant can pull data from the Bureau of Meteorology (BOM) using the Home Assistant integration. All we need to do is add some configuration code, upload a few files and then configure lovelace to show the weather using this data. I’ll also show you how to display the forecast cards in Home Asssitant using lovelace and BOM data.

After following this guide, you should have a lovely looking weather card displayed on your home screen which will look like this:

Home Assistant BOM Weather Card

Let’s get to it!

Finding out the nearest BOM weather station

Before we get to configuring the weather card, we need to find the nearest BOM weather station which we will use as the source of data. For this example we will use Melbourne Airport as our nearest radar.

  1. Visit the BOM website.
  1. Now select VIC.
  1. Click on MELBOURNE AREA LATEST OBSERVATIONS.
  1. The nearest radar in this example is MELBOURNE AIRPORT so let’s select it.
  1. Now we need to look at the URL in the address bar of your browser for this weather station to get the ID. To do this we need to see the ID before the .shtml extension.
  1. So in the above example our ID would be IDV60901.94866 however for our other sensor, we need to disregard the number after the .
station: IDV60901.94866
product_id: IDV60901
  1. Keep note of these two values as we will use them shortly.

Configure Home Assistant to use the BOM integration

  1. Open up your CONFIGURATION.YAML file
  2. We need to add the following code to your SENSOR section and replace STATION with the station ID above.
# Sensors
sensor:
  - platform: bom
    station: IDV60901.95874
    monitored_conditions:
      - apparent_t
      - cloud
      - cloud_base_m
      - cloud_oktas
      - cloud_type_id
      - delta_t
      - gust_kmh
      - gust_kt
      - air_temp
      - dewpt
      - local_date_time
      - local_date_time_full
      - press
      - press_qnh
      - press_msl
      - press_tend
      - rain_trace
      - rel_hum
      - sea_state
      - swell_dir_worded
      - swell_height
      - swell_period
      - vis_km
      - weather
      - wind_dir
      - wind_spd_kmh
      - wind_spd_kt
  - platform: bom_forecast
    product_id: IDV60901
    name: Melbourne
    forecast_days: 6
    rest_of_today: True
    friendly: True
    friendly_state_format: '{max}, {summary}'
    monitored_conditions:
      - 'max'
      - 'min'
      - 'chance_of_rain'
      - 'possible_rainfall'
      - 'summary'
      - 'detailed_summary'

INFORMATION!

Ensure you replace the station and product_id with the values you noted in step 6 above.

  1. Save your changes.

Adding the LoveLace custom compontents for the weather card

Next, we will add the customisation to make LoveLace show the BOM weather cards with the forecasts. Bremor has created an awesome GitHub project which we will leverage.

  1. Visit his GitHub page and download his project
  2. Extract the zip file
  3. Navigate to the unzipped location
  4. We need to find the custom_components folder
  5. Navigate to CONFIGURATOR > CUSTOM_COMPONENTS (If you don’t have this folder, create it)
  6. Create the bom_forecast folder inside the CUSTOM_COMPONENTS folder
  7. Upload the following files into the bom_forecast folder
    • sensor.py
    • manifest.json
    • init.py
  8. Restart home assistant

Adding the weather forcast card to Home Assistant

Now that we have everything in place, we can get to configuring the OVERVIEW page.

  1. Click on OVERVIEW
  2. Click on the 3 dot menu
  3. Click on CONFIGURE UI
  4. Click ADD
  5. Select the ENTITIES CARD
  6. Configure the card using the following settings:
  1. Click SAVE

You should now have the following weather card:

Home Assistant BOM Weather Card

Customising the names of BOM Sensors in Home Assistant

To change the names of the sensors from BOM “nameofsensor” to something more human readable, perform the following:

  1. Open up CONFIGURATION
  2. Click on CUSTOMIZATION
  3. Find the sensors starting with BOM
  4. Click on NAME and change the name to your liking
  1. Now go back to OVERVIEW and you should see the updated name of the sensor. Repeat the steps for the other BOM sensors as you please.

INFORMATION:

If you’re not able to customise the sensors, you may be missing the CUSTOMIZE.YAML file inside your CONFIG folder. Follow these steps.

Extra Configuration Options

For more configuration options visit the BOM Australia Home Assistant Documentation

SUPPORT ME!

If you’d like to support TECHmarC, or if you’re using an adblocker, I ask you to consider whitelisting my website.

The ads displayed on this site help go towards keeping the website alive. I know its a small ask but every little contribution helps! You can also support me by Buying me a Coffee!

 

Buy me a coffeeBuy me a coffee