yashsingh1/xdaforums huggingface dataset:
[Wear OS General] letsgoflyers81:
I'm stuck at the same place you are. When I run "adb shell getevent" from the command prompt I get results that show "gpnp_pon" for event1 and there's no "bcmpmu_on". So I've tried "adb shell sendevent cat /dev/input/event1 > /sdcard/doubletap" and "adb cat /dev/input/event1 > /sdcard/doubletap" and both give me the same error, "The system cannot find the path specified."
[Wear OS General] qingtest:
Hi I hoped to make it clear but was too lazy to wrote every detail where I assume readers were familiar with adb.

This is the answer for you two:

①You should know the basic idea is to simulate keypress.

The "input keyevent" does not have the ability to simulate a double tap, that's why we need to use adb to record.

The recorded data is put in the file "doubletap"

②From your question, I guess you are not so familiar with cmd right?

If you run "adb cat /dev/input/event1 > /sdcard/doubletap" in dos cmd, it will actually only run the command "cat /dev/input/event1 " and retrieve the result then write to a file "/sdcard/double" in windows. However, windows does not have such a path, that's why error is reported.

③ sorry I only have played with my own watch, I think the one ‘**on’ should be equivalent to my 'bcmpmu_on'.

④ To do it right, you need to quote the command like this: adb shell "cat /dev/input/event1 > /sdcard/doubletap"

Or first go into adb shell ,then run the command (like below picture)

↑After double press, press Ctrl+C to stop. Then adb will exit with "^C"

The file should already in /sdcard/, can check like below: (in your case doubletap)

Now you can simply run below command to test. should toggle theater mode 100%: (in your case doubletap)
[Wear OS General] letsgoflyers81:
I'm familiar with command prompt and know the basics with adb. I guess it was confusing that some of the steps were very detailed so I could do exactly what you wrote, but some steps were missing things and I didn't realize it. Thank you for your patience.

After doing what was in your last post I'm able to toggle theater mode from adb on my laptop while my laptop is connected, so that's great. However doing it from the Wearshell intent still doesn't work. I copied the code you posted and changed event2 to event1, but I'm pretty sure the problem is that your code uses su and my watch is not rooted. Do you know what the code would look like without using root?

This is the error I got from Wearshell
[Wear OS General] qingtest:
I just updated my watch to 5.1.1, so lost root. The code is no longer working for me either. I confirm the input and cat do not necessarily need su permission.

However, I don't have an existing code for you ( i am relative new in beanshell too). Will try and share with my spare time (you are welcome to do so too ;))
[Wear OS General] insaned:
Thanks a million for the patience to the detailed adb explanation which helped a lot!

Already working both in Adb, Wearshell and tasker intent. I have the Watch rooted..

However I DID a slight change to the code, I had to remove the " input keyevent 26" from the line, because it was causing only the screen to turn on and without it works great. The double tap on the button for theater mode doesn't need screen on anyway, so I gave it a shot to remove and it worked.
[Wear OS General] insaned:
Working on the rooted 5.1.1 version

Thanks
[Wear OS General] matejdro:
Actually here is easier version:

settings put global theater_mode_on 1

settings put global theater_mode_on 0

(Tested on 5.0.1. Does anybody have working SuperSu zip for 5.1.1?)
[Wear OS General] letsgoflyers81:
insaned said he has rooted 5.1.1 so it must be out there. Where is that code you posted entered?
[Wear OS General] matejdro:
It is shell command like all above.
[Wear OS General] insaned:
I'm not at home laternIncan provide de zip, but a Google searchnfor supersu wear will make it show up for sure.
[Wear OS General] matejdro:
I heard old SuperSU does not work on 5.1.1 so I was looking for new one but now I flashed old one and it looks like it works so no need for link for me. Thanks.
[Wear OS General] letsgoflyers81:
I used Wear-SuperSU-v2.40.zip and it rooted my G Watch R fine.

While connected to my laptop I can run the adb shell commands you posted and my watch does go in and out of theater mode. I'm sorry but can you explain this to me like an idiot? Where do I enter the commands to get them to run on the watch? If I just use a run shell action in Tasker it'll run them on the phone, not the watch.
[Wear OS General] matejdro:
If you want to run it via tasker on watch you can run this bsh script (check first post on how to run these):

import java.lang.Runtime;
import java.io.DataOutputStream;
Process su = Runtime.getRuntime().exec("su");
DataOutputStream outputStream = new DataOutputStream(su.getOutputStream());
outputStream.writeBytes("settings put global theater_mode_on 1\n");
outputStream.flush();
[Wear OS General] letsgoflyers81:
OK I wasn't sure because you said that was the easier version but I didn't know how much of what from the OP was still needed. So it's still doing everything from the OP just using that as the code saved as bsh script that I push to the watch, correct?
[Wear OS General] matejdro:
Correct.
[Wear OS General] letsgoflyers81:
Thank you, I got it. Now my watch goes into theater mode when plugged in, and it turns off when I unplug it.
[Wear OS General] Dacoco:
Is it possible to disable the automatic wake up when connected to my car bluetooth? I don't mean theater mode because i still want to get the notifications but no accidentialy lighting up while driving.

Is this possible without root?

Is it possible to root OTA?

Thx!
[Wear OS General] Rorschach666:
Hi Guys, this requires rooted android wear or phone rooted only? I ask because I wasted a lot of time to run it, unsuccessfully :crying: I have unrooted Smartwatch 3 and rooted Samsung Galaxy K ZOOM...
[Wear OS General] matejdro:
Works with unrooted phone, but watch must be rooted.
[Wear OS General] Rorschach666:
OK, thanks! Is there currently any way and toturial to root wear 5.1.1?
[Wear OS General] matejdro:
Check in your device's forums.
[Wear OS General] Alahdal:
Excellent, it is working fine.

With the new firmware for SW3. Double tap always enable the theater mode and one tap disable it. So, I created two files, one with double tap event and the other one tap event

Posted via Tapatalk
[Wear OS General] ShadowEO:
I wanted to share an easy tasker WearShell recipe with you guys. I have two Tasker tasks, one is to turn theater mode on, the other is to turn it off.

In the task, add a Send Intent action with these parameters:

On:

Action: de.fun2code.android.wear.shell.EXEC

Extra: bsh: Runtime.getRuntime().exec("su -c settings put global theater_mode_on 1");

Off:

Action: de.fun2code.android.wear.shell.EXEC

Extra: bsh: Runtime.getRuntime().exec("su -c settings put global theater_mode_on 0");

Off will turn off theater mode, however still leave the watch screen off, however the screen will come back on with the next tap and theater mode will be off.
[Wear OS General] Alahdal:
I'll try this on my sony SW3

UPDATE : works

Posted via Tapatalk
[Wear OS General] ShadowEO:
Glad it works for you. I'm working on other scripting ideas for my watch but can't think up anything :P

The code should work on all Android Wear based watches that support running WearShell as the code is simply telling the JVM to run the command. Either way, this opens the door for a lot of scripting on android wear.
[Wear OS General] danividalg:
LG G Watch R - Please, share your /sdcard/doubletap file

Hi,

I have a LG G Watch R smartwatch, I have tried to do this first step to generate the "doubletap" file.

The problem is that I'm not able to enter adb shell into my smartwatch.

I do the following:

- Enable debugging in my phone

- Enable debugging in my LG G Watch R

- Execute "adb forward tcp:4444 localabstract:/adb-hub"

- Execute "adb connect localhost:4444"

- Execute "adb devices" and get "localhost:4444 offline"

If I try to execute "adb shell" or any other I get message "device offline"

I have googled very much to fix this and the only possible solution I have found is to clear cache and data of "Android Wear" and "Google Play Services".

I don't want to make this because this will missconfigure many things and I will need to reconfigure all it again (I'm lazy, I know)

So, I want to ask everyone that have an LG G Watch R for if can send me by pm or post here the file /sdcard/doubletap generated and tell me the input event discovered (the command that you use to emulate the hardware button double tap, something like "cat /sdcard/doubletap > /dev/input/event2")

This way I do not need the debugging on the smartwatch and only need to use the last part of the tutorial to make this work :)

Thanks in advance and best regards :D
[Wear OS General] danividalg:
SOLVED: LG G Watch R - /sdcard/doubletap file

Ok, I have managed to debug my LG G Watch R not by bluetooth, but usb cable. (Downloaded drivers from here http://www.andromods.com/download-files/how-to-install-android-wear-usb-adb-drivers.html, Turn on ADB mode on the watch by going to about and tapping the build info 7 times and enabling ADB Debugging, Putting my smartwatch in its charging base and connecting it with a normal usb cable to my PC, Using ADB normally)

Now I have two files, one with the "Pressing Hard Buton Once" event and another one with the "Double Pressing Hard Buton" event.

I post it here, remember that this is for the LG G Watch R.

The commands to send the events is "cat /sdcard/hardbutton1 > /dev/input/event1" to make a single press and "cat /sdcard/hardbutton2 > /dev/input/event1" to make a double press.

I want to emphasize that my smartwatch is not rooted (at least at this moment).

Now I will try to use wearshell to use it with tasker and I will report :D
[Wear OS General] danividalg:
Hi again,

After many tries I can't get it working, at least without root in the smartwatch. :(

I don't want to unlock bootloader and/or change recovery or anything else of the stock image.

I would be willing to root the watch but without flashing any non official rom and without changing recovery or anything similar.

Does anyone know a way to root the smartwatch this way?

it's strange, because from the adb shell I can use the command "cat /sdcard/hardbutton2 > /dev/input/event1" or "cp /sdcard/hardbutton2 /dev/input/event1" and works perfectly, but from WearShell this commands or any other similar give me error (permission denied). And with adb shell I can use the command "settings put global theater_mode_on 1" and works perfectly, but from WearShell does not make anything (I suppose that it's a permission denied too).

Does anyone know any way to execute shell commands on the smartwatch like that ones using tasker or any similar tool?

Thanks and best regards :)
[Wear OS General] starstayler:
Thank you
[Wear OS General] Scorchgid:
Attempted this for my SW3 it hasn't worked. I am unsure if I have done something wrong. Would someone send me a task which I can import so I can't least compare.
[Wear OS General] matejdro:
Is your watch rooted? It does not work without it.
[Wear OS General] ShadowEO:
Indeed, the watch needs to be rooted to use the command as the settings command does not work for the normal user. You should also toggle the service status in WearShell at least once (Start it and then Stop it, the service isn't needed for the intents), which will make sure that the service is registered correctly on the watch.
[Wear OS General] Scorchgid:
No it is not rooted. I am a little nervous of rooting my watch apart from this feature is there any massive benefit?
[Wear OS General] ShadowEO:
Not entirely on 6.0.1 at this point, however there are a few very useful options in Advanced Settings for Wear that are pretty nice which are root only. In addition, there are some great kernels here which have extended my battery life tons along with the marshmallow update. I normally get about two days of use out of my watch.
[Wear OS General] pablo71:
Tasker WearShell Recipes !!

I'm excited about new recipes and want to learn some. my huawei watch has no light sensor so I'd love to just say "Ok Google Brightness 6" and have tasker send an intent to wearshell to run a shell command... could we open a new wesrshell tasker recipes thread? ... anyone know where I could get a list of shell commands used to perform android functions? I have autovoice working and intercepting ok google commands already so I got a a lot of functionality and I'm looking for ways to use it. awesome work people.
[Wear OS General] ShadowEO:
WearShell provides a full Java BeanShell implementation and gives access to the Android SDK. I'm sure if you check some SDK reference docs, you may be able to make a wearshell brightness script.
[Wear OS General] khaytsus:
If you use AutoWear, you can certainly do this.
[Wear OS General] pablo71:
SDK reference docs ... will do thank you
[Wear OS General] pablo71:
Wearshell Recipe for Brightness

Modified post of ShadowEO by pablo71 for brightness

I wanted to share an easy tasker WearShell recipe with you guys for brightness

In the task, add a Send Intent action with these parameters: for FULL BRIGHTNESS setting 5 (the number 254 in following tasker intent sets it)

Action: de.fun2code.android.wear.shell.EXEC

Extra: bsh: Runtime.getRuntime().exec("su -c settings put system screen_brightness 254 ");

Brightness Setting 4 = 204

Brightness Setting 3 = 153

Brightness Setting 2 = 128

Brightness Setting 1 = 106

Lower Settings are possible, which is why the app Swapp True Dark is so good, BUT DON'T SET BRIGHTNESS SO LOW YOU CAN'T USE YOUR WATCH

I set my brightness with an autovoice command filter creatively titled "brightness," so my intent looks this:

Action: de.fun2code.android.wear.shell.EXEC

Extra: bsh: Runtime.getRuntime().exec("su -c settings put system screen_brightness %avcommnofilter ");
[Wear OS General] manfredST:
I found a totally other solution for setting watch to screen off during the night.

I use tasker and autowear:

create a profile with autowear commandevent &powerconnected& starting a task with autowear single screen. text color black, backgrnd color black, timeout (in advanced) 36000.

create a second profile with autowear commandevent &powerdisconnected& starting a task with autowear app (launch system app Watch Face).

thats it.

if you connect your watch to power, the 1st profile open a black screen at the watch. this black screen will stay for 36000sec (10h)

if you disconnect the watch, the 2nd profile set the watchface back to screen and voila !

good luck and enjoy
[Wear OS General] pablo71:
...... that's creative thinking ... haha black screen ... yeah that solves it !
[Android One (First-Generation) Cross-Device Genera] Freetechware:
I am using pac rom, now i want to install cm 12 but for that first i have to install lollipop offcial. But i cannot find stock firmware for my spice android one.

Can anyone help me ?m
[Android One (First-Generation) Cross-Device Genera] lalitcoolbudy:
spice dream uno lollipop stock rom is here using sp flash tool : http://xdaforums.com/dream-uno/general/lollipop-firmware-lmy47o-using-sp-flash-t3062047
[Android One (First-Generation) Cross-Device Genera] ARAVIND_PAVAN:
DON'T CREATE THREADS FOR SOMETHING AS SMALL AS THERE IS A REQUEST THREAD IN THE FORUM LOOK IT AND DON'T flood FORUM WITH THREADS HIT THANKS IF I HELPED
[Android One (First-Generation) Cross-Device Genera] Saurabh K:
https://drive.google.com/uc?id=0B1QJMv9ppGsfb2szQkJMN3pwU0E

Here is the Stock 4.4.4
[Verizon HTC One (M8)] crazykas:
First of all this NOT Covert HTC One M8 Verizon to Fully Compatible T-Mobile Version which you can find here http://xdaforums.com/showthread.php?t=2710720!.I didn't find this & i was told by 2 xda members.I love my vzw m8 & the development here.But i always wanted to flash international roms since im using GSM carrier.As far as i knew we can't flash GSM roms on our CDMA phone expect ALL Variant supports roms.I was reading on a rom thread & i saw a guy that he flash CleanROM on his international 8!:cool:..Then i asked him how & he told me he flash any rom & most importantly he flash All Variant support kernel.Also another guy told me that he is flashing int roms on his VZW M8 & he told me the same about kernel.This is a risk.But i took chance & flash a International ROMs which is EragonM8 http://xdaforums.com/htc-one-m8/development/rom-24-1-eragonm8-1-0-4-16-401-9-sense-t3011968.Then the kernel.WOW!It actually works!:victory:..Enough talk.Here is the guide to flash.

READ CAREFULLY

*Follow the exact steps

*Im NOT responsible for anything happen to your phone!!!

Instructions

1.Download your desire INTERNATIONAL SENSE ROM from here http://xdaforums.com/htc-one-m8/development

*.I've tested ONLY SENSE ROMs.Haven't test AOSP ROMs*

2.Download lONElyX by lyapota from here http://xdaforums.com/htc-one-m8/orig-development/kernel-lonelyx-001-t2881605.

*I flashed 33 & any ALL Variant support kernel would do the job.But i recommend this.

1.Backup your current ROM.

2.

3.Go to recovery & delvick ,sytem,cache,data.Then flash the INT ROM.

4.During the ROM installation select International as your phone model.

5.After the installation DON"T reboot the device.

6.Now flash lONElyX_m8_Sense_kernel_033 kernel.

7.During the kernel installation select Verizon as your carrier.Then select DEFAULT when is asking wich ways install the kernel.Then select repack= repack with RAM disk from current ROM or Universalwhen it asking repack kernel image.(thanks to [MENTION=6489056]JellyKitkatLoli[/MENTION] )

8.Done..:good::highfive:..Now let is reboot..

Roms that i have tested

Erogon = http://xdaforums.com/htc-one-m8/development/rom-24-1-eragonm8-1-0-4-16-401-9-sense-t3011968

Leedroid = http://xdaforums.com/htc-one-m8/development/rom-leedroid-one-m8-l-v1-0-5-t3019102

Kernels you can flash

lONElyX

BeyondStock Kernel

SkyDragon Kernel

HyperNova kernel(Thanks to [MENTION=5021085]Bobbi lim[/MENTION] )

Credit

[MENTION=5021085]Bobbi lim[/MENTION]

[MENTION=6489056]JellyKitkatLoli[/MENTION]

WIthout those two i would never have flash International rom on my VZW M8.

*lyapota for his kernel

*skeleton1911 for his rom

*LeeDroid for his rom

Remember all variant support kernels do the job & select always Verizon as you carrier when kernel flashing..!

Enjoy your new INT ROM!!!:D

WARNING!!DO NOT TRY THIS ON ANY OTHER DEVICE.!!
[Verizon HTC One (M8)] Rushing:
Cool , thanks! Any screen shots to see what I'm missing!?
[Verizon HTC One (M8)] crazykas:
I'll post a video within few hours;)
[Verizon HTC One (M8)] JellyKitkatLoli:
Just a question since I don't know about your carrier but it's a good question since you live in a completely differnet area from mine, How's your reception over there?

With a international rom there shouldn't be a difference with anything from the ROMs over here but I need this information for something.

BTW this will make the VZW m8 into a Fully Compatible T-Mobile Version (However that requires some common SENSE ;) ), that thread is severely outdated for today.

Also about Layopta's kernel; tip - Just pick the international version and do UNIVERISAL RAMDISK, forget about Verizon, free yourself folks, free yourself.
[Verizon HTC One (M8)] crazykas:
I live in Sri Lanka.I have great reception!Thanks for that UNIVERISAL RAMDISK thing.Last time i chose UNIVERISAL,rom didn't rom.That's why i said that.I'll Update the OP.
[Verizon HTC One (M8)] Bobbi lim:
[MENTION=4130472]crazykas[/MENTION] This kernels - BeyondStock Kernel, SkyDragon Kernel & HyperNova kernel all are universal kernel that works as well :cool:

If you use these kernel, whichever ROM you want to flash, be it GSM or CDMA, everything will work fine ;) Just flash the desired ROM and either one of these kernels :laugh:
[Verizon HTC One (M8)] crazykas:
much appriciate your help guys!!!thanks alott:good::good::good:
[Verizon HTC One (M8)] Bobbi lim:
[MENTION=4130472]crazykas[/MENTION] I left out Elite kernel that works as well ;)
[Verizon HTC One (M8)] macro_dgo:
it's great, works perfectly, I flash the rom, Android_Revolution_HD-One_M8_41.0_866186, and works very well.

My carrier is TELCEL, and everything works, SMS, LTE (4G), voice call

The battery is great
[Verizon HTC One (M8)] crazykas:
Nice t hear!!:good:
[Verizon HTC One (M8)] ok_then_so:
verizon HTC m8

I have veizon htc m8 using in pakistan i have installed S rom ( sence 7 ) on it it works absolutely fine no force close apps no bugs and excellent battery life

i recommend S rom with latest sense 7, go fot it

Sorry dont know how to share link but you guys can find it easily
[Verizon HTC One (M8)] dinukap4:
Machn I'm a Sri lankan with a Verizon M8 And I have no idea how to flash this phone and no way to S-off this and Unlock the bootloader if you can link me to the tut on how to do it that would be great! Thanks
[Verizon HTC One (M8)] dottat:
Plenty of threads that actually support this around. Sunshine is your only option.
[Verizon HTC One (M8)] kerryh:
dotatt, I am using your RUU as a base. Will I be able to flash android revolution to my M8 following this method using this kernel?
[Verizon HTC One (M8)] crazykas:
Just make sure you are on latest Verizon firmware before flash flash any ROM and you are welcome to try.Read previous comments then you will see people who have succeeded and I've also flashed almost any GSM international ROM up to date.
[Verizon HTC One (M8)] king_david43:
What about the marshmallow gpe rom can that be flashed too or do the kernels not support 6.0 yet?
[Verizon HTC One (M8)] sob372:
Yes you need a 6.0 kernel, which doesn't yet exist for Verizon

Edit: it does now apparently, try this

http://xdaforums.com/showthread.php?t=3249193
[Verizon HTC One (M8)] MsDosExe:
Your m8 needs to be s-off and unlocked bootloader to do this? I just cannot install any custom recovery on mine so I cannot do any of the steps here, if so, the only way to do this is using sunshine?
[Verizon HTC One (M8)] dottat:
Sunshine to get s-off yes...then you can play.
[Verizon HTC One (M8)] MsDosExe:
I'm following the first post using the same roms and I'm just keep getting an status 7 error when I try to flash any rom. :/ Any hints?

-------

Nevermind, my TWRP was somewhat faulty, I flashed a new TWRP and I was able to flash everything without problems..
[Verizon HTC One (M8)] sid3091:
Any recommendations for which ROM i should try?
[Verizon HTC One (M8)] Theboiamond:
Hi all, does this method could unlock the european LTE band 7?
[Verizon HTC One (M8)] mbwambo:
Thanks bro....

Waooooooo ????? ARHD 50.2.....on my sprint s-off which is not WCDMA........... Working perfect
[Verizon HTC One (M8)] crazykas:
You are welcome bro..Hey where did you get that elemetx kernel? Is it only for sprint m8?
[Verizon HTC One (M8)] mbwambo:
This..elementalX was modded by sundream in S-rom its works for sprint and verison...so its on S-rom thread....

---------- Post added at 08:41 AM ---------- Previous post was at 08:37 AM ----------

I was looking for kenerl working on android 6 and on sprint variant then I found that kernel only modded by sundream..thoug not found on official elementalX......
[Verizon HTC One (M8)] Properly:
[MENTION=3472611]dottat[/MENTION]

[QRCODE]Sunshine to get s-off yes...then you can play. [/QRCODE]

Im S-ON,Verizon,unable to S-OFF,can I still flash international rom on my M8"?
[Verizon HTC One (M8)] dottat:
Nope. HTC Dev won't allow boot loader unlock either. You must get s-off or find another phone if that's what you need.
[Verizon HTC One (M8)] Properly:
[MENTION=3472611]dottat[/MENTION]

OK,can I ask you for a favor.Since I cannot S-OF,can you recommend me a good room for my M8,Im on Verizon,and it started to lag prety much.I dont like it anymore like this.
[Verizon HTC One (M8)] dottat:
If you aren't s-off or unlocked you cannot flash any rom.
[Verizon HTC One (M8)] Properly:
Anyway,thank you :)
[Verizon HTC One (M8)] crazykas:
hey can you give me a link?
[Verizon HTC One (M8)] mbwambo:
Here we go https://www.androidfilehost.com/?w=...ce3ed7001b57b8a0c04644495c31e8c90d8360ad7853c
[Verizon HTC One (M8)] niaz00196:
I am on 4.4.2, s-on, locked bootloader

now what I have to do for flashing international roms?