Your Home Digital Twin: Interactive floor 3d plan

You can post the console log to an issue in GitHub ? Never tested on MacOS, but it should be OS independent, it is based on a JS library. There could be some HW Acceleration nuances, but not with only two entities

Apologies for the late reply but I took me some time to confirm what you suggested and I also believed myself too. I reinstalled Windows on my old computer and I can confirm that it is OS independent and I somewhere have a bug in my code.

Yes, absolutely. I use it as my main dashboard! Thank you!

1 Like

Good day Adizanni, Yes, I have the card on one of the tabs in HA, but do not use it as it does not load on my iPhone or any of my older wall tablets. On the computer it takes 3 minutes or longer to load. Its a pity since I put long hours making it work, but unusable.

I know, if the model is too heavy the card shows its limits. You need to strike a balance between the quality of the rendering and the performances. I use mine as the home page for my HA and it loads fast, but I reduced the model to the bare minimum and still I think it is nice and useful.

Yes… Allowing an option for the card to open a default floor when using a multi floor model. e.g. 3 floors in a model but want floor 2 to open as the default view.

Hi
I am trying to make a dashboard with a sidebar card to the left with a meny and the rest of the screen to the right i use floor-card.
This works nice on the desktop but on my tablet the floor card is more to the left and the sidebar hides a part of it.
Why ?
I have tried alot to make this work but it will not.
I am using Panel:True and i have tried many variants of combining CSS styles and Card-mod but it’s always the same. It will not work between different resolutions.
Maybe the sidebar card i use on GitHub - DBuit/sidebar-card do something.
Are there somebody who knows ?

Have you tried @media queries to pick up different screen sizes?
See this post for how to use. Also see CSS left, right or padding to possibly move your card.

One thing I have noticed with the card when setting a camera view is it does not look the same on different devices. You are better off creating a conditional card that is specific to each screen resolution.

Hello @adizanni,

I’m using it as a view to my HA installation. The rendering speed relays on the client used. A 20Mb GLB model is well handled by a Rpi4 with 4Mb and fairly fast rendered by a modern (less than 5 years old) client computed with an average GPU.

There is a library called DRACOloader that is used to compress and uncompress threejs models: three.js docs. It is possible that the Digital Twin could benefit from this library. Keep on this awesome card.

1 Like

Thanks Andrew.
Yes it looks like i have to use @media queries.
I used this and changed height and margin-top in a card-mod.
It looks like this works.

1 Like

I am pleased to hear

Hi
I can see somebody have used Browser mod for popup.
I could only do this with gesture and running a script with browser mod configuration.
This works great.
The problem is that browser mod popup shows on all screens.
I know that to get this work on active screen i have to use a fire-dom-event.
This i have not succided to configure with floor card and gesture.

Anybody who have an ide on how to do this ?

I do not know how to confine the browser mod popup to the active screen. It’s not really an issue for me, since I typically only have one screen open, but please let me know if you figure it out.

For what it’s worth, here’s the script for one of my popup cards.

alias: 3D Family Room
sequence:
  - data:
      card_mod:
        style:
          ha-dialog$: |
            div {          
              background-color: transparent !important;
            }
      content:
        type: custom:stack-in-card
        mode: vertical
        card_mod:
          style:
            .: |
              ha-card {
                --ha-card-background: #637f8a60;
                --paper-item-icon-color: white;
                backdrop-filter: blur(4px);
                border-radius: 15px;
                color: white;
              }              
        cards:
          - type: custom:room-card
            title: Family Room
            card_mod:
              style:
                .: |
                  ha-card {
                    color: white;
                    --primary-text-color: white;  
                  }               
            templates:
              - name: t1
                template:
                  show_icon: true
                  state_color: true
                  styles:
                    color: white
                  tap_action:
                    action: toggle
              - name: t2
                template:
                  show_icon: true
                  state_color: true
                  styles:
                    color: white
                  tap_action:
                    action: more-info
            info_entities:
              - entity: switch.amplifier_switch
                icon: mdi:surround-sound
                show_icon: true
                name: Amplifier
              - entity: sensor.amplifier_power
            entities:
              - entity: switch.mini_plug_with_power_meter_2
                name: Bookcase Light
                icon: mdi:wall-sconce-flat
                template: t1
              - entity: switch.in_wall_paddle_switch_qfsw_700s_11
                icon: mdi:server-network
                name: Closet Light
                template: t1
              - entity: switch.desklight_switch
                name: Desk Lamp
                icon: mdi:wall-sconce-flat
                template: t1
              - entity: switch.fr_fan_light_x
                name: Fan Light
                icon: mdi:ceiling-fan-light
                template: t1
              - entity: switch.kauf_plug_12
                name: Floor Lamp
                template: t1
              - entity: switch.shellyplugus_b48a0a1b633c_switch_0
                name: Table Lamp
                icon: mdi:lamp
                template: t1
              - entity: fan.fr_helper_fan
                name: Fan
                template: t2
              - entity: switch.amplifier_switch
                icon: mdi:audio-video
                template: t1
              - entity: remote.family_room_tv
                icon: mdi:television-classic
                name: TV
                show_icon: true
                tap_action:
                  action: call-service
                  service: script.3d_tv_fr
      size: normal
    action: browser_mod.popup
icon: mdi:lightbulb
mode: single

Yes this is something similar to what i have.
But it popup on all screens.

Yes i will tell you if i figure it out.

For now i have set a destination inside the script and the dashboard link is opened with ?BrowserID=Dashboard in the end ,this will be the name of the registered browser , in this way popup always shows on that screen.
But in this way if i want to show the popup on a other screen it will not work.

I think this will have a simple answer.

I have a light object that has been split into 52 separate objects:

KitchenCeilingLight_1 to KitchenCeilingLight_52

If I click on the light object, I could get any of these 52 objects. For my first attempt at setting this object up, I am linking to just 1 of these.

  - entity: light.kitchen_ceiling_bulbs
    type3d: light
    object_id: KitchenCeilingLight_1
    light:
      lumens: "1500"

If I click KitchenCeilingLight_1 or indeed turn it on via the entity itself, the light on the plan does turn on.

I would like to have as little code as possible so do not want 51 copies of this.

I realise there is an object group. Can I add these to a single group and use the group name instead. eg

  - object_group: KitchenCeilingLights
    objects:
      - object_id: KitchenCeilingLight_1
'
'
      - object_id: KitchenCeilingLight_52

  - entity: light.kitchen_ceiling_bulbs
    type3d: light
    object_id: KitchenCeilingLights
    light:
      lumens: "1500"

I ask the question because I tried it and it did not seem to even show any light in the plan when I turned on the light but did not have errors when loading

This should be bracketed with greater-than and less-than signs:

object_id: <KitchenCeilingLights>

Not sure if case matters, but perhaps keep everything lower case, e.g. kitchenceilinglights, as well.