SOLVED: Can I somehow dim a tablet from Home Assistant?

Hi All
We have a tablet set up in the living room that is our dashboard. When we have overnight guests they sleep in the livingroom.
So I’ve created a button that turns off the light automation in the livingroom, but it would be nice if I could somehow get the screen dimmed as well, I doubt that it can be done, but I just wanted to ask?
So far I just press the on/off button for the tablet, and that will turn of the screen.

Can I create a simple binary sensor that I can set or unset for overnight guests, instead of turning of a single automation, so that I can get more things to react on the setting?

1 Like

This can be done using browsers like “Fully kiosk browser” and I think “wallpanel” supports it too. But I am interested if someone else knows an application dedicated to that only, instead of using a browser.

To explain what it does (before you even attempt to install them): You have to have Home assistant open on that browser (so forget about chrome or firefox or any other) and you have to do the right settings using mqtt to control the brightness or even the on/off state of the screen. There are also many more things you can do, such as motion detection or streaming through the tablets camera.

1 Like

You can try Tasker or MacroDroid, only for Android.

1 Like

For the Fully Kiosk option, either use the REST API directly or take a look at https://github.com/thomasloven/lovelace-fullykiosk/blob/master/README.md.

1 Like

Ok, I’m using wallpanel for the tablet, but I don’t see that option available in the documentation yet. I can turn on the screen, but I don’t see that I can turn it off.

I’ll look at the fully kiosk, I haven’t seen that yet, is that payware?

You are right, you cant turn it off from wallpanel, but you can dim the screen. Also you can enable screensaver and use a black photo (workaround?)

Fully kiosk is free but if you enable the “pro” features it has a message on the corner of the screen to buy a full license. You can install it and see how it goes and if you like it, just buy it to get rid off the message.

1 Like

Just set the android setting for screen to go off after a set amount of time.

In wallpanel you can get the screen to turn on when there is someone close to the tablet.

1 Like

Ok, so with wallpanel, is it a command I can send?
I don’t like it to go off on a timeout, and turn on with presence, as we also use it just to glance at, without being right next to it.
So, I think I’ll look at a command for wallpanel, or a command for fully kiosk for me.

You have a choice

1 Like

Ahaaaaaa, that was the documentation I was looking for :smiley:
So with that, I should be able to dim the tablet when it’s in “guest mode”, and when not, it goes back to normal brightness. I really have to look into that, and also get the wallpanel active on mqtt :slight_smile:
Thankyou @AhmadK (and of course @nickrout, @argykaraz, @ronschaeffer and @woody4165 :smiley:)

1 Like

It works perfectly with mqtt commands and sensors, weehee, @thanksmister have made a brilliant product there.

Now, the second part was if I can set a variable that will indicate this is activated? So that I can have automations use that as a condition?

Wallpanel is publishing the app state through mqtt
There are examples in the documentation, but I will paste them here:

Application State Data
The application can also publish state data about the application such as the current dashboard url loaded or the screen state.

Key	Value	Example	Description
currentUrl	URL String	{"currentUrl":"http://hasbian:8123/states"}	Current URL the Dashboard is displaying
screenOn	true/false	{"screenOn":true}	If the screen is currently on.
brightness	true/false	{"brightness":100}	Current brightness value of the screen.
State values are presented together as a JSON block
eg, {"currentUrl":"http://hasbian:8123/states","screenOn":true}
For REST
GET the JSON from URL http://[mywallpanel]:2971/api/state
For MQTT
WallPanel publishes state to topic [baseTopic]/state
Default Topic: wallpanel/mywallpanel/state

So, I guess you can see if the screen i s on or off, or if it is dimmed.

Yes, of course, I’ve already set up to monitor the battery state in the tablet, but that wasn’t the issue for me, sorry for being unclear.

I would like to set a ‘state’ that says ‘overnight guests’.
This state would be set by the button on the tablet.
Then the automations would be activated by that state, and the state could be used as a condition for other automations.
My idea was to make a ‘binary sensor’, but I’ve yet to find out how to make a sensor from nothing :slight_smile:

Your state can be held in a input boolean.

1 Like

YES, perfect, thankyou very much @nickrout