Android Dash Board Browser with Motion Detection and MQTT

Hi,
HADashboard 2 motivated me to stick an Android tablet to the wall. Only problem is the standard browsers are missing some features. So i wrote an app to display a full screen website and switch on the screen when the front camera detects motion.
Since i was on it i also added MQTT for remote control and for reading the tablet sensors.

You find sources, app and configuration details on github https://github.com/ray0711/homeDash
Under releases you find a self signed app. To install it you need to enable untrusted sources in the Android settings. Or you build it yourself form sources.

I’m happy about forks and pull requests.

18 Likes

Definitely will be checking this one out. Sounds like it’s a perfect fit for what we’re doing with HASS vs the generic Kiosk applications out there and I love the remote control capabilities for URL and such, never thought of wanting that!

Heck - that’s JUST what I needed!

I have two Samsung 8" inch tablets (possibly two more if this works well) which will be wall mounted.

I have an idea here too.

It might be good to be able to swtich on the tablet display over MQTT ::::: HOLD THE PHONE! - You’ve done that too! That means if there is an external trigger (say, motion detected on another camera, or a persistent_notification being displayed) - we can forcibly turn on the tablet screen. NICE!

This is really neat.

Being just a little security conscious - how can we be sure your app is playing nice? I’m only asking - not accusing! One must always ask questions :slight_smile:

B

1 Like

Grab the source, review it, and compile it yourself… that’s why it’s on Github :slight_smile:

Cool

However loaded to my phone, and because I am not home it cannot connect to my HA machine.

Now my phone is stuck on an error message, full screen, with no escape. Soft buttons do not even work. I can however reboot my phone with the on/off hard button.

"Android Logo
Webpage not available

The webpage at http://xxxxxxxx/ could not be loaded because:

net::ERR_NAME_NOT_RESOLVED"

EDIT: workaround to escape: highlight something on the error message and choose “search the web” - the app then backgrounds. However this is only a workaround.

Is there any means to specify a username and password for the MQTT connection? Wasn’t able to guess any format with the URI, not familiar with the android MQTT code

Hey, not all of us are hardcore devs - some of use us are just-core devs. Just enough to get in trouble :slight_smile:

1 Like

You should be able to pull up from the bottom screen border to get the Android controls (like back and home).

I wouldn’t run the app on my phone without charger it is not really optimized for energy saving. Camera and sensor keep the device busy.

Not yet implemented. Looks like the library doesn’t accept username/password in the url but needs it as separate options.

I try to add it over the weekend. If you want it faster add something here

HomeDashService.java:124
  MqttConnectOptions mqttConnectOptions = new MqttConnectOptions();
+            mqttConnectOptions.setUserName(...);
+            mqttConnectOptions.setPassword(...);

Fair enough. :slight_smile: didn’t mean to be snarky there but really in the end there’s that trust factor in everything right…

You might just suck me into setting up a VM or Docker with an Android build environment by the weekend :slight_smile:

Just dawned on me that there is no apk to download. Bummer! Not within my skillset to build a working dev stack to compile this… Let me know how you go.

i also love to try this, but i have no idea how to install this on my android tablet.

It’s all there…
Releases: https://github.com/ray0711/homeDash/releases

2 Likes

unfortunaltey i get error by parsing :frowning: i am running android 5.0 … i never built app by myself but is it possible to compile a version for 5.0?

or even downwards?
i am running android 4 on my tablets.

Pulling up from the bottom was probably the one thing i didn’t try, thank you.

Yes I just put it on my phone out of curiosity. I’ll be trying on my tablet tonight.

Ok somehow I’ve pulled out of my butt being able to compile this and add the MQTT usernames and passwords mod :slight_smile: Although I’m curious why it doesn’t display the current setting like the others do? I suppose that’s more an Android development question than a homeDash question – I have not done Android apps before.

Sure is - Too eager to stop and read - my bad.

Installed!

1 Like

Awesome!
First question: does it work?:smiley:

Displaying the current value happens somewhere by binding a change listener… But likely we don’t want to display the password anyway

Waiting for the pull request.