Floorplan for Home Assistant

I’ll give adding the # a try. All the entity names match the names in HASS exactly. I’ll also see if I can add a new layer and then move all the entities to that layer.

I just imported your SVG into my HA and changed the id of your lights to match mine, and they worked perfectly. I don’t think it has anything to do with your SVG. Must be naming conventions or the YAML file

@shire210 so labels don’t matter? Good to know.

Nope! Not in my experience. More of a user friendly name to use.

@atomicpapa I created a new floorplan.yaml to test the basics. Ran my HA with this floorplan yaml and your SVG and the two test lights worked. I would suggest replacing your floorplan.yaml with the code from below and change the light entities to match your lights and see if that works. I do not have camera linked to test them, but this should give you a good starting point to build off of.

floorplan.yaml (884 Bytes)

So I am officially an idiot. I had accidentally overwritten my edited floorplan.yaml with the sample floorplan.yaml. It just so happens that 2 of my cameras are named exactly like the 2 cams in the sample that were working. You may all begin laughing now.

5 Likes

To what version did you downgrade to??

Any updates on floorplan not working on IOS?

I went down to 0.48.1, but that was probably overkill. 0.49 should also work.
I went down this far as with higher versions floor plan would work on my new iPad but not old one, so kept trying. Once I reached 48 and it still didn’t work I gave up…
Once you figure out the trick on how to downgrade it is really quick, so I would just go one step at a time and see if it works. Avoid the xx.0 versions and use the xx.1 or XX.2 versions.
Look at my post history if you have issues downgrading.

help me out if you can please.
How do I add multiple classes to a state?

I was trying to have my cars show up when they are home and hide when not_home (I got that done).
but now… I created a sort of spinner with the zone.state inside to show when the car is not_home and hide when it is home.
the problem that im having is that when I had this spinner to the equation everything shows up all the time.
here is my configs.

Floorplan.yalm

    - name: Devices
      entities:
        - device_tracker.jizar_nil
        - device_tracker.jizar_jizar
      states:
        - state: 'home'
          class: 'visible'
        - state: 'not_home'
          class: 'invisible'
          
    - name: Location
      entities:
         - sensor.nil
         - sensor.jizar
      text_template: '${(entity.state)}'
      states:
        - state: 'not_home'
          class: 'visible'
        - state: 'home'
          class: 'invisible'
     
    - name: spinner
      entities:
         - sensor.nilspin
         - sensor.jizarspin
      states:
        - state: 'not_home'
          class: 'visible','spin'
        - state: 'home'
          class: 'invisible'

floorplan.css

.visible {
opacity: 100 !important;
visibility: visible !important;
}

.invisible {
opacity: 0 !important;
visibility: hidden !important;
}

.spin {
transform-origin: center;
-webkit-animation: rotation 2s infinite linear;
}

Hello, I’m trying to get it to work, so far I loaded the 3 files in WWW folder and uploaded my SVG but when I go to floorplan its empty. I don’t have anytime configure yet I just want to make sure I can see my SVG floorplan in home assistant

panel_custom:
  - name: floorplan
    sidebar_title: Floorplan
    sidebar_icon: mdi:home
    url_path: floorplan
    config: !include floorplan.yaml

and I have these on my floorplan.yaml

name: Demo Floorplan
image: /local/custom_ui/floorplan/floorplan.svg
stylesheet: /local/custom_ui/floorplan/floorplan.css

This should be enough to display my svg?

Did you include the lib folder? See my earlier comment in this thread:

Thank you DDK, That did the trick.

1 Like

tested stable version 0.50.2 - also the new update (0.52.0) doesn’t change anything here

sup guys, I’m trying to add my cars to my floorplan, but I use many zones on my config and also the Google map track addon to show street’s name.
I want to make my states: to recognize the right command but having no luck with it. can anyone help?

heres what I got right now.

  • name: Devices
    entities:
    - device_tracker.jizar_nil
    - device_tracker.jizar_jizar
    states:
    - state: template
    value_template: ‘{{ states.entity.state != “home” }}’
    class: ‘invisible’

anything else I can try?

Quick help please, I’m in the beginning process I have the lights working

but now im trying to add the temperate but it’s not working

this is what I have

- name: thermostat_temp
  entities:
    - climate.home_upstairs_thermostat_nest          
  text_template: '${entity.attributes.current_temperature ? Math.ceil(entity.attributes.current_temperature) + "°": "undefined"}'
  class_template: 'return "static-temp";'

also in my floorplan, i don’t see the room names like living room, dining room kitchen etc.

I have temp map to climate.home_upstairs_thermostat_nest in my svg FYI

1 Like

here is how it looks in home assistant, XX supoosed to display my temp from the nest

where it says “climate.home_upstairs_thermostat_nest” you have to edit to the device you have reading the temperature.
in my case :

  • name: Sensors
    entities:
    - sensor.motion_sensor_temperature
    - sensor.dark_sky_temperature
    text_template: ‘${entity.state ? Math.ceil(entity.state) : “undefined”}’

How do set up sensors that have different types of output? Using the example above, 2 sensors that have numbers for output vs a door/window sensor that has text output. Do you setup 2 different sensor sections?

- name: Sensors

blah blah

- name: Sensors (2?)

blah blah

Hello everyone
Big fan of Floorplan ! it works perfectly.
I am not sure if i am missing something here but is there a way to deal with covers ?
If i declare an action as:
domain: cover
service: close_cover
it works! but I can only get one action (open or close), where I expected to have the choice to open/shut/stop …

Thanks for clarifying this to me

Anything you left as text won’t display, you need to convert it to a path: Path -> Object to path

I’d also suggest turning on the warnings in floorplan.yaml, that really helps.