yashsingh1/xdaforums huggingface dataset:
[Google Home] bj00rn:
Pretty much worked the third time around. Started mtk gui app and powered on the device with both volume buttons held until i saw that connection had been established in the GUI.

Are you sure that you have wired it up correctly and have a stable connection? What does it say in mtk gui. I there should be some debug info in there.
[Google Home] bj00rn:
What pins did you get?
[Google Home] cmccambridge:
On more practice here, I believe only VOL+ is actually necessary... likely my original note on both volume buttons was a result of the flaky/timing-sensitive nature rather than a real requirement.

I haven't run mtkclient or the GUI on Linux to compare... on the Windows version, it repeatedly runs a connection attempt in a loop. Each attempt waits several seconds, then times out and tries again. In that looping mode, I found it was critical to plug in the power cable at the end of a previous loop. This gave just enough time for mtkclient to circle around and start trying to connect again while the very first power-on steps were taken by the clock, so that the bootrom interface window would overlap with the mtkclient listening window. Again, might be a Windows-only nuance, but just in case it helps :)

This is a good point - given that getting the bootloader to connect is a little flaky, I'd first make sure that your hardware is working properly. Let the device boot all the way up, and you should be able to see some USB device connected, either a MTP interface or an ADB interface depending on whether you enabled USB Debugging. (e.g. should see an entry in lsusb output, for vendor ID 0x0e8d... from my testing:

Vendor ID	Device ID	Function
0x0e8d	0x0003	Boot ROM serial port (requires holding VOL+ while powering on, only connected for a second or two unless you have mtkclient running to handshake with it)
0x0e8d	0x2000	MediaTek PreLoader - also appears only briefly unless you have mtkclient running.
0x0e8d	0x2001	MediaTek DA (download agent) - appears as one stage during the mtkclient operation
0x0e8d	0x2008	MTP Interface, shows up as "LenovoCD-24502F" when clock is fully booted and USB debugging is not enabled (even without root or sideloaded apps)
0x0e8d	0x201c	Android ADB Interface, shows up when fully booted with USB Debugging enabled
[Google Home] cmccambridge:
I'm finally getting around to fixing my volume buttons, but am struggling to recreate this success... I've got the two files edited in the RW /system overlay, and adb shell cat /system/etc/device* confirms my edits are in place. Yet, Key Mapper still complains that my volume actions won't work due Do Not Disturb mode.

Were there any other changes you made @bj00rn, to try and grant that ACCESS_NOTIFICATION_POLICY permission? Even after updating the XML files to set keymapper as the device owner & admin, I'm still failing when I try to grant that permission either through the app (drops me at that settings page about "Do Not Disturb is not supported on your device") or through adb:

λ adb shell pm grant io.github.sds100.keymapper android.permission.ACCESS_NOTIFICATION_POLICY allow
Security exception: Permission android.permission.ACCESS_NOTIFICATION_POLICY requested by io.github.sds100.keymapper is not a changeable permission type

java.lang.SecurityException: Permission android.permission.ACCESS_NOTIFICATION_POLICY requested by io.github.sds100.keymapper is not a changeable permission type
at com.android.server.pm.permission.BasePermission.enforceDeclaredUsedAndRuntimeOrDevelopment(BasePermission.java:429)
at com.android.server.pm.permission.PermissionManagerService.grantRuntimePermission(PermissionManagerService.java:2195)
at com.android.server.pm.permission.PermissionManagerService.access$900(PermissionManagerService.java:125)
at com.android.server.pm.permission.PermissionManagerService$PermissionManagerServiceInternalImpl.grantRuntimePermission(PermissionManagerService.java:3193)
at com.android.server.pm.PackageManagerService.grantRuntimePermission(PackageManagerService.java:5804)
at com.android.server.pm.PackageManagerShellCommand.runGrantRevokePermission(PackageManagerShellCommand.java:1955)
at com.android.server.pm.PackageManagerShellCommand.onCommand(PackageManagerShellCommand.java:230)
at android.os.ShellCommand.exec(ShellCommand.java:104)
at com.android.server.pm.PackageManagerService.onShellCommand(PackageManagerService.java:21998)
at android.os.Binder.shellCommand(Binder.java:881)
at android.os.Binder.onTransact(Binder.java:765)
at android.content.pm.IPackageManager$Stub.onTransact(IPackageManager.java:4860)
at com.android.server.pm.PackageManagerService.onTransact(PackageManagerService.java:4076)
at android.os.Binder.execTransactInternal(Binder.java:1021)
at android.os.Binder.execTransact(Binder.java:994)

Did you do anything additional like removing keymapper as the device admin, etc.?
[Google Home] cmccambridge:
(Re-)Success: Restoring Volume Keys by setting Key Mapper as Device Owner​

Ah ha! Looking at the overlayfs project used above (which was failing for me in my previous post...), I realized it's been under heavy development since the time of your first post... and has (potentially?) undergone some significant revisions in how it's implementing the overlayfs itself.

Got me thinking... perhaps it only worked at the proper stage of boot in an earlier release, and not in the current one I tried (v2.24). It certainly did work, eventually, as I was seeing the desired content in the modified files... but yet Key Mapper was acting as though it were not a Device Admin and kept bouncing me back to the Do Not Disturb problem. I started digging back through the overlayfs version history and realized: before I reverse engineer a very nice, feature-rich overlay option... maybe I can brute force it the same way the BromiteSystemWebView does...

So, I present: keymapper-owner, a Magisk module that does nothing except smash /system/etc/device_owner_2.xml and /system/etc/device_policies.xml with the updated versions pointing to io.github.sds100.keymapper that @bj00rn figured out in the earlier post:

For anybody else looking for the smash-and-grab version of making Key Mapper be your device admin to restore the Volume keys, attached is a magisk module that will do it. (Don't have to take my word for it: the ZIP file is just a couple tiny text files that you can quickly read to validate that nothing else is happening in there :) )

This recreates @bj00rn 's earlier success (without relying on overlayfs) by simply overwriting the two critical files in /system/etc using a Magisk module, early enough in the boot cycle to have the desired effect: 🎉

Steps:

1. Download attached keymapper-owner-magisk-v0.1.zip file

2. Push to your device

3. Install as a Magisk module from storage

4. Reboot

🎉
[Google Home] bj00rn:
Yes turns out filesystem was unsupported in early versions. Fixed by dev but i think there were a few broken releases until he got it right. Should work in latest release though.

Quite handy to have a rw system to experiment with. I've been experimenting with the audio xml files to try to fix the broken recording sample rate with no so success so far.

A thing i would like to try out is to remove the device admin altogether to achieve an 'unmanaged' device. Once the device is unmanaged, granting restricted permissions should work. Not sure how the system would react though.

Also there seems to have been deprecations around device owner in android 10, can't wrap my head around the docs though.
[Google Home] bj00rn:
Maybe fixed in: https://github.com/Nailik/rhasspy_mobile/issues/326#issuecomment-1524864150
[Google Home] Syco54645:
Yes it is wired correctly. When the clock has booted I see it as a device. I have mtk client connecting but when it attempts to dump preloader the device drops. I have tried windows 10, windows 11 and various versions of Linux. All produce the same results. I must be missing something here.
[Google Home] bj00rn:
Im clueless im afraid :-(.

I think linux is your best bet here to avoid any driver related errors. Timing is crucial to get it to connect.

This looks wierd..

Maybe try asking on mtkclient github if you are stuck.
[Google Home] bj00rn:
See https://github.com/bkerler/mtkclient/issues/672
[Google Home] Syco54645:
Thank you for the info and link. Unfortunately the live cd does not actually boot, at least that I can figure out. I burned it to a DVD, not bootable. Used balena etcher, Unetbootin, Ubuntu startup disk creator, and a few others. None ended up bootable. I will try to install 22.04 and then apply the kernel patches I guess.
[Google Home] Syco54645:
No idea what the issue was before, got it working first try today. I have 2 rooted clocks now.
[Google Home] bj00rn:
Did you manage to get the clock working as a rhasspy sattelite?

The patched version is rhasspy mobile captures audio fine, but im struggeling to get the configuration (base and sattelite, MQTT) working..

Do you mind sharing your config?
[Google Home] gfluf:
Sorry for letting you wait this long, somehow the notification slipped by unnoticed. 😇

Currently I don't need/use the wake word detection on the smart clocks, so I'm not sure whether it actually works. Apart from that everything seems to be working. The overall setup consists of three satellites and a dockerized variant of mosquitto as the MQTT-broker.

I attached an export of the current configuration running on one of the clocks. It is based on an earlier version of this tutorial from the official rhasspy documentation. It's probably not the final/cleanest configuration, but the MQTT-related stuff has been stable for a while.

Hope this helps :)
[Google Home] bj00rn:
Thanks! Will give it a go? No luck with wake word detection so far.
[Google Home] bj00rn:
Seems that porcupine is not using the settings. Its using its own audio stream (MONO@16khz) so local wake is still broken.

Advanced Porcupine Recording settings · Issue #384 · Nailik/rhasspy_mobile

Add an option so users can choose whether porcupine also uses the advanced audio input settings. This issue is a follow up to #326 Use this function to process incoming data https://github.com/Pico...

github.com
[Google Home] SmartAlex2010:
Did anyone get any .img files or can someone extract some for me so that I can install Magisk on the clock? (I'm sorry if anyone put them in here already, I'm lazy.)
[Google Home] SmartAlex2010:
Once you have installed a different launcher you could alternatively use a Bluetooth keyboard connected via settings to make it faster to get a keyboard installed on the clock.
[Google Home] Jocaru:
Hello all!

I've got some Lenovo Smart Clock 2 devices in my hands that are the demo versions. I already have a couple that I bought before for myself and rooted one of them (I had to end up soldering the cables to the PCB but have unsoldered them because I use the wireless charging base). I'm trying to recover somehow the demo units but had no luck yet, it seems it boots differently and I can't unlock it.

I would like to ask one of you (@cmccambridge @bj00rn ??) if you can make a full backup of your device firmware so I can try to flash it, and also for some ideas to unlock it.

I already tried with typical fastboot commands but they do not work. I also tried using mtkclient but it seems that the device is not recognized when booting with vol- and vol+.
[Google Home] mclayton7:
I've tried to follow the instructions posted here, along with this guide: https://github.com/ThomasPrior/LenovoSmartClock2. The only caveat is I had to roll back to v1.52 of mtkclient because the main branch was giving me errors. After attempting to flash the Magisk-patched firmware (python mtk w boot,vbmeta boot.patched,vbmeta.img.empty) I'm stuck on the clock showing "FASTBOOT mode..." Any ideas what I did wrong and whether or not there's a way to recover? I tried re-flashing the original boot.img and that did not work either.

Any thoughts? Thanks for the help!
[Google Home] Mdausch:
Has anyone had any experience with the clock resetting the default home app?

I’m trying to set WallPanel as mine, and after a while of sitting it seems to crash and prompt for which launcher to use.
[Google Home] Mdausch:
Not sure if it’s having trouble with this since I have multiple options for which launcher to use (I have it set up right now for the smash action to open last launcher)
[Google Home] zuz242:
First off, thanks for your effort. I printed and build the pogo programming stand and succeded to root one of my 2 clocks ;)

The second clock i kind of bricked, im afraid. After writing the patched bootimage back it is stuck in a "orange state" boot loop. Any idea where i went worng or how to fix it?

Trying to factory reset (with holding both bottons at start to get into recovery / fastboot shows the same loop..
[Google Home] Dismal.:
Anyone tried changing qemu.hw.mainkeys=1 to qemu.hw.mainkeys=0 so you can use a nav bar. (Root is required)
[Google Home] Patricen:
Hello, I do have 2 smart clocks and for any reason one of the purchased clocks requires an update that does not proceed. Is there a way to clone one of the clock's ROM to the other (I do have a dock with USB)?

Thanks!
[Google Home] CobreDev:
All of this information is fantastic! I plan to find some pogo pins and print a USB adapter dock soon. I also have a second clock on the way.

Has anyone figured out how to control the light on the wireless charging dock? That would be very nice to have exposed to Home Assistant somehow!
[Google Home] CobreDev:
Update: I’ve found a GitHub project that claims to be able to control the light. I haven’t had a chance to try it, but i’m linking it here:

GitHub - TymEK49/Lenovo-Smart-Clock-2

Contribute to TymEK49/Lenovo-Smart-Clock-2 development by creating an account on GitHub.

github.com
[Google Home] Criminal90:
I've tried and works perfectly!

Thanks
[Google Home] Dismal.:
Also found this inside the OTA app https://smartdmdl-stage.lenovo.com/...01215083419869/otapackage/update_007to008.zip. Also saved to wayback machine just in case.
[Google Home] calvinium:
Hi,

Just aquired one of these in great condition with the wireless charging dock from a local Op Shop. First thing I did after a wipedown and a factory reset was start looking for custom firmware and found this thread. I see in one of the early posts, someone dismantled the dock and identified pads for an unpopulated micro USB connector, but I think they only did a precursory check whether the pads go through to the pogo pins, as they surmised it was not able to be used.

Not sure if this has been corrected or not, but on doing a similar teardown of my unit, I found that the ground and power pins of the micro USB pads do go straight to the correct pogo pins on the dock, and that the D+ and D- go to a set of unpopulated bridge jumpers, which the other sides do go straitght to DP and DM on the pogo pins. There is also the USB OTG line that has a number of unpopulated components between it and the CH552T USB controller chip (that were unfortunately cropped during the photo editing on my phone). These may have just been another bridge and maybe an LED? I'll reexamine when I have time on the weekend. The USB data lines switch to the other side of the board via some ... vias.

The bridge jumpers are on the same side as the pogo pins (ie the opposite side to the micro USB pads), in the corner near the DP pin of the pogo pins (see photo below)

So, in summary, it should be possible to use the micro USB pads to populate a USB connection on the wireless charging dock that interfaces with a clock when mounted. I'll try and investigate further on the weekend, time permitting
[Google Home] trout_of_death:
Alright guys, stupid question. I've been out of the rooting game for years now. However, I'm trying to use this clock to display my HA Dashboard and it needs a new WebView to display properly. I don't have the dock, I don't have a 3d printer, and I can't find a way to enable wireless adb/install Magisk w/o having ADB first to put the install files on.

Has anyone been able to update the WebView w/o needing to do the USB hack?

Option B, I really don't have the time to invest in this right now, but I would like this working. Can I just pay someone who's done it on theirs to do mine?
[Google Home] Banana9123:
I’ve also got a problem, I tried adding a pin lock in settings to the device, and used a key remapper to lock it, but once I did this, the clock only loads the Lenovo logo, and doesn’t function, any ideas? Holding volume up and down doesn’t work to reset it

How do you make the pogo stand?
[Google Home] Banana9123:
How do you get one of the usb connectors, and the pogo pins?
[Google Home] cmccambridge:
I got a USB connector by cutting an old spare USB cable in half and soldering on to the wires.

For individual pogo pins, I appear to have ordered from AliExpress many years ago, specifically this item, though any 0.5mm pogo pins should work fine for that specific dock option. Or you could use small drill bits to expand the holes to a larger diameter for other larger pogo pins. I usually end up using my pin vise drill to clean up 3D prints of small diameter holes like this regardless, to avoid bending the pogo pins when I insert them.

For the PreciDip all-in-one option, check for an electronics distributor in your area, e.g. in the US I would order from Mouser or Digikey.
[Google Home] Banana9123:
Thanks, and for unlocking it I after I set up a password, would I need to root it?
[Google Home] cmccambridge:
I apologize, I don’t understand the question. My devices had no password.

From the USB connection you’re interfacing with earlier stages of the boot process than the ultimate Android image, so options probably exist if you need to make further modifications or reflash it. Unfortunately that’s beyond my expertise.
[Google Home] Banana9123:
So I used the “calendar method” of downloading a keyboard and launcher, and once I had access to full android (not rooted though) I added a pin to login through settings, then the device shut off and locked itself, and when it boots, it doesn’t give me the option to enter my pin, it just shows the Lenovo logo
[Google Home] cmccambridge:
Ah, I see. I don’t know how PIN lock works on Android in general nor these mediatek chips in specific, though it’s been a recurring theme with the clocks that they lack many of the expected bundled applications and UIs, making stock Android features behave poorly or fail.

Perhaps one of the USB interfaces accessible through the dock during boot would let you factory reset the device and clear the lock, or perhaps the lock is a deeper function of the chip that also locks out the factory reset flow… no idea.

Good luck!

If nothing else, other folks reading this thread will likely want to be very wary of setting a PIN!
[Touch Pro, Fuze General] Nipje:
Hello,

I have a very strange problem with my HTC Touch Pro phone.

I'll explain my problem:

When you turn on your phone and you are on the "Home page" (the page where the time is displayed) there is a bar at the bottom of the display.

This bar says Phone and Programs.

When i access my volume control by using the 2 buttons on the left side of the phone a black screen appears with some bars on it to indicate the volume. Note that the black bar with the Phone and Programs buttons is gone!

But the problem is that i can slightly see the Phone and Programs text trough the black screen of the volume control...

The first time i turned on my phone it was clearly visible, but after hard-resetting my phone 3 times it seems to be all gone now.

What could have caused this problem? Are these texts burned into my screen or is my screen sensetive to white letters?

I really dont know what to think about it because it seems very strange to me that it is now gone after 3 hard-resets...

Does anyone know what may have caused this problem?

edit

When i still had the problem i checked out if the text that was visible on the volume screen was the actual text that should stand in the black bar on the bottom, but when i accessed the volume control from the Programs tab (notice that the menu bar then displays "All programs" and "Remove"), but the volume controll still displayed Phone and Programs, so it isn't the actual text that is visible, so it cant be something like a shine-trough or something like that.

Really dont know what to think, at this time 3x hard-resetting the phone helped and the texts aren't visible anymore, but i'm still worried that my screen is over-sensitive or maybe broken or something =\

edit

The text is getting visible again after having my phone on "stand by" for 10 minutes.
[Touch Pro, Fuze General] Nipje:
Does anyone has a solution or does anyone knows what the problem can be? i would like a awnser today because i could go the the store tomorrow, i may be able to switch it for a new one if the screen is really broken.

Hope someone knows more!

edit

Maybe some of you dont see it on your one Touch pro, but you will if you REALLY look close at the bottom left and right corner in your volume control screen.

Could it have something to do with lazy pixels or something?

edit

It seems to get worse when i have the phone and programs texts on my screen for 10 minutes, and then switch to volume management. Are my pixels lazy or something?
[Touch Pro, Fuze General] Nipje:
The longer the screen stays on with the Phone and Programs texts on and the icons of the menu etc, the more you see when you turn on volume control.

it just looks like it burns into my screen.
[Touch Pro, Fuze General] johanromijn:
Take care! Maybe it burned into your eyes!

No, serious it cannot burn into your screen.

Only CRT screens can burn it, not TFT.
[Touch Pro, Fuze General] Nipje:
Hmm ok thats true haha,

But what else can cause such a problem... it is only visible if the phone is off stand by for a few minutes.

I had my phone on stand by the rest of this evening and just turned it on and now it is all gone again. But if i put my phone on the home screen for a few minutes, so with the texts, then its visible again on the volume controll screen
[Touch Pro, Fuze General] Nipje:
Had the phone on standby the whole night and now the texts are gone again.

They seem to get "burned" in somehow if the phone is off standby for a few minutes, but then when its on standby for a while they are gone again.

Just wanna know if more people have the same problem, or else i could send back my phone to HTC for a repair
[Touch Pro, Fuze General] Black93300ZX:
http://compreviews.about.com/od/monitors/a/LCDBurnIn.htm
[Touch Pro, Fuze General] Nipje:
Well that seems to be the problem over here...

But when i turned on the phone for the first time there was much more "image burning" on the screen, and at this moment it is all gone ...

Could it be that the screen had to "warm up" or something because the phone is just 2 days old. The longer i used the phone the less the image burning is now.

Do these screens have to warm up or something when you turn on the phone the first time?
[Touch Pro, Fuze General] Black93300ZX:
They shouldn't... Especially if you bought it locally, I'd take the safe road and return it. I'm not sure if it's exactly what that source describes, but I don't like taking chances with phones as expensive as this.
[Touch Pro, Fuze General] Nipje:
Hmm ok, thats wierd because the more i used it the less burned in texts are visible.

at this point there is nothing visible on my screen anymore ..

isnt there ANYONE else here that has the same problem or that wants to try it out and leave the phone off standby for some time ? :P
[Touch Pro, Fuze General] Nipje:
Someone that has the same problem, or someone who wants to check their phone for the same problem?

I dont know if i should return my phone for a repair..
[Touch Pro, Fuze General] Nipje:
Problem is getting visibl again,

Have used my phone some time today, but i didnt have it off standby for longer than 1 minute, and still there is a white bar slightly visible on the volume controll screen.

This is definately a problem with the screen right? something like Lazy pixels or something..

Anyone that can help?

btw, its seems that only the white colors get burned in

edit

It only seems to get "Burned" in when i'm in a window with white bars or spaces, and it fades when i have the phone on a black screen for a while..