[ROOT]Xperia Z1 Touch Screen Tweak - Xperia Z1 General

Since there's no thread about fixing this here in Z1's forum, I'd make one with possible fix on the crazy touch screen problem.
As far as I know, this is a firmware-related problem, and can be fixed by tweaking down the touch screen sensitivity. You'll need
to be rooted to use this modification. Always remember, try at your own risk, and don't forget to hit thanks button if I helped!!
HOWTO:
1. Take a backup with CWM or TWRP.
2. Use any root explorer that you like, and navigate to /system/usr/idc/.
3. Copy the file "clearpad.idc" to somewhere else, like the SDcard storage for editing.
4. Open up the file with Jota+ or the text editor of your choice, and find the line "touch.filter.level". By default it would be 2, but
here I would suggest a value of either 5 or 6 for lowered sensitivity.
Code:
touch.filter.level=6
5.Save the file and then mount /system as writable.
Code:
mount -o remount,rw /system /system
6. Paste the modified clearpad.idc back to /system/usr/idc/ and set correct permissions.
Code:
cp clearpad.idc /system/usr/idc/ && chmod 644 /system/usr/idc/clearpad.idc
7. Remount /system as read-only and reboot.
Code:
mount -o remount,ro /system /system && reboot
Well, this worked for me, and as I know there are lots of people out there irritated by this problem, this should provide a proper
method for restoring the functionality for their Z1's. Now a greasy screen and slight moisture would not upset the touch screen unlike before.
p.s. I'm on NUT's .290 with C6903. This should also work for other models and Android versions.
If this worked for you, then please kindly click on the THANKS button down below <3

I posted this fix already.
I have already posted this fix in 2 threads.

I just did, after testing will post my results
Enviado desde mi C6906 mediante Tapatalk

aznrogerazn said:
Since there's no thread about fixing this here in Z1's forum, I'd make one with possible fix on the crazy touch screen problem.
As far as I know, this is a firmware-related problem, and can be fixed by tweaking down the touch screen sensitivity. You'll need
to be rooted to use this modification. Always remember, try at your own risk, and don't forget to hit thanks button if I helped!!
HOWTO:
1. Take a backup with CWM or TWRP.
2. Use any root explorer that you like, and navigate to /system/usr/idc/.
3. Copy the file "clearpad.idc" to somewhere else, like the SDcard storage for editing.
4. Open up the file with Jota+ or the text editor of your choice, and find the line "touch.filter.level". By default it would be 2, but
here I would suggest a value of either 5 or 6 for lowered sensitivity.
Code:
touch.filter.level=6
5.Save the file and then mount /system as writable.
Code:
mount -o remount,rw /system /system
6. Paste the modified clearpad.idc back to /system/usr/idc/ and set correct permissions.
Code:
cp clearpad.idc /system/usr/idc/ && chmod 644 /system/usr/idc/clearpad.idc
7. Remount /system as read-only and reboot.
Code:
mount -o remount,ro /system /system && reboot
Well, this worked for me, and as I know there are lots of people out there irritated by this problem, this should provide a proper
method for restoring the functionality for their Z1's. Now a greasy screen and slight moisture would not upset the touch screen unlike before.
p.s. I'm on NUT's .290 with C6903. This should also work for other models and Android versions.
If this worked for you, then please kindly click on the THANKS button down below <3
Click to expand...
Click to collapse
too bad, it doesnt work. tried change to 1 or 7, but problem still exist.
there is already other thread talking about tis.

chunlianghere said:
too bad, it doesnt work. tried change to 1 or 7, but problem still exist.
there is already other thread talking about tis.
Click to expand...
Click to collapse
then what can we do?

rasoooli said:
then what can we do?
Click to expand...
Click to collapse
Ive got the problem too with no AFS on the phone ://
Currently, Im able to solve the problem by wiping the phone for like 10secs with my tshirt. After that the touchscreen ALWAYS works flawlessly for like 5 mins. Im going to buy a new protector tomorrow and hope that that is going to fix this issue!

Richylitschy said:
Ive got the problem too with no AFS on the phone ://
Currently, Im able to solve the problem by wiping the phone for like 10secs with my tshirt. After that the touchscreen ALWAYS works flawlessly for like 5 mins. Im going to buy a new protector tomorrow and hope that that is going to fix this issue!
Click to expand...
Click to collapse
Hi everybody!
For me, if i turn off the screen (only with the power button, nothing more), the problem fix during some time (sometimes 5 minutes, sometimes hours).
I have the latest stock version, locked bootloader and rooted. Xperia Z1 C6093.

i think the many problem with the touch screen is by taking of the asf that sony puts on these phones. i took it of 2 days ago and since then it was always doing strange touchscreen things like making selections out of it's own or thinking there where 2 fingers on the screen.

omaroe666 said:
i think the many problem with the touch screen is by taking of the asf that sony puts on these phones. i took it of 2 days ago and since then it was always doing strange touchscreen things like making selections out of it's own or thinking there where 2 fingers on the screen.
Click to expand...
Click to collapse
mine never take out ASF already have strange touchscreen

Related

[Q] Getting past the "Read-only file system"

Ultimately... All I'm trying to do is put my custom ringtone on the internal memory so that it still plays correctly when the sd card is connected to my computer. (Though I certainly wouldn't mind removing the obnoxious "boot_att.ogg" file as well.) But I keep getting thwarted. First by the discovery that there's no /home directory (which kind of weirds me out, but that's a whole 'nother story).
Anyway, my phone is rooted with z4root, and I'm trying to do this by two different methods. [Correction: It would be better to say that I've tried this using two different programs] I've tried using "adb shell," and I've tried using "Android Terminal Emulator". I can successfully use su in both of them (but if I can't rewrite anything, then I don't see what the difference is). Then I go to the directory on my sd card where the cell ring is and I type
cp cell\ ring.mp3 /system/media/audio/ringtones/​
And it replies
cp: /system/media/audio/ringtones/cell ring.mp3: Read-only file system​
So, I found these instructions that say to use "mount -o rw,remount -t yaffs2 /dev/block/mtdblock3" (though I think it needs to be "mtdblock7" for mine) or "mount -o rw,remount -t rootfs /" But when I do either of those, it returns
Usage: mount [-r] [-w] [-o options] [-t type] device directory​
Which I take to mean that the "mount" command isn't being used correctly (and my experience with the mount command on desktop bash is limited, so I don't have any clue how to correct it).
It's worth noting that I have the exact same results in both adb shell and Android Terminal Emulator.
So, I found another thread (I think one on XDA) that said that I need to be in recovery mode to write to /system, which kind of makes sense. But I have no clue how to do that. And Google is not helping. The only instructions I could find said to turn the phone off and hold down the camera and volume up button. Which did nothing. And it's a good thing nobody was watching because I'm sure I looked like an idiot.
So... I guess I'll have to ask, how do I get into recovery mode? But at this point, I keep coming across so many absurd things keeping me from this that I wouldn't be surprised if next I get an error.
Therefore, my question is this: Is there a way to get into recovery mode, or, alternatively, is there a way to keep my ringtone working even while my sd card is connected to my computer?
Do you have busybox installed?
Have you tried Root Explorer? It has a button to toggle read-write and read only in a folder.
I do have busybox installed. I have no idea what it does, but I installed it in an attempt to enable sideloading (which I have yet to successfully do; apparently the file isn't in the same place on the Flipside as the Captivate and I was going by a Captivate guide).
I have not yet tried Root Explorer. I know this sounds stupid since it's just four dollars, but I tend to shy away from mobile programs that cost money. (Don't know why, I've been that way since my black and white palm pilot.) But, that's just something that's weird about me, lol. I'll get Root Explorer tomorrow and come back.
Busybox is a set of command line utilities. More Info. The link in my previous post is to an installer for Busybox. Busybox provides a set of commands that can be used and many of the tutorials on modifying an android phone use them. Some don't clearly state Busybox is required.
If you are using this thread as a guide to enabling installation from unknown sources be sure to read the whole thread. In particular this post.
Mission accomplished: Root explorer worked perfectly. I saw it in the marketplace before, but I didn't know it can change read/write privileges. (I didn't get it because I thought it was going to have the same effect as Android Terminal Emulator, just without the GUI. Obviously, I am pleasantly corrected.)
And I have a correction: I did not have BusyBox installed; I had the installer installed. But it is installed now.
Thanks also for the links; sideloading is on my to-do list, after removing AT&T bloatware.
And I have one quick question: Do you (or anybody reading) happen to know if it'll be ok if I remove that boot_att.ogg file in /system/media/audio? I don't know if AT&T designed it so that the phone will crash without it, so I thought I'd ask before removing it.
adanedhel728 said:
. . . .
And I have one quick question: Do you (or anybody reading) happen to know if it'll be ok if I remove that boot_att.ogg file in /system/media/audio? I don't know if AT&T designed it so that the phone will crash without it, so I thought I'd ask before removing it.
Click to expand...
Click to collapse
I have not tried any mods of the boot sound. I would suggest that you replace the file with one that is the same name but just silence if removing it does not work.
Mounting file system as Read/Write
I too can affirm that the "Root explorer" app works perfectly for toggling the Read Only File System to Read Write.
I have a Samsung Captivate from AT&T that I upgraded to Froyo (2.2) using the official release from Samsung via the Kies Mini interface. First, I can say that was very worth it. Love 2.2 much better than stock 2.1
I rooted the phone with SuperOnceClick1.7 (had to have a Windoze OS to run that though) that I got from XDA developers and it worked like a charm. I then removed all the bloatware that AT&T likes to inflict upon its users by using "Titanium Backup." Finally, I added "Terminal Emulator" and verified that the su command was working and then "cd" to the "/etc" folder where the "PowerOn.wav" file is for the annoyingly loud startup sound is to delete it. When I issued the "rm" command to delete the file, got the dreaded "can't delete dueo the Read-only file system" or something very similar. Tried using the Android SDK via adb and that gave exact same results.
What to do?...Found this thread that gave great advice that "Root explorer" does work to toggle the R/O to R/W so the file could be deleted.
Thank you marvin02 for the great lead!!!
I have removed the "boot_att.ogg" file without any problems and went as far as swapping out the "bootanimation.zip" also without any problems. Now using CyanogenMod 5 boot animation but... haven't had any luck replacing the .ogg file for a custom startup sound. Tried encoding audio to the same specs as the original but keep getting this strange noise at boot time instead. Just thought I'd throw that in.
Quick question...
I just downloaded the free explorer from Speed which makes Root Explorer.
don't see any button to change read only to read/write. Is that a feature only in the paid Root Explorer?
Thanks from a Noob.
Edit: Just so if there are any other noobs asking... Yes, need to get the paid version to be able to write in system folders.
The free version is not able.

Sensor calibration problem.

Hello.
There are many threads regarding tilt sensor calibration for other models.
Saw one for G3 but couldn't get it to work.
In apps where pitch & roll is used. Like google sky map and labyrinth, cant use the app because pitch & roll is not working correctly. It is not hardware problem. Luckily for labyrinth, they have option to calibrate, which works great but only for labyrinth app.
I tried editing the akmd_set.txt file under /data/misc/ but even after changing the numbers around, rebooting the phone, had no affect on the pitch value from Sensordebug app. I even deleted the file, starting sensordebug, went back to edit the file. No luck there.
Any clues?
Thanks in advance.
Things i've tried are.
1.
su system/bin/sensorcalibutil_yamaha -> galaxy 3 dont seem to have this calibration option...
2.
su
chmod 777 /data
chmod 777 /data/misc
chmod 777 /data/misc/akmd_set.txt
This allowed me to see & edit akmd_set.txt file in astro but changes did not affect the sensordebug info even after restart.
things i tried.
3. su /system/bin/akmd2 -s and it had calibrate accelerator menu~!!!
So i tried it but all it did was give me x y z values. Didnt affect even after restart. I copied the values (it were really high, like -1800, 2560, -3700) in to the akmd_set.txt under /data/misc and reboot, still nothing..
any ideas guys?
Thanks.
Sample Files?
Hello guys.
Help me out here.
Can you guys upload akmd_set.txt file from /data/misc
&
akmd2 file from /system/bin
I'll try replacing them with your working file...
Thanks in advance.
samsung AS
sigh...
nothing seems to work...
guys are A/S center told me to wait for official froyo release... that it will fix the problem...
sigh... somewhat i am skeptical.. tried jpf already but didnt work...
any ideas?
mainboard problem...
So it was mainboard problem...
even with froyo update. calibutil_yamaha couldnt initialize...
So went back to the service center... exchanged mainboard... and voila..
all working again...
Looks like you answered that yourself... nice job... good for future reference

Thread closed.

Thread closed.
Thread closed.
Yank555 said:
Hi,
REMEMBER
FIRST OF ALL, do a Nandroid backup, as well as a backup of your sd-card content !
You're doing this at your very own risk, I'm not to be held responsible if something goes wrong
Now that said, let's get going
In case somebody wants to check it out, here is the swap activation script I wrote (attached) as well as explanations on how to make it all work :
1) Partition your sd-card (Minitool Partition Wizard, 4ext, CWM...)
2) Boot your system with the partitionned sd-card
3) If necessary customize the 99swap script (attached to this post) and then put it onto your sd-card's root folder, you'll need it while executing the commands in step 4.
4) Open a terminal and type the following
NB: Change "mkswap /dev/block/mmcblk0p3" accordingly to point to the swap partition you've created in step 1.
5) Reboot your phone, start a terminal again and type free, you'll need to see something different than 0 in your swap line, look at the attached print-screen
Swappiness will be set to 50 by the script, which is a rather conservative swap use, made sense to me since SD-swap is slower than ram, better not to use it too agressively. Feel free to experiment with the swappiness variable in the script (values between 0 and 100, 0 meaning "try not to swap", 100 meaning "try to swap all the time")
If you want to try and have a question, just let me know !
JP.
PS: You can find the thread for hard swap for the htc Sensation / XE here.
Click to expand...
Click to collapse
Hi JP,
This is a gem of a post! Thanks alot for the script and the detailed breakdown. Before I get into it though, I must warn you that I am more of a beginner with no coding/scripting experience (I don't know how to use adb or anything)...
Here's what I'm trying to do: I'm trying to activate hard-swap on my hd2 (currently) running the ParanoidAndroid by Xylograph. I've created 3 partitions on my 16gb class 6 sd card: first, fat32 (32k cluster), next, 1GB ext2 (default), 500MB swap.
Procedure:
1. I extracted the script and copied it directly to system/etc/init.d folder of the Rom (I looked at the terminal commands you posted and the first few lines looked like copying the file from the sd root to the init.d folder (it was just a guess though), so I figured might as well put it into the rom before I flash it)
2. Flashed the rom
3. To activate it, I typed the following into the terminal:
su
mount -o remount,rw /system
mkswap /dev/block/mmcblk0p3
mount -o remount,ro /system
exit
after the mkswap command, I did get an activation notification that a certain amount was assigned to swap. But my celebrations were cut short after I rebooted and used the free command to check. The entire swap row still read 0.
I was wondering if you can point me in the right direction... thanks!
Also, is there a way to create a cwm flashable version?
bullcrapr said:
Hi JP,
This is a gem of a post! Thanks alot for the script and the detailed breakdown. Before I get into it though, I must warn you that I am more of a beginner with no coding/scripting experience (I don't know how to use adb or anything)...
Here's what I'm trying to do: I'm trying to activate hard-swap on my hd2 (currently) running the ParanoidAndroid by Xylograph. I've created 3 partitions on my 16gb class 6 sd card: first, fat32 (32k cluster), next, 1GB ext2 (default), 500MB swap.
Procedure:
1. I extracted the script and copied it directly to system/etc/init.d folder of the Rom (I looked at the terminal commands you posted and the first few lines looked like copying the file from the sd root to the init.d folder (it was just a guess though), so I figured might as well put it into the rom before I flash it)
2. Flashed the rom
3. To activate it, I typed the following into the terminal:
su
mount -o remount,rw /system
mkswap /dev/block/mmcblk0p3
mount -o remount,ro /system
exit
after the mkswap command, I did get an activation notification that a certain amount was assigned to swap. But my celebrations were cut short after I rebooted and used the free command to check. The entire swap row still read 0.
I was wondering if you can point me in the right direction... thanks!
Also, is there a way to create a cwm flashable version?
Click to expand...
Click to collapse
Thanx
In fact you understood correctly that is was about copying the file to init.d.
By the way, these commands do the following :
mount -o remount,rw /system - Mount system partition in read-write
mount -o remount,ro /system - Mount system partition in read-only
So to format the swap partition "mkswap /dev/block/mmcblk0p3" there was no need for it, but it didn't harm in any way, so you're fine there
I guess what is missing is the "chmod 755 /system/etc/init.d/99swap" command which will set the correct file access to the script so it can get executed at boot.
You might do the following in a terminal :
su
mount -o remount,rw /system
chmod 755 /system/etc/init.d/99swap
mount -o remount,ro /system
exit
It should be fine then.
Alternatively you could set the rights with your file explorer (in root explorer mode), they must be "rwxr-xr-x" (which is Read-Write-Execute, Read-Execute, Read-Execute), most file-manager will allow you to do that as well.
I've been working on the script variant for htc Sensation, it is more advanced, dynamic so it can find the swap partition by itself.
I'll make a CWM flashable as soon as I get to it that will handle everything except partitioning the SD card, obviously, for both devices.
As soon as I'm done I'll post the HD2 version here as well (very little change, between both devices, just the access path to the sd-card partitons to change (=1 line in the script).
JP.
Edit ------------------------------------------------
I just reread your post, if in fact you put it into the ROM zipfile, then file access should be correct !?
Could you post the following file (if it exists) :
/data/swap.0.log ?
JP.
Yank555 said:
Thanx
In fact you understood correctly that is was about copying the file to init.d.
By the way, these commands do the following :
mount -o remount,rw /system - Mount system partition in read-write
mount -o remount,ro /system - Mount system partition in read-only
So to format the swap partition "mkswap /dev/block/mmcblk0p3" there was no need for it, but it didn't harm in any way, so you're fine there
I guess what is missing is the "chmod 755 /system/etc/init.d/99swap" command which will set the correct file access to the script so it can get executed at boot.
You might do the following in a terminal :
su
mount -o remount,rw /system
chmod 755 /system/etc/init.d/99swap
mount -o remount,ro /system
exit
It should be fine then.
Alternatively you could set the rights with your file explorer (in root explorer mode), they must be "rwxr-xr-x" (which is Read-Write-Execute, Read-Execute, Read-Execute), most file-manager will allow you to do that as well.
I've been working on the script variant for htc Sensation, it is more advanced, dynamic so it can find the swap partition by itself.
I'll make a CWM flashable as soon as I get to it that will handle everything except partitioning the SD card, obviously, for both devices.
As soon as I'm done I'll post the HD2 version here as well (very little change, between both devices, just the access path to the sd-card partitons to change (=1 line in the script).
JP.
Edit ------------------------------------------------
I just reread your post, if in fact you put it into the ROM zipfile, then file access should be correct !?
Could you post the following file (if it exists) :
/data/swap.0.log ?
JP.
Click to expand...
Click to collapse
Hi JP
You are incredibly helpful and I appreciate it!
I finally got some time off and tried out what you mentioned... but to no avail. I applied the necessary permissions through the terminal (chmod 755) as well as through the root browser, but it was still the same. After that I even retried the terminal commands, and included the "chown 0:2000...", but that didn't work either...
... and then I saw your post update...
About that, i just typed it into the terminal, and I got "not found".
Was that what I was supposed to do?
bullcrapr said:
Hi JP
You are incredibly helpful and I appreciate it!
I finally got some time off and tried out what you mentioned... but to no avail. I applied the necessary permissions through the terminal (chmod 755) as well as through the root browser, but it was still the same. After that I even retried the terminal commands, and included the "chown 0:2000...", but that didn't work either...
... and then I saw your post update...
About that, i just typed it into the terminal, and I got "not found".
Was that what I was supposed to do?
Click to expand...
Click to collapse
Hi,
You're welcome
The file '/data/swap.0.log' is a text-file containing info on the execution of the script...
If it's not there, then the script didn't run at all...
I should have a little time later today, will try to make the CWM flashable solution for you, should be a no fuss solution, as long as the sd-card has a swap partition
How did you partition the card ? CWM ?
JP.
Sent from my Android Revolution HD 6.6.5 XE / faux kernel 007b3 powered htc Sensation XE using xda premium
I created a 256Gb partition...
Click to expand...
Click to collapse
man thats a helluva sd card ya have there! hehe.
samsamuel said:
man thats a helluva sd card ya have there! hehe.
Click to expand...
Click to collapse
Haha I noticed that too :') I want one of those now
Nigeldg said:
Haha I noticed that too :') I want one of those now
Click to expand...
Click to collapse
Thanx for pointing that out Mb of course, but in a few years that might be possible
My first hdd had 60Mb, and that's not soooo long ago
JP.
Sent from my Android Revolution HD 6.6.5 XE / faux kernel 007b3 powered htc Sensation XE using xda premium
heh, my first was a 20mb HDD mounted on a pcb card and plugged into an ISA slot, took up the full length of the PC, weighed LOADS, could have beaten burglars to death with it.
bullcrapr said:
Hi JP
You are incredibly helpful and I appreciate it!
I finally got some time off and tried out what you mentioned... but to no avail. I applied the necessary permissions through the terminal (chmod 755) as well as through the root browser, but it was still the same. After that I even retried the terminal commands, and included the "chown 0:2000...", but that didn't work either...
... and then I saw your post update...
About that, i just typed it into the terminal, and I got "not found".
Was that what I was supposed to do?
Click to expand...
Click to collapse
+1 with this (also on Paranoid Rom 1.1a) but I think that it's something with the ROM coz on earlier build v1 this method worked verry good I hope that Yank will find a solution coz it reallly helps wit our 576 ram
samsamuel said:
heh, my first was a 20mb HDD mounted on a pcb card and plugged into an ISA slot, took up the full length of the PC, weighed LOADS, could have beaten burglars to death with it.
Click to expand...
Click to collapse
Mine was huge at the time, was on of the first to have such a big one, even partitioned it into 3 since it was just too big And it was an external device, the size of a pizza-box (it was en Atari Megafile 60, I still have it !!).
triggaz said:
+1 with this (also on Paranoid Rom 1.1a) but I think that it's something with the ROM coz on earlier build v1 this method worked verry good I hope that Yank will find a solution coz it reallly helps wit our 576 ram
Click to expand...
Click to collapse
I'm working on the CWM flashable right now, should be done within 1-2 hours at most
Yank555 said:
Hi,
You're welcome
The file '/data/swap.0.log' is a text-file containing info on the execution of the script...
If it's not there, then the script didn't run at all...
I should have a little time later today, will try to make the CWM flashable solution for you, should be a no fuss solution, as long as the sd-card has a swap partition
How did you partition the card ? CWM ?
JP.
Sent from my Android Revolution HD 6.6.5 XE / faux kernel 007b3 powered htc Sensation XE using xda premium
Click to expand...
Click to collapse
Hi JP, once you told me it was the address to the file, i just navigated there using my explorer and lo and behold!, there it was (attached). If you must know, in my earlier post, the idiot in me just typed it in the terminal and the terminal replied not found.
I made my partition using freeware called Minitool partition wizard. Is 500mb too big for swap in your opinion? I was thinking of compensating for zram, and hence the size... thanks for your speedy responses...
edit...
and hey! whadya know? in the meantime, this place is coming alive!!
bullcrapr said:
Hi JP, once you told me it was the address to the file, i just navigated there using my explorer and lo and behold!, there it was (attached). If you must know, in my earlier post, the idiot in me just typed it in the terminal and the terminal replied not found.
I made my partition using freeware called Minitool partition wizard. Is 500mb too big for swap in your opinion? I was thinking of compensating for zram, and hence the size... thanks for your speedy responses...
edit...
and hey! whadya know? in the meantime, this place is coming alive!!
Click to expand...
Click to collapse
Hmm ... strange, the content of the file looks like a logcat ?! Not what I was expecting to see
Give me a little hour, and I think I should be done with the flashable hard-swap and we'll go from there
Minitool is excellent, but did you pay attention to only create "primary" partition ? If it is a logical partition it won't work...
Can you insert your SD card into your card reader, start Minitool an post a print screen of it ?
JP.
EDIT :
About size ... I believe 256Mb is enough, even read somewhere t shouldn't be more than 256, but I think there was no specific reason given.
Yank555 said:
Hmm ... strange, the content of the file looks like a logcat ?! Not what I was expecting to see
Give me a little hour, and I think I should be done with the flashable hard-swap and we'll go from there
Minitool is excellent, but did you pay attention to only create "primary" partition ? If it is a logical partition it won't work...
Can you insert your SD card into your card reader, start Minitool an post a print screen of it ?
JP.
EDIT :
About size ... I believe 256Mb is enough, even read somewhere t shouldn't be more than 256, but I think there was no specific reason given.
Click to expand...
Click to collapse
Here we go...
Minitool image attached... I typically pay attention to the partition type and made sure both of them were primary
About the logcat, I suspect you're right... I was trying to do one from my pc for the first time using adb and tried the only few commands I know (mkswap...), I think that's what you saw then...
Incidentally, do you feel if I reduce the swap size, the script has a better chance at surviving the boot?
bullcrapr said:
Here we go...
Minitool image attached... I typically pay attention to the partition type and made sure both of them were primary
About the logcat, I suspect you're right... I was trying to do one from my pc for the first time using adb and tried the only few commands I know (mkswap...), I think that's what you saw then...
Incidentally, do you feel if I reduce the swap size, the script has a better chance at surviving the boot?
Click to expand...
Click to collapse
Don't bother, I will test 500Mb and let you know if that is the issue
JP.
I have 512mb partition and it worked without problems as I mentioned earlier so I think that opposite to the "size does matter" in this case it doesn't plus I used it with zram from marc1706.
triggaz said:
I have 512mb partition and it worked without problems as I mentioned earlier so I think that opposite to the "size does matter" in this case it doesn't plus I used it with zram from marc1706.
Click to expand...
Click to collapse
Hi triggaz, are you using the built in zram on Para1.1a? Or have you applied a script from elsewhere? I enabled the built-in zram, but get a "not found" reply when i try zram_stats in the terminal. Can you tell me how you got zram working? thanks...
bullcrapr said:
Hi triggaz, are you using the built in zram on Para1.1a? Or have you applied a script from elsewhere? I enabled the built-in zram, but get a "not found" reply when i try zram_stats in the terminal. Can you tell me how you got zram working? thanks...
Click to expand...
Click to collapse
https://www.dropbox.com/s/xr3z102gxiw2f62/marc1706_zram_100MB.zip
all credits to Dorimanx for ZRAM mod and mark1706 for modifications
I flashed this and then used the compcashe options in Paranoid (set to 26%)

[MOD][SCRIPT] Get More Storage by Relocating Dalvik Cache!

DISCLAIMER: YOU AGREE TO TAKE FULL RESPONSIBILITY FOR YOUR DEVICE IF YOU PROCEED.
The original thread (http://forum.xda-developers.com/moto-g/general/mod-save-data-space-cache-partition-t2942765) was getting to cluttered up with development and testing so I decided to start a new thread with the "finished" product. The original thread will be renamed to Q&A/Development. We might even ask for the old thread to be closed down. (up to @Bert98, the thread's creator.)
Moto G's internal eMMC card has a ~600Mb partition called /cache, which is not used since the apps' cache is stored in /data, so the latter fills up and the first one stays empty.
Owning a 8Gb model, having 600Mb not available for storage really bugged me, because my phone's memory (/data partition) was always full because it's a 5.7Gb space shared between apps and microSD files.
Now, it may not work for you if:
a) you have A LOT of apps installed.
And by "a lot", I mean more than 90-100 apps, but if you have a 8Gb model, you probably don't
b) you're running ART (this is default in lollipop and newer)
Since ART uses a lot more space than dalvik, the space in the /cache partition probably won't be enough. When I was running ART, it used 1Gb more than dalvik.
Original post by @Bert98
Click to expand...
Click to collapse
This was tested on my moto g 16GB which is running RetailUS_4.4.4 kitkat with CWM recovery. The custom ROM procedure was tested on the same phone but with cm11 Nightly installed.
Prerequisites:
1. You must have "adb root" functioning. If you don't head to this thread: http://forum.xda-developers.com/showthread.php?t=1687590 and there is a free download link at the bottom of the post.
Download and install the apk on your phone. Open up adbd insecure (the new app) and grant it superuser rights PERMANENTLY. Check the box that says "enable insecure binary" and make sure to check the box
that says "enable at boot."
2. You must have a recovery that can accept adb shell commands.
3. Root Access Duh?!
4. A windows machine capable of running batch files.
5. A decent text editor, notepad will work but notepad++ is strongly recommended. (Only needed if you are using STOCK ROM procedure)
Please, please make a nandroid backup before you continue!!!!
Stock ROM procedure:
Read the directions very carefully and then read them again, before continuing.
1. Download the cachemover_v1.3.zip from: LINK REMOVED DUE TO SCRIPT ISSUES.
2. Extract the contents.
3. Connect device to PC and navigate to the extracted folder.
4. Double click/Run the cachemover_Stock.bat
5. Follow the onscreen instructions until you get to the part where it says to edit a file.
6. About halfway through the script it will pull a file called "init.qcom.post_boot.sh" to the folder.
7. Open it with a TEXT editor and navigate to about line 487 (Might be different for 8gb model). Look here for a better understanding: https://www.dropbox.com/s/jr5lyl5s5i2jtpg/where to paste code.PNG?dl=0
8. Start a new line and paste this code in the file: (Refer to the image above for help)
Code:
chmod 655 /cache
chmod 655 /cache/dalvik-cache
chmod 655 /cache/dalvik-cache/*
9. Make sure to save the file in the same folder as the cachemover_Stock.bat
10. Press any key to continue on the script and let it do its thing.
11. It will reboot several times and land you on the home screen/lock screen.
12. If the script hangs after a reboot, you need to unlock the device to reestablish a connection with your computer.
13. There might be one or two force closes but once you close the notifications they will not come back.
Custom ROM procedure:
USE THIS FOR ROMS THAT DO NOT REMOUNT OR CHANGE PERMISSIONS OF /CACHE ON BOOT
1. Download the cachemover_v1.3.zip from: https://www.dropbox.com/s/bzj34g4q1s61ojz/cachemover_v1.3.zip?dl=0
2. Extract the contents.
3. Connect device to PC and navigate to the extracted folder.
4. Double click/Run the cachemover.bat
5. Follow the onscreen instructions.
If anything goes wrong:
Go to recovery, wipe cache, then wipe dalvik-cache and reboot. This should get your device back to how it was.
(If you used STOCK ROM procedure)
The script made a backup of the "init.qcom.post_boot.sh" file to /sdcard/init_backup
You can restore the shell script to /system/etc/ via shell commands or by using a root browser. To restore permissions:
Code:
chmod 740 /system/etc/init.qcom.post_boot.sh
chown root:root /system/etc/init.qcom.post_boot.sh
Custom ROM procedure already has a restore script!
I am currently working on an auto restore script for stock and that will be relased soon, hopefully! :good:
Changelog:
v1.0 - First stable release. Does not work on STOCK ROM.
v1.1 - Added a restore script.
v1.3 - Added support for STOCK ROM. There are still a few bugs.
How it works?!?!
Coming soon...
Huge thanks to @Bert98 and @dd043
Hit the thanks button if it worked! I went through about 50 factory resets, and reflashed the ROM about 25 times, and put about 10 hours of work into this script! Really motivates me for future projects. :laugh:
Thanks for your help man and effort.
I encountered a problem, everything works up until my device boots in CWM to fix permissions, then just sits there doing not alot I don't even see the option in my CWM.
Any ideas? cheers
Sent from my XT1032 using XDA Free mobile app
When it reboots to cwm unplug the cable and replug it, if it hangs just type these commands manually from a command window.
chmod 655 /cache
chmod 655 /cache/dalvik-cache
chmod 655 /cache/dalvik-cache/*
reboot
If this does not work you may ned to go into mounts & storage in the cwm menu and click mount /cache. Then try the commands again.
I'm having some issues on stock.
I thought 0655 fixed everything but no, I can't install any app after moving the dalvik-cache to /cache. I tried chmoding 0777 on the new cache folder, on /cache itself, to no avail.
Code:
E/dexopt cannot open '/data/dalvik-cache/[email protected]' for output
Anyone can confirm it's not only my device? And/or can help find a fix?
Also does someone knows how to execute commands on a particular init step? Real init.rc scripts can do:
Code:
on post-fs-data
mount -o bind /cache/dalvik /data/dalvik-cache
It there was a way to achieve the same from post_boot/init.d we could mount -o bind /cache/dalvik /data/dalvik-cache and all permissions issues would disappear as well as the need for symlink.
You have a typo in the threads title. Just a heads up.
Vuciz said:
You have a typo in the threads title. Just a heads up.
Click to expand...
Click to collapse
Thanks for letting me know!
dd043 said:
I'm having some issues on stock.
I thought 0655 fixed everything but no, I can't install any app after moving the dalvik-cache to /cache. I tried chmoding 0777 on the new cache folder, on /cache itself, to no avail.
Code:
E/dexopt cannot open '/data/dalvik-cache/[email protected]' for output
Anyone can confirm it's not only my device? And/or can help find a fix?
Also does someone knows how to execute commands on a particular init step? Real init.rc scripts can do:
Code:
on post-fs-data
mount -o bind /cache/dalvik /data/dalvik-cache
It there was a way to achieve the same from post_boot/init.d we could mount -o bind /cache/dalvik /data/dalvik-cache and all permissions issues would disappear as well as the need for symlink.
Click to expand...
Click to collapse
Let me try and do that right now... Ill get back to you if it does!
My script works on stock btw... But the mount way seems a bit easier and might cause less errors than my way.
Try it please.
skyguy126 said:
Let me try and do that right now... Ill get back to you if it does!
My script works on stock btw... But the mount way seems a bit easier and might cause less errors than my way.
Try it please.
Click to expand...
Click to collapse
Yes I've tried your script, all went well but the result is the same. The script itself works nicely btw
Applications present before moving cache work perfectly, but I can't install anything new. I suspect it might be my device but before wiping everything I'd prefer feedback from others :fingers-crossed:.
I cannot install new apps as well. The mount command you showed me has the same effect too. I honestly don't know anymore, the sym link did not allow the install of new apps nor did the mount command you sent me. Correct me if I am wrong.
Edit: Going through all the init files on my phone to see which one remounts /cache at boot.
Why does the init.rc get overwritten at boot. Is it because the kernel (boot.img) is the one that copies it over? I have found by changing the perms/locations in this file and init.target.rc you can achieve what this mod is trying to acomplish.
I don't see the mount cache command in CWM strange
I've managed to get back to normal, thanks for everyone's help though, I will keep and eye on the thread
Sent from my XT1032 using XDA Free mobile app
non-windows version?
Thanks for this tool. It's a great idea and our Motos really need it.
However, I have a problem - I do not own a windows license (os x and ubuntu user) and I would prefer not to spend $120 just to use it for this script. Pirating is out of the question for me.
I was wondering if there is any chance of having this script written for linux and/or mac. If impossible, is there a LEGAL way of running windows in a virtual machine? Something like a trial or similar?
If you know how just convert it to shell script for osx and Linux. I give you permission to do this but you may not take credit or rehost your creation.
Ok so I have the kernel extracted and we could modify and flash that, but I believe that it's not really necessary. There are a lot of risks to flashing kernels and I am not willing to take it. So is there a way we can modify dalvik so it creates it's cache in /cache instead.
skyguy126 said:
Why does the init.rc get overwritten at boot. Is it because the kernel (boot.img) is the one that copies it over? I have found by changing the perms/locations in this file and init.target.rc you can achieve what this mod is trying to acomplish.
Click to expand...
Click to collapse
Yes the init.rc is in the boot ramdisk. I don't think it would be worth the trouble to rebuild a boot.img. The moto g is fairly unbrickable but it's quite a lot of work to setup an environment to rebuild an image :/.
Too bad for the mount command, I was sure it was working but maybe I had changed something else and don't quite remember the steps to reproduce
We could possibly implement a shell script toggler for when we need to install new apps, but I'm afraid it'd become annoying fairly quickly: I noticed the issue initially because google play services decided to update itself, failed, and broke all google apps. As far as I know this autoupate can't be disabled.
Thanks for trying!
dd043 said:
Yes the init.rc is in the boot ramdisk. I don't think it would be worth the trouble to rebuild a boot.img. The moto g is fairly unbrickable but it's quite a lot of work to setup an environment to rebuild an image :/.
Too bad for the mount command, I was sure it was working but maybe I had changed something else and don't quite remember the steps to reproduce
We could possibly implement a shell script toggler for when we need to install new apps, but I'm afraid it'd become annoying fairly quickly: I noticed the issue initially because google play services decided to update itself, failed, and broke all google apps. As far as I know this autoupate can't be disabled.
Thanks for trying!
Click to expand...
Click to collapse
How about making a simple apk that toggles this feature. Something like when you click the icon it doesn't even open but gives a little notification of success. Something like that. I myself am not experienced with apks but I can put together a shell script for the apk.
skyguy126 said:
Ok so I have the kernel extracted and we could modify and flash that, but I believe that it's not really necessary. There are a lot of risks to flashing kernels and I am not willing to take it. So is there a way we can modify dalvik so it creates it's cache in /cache instead.
Click to expand...
Click to collapse
Patching dalvik itself sounds promising. It can probably be done with in a batch script with a command line hex editor.
The path is defined in frameworks/base/cmds/installd/installd.h
Code:
#define DALVIK_CACHE_PREFIX "/data/dalvik-cache/"
Not sure if there is another mention in the source tree.
But there's nothing to say we wouldn't face the same issue, the error message in the logcat is pretty generic
dd043 said:
Patching dalvik itself sounds promising. It can probably be done with in a batch script with a command line hex editor.
The path is defined in frameworks/base/cmds/installd/installd.h
Code:
#define DALVIK_CACHE_PREFIX "/data/dalvik-cache/"
Not sure if there is another mention in the source tree.
But there's nothing to say we wouldn't face the same issue, the error message in the logcat is pretty generic
Click to expand...
Click to collapse
Ill try it. I don't mind doing a bunch of resets because I am using my moto g as a test bench anyway. My daily driver is the OnePlus One
dd043 said:
Patching dalvik itself sounds promising. It can probably be done with in a batch script with a command line hex editor.
The path is defined in frameworks/base/cmds/installd/installd.h
Code:
#define DALVIK_CACHE_PREFIX "/data/dalvik-cache/"
Not sure if there is another mention in the source tree.
But there's nothing to say we wouldn't face the same issue, the error message in the logcat is pretty generic
Click to expand...
Click to collapse
EDIT: Unfortunately it didn't work. I don't know if I modified the installd file correctly. The program I used is HxD.
Is there a way we can force dalvik to start after the directories are created. And change dalvik to create it in /cache.

[7.0] Enable google daydream (root needed)

I've managed to get daydream VR up and running on my LG G5.
I'm just gonna jump straight to the point and explain how I've managed to do this.
To set this up, you're gonna have to be on Android 7.0, and have root access.
First of all, enable ADB Debugging in your developer settings and test if it works on your computer, we are gonna need this later on.
Download and install the following apps;
Daydream apk http://www.apkmirror.com/apk/google-inc/daydream/daydream-1-1-161121023-release/daydream-1-1-161121023-android-apk-download/
VR Serviceshttp://www.apkmirror.com/apk/google-inc/google-vr-services/google-vr-services-1-1-141111507-release/
Daydream Keyboardhttp://www.apkmirror.com/apk/google-inc/daydream-keyboard/daydream-keyboard-1-0-release/daydream-keyboard-1-0-android-apk-download/
Any root explorer app, i used https://play.google.com/store/apps/details?id=com.jrummy.root.browserfree&hl=en
Open up the root explorer and navigate to: /system/etc/permissions
In the permissions folder, look for the following file and open it: "handheld_core_hardware.xml"
BE SURE TO CREATE A COPY THE FILE FIRST SO YOU HAVE A BACK-UP OF THE ORIGINAL HANDHELD_CORE_HARDWARE FILE
Add the following lines between the <permissions> tags
"<feature name="android.software.vr.mode" />"
"<feature name="android.hardware.vr.high_performance" />"
Reboot your phone. A lot of things will crash when it starts up, this happened to me too. This happens because the file we just edited doesn't have the proper permissions set up.
To fix this problem we're gonna open up an ADB Shell on the computer.
Once you have ADB open do the following commands:
SU (and grant superuser permissions on phone)
mount -o rw,remount -t /system
chmod 644 /system/ect/permissions/handheld_core_hardware.xml
mount -o ro,remount -t /system
reboot
Now, if we open the daydream app we can launch daydream by pressing the cardboard button in the corner.
You can also use a secondary android phone as a controller, if you have one. Google has a guide set up for this https://developers.google.com/vr/daydream/controller-emulator
Sources: https://www.reddit.com/r/Android/comments/5hno6u/got_daydream_to_work_on_my_5x_might_work_on_other/
If you have any questions, feel free to leave a comment and i'll get back to you as soon as i can!
Thank you
Successfully tried this on fulmics 1.0. Even didn't have to chmod after reboot, config file already was 644. Thank you a lot for this tutorial, its great to know we can use g5 with daydream, in my opinion the experience with the qhd lcd screen is good enough, amoled is not a (real) must.
tatsujin said:
Successfully tried this on fulmics 1.0. Even didn't have to chmod after reboot, config file already was 644. Thank you a lot for this tutorial, its great to know we can use g5 with daydream, in my opinion the experience with the qhd lcd screen is good enough, amoled is not a (real) must.
Click to expand...
Click to collapse
I'm glad it works for you! i think i had to chmod since i'm on stock v20a. This will probably (don't take my word for it though) work on a lot of newer high-end phones running on 7.0 or higher.
There's a way to use it without NFC ?
Confirmed on Xiaomi Mi5
Works perfectly on a Xiaomi Mi5 with a Moto G controller emulator both running on LineageOS 14.1.
Only a couple of Games wont Run, but almost everyone does and runs smoothly.
did so just without rooting and editing the xml File
Everything Works fine - the g5 says "Hold the Home Button...", my old Samsung galaxy s4 (Controller Emulator) says Bluetooth (Connected)
but if i push the Controller Home Button on the s4 nothing happend on the g5
are you shure it will work with root and editing xml File?
i Don t want to root the g5
thanks
xamax88 said:
did so just without rooting and editing the xml File
Everything Works fine - the g5 says "Hold the Home Button...", my old Samsung galaxy s4 (Controller Emulator) says Bluetooth (Connected)
but if i push the Controller Home Button on the s4 nothing happend on the g5
are you shure it will work with root and editing xml File?
i Don t want to root the g5
thanks
Click to expand...
Click to collapse
I haven't gotten around to figuring out how the controller emulator actually works, you need to initiate the pairing on the G5 (or the phone that's running daydream) as far as i know. I have no idea if it works without root since you're editing a build.prop, i couldn't tell you since i'm always rooted.
night.shadows said:
There's a way to use it without NFC ?
Click to expand...
Click to collapse
How do you mean use it without nfc? If you're talking about the controller emulator, open the link in the OP (original post) to the google page that provides you with the controller emulator. It explains pretty much everything you need to know when it comes down to that.
TFDRA said:
How do you mean use it without nfc? If you're talking about the controller emulator, open the link in the OP (original post) to the google page that provides you with the controller emulator. It explains pretty much everything you need to know when it comes down to that.
Click to expand...
Click to collapse
No I meant use daydream on non-nfc phone, but I've found in the developers options, thanks !
Just keeps crashing
So i go into the daydream app and go into the actual vr mode and it just crashes the app, idk what to do from here. I bought the daydream headset and i have a oneplus 3t so I dont really know what to do and it sucks cause i really wanna use it.
statertot said:
So i go into the daydream app and go into the actual vr mode and it just crashes the app, idk what to do from here. I bought the daydream headset and i have a oneplus 3t so I dont really know what to do and it sucks cause i really wanna use it.
Click to expand...
Click to collapse
Check out this thread on the oneplus forums, someone managed to get it working on the oneplus3.
I think the proccess would be fairly similar for you since you're probably using oxygenOS as well.
https://forums.oneplus.net/threads/major-announcement-daydream-vr-fully-running-on-op3-oxygenos.479505/
TFDRA said:
Check out this thread on the oneplus forums, someone managed to get it working on the oneplus3.
I think the proccess would be fairly similar for you since you're probably using oxygenOS as well.
https://forums.oneplus.net/threads/major-announcement-daydream-vr-fully-running-on-op3-oxygenos.479505/
Click to expand...
Click to collapse
Hi I've tried this method but I'm stuck, when it try to modify the permissions of the file the terminal keeps saying its a read only file system, help please :crying:
matias041198 said:
Hi I've tried this method but I'm stuck, when it try to modify the permissions of the file the terminal keeps saying its a read only file system, help please :crying:
Click to expand...
Click to collapse
If you have root, you can try running these commands in a terminal:
Code:
su
mount -o remount rw /
SkyrisBactera said:
If you have root, you can try running these commands in a terminal:
Code:
su
mount -o remount rw /
Click to expand...
Click to collapse
I've tried with no success
Code:
victara:/ $ su
victara:/ # mount -o rw,remount -t /system
/system/etc/permissions/handheld_core_hardware.xml <
chmod: chmod '/system/etc/permissions/handheld_core_hardware.xml' to 100644: Read-only file system
1|victara:/ # mount -o remount rw /
mount: '/' not in /proc/mounts
I just realised I can't change permissions of any file in my phone :crying:
I've attached my handheld core hardware file, it's from my Moto x 2014 (VICTARA). Can anyone please make it .xml, set permissions and make a flashable .zip? Thanks
EDIT: I was able to mount the /system using root explorer somehow, after that it was straight forward
Hi, i'm planning on buying the lg g5 and the daydream view headset, is it worth it? does it work well? i want to know if daydream games are working with the daydream controller too. Thanks a lot!!!
guideahon said:
Hi, i'm planning on buying the lg g5 and the daydream view headset, is it worth it? does it work well? i want to know if daydream games are working with the daydream controller too. Thanks a lot!!!
Click to expand...
Click to collapse
Maybe you should get a phone with oficial daydream support
Hi, i tried all the steps from here, the daydream app crashes and i cant play any daydream games, do i have to install any specific version?? i'm on stock 20a
Hi, followed the guide on a LG G2 with BOBO-VR Z5 with controller, everythings fine except the pairing of the controller through bluetooth.
"No controller found. Make sure that your controller is charged and next to your phone, then try again."
Any idea?
Install Magisk Module Daydream Enabler
Install Magisk Module Daydream Enabler For solve this issue in a better way.

Categories

Resources