Skip to content

amaximus/radioactivity_hu

Repository files navigation

hacs_badge

Buy me a coffee

Home Assistant custom integration for Radioactivity data for Hungary

This custom component integrates radioactivity information provided by Disaster Recovery Directorate (Katasztrófavédelem).

The state of the sensor will be the level of the environmental radioactivity. Thresholds are defined on the bottom of the page Háttérsugárzás - Aktuális adatsor

Installation

The easiest way to install it is through HACS (Home Assistant Community Store), search for Radioactivity Hungary in the Integrations.

Configuration:

Define sensor with the following configuration parameters:


Name Optional Default Description
name Y radioactivity_hu name of the sensor
station Y `` name of the measuring station (see below)

Measuring station name should match the 'Állomás' specified at Háttérsugárzás - Aktuális adatsor. When not set the component will scan all active stations with measurement data not older than two days and the state of the sensor will be the highest level of measurement from this set of stations. The attributes (station, last_measurement_time) will be set as per the station with the highest level of measurement.

Example of radioactivity information:

Radioactivity attributes

Examples

platform: radioactivity_hu

Example Lovelace UI custom button card:

type: custom:button-card
color_type: icon
show_label: true
show_name: false
show_icon: true
entity: sensor.radioactivity_hu
size: 30px
styles:
  label:
    - font-size: 90%
    - text-align: left
  card:
    - height: 80px
  icon:
    - color: >
        [[[
          var r_val = states['sensor.radioactivity_hu'].state;
          if ( r_val > 500 ) {
            return "red";
          } else if ( r_val > 250 ) {
            return "var(--paper-item-icon-active-color)";
          }
          return "var(--paper-item-icon-color)";
        ]]]
label: radioaktivitás

Radioactivity button

Thanks

Thanks to all the people who have contributed!

contributors