This application is a custom developed apk which allows devices running on the
- Smatek T6E variants
- Sonoff NSPanel Pro
- Zemismart T6E
- Avatto T6E
- Tuya T6E
- or similar architecture
to leverage certain features such as proximity sensor, light sensor, and Home Assistant integration.
Application mainly tested on NSPanel Pro but may works on other devices.
Donate me if you want:
- App version history
- NSPanel Pro device info
- NSPanel Pro device rooting and sideload
- Install custom launcher
- Install custom webview
- Install app
- Manual for v2.x
- Manual for v1.x
Actual plan is to have a release in every Quarter.
- set screensaver brightness
- Zigbee gateway integration
- proxy devices to mqtt
- Automatic App updater
- HA commands
- json based device configuration
- play audio
- voice based commands
- mqttv5 ssl
- Zigbee gateway integration
- possibility to change between router and coordinator mode
- Gesture
- multitouch gesture detection
- Wake on Wave for Screensaver does not work Issue #145
- Pro Tools keep crashing on tap after screen off Issue #143
- Proximity sensor trigger label on sensor tab keeps visible after trigger
Note Wake-on-Screensaver toggle has been removed because the new wake-on-wave method handles as well
Convenience update due to the release of a new device 120p
- Support of 120p
- Set display rotation
- Control Screen-on screen dim behaviour
- Proximity wake-up no longer working after wake-up signal is sent via MQTT Issue #115
- When Scheduled Reboot is activated, app repeatedly closes itself Issue #113
- added Device Admin permission request in order to sleep the device via MQTT Issue #103
- Fixed compatiblity issue with other launchers such as Lawnchair Issue #104
- It has been made possible to connect MQTT with empty username/password pair Issue #105
Release is dedicated to:
- HA commands
- wake_up device
- sleep device
- reboot device
- switch to launcher
- enbable adb
-
- control sw1,sw2 built-in switches
- Gesture
- double, triple tap gesture detection (only available firmware under 1.11.0)
- System enhancement
- navigation bar by swipe up
- notification bar by swipe down
- Scheduled reboot
- Application watchdog
- json serialization was fully rewritten, enabler for device provisioning
- mqttv5 client was implemented, enabler for ssl and zigbee
- switched to local broadcast, perf optimization
- auto test covarage was increased
- Crash when setup mqtt and main switch is off
- Crash when changing mqtt config (seaky#82)
Release is dedicated to:
new features (see updated manual Manual 2.x version )
- Touch gestures on dark screen (seaky#27)
- Wake up from Screen Saver (seaky#52)
- Display sleep mode (seaky#40)
- Different Screen-on at weekdays and weekends (seaky#36)
- Switch to selected App (seaky#46)
- Home on gesture
- MQTT Native Integration (seaky#51)
- MQTT Home Assistant integration (seaky#21)
- Audio feedback
- Brightness between BELOW and ABOVE is not handled properly (seaky#55)
- Restart app after reboot does not work (seaky#49)
- Display sleep time UI refresh bug (https://github.com/seaky/nspanel_pro_tools_apk/ issues/47)
- Misleading screen-on begin time calculation (seaky#44)
new features (see manual Manual 2.x version )
- code has been fully redesigned (see Backward compatibility)
- a lot easier to add new capabilites
- enables to add internal event listeners and therby make MQTT/HASS integration
- new Preference based UI
- a lot easier to add new UI elemens. Due to the small screen a scrollable view is much more convenient or usable
- screen always on/off feature (seaky#5, seaky#14)
- reboot device from app (seaky#6)
- change hostname from app (seaky#8)
- system display sleep time setting from app
- predefinied brightness scenarios based on lightsensor trigger events
- now automatically launched apps can wait for established wifi connection
- touch-screen reader memoryleak fixed
- request exclude app from battery optimization, helps to prevent app kill by system
- wake-on-wave can be turned off
- added light sensor feature
- auto adjust brightness (experimental)
- added set brightness
- adjust brightness
- optimized toggle operations
- preparation for future updates
- main switch called "active" fully turn off all features of the app including app launch
- all features can be set independently
- note switch defaults are still off (will be changed in 1.2)
- known bugs
- trigger label sometimes permanently visible solution: navigate between menus
- auto adjust brightness level can be very low
- light menu icon is wrong
Note Don't forget to activate main switch
- first production release
- support wakeup on proximity sensor trigger
- support wakeup on touch
- support autolaunch application
- new dark design
- renamed original "ProximityTool" app to "NSPanelTools" app
- moved to new repositroy
- first release
- support wakeup on proximity sensor trigger
Sonoff NSPanel Pro is a smart home control panel which based on Android 8.1 Oreo (AOSP) system.
Device info: https://itead.cc/product/sonoff-nspanel-pro-smart-home-control-panel/
- Download ADB drivers and install.
- Download Android platform-tools unzip it to a folder.
- Get device ip address (if you dont know what is ip-address and dont know how to find it do not root the device, you will mess the device up)
Tip
You'll find the ip address within Sonoff app settings or in your router dhcp clients view
- Registrate your device with the eWeLink app just follow the device registration process
- To gain ADB access tap on the device id quickly multiple times to enable developer mode
- after you consider the adb agreement you will able to acces device through the adb command
Warning
If you accept the agreement you won't be able to revert it.Your device will be rooted forever. You wont get any new future updates forever.
Tip
With my RootTool app you can update your device
- connect to device with adb
start adb listen:
adb tcpip 5555
list devices
adb devices -l
connect device
adb connect <ip-address>
- Install a custom Launcher (see Install Launcher)
connect device
adb connect <ip-address>
list devices
adb devices -l
press home button
adb shell input keyevent 3
press power button
adb shell input keyevent 26
show notifications
adb shell cmd statusbar expand-notifications
install app
adb install <apk>
To handle the device more easily, you need to install a custom launcher.
Download UltraSmall Launcher
- install and simulate home key press
- select set "Launcher" as default
If you want to use Home Assistant companion app you must update factory provided webview component.
Tip
You dont need to instal Xposed root firmware as blackadder mentioned.
Just simple download com.android.webview_108.0.5359.128.apk or any new version which supporst arm64-v8, armeabi-v7a on firmware above 1.5 Lineageos version can be installed!
WebView 108 for firmware >=1.5
Under frimware version 1.5 you have two options, update firmware by my frimware updater or simply install this resigned version below.
install webview apk
adb install -r <webview>
- Download apk from releases section
- adb install -r [filename.apk]
- backward compatibility
- main switch
- display menu
- sensor menu
- tools menu
- integration menu
- settings menu
- Home Assistant
- Example configuration
Note
If the version number is marked, then it is only valid for that version.
version 2.x supports all v1.x features. Except the automatic brightness change which was experimental and replaced by light-level triggered brightness control see [Brightness category] (#brightness-category).
Note
All configuration for v1.x is obsolete in 2.x therefore 2.x app must be reconfigured before use.
Main switch allows for the complete disabling of the application's functions. Controls the background activities. Purpose of being able to disable the whole app without uninstall.
- active toggle
- activates a background service which runs even if the app is "killed" from app-switcher
- off state turns all app features off including "launch app after reboot"
This tab groups all screen or display related configurations and features. Such as how and when to turn on and off or how bright is it. etc
Category for all wake-up related functions.
Unfortunatelly this AOSP 8.1 build does not support wakeup device which causes that if official app is not running the device will go to deepsleep. Due to the lack of power button, just a hard reset (unplug) can wake up the device.
Wake up the device by hand wave.
Note
Before turning it on, set up the sensor parameters on the sensor tab.
Wake up the device by touch gesture. Multiple gestures can be selected the behaviour will be the same it will wakes up the device.
Important
FW Over 1.10.0 wont support touch gestures.
Dismiss the ScreenSaver if it is active. Only works if wake-on-wave is enabled.
Category for all brightness related functions.
Set system level display brightness. On certain cases it is used to set if no light change event is triggered.
Set brightness to the given value if light-below event is triggered.
Note
Before turning it on, set up the sensor parameters on the sensor tab.
Set brightness to the prescribed value.
Set brightness to the given value if light-above event is triggered.
Note
Before turning it on, set up the sensor parameters on the sensor tab.
Set brightness to the prescribed value.
Category for all (lcd) screen related functions.
Set system level display sleep time. After the prescribed interval the screen will be turned off if another function does not override it, for example: Prevent turn off or Screen begin
Defines the sleep mode behaviour
- Screen off
- completely turn the screen off
[!IMPORTANT] touch gestures only available in this mode
- Screen dim
- after prescribed Display sleep time the screen will dim
During a predefinied period it turns on the screen and it remains on untile the end of the interval.
The time when the screen-on begins on weekdays.
Tip
If both begin time and end time is "00:00" it will be disabled or ignored If the weekend is disabled, weekdays will jump over weekends. So after friday the monday will be scheduled. If the weekend is enabled, after friday the weekend intervall will take effect.
The time when the screen-on ends.
The time when the screen-on begins at weekends
Tip
If both begin time and end time is "00:00" it will be disabled or ignored If the weekdays is disabled, weekends will jump over weekdays. So after sunday the next saturday will be scheduled. If the weekdays is enabled, after sunday the weekdays intervall will take effect.
The time when the screen-on ends.
Category for proximity sensor related functions.
Proximity sensor live value shows actual sensor value and shows the trigger when it is activated.
Above the value the trigger event will be create
Category for proximity sensor related functions.
Light sensor live value shows actual sensor value and shows the trigger when it is activated.
Below the value the trigger event will be created
Above the value the trigger event will be created
Autostart or launch other app after device restart
Launch selected application after device reboot
Start selected application after WIFI connection is established
Monitoring selected app daily if it is not running, then it starts it.
Switch to selected application
Always shows the system level navigation bar.
Available if NavigationBar is turned off. An edge swipe up enables the navigation bar for X seconds.
Shows the system level notification bar by edge swipe down. Originally it is disabled in Sonoff system.
Switch to default launcher
The selected gesture will switch back to this application.
Not yet available planned to v2.2
Category for MQTT and HomeAssistant related settings
The current state of the connection.
Possible states:
- connecting
- initiating connection
- connected
- connection established
- disconnected
- no live connection
- failure
- can not establish connection, retry every 5sec
Setup MQTT Connection
If turned off the connection will be dissconnected
If turned off the connection will be dissconnected. Turn on only if you setup connection parameters correctly
The current state of the connection.
You can select the messages you want to publish on this channel. Only publish those that you really need.
Currently supported events:
- Trigger - proximity
- send if proximity triggered
- Trigger - light-below
- send if light-below triggered
- Trigger - light-above
- send if light-above triggered
- Trigger - light-normal
- send if light value between below and above
- Device - wake up
- send if device wake up triggered
- Device - sleep
- send if device go to sleep, wont be triggered if Display sleep mode is Screen dim
- Gesture - tap
- send if gesture detected, touch gesture only available when the screen is off
- Gesture - swipe up
- send if gesture detected, touch gesture only available when the screen is off
- Gesture - swipe down
- send if gesture detected, touch gesture only available when the screen is off
- Gesture - swipe left
- send if gesture detected, touch gesture only available when the screen is off
- Gesture - swipe right
- send if gesture detected, touch gesture only available when the screen is off
MQTTv3 server host name only non-SSL is available in v2.1
MQTTv3 server port only non-SSL is available in v2.1
MQTTv3 client id
Configured username
Configured password
Automaticall generated Device Id is not quite human friendly, Hostname can be used as deviceid.
Important
Hostname must be set
Unique device id
Enables MQTT Integration based integration, events and diagnostics are implemented.
If enabled it sends configuration message to the proper topics
Tip
In case of configuration trouble, off-on will reconfigure the HA endpoint
Topic prefix usually homeassistant the default
Plays audio on certain events such as identified touch gestures on in order to provide audio-based feedback.
Autostart NSPanelTools app after device restart
This option reboots the device
Changes the device hostname
Changes log level to debug
Changes log level to verbose
Display app log
Integration based on HA official MQTT module.
Important
Currently MQTT Support only non SSL connections.
Configured device data:
- name
- unique id
- manufacturer
- model
- firmware version
Device entities are unique thus generated entity name can be renamed anytime.
If an event has not been sent the value is unknown
- Sends IP Address string once a day every 24h.
- Receives availability information, if the "eye" icon is gray the device is offline
Sends event when the proximity sensor trigger is occured. Event values:
- triggered
Sends event when the touch event is triggered.
Important
Touch events can only be triggered when the screen is off.
Event values:
- tap
- swipe_up
- swipe_down
- swipe_left
- swipe_right
Sends light sensor triggers is occured. Event values:
- light_above
- light_below
- light_undefinied
- reboot device
- sleep
- wake_up
- play custom audio
- wake on wave: on
- wake on gesture: off
- wake from screen saver: off
- brightness: 100
- brightness on light-below: true
- brightness on light-below: 0
- brightness on light-above: true
- brightness on light-below: 100
- display sleep: 15
- prevent turn off: off
- screen-on time: on
- screen-on time begin weekdays: 07:00
- screen-on time end weekdays: 09:00
- screen-on time begin weekends: 08:00
- screen-on time end weekends: 10:00
- launch app after reboot: Home Assistant
- wait for wifi: on
- home on gesture: swipe-right
- mqtt enable: on
- publish events: tap, swipe-up, swipe-down, swipe-left
- ha integration: on
- auido feddback: on
- resume on reboot: on
- hostname: nspanel#
- debug: off
-
Room: Automation for touch events, every room has its own automation
- swipe_up: shutter open
- swipe_down: shutter close
- tap: shutter stop
- swipe_left: turn light on / off
- proximity: wake up device
-
Entrance: Special configuration for home entrance
- swipe_up: I'm home -> shutters up, air vent on
- swipe_down: Leave home -> electricity off, shutters close
- swipe_right: #1 garage door open/closew
- swipe_left: #2 garage door open/close
- tap: wake up device
- proximity: wake up device
description: "bedroom nspanel2 automation"
trigger:
- platform: state
entity_id:
- event.nspanel2_touch
attribute: event_type
condition: []
action:
- choose:
- conditions:
- condition: state
entity_id: event.nspanel2_touch
attribute: event_type
state: swipe_up
sequence:
- service: cover.open_cover
target:
entity_id:
- cover.rollershutter_0013
device_id: []
area_id: []
data: {}
- conditions:
- condition: state
entity_id: event.nspanel2_touch
attribute: event_type
state: swipe_down
sequence:
- service: cover.close_cover
target:
entity_id: cover.rollershutter_0013
data: {}
- conditions:
- condition: state
entity_id: event.nspanel2_touch
attribute: event_type
state: swipe_right
sequence:
- service: cover.stop_cover
target:
entity_id: cover.rollershutter_0013
data: {}
mode: single
Switch controls the background activities. Purpose of being able to disable the whole app without uninstall.
- active toggle
- activates a background service which runs even if the app is "killed" from app-switcher
- off state turns all app features off including launch app after reboot
Unfortunatelly this AOSP build does not support wakeup device which causes if official app is not running the device will go to deepsleep. Due to the lack of power button, just a hard reset (unplug) can wake up the device.
Wake up on wave and touch feature are implemented in the app btw that was the original purpose of the app.
- wake-on-wave
- toggle state is presisted
- feature activates itself if the screen goes off
- this option observes the proximity sensor gestures
- wake-on-touch
- panel touch will also wakes up the device
- feature activates itself if the screen goes off
- this option observes the panel touch
- resume on boot
- start the selected app after reboot automatically
- feature activates itself after reboot
- after the reboot this app may not visible in app switcher, nonetheless the background service will be active
This feature enables to run an application as a default app such as HomeAsistant.
- select
- select installed application if launch on startup activated the app selection is disabled
- always test it with test button before activates
- launch on startup
- runs the selected app after reboot
- test button
- launch the selected app
This feature enables utilization of light sensor.
- set brightness
- panel brightness can be changed manually
- if auto adjust is turned on it shows the calculated brightness value in relatime
- auto adjust brightness
- automatically calculates and adjust the brightness based on sensed lux