Animating Smart Home Devices with Floorplan for Homeassistant

I’ve always been fascinated by how technology can bring our homes to life, and recently I stumbled upon something truly amazing while exploring Homeassistant. The Floorplan for Homeassistant integration has completely transformed how I interact with my smart devices, and I wanted to share my experience with you all.

A few weeks ago, I decided to create an animated visualization of my heating system. I’ve been using Floorplan to map out various entities in my home, but I wanted to take it a step further by adding some dynamic animations. The result? Pure magic!

Here’s how I did it:

  1. Designing the SVG Layout: I started by sketching out my heating system components in Inkscape, a free and powerful vector graphics editor. I mapped out my solar thermal setup, ground-source heat pump, and even the central ventilation system. The key was to create a layout that was both visually appealing and functional.

  2. Bringing It to Life with Code: Using the Floorplan for Homeassistant integration, I linked each SVG element to its corresponding entity in Homeassistant. For example, my heat pump now has a pulsating animation that changes color based on its power consumption. The code was surprisingly straightforward. Here’s a snippet of what I used:

yaml

  • entity: sensor.heat_pump_power
    element: heat_pump
    state_action:
    action: call-service
    service: floorplan.class_set
    service_data:
    class: “$(entity.state > 10) ? ‘active’ : ‘’”
  1. The End Result: The final dashboard is not only functional but also visually engaging. My family loves watching the heat pump “work” in real-time, and it’s been a great way to educate them about our home’s energy systems. The best part? It’s incredibly smooth and responsive, thanks to the optimized animations and SVG rendering.

I’d love to hear if anyone else has tried something similar or has tips for enhancing these animations further. Whether it’s adding more complex animations or integrating other systems, the possibilities are endless!

Cheers to the endless creativity of the Homeassistant community! :tada: