🔹 Browser_mod - turn your browser into a controllable device, and a media_player

But not with the spotify media items right?

Yes, you need to select media player and then select spotify media player. So you need Spotify integration as well: https://www.home-assistant.io/integrations/spotify/

The screenshot you is Spotify media.

And the media browser card will update if media player Spotify is selected?

What do you mean? It’s the media browser exactly like in the sidebar, but now in Lovelace through iframe. Nothing more, nothing less :).

1 Like

does anyone know how to retrieve the page number on which the browser is positioned?
example: / lovelace / 1 rather than / lovelace / 2 where 1 or 2 is the page number.
I need to create a template to give the command to go to the next page, like if I in page 1:

service: browser_mod.navigate
service_data:
   navigation_path: / lovelace / 2

@byxil WallPanel app has such a feature, it provides info where the browser is positioned via mqtt.
I use it to return browser to the default page and no problem at all.

Tks,

They are trying to get it avaialble but i think it has been declined:
It would be great if we can launch the mediabrowser card from a popup more easilly. Is there any way we can “mod” this as a plugin/integration? Maybe this can be done with browser mod @thomasloven ?

Firstly, this is a terrific custom component!
Well done @thomasloven!

Is there a way of using browser_mod.window_reload and specify which device it will reload?
I’ve tried the following but it still forces reloading of all computer’s browsers.

service: browser_mod.window_reload
service_data:
  deviceID: Bathroom-Tablet

I’ve created a picture_elements card and managed to find a way to add a video stream, however, when the video is displayed it is not the correct size and requires a browser window reload to correct it.

hy,
im new in HA and in Browser_mod.
I install with HACS breowser_mod and add this line in configuration.yaml

browser_mod:
  prefix: "browser_mod_"

After that, i add this to dashborad but when i click to the entities nothing appen.
I would like to appear a pop-up when click in the entities in the dashboard.
Can you help me please?
thk

type: entities
title: test
entities:
  - entity: sensor.media_temperature_interne_climatizzatori
    icon: 'mdi:home-thermometer'
    name: Temperatura Media Climatizzatori
    tap_action:
      action: call-service
      service: browser_mod.popup
      service_data:
        title: Popup example
        card:
          type: entities
          entities:
            - sensor.climatizzatore_ufficio_inside_temperature
        deviceID:
          - this
          - dashboard

I am getting thousands of these errors -> " ERROR (MainThread) [frontend.js.latest.202010214] http://192.168.1.8:8123/browser_mod.js:149:7364 Uncaught TypeError: window.queueMicrotask is not a function"

Would anyone know what is causing this?

Thanks for this awesome integration, i love it!
I’m using it to popup a card with vacuum info (from a button):

How can i avoid the scrollbars? In general it’s a bit too big.

Here is my config:

type: button
name: Schoonmaak
tap_action:
  action: call-service
  service: browser_mod.popup
  service_data:
    title: Schoonmaak
    large: true
    deviceID:
      - this
    card:
      type: horizontal-stack
      cards:
        - type: 'custom:xiaomi-vacuum-map-card'
          entity: vacuum.xiaomi_cloud_map_extractor
          camera_refresh_interval: 2
          map_camera: camera.vacuum_map
          calibration_points:
            - vacuum:
                x: 25500
                'y': 25500
              map:
                x: 316
                'y': 448
            - vacuum:
                x: 26500
                'y': 25500
              map:
                x: 316
                'y': 408
            - vacuum:
                x: 26500
                'y': 26500
              map:
                x: 276
                'y': 408
        - type: entities
          entities:
            - entity: automation.dagelijks_stofzuigen
            - entity: input_datetime.start_cleaning_at
            - entity: input_boolean.clean_living_room
            - entity: input_boolean.clean_pc
            - entity: input_boolean.clean_bedroom
            - entity: input_boolean.clean_hall
            - entity: input_boolean.clean_kitchen
            - entity: script.vacuum_clean_zones
              icon: 'mdi:play'
              secondary_info: last-changed
              action_name: Start
icon: 'mdi:broom'

previously, we had to edit the configuration.yaml and enter the correct device-id, if for some reason the device_id got changed. Required a restart to correct it.
Didn’t happen every day, but too often to neglect.

Some short time ago, Browser-mod was updated to be able to edit the device-id in the Frontend, (entityID on the browser-player card) which is a great development. click the device_id, enter the old (the one set in configuration.yaml) and we’re set again. No more restart necessary.

I was wondering if we could somehow automate the process. Or at least half way.
1- notice the device_id got changed
2- click a script button, to reset that (maybe reading the correct device_id recorded in the secrets file using an input_text in mode: password )

of course, this would have to be device dependent, and I am not sure we can template that in a regular jinja template?

we would need the availability of the browser_mod command Set deviceID in the first place. Thomas, is this available, or do you need a FR for that? Couldn’t find it in the list of services, or the documentation on the Repo.

thanks for having a look and your thoughts on the matter!

1 Like

I have problems with the popups behaviour. On smartphone it is working perfect. On dekstop or tablet however only the popup shows the title information but no entities or anything else. For example:

  - cards:
      - card:
          entity: switch.dennis_pc
          icon: 'mdi:home-thermometer-outline'
          name: Temperatuur
          style: |
            ha-card {
              --paper-item-icon-active-color: #e79118;
            }
          tap_action:
            action: call-service
            service: browser_mod.popup
            service_data:
              card:
                cards:
                  - entities:
                      - type: 'custom:mini-graph-card'
                        entities:
                          - sensor.temperature_158d00022725bc
                        name: Slaapkamer
                        show:
                          labels: true
                          color_thresholds:
                            - value: 18
                              color: '#f39c12'
                            - value: 19
                              color: '#d35400'
                            - value: 20
                              color: '#c0392b'
                        hours_to_show: 48
                        points_per_hour: 1
                      - type: 'custom:mini-graph-card'
                        entities:
                          - sensor.temperature_158d0004460bb5
                        name: Woonkamer
                        show:
                          labels: true
                          color_thresholds:
                            - value: 18
                              color: '#f39c12'
                            - value: 19
                              color: '#d35400'
                            - value: 21
                              color: '#c0392b'
                        hours_to_show: 48
                        points_per_hour: 1
                    show_header_toggle: false
                    type: entities
                mode: horizontal
                type: 'custom:stack-in-card'
              deviceID:
                - this
              large: false
              title: Temperatuur
          type: button
        style: |
          ha-card {
            height: 128px;
            --paper-item-icon-active-color: #e79118;
          }
        type: 'custom:mod-card'

I tried a lot but I can’t find why it is working on my smartphone but not on any other device…

EDIT: figured it is working on ios devices, but on android and windows still no success

What is the reason, why browser_mod ignores this enty?
I still get the errors.
Is it the wrong component?

logbook: !include logbook.yaml
logger:
  default: error
  logs:
    custom_components.bhyve: warning
    custom_components.alexa_media: error
    **custom_components.browser_mod: critical**

I’ll preface this with saying I’m a total noob with HA and browser_mod (transitioning from SmartThings) so I’m sure I’m missing something obvious. How do I get bm to play a local mp3 stored on the HA device (not the browser device) via the media player? I have the browser devices showing up, and the light switches work, but can’t get media player to do anything. The player card in lovelace will change to playing but no audio is heard even though volume is heard. I can play the same file via Media Browser fine. I copied the mp3 via Samba addon to the media folder. I tried variations of the below script (with media and local, with and without quotes around file). I also tried using a url like https://myduck.duckdns.org:8123/media/alright.mp3 but couldn’t get those to work directly in the browser either but I probably don’t have the format/path right

bm_play:
  alias: Browser Play
  sequence:
    service: media_player.play_media
    data:
      entity_id: media_player.desktop
      media_content_id: /media/alright.mp3
      media_content_type: music

I also enabled logging but don’t see any errors in the log

logger:
  default: info
  logs:
    homeassistant.components.media_player: debug

EDIT: Of course I got it working after posting. Had to create a www folder under config to make the file accessible to other devices. If there is a better alternative I’d love to know, but for now this is working.

Hi, I’m using the latest version of browser mod and I have the following error in logs. I really don’t know how to fix it. Can you help me please.

Logger: homeassistant.components.websocket_api.http.connection
Source: custom_components/browser_mod/helpers.py:47
Integration: Home Assistant WebSocket API (documentation, issues)
First occurred: 2:26:08 AM (13 occurrences)
Last logged: 2:26:49 AM

  • [2855708440] Error handling message: Unknown error
  • [2851426800] Error handling message: Unknown error

Traceback (most recent call last): File “/usr/src/homeassistant/homeassistant/components/websocket_api/connection.py”, line 95, in async_handle handler(self.hass, self, schema(msg)) File “/config/custom_components/browser_mod/connection.py”, line 42, in handle_update devices[deviceID].update(msg.get(“data”, None)) File “/config/custom_components/browser_mod/connection.py”, line 83, in update self.sensor = self.sensor or create_entity( File “/config/custom_components/browser_mod/helpers.py”, line 47, in create_entity adder = hass.data[DOMAIN][DATA_ADDERS][platform] KeyError: ‘sensor’

Hi,
Sorry if it was already answered, tried to search for it.
Is it possible to auto close the browser mod popup after defined amount of time?
Regardless mouse or any keys.
Maybe some automation?

I am not able to figure the root cause. Apparently I haven’t anything like these.

Ever figure this out? Amazon Fire 10 running FKB. I use browsermod to play a mp3 chime when my outdoor surveillance camera has motion. Very often when I touch the screen, the chime will play, like it was queued up

Nope, it still does it from time to time. Confusing for all concerned when it plays a random mp3 we normally associate with a specific action. It always comes if I touch the screen. It’s as if, as you say, the message was ‘queued’ and bursting to play itself.