HABPanelViewer 0.9.27

Hi ,

I switch more and more to the new oh3 MainUI. Are there plan’s also the support the MainUI in the HABPanel Viewer ? This would be greate because HPV is perfect for Tablet Usage with this full integration with Items and Comands.

Regards

1 Like

I use HPV with the main UI. What do you mean with “support MainUI”?

Hi :slight_smile: I have a question…does anyone have the same Problem:

I have a rule, which plays a sound over webaudio…

The first 5 minutes of the freshly started habpanel it works perfectly…but than it stops and no sound is played…

I tried the following:

  1. Turned off all Energy-saving measures of android
  2. activated the developer-options and turned on “stay active during charging” which keeps the screen on as the tablet is always plugged in…
  3. installed a “keep screen active” app

I also noticed that I was not able to prevent WIFI from energy-saving…is there an adb command for that? I don’t see an option here…

I run on a Fire HD 8 2020 with habpanel as default viewer (activated and installed via adb/F-Droid) and OH3.0.1

First off, thank for your continued support @vbier, I’ve been using HPV for a few tablets in my home and It helps me optimise my tablets for a great “home-control-from-a-tablet” experience.

Now about the issue. I’ve migrated from OH2 to OH3. HabPanelViewer (HPV) still works properly, but I have a problem with not being able to receive the commands any more. For that to work, one needs to configure the openHAB URL in the settings, but when configuring that with OH3, I receive the message Could not query available services from openHAB. I can understand why that is happing, because when I visit the url (https://openhab3.local/rest/services) from the tablet, or my local webbrowser (clean session), I receive an {"error":{"message":"Authentication required","http-code":401}} because I was obviously not authenticated. How should I go on about this? Does the above mentioned OH3 custom APK build offer a way to maybe login with a username/password/token? Is there maybe another work-around to get commands working again?

1 Like

I had the same problem. Just install this version:

https://github.com/vbier/habpanelviewer/blob/master/app-debug.apk

1 Like

That solved my issue. Thank you!

Hi would that be nice to have a Command to play music file (from local storage or URL).
So I could have a real doorbell sound. Currently TTS is saying “someone is at the gate” but the voice is not nice and it is quite stressing. Wife complains.
I had that done previously with casting to the google home, but that is super not reliable. Like works 2 in 5 times and there is that introductory sound that is annoying.

I’m running the latest debug version of HPV (habpanelviewer/app-debug.apk at master · vbier/habpanelviewer · GitHub)

I have three tablets running HPV:

  • 2 x Lenovo TB-X505F running Android 10
  • 1 x HTC Nexus 9 running LineageOS 15.1 on Android 8

The HTC tablet was completely reinstalled with the above configuration, with the HPV debug version mentioned above, but it won’t start.
The Lenovo tablets worked at first, but stopped working last night at around the same time, which suggest to me something at either the OH3 side changed, or some logic in HPV was triggered.
HabPanel does run perfectly on all tablets when run from Chrome and Firefox, so it seems that part of OH3 is running fine.

Can I provide some kind of debug log that might help figure out what the problem is? How do I do this? When I start HPV now it simply gives me the ‘Stopped working’ message directly after starting it. Clearing caches, storage and reinstalling have not helped for all three tablets.

Genrate an adb log like described here:

Create an issue in github and add the log there or send it via pm if you do not want to post the log.

1 Like

You can use WebAudio as audio sink and play audio with openHAB. See Multimedia | openHAB

1 Like

Ok great, that is a solution,
Is there a way to target one particular panel as webaudio target?

I have 7 HABpanel tablets and they all play at once (or almost at onec depending on the model they have up to 1 sec od delay) Almost sent my wife to mental hospital after testing some doorbells.

Or I just have to mute all others and select just one.

It does not look like you can restrict it to one tablet. If you use different comand items for the tablets, you can also send a notification and set a custom notification sound for HPV on the tablet.

Question:

I also use HPV to start apps, e.g. Doorbird. My problem is, when hpv opens an app, the tablet does not go into sleep mode, i.e. the app just keeps running, no screensaver. I use the command “START_APP com.doorbird.doorbird”

Behavior is the same for all apps. Is there a trick?

Many Thanks

Gerhard

I have each of my tablets grouped into misc groups so I can make them respond by changing screen, TTS, or sound on my need. Theater panels dim when movie starts, all tablets flip to the security cam when a door bell is pressed, etc.

Maybe I’m doing something dumb but I can’t seem to send commands to my HPV instance:

openhab> openhab:send Tablet_BathMain_Command "REBOOT"
Command has been sent successfully.

But the command never arrives on the tablet

Items file:

...
String      Tablet_BathMain_Command
...

Config from Tablet:

<?xml version='1.0' encoding='utf-8' standalone='yes' ?>
<map>
    <boolean name="pref_allow_mixed_content" value="true" />
    <boolean name="pref_autoplay_video" value="true" />
    <boolean name="pref_battery_enabled" value="true" />
    <boolean name="pref_brightness_average" value="true" />
    <boolean name="pref_brightness_enabled" value="true" />
    <boolean name="pref_capture_screen_enabled" value="false" />
    <boolean name="pref_connected_enabled" value="true" />
    <boolean name="pref_current_url_enabled" value="true" />
    <boolean name="pref_desktop_mode" value="false" />
    <boolean name="pref_device_admin" value="true" />
    <boolean name="pref_disable_cache" value="false" />
    <boolean name="pref_hardware_accelerated" value="true" />
    <boolean name="pref_immersive" value="true" />
    <boolean name="pref_intro_shown" value="true" />
    <boolean name="pref_javascript" value="true" />
    <boolean name="pref_load_start_url_on_screenon" value="false" />
    <boolean name="pref_log_browser_messages" value="true" />
    <boolean name="pref_motion_detection_enabled" value="false" />
    <boolean name="pref_motion_detection_new_api" value="true" />
    <boolean name="pref_motion_detection_preview" value="false" />
    <boolean name="pref_pressure_average" value="true" />
    <boolean name="pref_pressure_enabled" value="false" />
    <boolean name="pref_prevent_dragging" value="false" />
    <boolean name="pref_proximity_enabled" value="false" />
    <boolean name="pref_restart_enabled" value="true" />
    <boolean name="pref_screen_enabled" value="true" />
    <boolean name="pref_show_context_menu" value="true" />
    <boolean name="pref_show_on_lock_screen" value="true" />
    <boolean name="pref_startup_enabled" value="true" />
    <boolean name="pref_temperature_average" value="true" />
    <boolean name="pref_temperature_enabled" value="true" />
    <boolean name="pref_track_browser_connection" value="true" />
    <boolean name="pref_usage_enabled" value="false" />
    <boolean name="pref_volume_enabled" value="true" />
    <string name="pref_battery_charging_item">Tablet_BathMain_Battery_Charging</string>
    <string name="pref_battery_item">Tablet_BathMain_Battery_Low</string>
    <string name="pref_battery_level_item">Tablet_BathMain_Battery_Level</string>
    <string name="pref_battery_temp_item">Tablet_BathMain_Battery_Temp</string>
    <string name="pref_brightness_intervall">60</string>
    <string name="pref_brightness_item">Tablet_BathMain_Brightness</string>
    <string name="pref_command_item">Tablet_BathMain_Command</string>
    <string name="pref_connected_interval">60</string>
    <string name="pref_connected_item">Tablet_BathMain_ConnectedTime</string>
    <string name="pref_current_url_item">Tablet_BathMain_Url</string>
    <string name="pref_jpeg_quality">70</string>
    <string name="pref_menu_position">right</string>
    <string name="pref_motion_detection_granularity">20</string>
    <string name="pref_motion_detection_leniency">20</string>
    <string name="pref_motion_detection_sleep">500</string>
    <string name="pref_openhab_version">OH3</string>
    <string name="pref_pressure_intervall">60</string>
    <string name="pref_screen_item">Tablet_BathMain_Screen</string>
    <string name="pref_server_url">http://openhab.imagilan</string>    <!-- used for the API access -->
    <string name="pref_start_url">http://openhab.imagilan?kiosk=on</string>    <!-- used to start a tablet on a specific screen (needs to be full URL) -->
    <string name="pref_startup_item">Tablet_BathMain_StartupTime</string>
    <string name="pref_take_pic_delay">100</string>
    <string name="pref_temperature_intervall">60</string>
    <string name="pref_theme">dark</string>
    <string name="pref_usage_item">Tablet_BathMain_Usage</string>
    <string name="pref_usage_timeout">60</string>
    <string name="pref_volume_item">Tablet_BathMain_Volume</string>
</map>

and a debug log from the tablet: Ubuntu Pastebin

any ideas on what I could be doing wrong or where I could look next to debug this? (Source: openhab
Version: 3.1.0~S2409-1)

Incidentally I’m running the new main UI on HPV. It seems to be working well. I presume there shouldn’t be any problems with it not being HabPanel.

I believe you want to send “RESTART”, I don’t believe REBOOT is a valid command.

Also have you assigned the command item in the HPV Config/Preferences?

I have assigned it. I’ve tried all the commands, like SCREEN_ON/OFF etc. Value reporting works just fine. The Command_Log window shows nothing reported.

What is your item type?

I have 8 tablets, on Lenovo M8/M10 tablets. Battery opt is off (I had a problem with it on, and lag) HPV 0.9.27pre (4/18/21)

String HabPanel_T_1_Control "Tablet Control" (gHabpanelAllControl, gHabpanelTheaterControl)

I use the TTS and SHOW_URL extensively in rules

// Door Contact Announce
        rule "Announce Doors Contacts"
            when 
                Member of gDoors changed
            then
                val ActiveDoor = triggeringItem.label.toString()
                val ActiveDoorStatus = triggeringItem.state.toString()
                val ActiveDoorTTS = "" + ActiveDoor + " " + ActiveDoorStatus
                if (Virtual_StringHouseStatus.state == "Sleep" ) {
                    logInfo("security.rules", "(SLEEP) " + ActiveDoorTTS)
                    gHabpanelAllControl.sendCommand("TTS_SPEAK  " + ActiveDoorTTS)
                } else {
                    logInfo("security.rules", "(DAY) " + ActiveDoorTTS)
                }
            end

// DrewsOffice
        rule "tablet_scheduleEventDrew"
            when
                Item w_drew_current_event_active changed or
                Item p_zach_current_event_active changed or
                Item p_drew_current_event_active changed or
                Item PdDrewCount changed
            then
                HabPanel_A_Control.sendCommand("SET_BRIGHTNESS 100")
                HabPanel_A_Control.sendCommand("SCREEN_ON")
                HabPanel_A_Control.sendCommand("SHOW_URL http://10.0.10.231:8080/habpanel/index.html#/view/TODO?kiosk=on")
            end

Where can I download 0.9.27pre? Happy to try that version out.

These are the configs I’m using: tablet control (not working) · imaginator/system@7a110f1 · GitHub I’m presuming the “Command Log” screen shows what commands are being sent through.

Your items looked fine. you don’t need the groups I had in mine, they are just for my use. Tho feel free copy the group names. :smiley:

I got the apk off the HPV github.

app-debug.apk it worked for me, so never bothered changing it.