DIY Geiger Counter Integration with Home Assistant

Hey everyone, I wanted to share my recent project integrating a DIY Geiger Counter with Home Assistant. It’s been a fun and educational experience, and I hope it might inspire others to try something similar!

I purchased the DIY Geiger Counter kit from Banggood and decided to connect it to my existing HA setup. The kit includes a Geiger tube, a preamplifier, and some basic components. I also added a DHT22 sensor to monitor temperature and humidity alongside radiation levels.

The Setup

I used an Arduino Nano to interface with the Geiger Counter and DHT22 sensor. The data is sent via serial to my Raspberry Pi running Home Assistant. Here’s a snippet of the code I wrote:

python
/* Geiger Counter and DHT22 Sketch */
#include “DHT.h”
#define DHTPIN 4
#define INTPIN 2
#define DHTTYPE DHT22

// Code continues with setup and loop functions…

Integration with HA

The serial data is read by Home Assistant using the serial platform. I configured the sensors in my configuration.yaml:

yaml
sensor:

  • platform: serial
    name: nano
    serial_port: /dev/serial/by-id/usb-1a86_USB_Serial-if00-port0
    baudrate: 115200

I then used templates to extract individual values like counts per minute (CPM) and microsieverts per hour (µSv/h). Here’s an example of one of the template configurations:

yaml
template:
sensor:
- name: geiger_count_total_from_startup
state: “{{ states(‘sensor.nano’).split(‘,’)[0] | float(default=0) }}”
icon: mdi:radioactive

Results

After a few days of testing, the system is running smoothly. I’ve set up a Lovelace dashboard to display the radiation levels, temperature, and humidity in real-time. It’s been fascinating to see how environmental factors can influence radiation readings.

I’d love to hear if anyone else has tried something like this or has suggestions for improvements! Feel free to reach out in the comments.