Frndz those phone are stuck at boot animation bcoz of oc kernal (nand problem) do below following steps:-
you should hv installed on your pc/laptop 1)htc sync
2)adb
Frist flash twrp 2.4.1.0 recovery by cute prince after that,
download flash_erase file from cute prince forum,
now copy cm9 rom and flash_erase file to sd card,
go to recovery(twrp recovery) click install nw install cm9 rom,
nw go to mount and mount system & mount sdcard,
after that go to advanced>file manager>sdcard> in sd card u vill see flash_erase.txt rename dat file to flash_erase,
now copy flash_erase file by clicking on it(it vill show copy option) go back to root of ur internal memory,
there u vill see system,go to system>xbin ,
copy dat file in xbin after copying dat file u vill see flash_erase in xbin folder,
click on flash_erase u vill see chmod755 click it nw go back to recovery and unmount everything,
nw connect ur phone to pc/laptop(u should hv adb and htc sync),
open cmd as administrator>nw copy below all code and paste it in cmd,
code:-
adb shell
su
cd /system/xbin
./flash_erase -N /dev/mtd/mtd2 0 0
./flash_erase -N /dev/mtd/mtd4 0 0
./flash_erase -N /dev/mtd/mtd5 0 0
thanks to sheker developer of flyrom
and cute prince for nand recovery procedure
hit thanks if i helped yuh...
Sent from my HTC Explorer A310e using xda premium
Thank's!
Good work to make it easy for newbies....
Why didn't you create it in general section?
Sent from my HTC Explorer using xda premium
Barkat.Paki said:
Good work to make it easy for newbies....
Why didn't you create it in general section?
Sent from my HTC Explorer using xda premium
Click to expand...
Click to collapse
Thanks n OK I vil make new thread in general :thumbup:
Sent from my HTC Explorer A310e using xda premium
when i type su i get permission denied error.. :/
chand9336 said:
when i type su i get permission denied error.. :/
Click to expand...
Click to collapse
Bro dat happened wid me also so jst copy whole code which starts from adb shell till end of the code dn hit enter dn u vill see "erase complete 100 percent " on cmd :thumbup:
Sent from my HTC Explorer A310e using xda premium
i pasted the whole code and i just get permission denied.. :\
i pasted the whole code and i just get permission denied.. :\
Click to expand...
Click to collapse
Cn u gve me d log cat or take a picture of dat cmd and send me
Sent from my HTC Explorer A310e using xda premium
[email protected]:/system/xbin $ ./flash_erase -N /dev/mtd/mtd2 0 0
flash_erase: error!: /dev/mtd/mtd2
error 13 (Permission denied)
255|[email protected]:/system/xbin $ ./flash_erase -N /dev/mtd/mtd4 0 0
flash_erase: error!: /dev/mtd/mtd4
error 13 (Permission denied)
255|[email protected]:/system/xbin $ ./flash_erase -N /dev/mtd/mtd5 0 0
flash_erase: error!: /dev/mtd/mtd5
error 13 (Permission denied)
255|[email protected]:/system/xbin $ ./flash_erase -N /dev/mtd/mtd2 0 0
./flash_erase -N /dev/mtd/mtd2 0 0
flash_erase: error!: /dev/mtd/mtd2
error 13 (Permission denied)
255|[email protected]:/system/xbin $ ./flash_erase -N /dev/mtd/mtd4 0 0
./flash_erase -N /dev/mtd/mtd4 0 0
flash_erase: error!: /dev/mtd/mtd4
error 13 (Permission denied)
255|[email protected]:/system/xbin $ ./flash_erase -N /dev/mtd/mtd5 0 0
./flash_erase -N /dev/mtd/mtd5 0 0
flash_erase: error!: /dev/mtd/mtd5
error 13 (Permission denied)
255|[email protected]:/system/xbin $
chand9336 said:
[email protected]:/system/xbin $ ./flash_erase -N /dev/mtd/mtd2 0 0
flash_erase: error!: /dev/mtd/mtd2
error 13 (Permission denied)
255|[email protected]:/system/xbin $ ./flash_erase -N /dev/mtd/mtd4 0 0
flash_erase: error!: /dev/mtd/mtd4
error 13 (Permission denied)
255|[email protected]:/system/xbin $ ./flash_erase -N /dev/mtd/mtd5 0 0
flash_erase: error!: /dev/mtd/mtd5
error 13 (Permission denied)
255|[email protected]:/system/xbin $ ./flash_erase -N /dev/mtd/mtd2 0 0
./flash_erase -N /dev/mtd/mtd2 0 0
flash_erase: error!: /dev/mtd/mtd2
error 13 (Permission denied)
255|[email protected]:/system/xbin $ ./flash_erase -N /dev/mtd/mtd4 0 0
./flash_erase -N /dev/mtd/mtd4 0 0
flash_erase: error!: /dev/mtd/mtd4
error 13 (Permission denied)
255|[email protected]:/system/xbin $ ./flash_erase -N /dev/mtd/mtd5 0 0
./flash_erase -N /dev/mtd/mtd5 0 0
flash_erase: error!: /dev/mtd/mtd5
error 13 (Permission denied)
255|[email protected]:/system/xbin $
Click to expand...
Click to collapse
Set permission to 755
Sent from my HTC Explorer A310e using xda premium
chand9336 said:
[email protected]:/system/xbin $ ./flash_erase -N /dev/mtd/mtd2 0 0
flash_erase: error!: /dev/mtd/mtd2
error 13 (Permission denied)
255|[email protected]:/system/xbin $ ./flash_erase -N /dev/mtd/mtd4 0 0
flash_erase: error!: /dev/mtd/mtd4
error 13 (Permission denied)
255|[email protected]:/system/xbin $ ./flash_erase -N /dev/mtd/mtd5 0 0
flash_erase: error!: /dev/mtd/mtd5
error 13 (Permission denied)
255|[email protected]:/system/xbin $ ./flash_erase -N /dev/mtd/mtd2 0 0
./flash_erase -N /dev/mtd/mtd2 0 0
flash_erase: error!: /dev/mtd/mtd2
error 13 (Permission denied)
255|[email protected]:/system/xbin $ ./flash_erase -N /dev/mtd/mtd4 0 0
./flash_erase -N /dev/mtd/mtd4 0 0
flash_erase: error!: /dev/mtd/mtd4
error 13 (Permission denied)
255|[email protected]:/system/xbin $ ./flash_erase -N /dev/mtd/mtd5 0 0
./flash_erase -N /dev/mtd/mtd5 0 0
flash_erase: error!: /dev/mtd/mtd5
error 13 (Permission denied)
255|[email protected]:/system/xbin $
Click to expand...
Click to collapse
Before flash commands run "su "
Sent from my HTC Explorer A310e using xda app-developers app
i am getting this
* daemon not running. starting it now on port 5037 *
* daemon started successfully *
su
cd /system/xbin
./flash_erase -N /dev/mtd/mtd2 0 0
./flash_erase -N /dev/mtd/mtd4 0 0
./flash_erase -N /dev/mtd/mtd5 0 0
su
cd /system/xbin
./flash_erase -N /dev/mtd/mtd2 0 0
./flash_erase -N /dev/mtd/mtd4 0 0
./flash_erase -N /dev/mtd/mtd5 0 0
~ # su
/sbin/sh: su: not found
~ # cd /system/xbin
/sbin/sh: cd: can't cd to /system/xbin
~ # ./flash_erase -N /dev/mtd/mtd2 0 0
/sbin/sh: ./flash_erase: not found
~ # ./flash_erase -N /dev/mtd/mtd4 0 0
/sbin/sh: ./flash_erase: not found
~ # ./flash_erase -N /dev/mtd/mtd5 0 0
/sbin/sh: ./flash_erase: not found
~ # ←[6nsu
theanswer.3 said:
i am getting this
* daemon not running. starting it now on port 5037 *
* daemon started successfully *
su
cd /system/xbin
./flash_erase -N /dev/mtd/mtd2 0 0
./flash_erase -N /dev/mtd/mtd4 0 0
./flash_erase -N /dev/mtd/mtd5 0 0
su
cd /system/xbin
./flash_erase -N /dev/mtd/mtd2 0 0
./flash_erase -N /dev/mtd/mtd4 0 0
./flash_erase -N /dev/mtd/mtd5 0 0
~ # su
/sbin/sh: su: not found
~ # cd /system/xbin
/sbin/sh: cd: can't cd to /system/xbin
~ # ./flash_erase -N /dev/mtd/mtd2 0 0
/sbin/sh: ./flash_erase: not found
~ # ./flash_erase -N /dev/mtd/mtd4 0 0
/sbin/sh: ./flash_erase: not found
~ # ./flash_erase -N /dev/mtd/mtd5 0 0
/sbin/sh: ./flash_erase: not found
~ # ←[6nsu
Click to expand...
Click to collapse
Did u set permission to 755
Sent from my HTC Explorer A310e using xda premium
9282gkg said:
Did u set permission to 755
Sent from my HTC Explorer A310e using xda premium
Click to expand...
Click to collapse
how i can set??
theanswer.3 said:
how i can set??
Click to expand...
Click to collapse
For dat u must hv twrp recovery ,see ma procedure on 1st page
Sent from my HTC Explorer A310e using xda premium
9282gkg said:
For dat u must hv twrp recovery ,see ma procedure on 1st page
Sent from my HTC Explorer A310e using xda premium
Click to expand...
Click to collapse
i've done everything on your first post.
theanswer.3 said:
i've done everything on your first post.
Click to expand...
Click to collapse
K Dan go to recovery mode I.e twrp n mount system dn go to system/ xbin wer u hv pasted flash_erase file Dan click on dat file u vill see chmod 755 tab click on dat tab . Dats how to set permission.. nw connect phone to PC in recovery mod n open cmd as admin. N nw copy whole code n paste in cmd dats it:thumbup:
Sent from my HTC Explorer A310e using xda premium
First of all thanks for the detailed procedure.
Second, there is no xbin folder in system folder. There is only bin folder in system folder!!
vikingmax said:
First of all thanks for the detailed procedure.
Second, there is no xbin folder in system folder. There is only bin folder in system folder!!
Click to expand...
Click to collapse
Bro 1st mount system dan u vill see xbin
Sent from my HTC Explorer A310e using xda premium
9282gkg said:
Bro 1st mount system dan u vill see xbin
Sent from my HTC Explorer A310e using xda premium
Click to expand...
Click to collapse
Thanks alot anyways
Hey I'm trying to unlock my a110 over adb. All known ways didn't work because I can't get permission for critical commands like "rm *key" (no SU rights for ADB) and I can't acess recovery because I use TeamWin which uses touch input. Also Busybox doesn't seem to be installed.
I was trying to get acess by emulating the touch input with "adb shell input swipe x1 y1 x2 y2" but it doesn't work with complex patterns, just seperate lines.
So I'm trying to use sendevents like:
Code:
adb shell sendevent /dev/input/event2 3 0 200
adb shell sendevent /dev/input/event2 3 1 600
adb shell sendevent /dev/input/event2 1 330 1
adb shell sendevent /dev/input/event2 0 0 0
adb shell sendevent /dev/input/event2 3 0 100
adb shell sendevent /dev/input/event2 0 0 0
adb shell sendevent /dev/input/event2 3 0 108
adb shell sendevent /dev/input/event2 0 0 0
adb shell sendevent /dev/input/event2 1 330 0
adb shell sendevent /dev/input/event2 0 0 0
But it doesn't seem to work. Can someone record a swipe pattern over "adb shell getevent" so I can confirm I'm using the correct device?
Or is there a way to use TeamWin Recovery without screen?
USB mouse
bro u can unlock using a USB mouse connected with USB OTG cable.
or try this method. but u need cwm recovery as your touch is broken. install cwm recovery with sp flash tool.
http://forum.xda-developers.com/micromax-a110/help/pattern-lock-t2820060
Thanks that helped!
Hi guys. I googled it and found I should type this to terminal emulator: 'ps | grep zygote'. Every one who had my problem got 1 line as a result, here is mine: '$ ps | grep zygote
634 root 0:13 {main} zygote
2634 u0_a214 0:00 grep zygote
17222 root 0:00 {main} app_process /system/bin com.android.commands.am.Am broadcast --user 0 -a eu.chainfire.supersu.NativeAccess --es su_appname zygote --ei su_fromuid 10207 --ei su_access 2 --ei su_touid 0 --es su_cmd INTERACTIVE --ei su_code 24769 --ei su_uid_mismatch 0 -n eu.chainfire.supersu/.NativeAccessReceiver --receiver-replace-pending --include-stopped-packages
17791 root 0:00 {main} app_process /system/bin com.android.commands.am.Am broadcast --user 0 -a eu.chainfire.supersu.NativeAccess --es su_appname zygote --ei su_fromuid 10207 --ei su_access 2 --ei su_touid 0 --es su_cmd INTERACTIVE --ei su_code 24769 --ei su_uid_mismatch 0 -n eu.chainfire.supersu/.NativeAccessReceiver --receiver-replace-pending --include-stopped-packages
18257 root 0:00 {main} app_process /system/bin com.android.commands.am.Am broadcast --user 0 -a eu.chainfire.supersu.NativeAccess --es su_appname zygote --ei su_fromuid 10207 --ei su_access 2 --ei su_touid 0 --es su_cmd INTERACTIVE --ei su_code 24769 --ei su_uid_mismatch 0 -n eu.chainfire.supersu/.NativeAccessReceiver --receiver-replace-pending --include-stopped-packages
18641 root 0:00 {main} app_process /system/bin com.android.commands.am.Am broadcast --user 0 -a eu.chainfire.supersu.NativeAccess --es su_appname zygote --ei su_fromuid 10207 --ei su_access 2 --ei su_touid 0 --es su_cmd INTERACTIVE --ei su_code 911556 --ei su_uid_mismatch 0 -n eu.chainfire.supersu/.NativeAccessReceiver --receiver-replace-pending --include-stopped-packages
18804 root 0:00 {main} app_process /system/bin com.android.commands.am.Am broadcast --user 0 -a eu.chainfire.supersu.NativeAccess --es su_appname zygote --ei su_fromuid 10207 --ei su_access 2 --ei su_touid 0 --es su_cmd INTERACTIVE --ei su_code 24769 --ei su_uid_mismatch 0 -n eu.chainfire.supersu/.NativeAccessReceiver --receiver-replace-pending --include-stopped-packages
19191 root 0:00 {main} app_process /system/bin com.android.commands.am.Am broadcast --user 0 -a eu.chainfire.supersu.NativeAccess --es su_appname zygote --ei su_fromuid 10207 --ei su_access 2 --ei su_touid 0 --es su_cmd INTERACTIVE --ei su_code 911556 --ei su_uid_mismatch 0 -n eu.chainfire.supersu/.NativeAccessReceiver --receiver-replace-pending --include-stopped-packages
19343 root 0:00 {main} app_process /system/bin com.android.commands.am.Am broadcast --user 0 -a eu.chainfire.supersu.NativeAccess --es su_appname zygote --ei su_fromuid 10207 --ei su_access 2 --ei su_touid 0 --es su_cmd INTERACTIVE --ei su_code 24769 --ei su_uid_mismatch 0 -n eu.chainfire.supersu/.NativeAccessReceiver --receiver-replace-pending --include-stopped-packages
21212 root 0:00 {main} app_process /system/bin com.android.commands.am.Am broadcast --user 0 -a eu.chainfire.supersu.NativeAccess --es su_appname zygote --ei su_fromuid 10207 --ei su_access 2 --ei su_touid 0 --es su_cmd INTERACTIVE --ei su_code 911556 --ei su_uid_mismatch 0 -n eu.chainfire.supersu/.NativeAccessReceiver --receiver-replace-pending --include-stopped-packages
21334 root 0:00 {main} app_process /system/bin com.android.commands.am.Am broadcast --user 0 -a eu.chainfire.supersu.NativeAccess --es su_appname zygote --ei su_fromuid 10207 --ei su_access 2 --ei su_touid 0 --es su_cmd INTERACTIVE --ei su_code 24769 --ei su_uid_mismatch 0 -n eu.chainfire.supersu/.NativeAccessReceiver --receiver-replace-pending --include-stopped-packages
21713 root 0:00 {main} app_process /system/bin com.android.commands.am.Am broadcast --user 0 -a eu.chainfire.supersu.NativeAccess --es su_appname zygote --ei su_fromuid 10207 --ei su_access 2 --ei su_touid 0 --es su_cmd INTERACTIVE --ei su_code 911556 --ei su_uid_mismatch 0 -n eu.chainfire.supersu/.NativeAccessReceiver --receiver-replace-pending --include-stopped-packages
21819 root 0:00 {main} app_process /system/bin com.android.commands.am.Am broadcast --user 0 -a eu.chainfire.supersu.NativeAccess --es su_appname zygote --ei su_fromuid 10207 --ei su_access 2 --ei su_touid 0 --es su_cmd INTERACTIVE --ei su_code 24769 --ei su_uid_mismatch 0 -n eu.chainfire.supersu/.NativeAccessReceiver --receiver-replace-pending --include-stopped-packages
22183 root 0:00 {main} app_process /system/bin com.android.commands.am.Am broadcast --user 0 -a eu.chainfire.supersu.NativeAccess --es su_appname zygote --ei su_fromuid 10207 --ei su_access 2 --ei su_touid 0 --es su_cmd INTERACTIVE --ei su_code 911556 --ei su_uid_mismatch 0 -n eu.chainfire.supersu/.NativeAccessReceiver --receiver-replace-pending --include-stopped-packages
22298 root 0:00 {main} app_process /system/bin com.android.commands.am.Am broadcast --user 0 -a eu.chainfire.supersu.NativeAccess --es su_appname zygote --ei su_fromuid 10207 --ei su_access 2 --ei su_touid 0 --es su_cmd INTERACTIVE --ei su_code 24769 --ei su_uid_mismatch 0 -n eu.chainfire.supersu/.NativeAccessReceiver --receiver-replace-pending --include-stopped-packages
22565 root 0:00 {main} app_process /system/bin com.android.commands.am.Am broadcast --user 0 -a eu.chainfire.supersu.NativeAccess --es su_appname zygote --ei su_fromuid 10207 --ei su_access 2 --ei su_touid 0 --es su_cmd INTERACTIVE --ei su_code 397631 --ei su_uid_mismatch 0 -n eu.chainfire.supersu/.NativeAccessReceiver --receiver-replace-pending --include-stopped-packages
23650 root 0:00 {main} app_process /system/bin com.android.commands.am.Am broadcast --user 0 -a eu.chainfire.supersu.NativeAccess --es su_appname zygote --ei su_fromuid 10207 --ei su_access 2 --ei su_touid 0 --es su_cmd INTERACTIVE --ei su_code 911556 --ei su_uid_mismatch 0 -n eu.chainfire.supersu/.NativeAccessReceiver --receiver-replace-pending --include-stopped-packages
23845 root 0:00 {main} app_process /system/bin com.android.commands.am.Am broadcast --user 0 -a eu.chainfire.supersu.NativeAccess --es su_appname zygote --ei su_fromuid 10207 --ei su_access 2 --ei su_touid 0 --es su_cmd INTERACTIVE --ei su_code 24769 --ei su_uid_mismatch 0 -n eu.chainfire.supersu/.NativeAccessReceiver --receiver-replace-pending --include-stopped-packages
24047 root 0:00 {main} app_process /system/bin com.android.commands.am.Am broadcast --user 0 -a eu.chainfire.supersu.NativeAccess --es su_appname zygote --ei su_fromuid 10207 --ei su_access 2 --ei su_touid 0 --es su_cmd INTERACTIVE --ei su_code 911556 --ei su_uid_mismatch 0 -n eu.chainfire.supersu/.NativeAccessReceiver --receiver-replace-pending --include-stopped-packages
24225 root 0:00 {main} app_process /system/bin com.android.commands.am.Am broadcast --user 0 -a eu.chainfire.supersu.NativeAccess --es su_appname zygote --ei su_fromuid 10207 --ei su_access 2 --ei su_touid 0 --es su_cmd INTERACTIVE --ei su_code 24769 --ei su_uid_mismatch 0 -n eu.chainfire.supersu/.NativeAccessReceiver --receiver-replace-pending --include-stopped-packages
25498 root 0:00 {main} app_process /system/bin com.android.commands.am.Am broadcast --user 0 -a eu.chainfire.supersu.NativeAccess --es su_appname zygote --ei su_fromuid 10207 --ei su_access 2 --ei su_touid 0 --es su_cmd INTERACTIVE --ei su_code 911556 --ei su_uid_mismatch 0 -n eu.chainfire.supersu/.NativeAccessReceiver --receiver-replace-pending --include-stopped-packages
25669 root 0:00 {main} app_process /system/bin com.android.commands.am.Am broadcast --user 0 -a eu.chainfire.supersu.NativeAccess --es su_appname zygote --ei su_fromuid 10207 --ei su_access 2 --ei su_touid 0 --es su_cmd INTERACTIVE --ei su_code 558527 --ei su_uid_mismatch 0 -n eu.chainfire.supersu/.NativeAccessReceiver --receiver-replace-pending --include-stopped-packages
25706 root 0:00 {main} app_process /system/bin com.android.commands.am.Am broadcast --user 0 -a eu.chainfire.supersu.NativeAccess --es su_appname zygote --ei su_fromuid 10207 --ei su_access 2 --ei su_touid 0 --es su_cmd INTERACTIVE --ei su_code 24769 --ei su_uid_mismatch 0 -n eu.chainfire.supersu/.NativeAccessReceiver --receiver-replace-pending --include-stopped-packages
25957 root 0:00 {main} app_process /system/bin com.android.commands.am.Am broadcast --user 0 -a eu.chainfire.supersu.NativeAccess --es su_appname zygote --ei su_fromuid 10207 --ei su_access 2 --ei su_touid 0 --es su_cmd INTERACTIVE --ei su_code 911556 --ei su_uid_mismatch 0 -n eu.chainfire.supersu/.NativeAccessReceiver --receiver-replace-pending --include-stopped-packages
26032 root 0:00 {main} app_process /system/bin com.android.commands.am.Am broadcast --user 0 -a eu.chainfire.supersu.NativeAccess --es su_appname zygote --ei su_fromuid 10207 --ei su_access 2 --ei su_touid 0 --es su_cmd INTERACTIVE --ei su_code 476629 --ei su_uid_mismatch 0 -n eu.chainfire.supersu/.NativeAccessReceiver --receiver-replace-pending --include-stopped-packages
26152 root 0:00 {main} app_process /system/bin com.android.commands.am.Am broadcast --user 0 -a eu.chainfire.supersu.NativeAccess --es su_appname zygote --ei su_fromuid 10207 --ei su_access 2 --ei su_touid 0 --es su_cmd INTERACTIVE --ei su_code 558527 --ei su_uid_mismatch 0 -n eu.chainfire.supersu/.NativeAccessReceiver --receiver-replace-pending --include-stopped-packages
$'
I'm woried. What should I do?
(Also I don't use WhatsApp)
For those on linux, I want to share a bash script that loops over an array of apks to de-install. So you can just list the apps you don't want in a clear overview, and then the script will figure out if it's installed as user or system app and delete it. No harm if the app is not installed, as it will just inform about it.
I put some examples in the list. Please adjust to your needs!
Code:
#!/bin/bash
# list any packages you want to deinstall
apk=(
#google
com.google.android.apps.docs
com.google.android.videos
com.google.android.apps.tachyon
com.google.android.googlequicksearchbox
com.google.android.gm
com.google.android.apps.maps
com.google.android.youtube
com.google.android.apps.youtube.music
com.google.android.apps.photos
com.google.android.apps.wellbeing
com.google.android.syncadapters.calendar
com.google.android.syncadapters.contacts
com.google.android.tts
com.google.ar.lens
com.google.android.marvin.talkback
com.google.android.inputmethod.latin
com.google.android.projection.gearhead
#android
com.android.browser
com.android.chrome
#3rd party
com.facebook.katana
com.netflix.mediaclient
com.linkedin.android
com.alibaba.aliexpresshd
com.amazon.mShop.android.shopping
com.ebay.mobile
com.ebay.carrier
com.facebook.appmanager
com.facebook.system
com.facebook.services
com.netflix.partner.activation
)
for m in "${apk[@]}" #loop through the list of packages
do
package=$(adb shell pm path ${m}) #get installation path for each package
if [ -z $package ] #if no path is found
then
echo "Can't find package ${m}" #then notify
else
if [[ $package == *"system"* ]] #else if package is installed in system path
then
echo "Removing system $package:"
adb shell pm uninstall --user 0 ${m} #then remove it as a system app
else #else package is installed in user path
echo "Removing user $package:"
adb shell pm uninstall ${m} #so remove it as an user app
fi
fi
done
I know about the input tap x y shell command, however, I'm trying to understand how to
perform a click using the sendevent command. I have been able to achieve it with the following command:
Code:
sendevent /dev/input/event5 3 53 X &&
sendevent /dev/input/event5 3 54 Y &&
sendevent /dev/input/event5 0 2 0 &&
sendevent /dev/input/event5 0 0 0 &&
sendevent /dev/input/event5 0 2 0 &&
sendevent /dev/input/event5 0 0 0
Where `X` and `Y` is the position that will be clicked, I'm testing it on the android emulator `BlueStacks 5` which the Display Resolution set to `1920x1080`.
The code is working and the click is fired, however, I couldn't understand how to convert the position where I want to be clicked to the sendevent XY position.
If I send using ADB:
Code:
sendevent /dev/input/event5 3 53 2000 &&
sendevent /dev/input/event5 3 54 2000 &&
sendevent /dev/input/event5 0 2 0 &&
sendevent /dev/input/event5 0 0 0 &&
sendevent /dev/input/event5 0 2 0 &&
sendevent /dev/input/event5 0 0 0
It clicks somewhere around x75 y75, how is this calc done? i mean screen xy -> sendevent xy?
--------------------
How to replicate:
--------------------
* First enable BlueStacks 5 adb in the window: Settings -> Advanced -> Android debug bridge
* Open a cmd window and run cd C:\Program Files\BlueStacks_nxt assuming BlueStacks where installed in the default path.
Execute the commands:
* hd-adb.exe connect 127.0.0.1:X where X is the port shown in the window where you enabled the ADB.
* hd-adb.exe -s 127.0.0.1:X shell
Now we are on the shell, execute a new command: getevent -p
and search for:
Code:
... /dev/input/event5
name: "BlueStacks Virtual Touch"
On my emulator the input event for touch is `event5` on yours it can be different, replace it according.
Now you can simulate a click with the code below changing `XY` to the position where you want to be clicked:
Code:
sendevent /dev/input/event5 3 53 X &&
sendevent /dev/input/event5 3 54 Y &&
sendevent /dev/input/event5 0 2 0 &&
sendevent /dev/input/event5 0 0 0 &&
sendevent /dev/input/event5 0 2 0 &&
sendevent /dev/input/event5 0 0 0
I'm trying to figure out how to convert the emulator screen position to the sendevent position.
For example, if you want to perform a click at `x200 y200`, using sendevent what is the value needed?
How to calculate it?
Note: cross-post StackOverflow.
Bump