Everything Development Thread - HTC Amaze 4G

Hi guys, I've gotten quite a few pm's lately about learning how to develop things for our Amaze. So I decided to make this thread as a the one stop shop to ask all your development questions and to discuss the problems your encountering and get answers to them instead of keeping everything private so if you want to learn how to cook, modify, develop your own android rims this is the place to come Ask away
Sent from my HTC_Amaze_4G using xda premium

Awesome! Well i wanna learn how to cook roms and modify them, like for example replacing apps and adding apps
Sent from my iPad using Tapatalk HD

Umm... How do you flash a Rom
Sent from my HTC_Amaze_4G using Tapatalk 2

ETA on an update for Team nightmare Sense 4.0?

eggydrums said:
Awesome! Well i wanna learn how to cook roms and modify them, like for example replacing apps and adding apps
Sent from my iPad using Tapatalk HD
Click to expand...
Click to collapse
A good place to start would be here http://forum.xda-developers.com/showthread.php?t=633246 it' lets you extract roms and a bunch of other things so you can see how a rom is constructed. /system/app is where the system apps are they can't be updated from market so that's where you would put superuser and stuff but user apps would go in /data/app which you can make using the kitchen i linked you too I made my first rom with it http://forum.xda-developers.com/showthread.php?t=1303850
ziggy46 said:
Umm... How do you flash a Rom
Sent from my HTC_Amaze_4G using Tapatalk 2
Click to expand...
Click to collapse
Well ziggy first you take your amaze and put it in the oven for 1 Hour then you take it to a body of water and through it right in the middle and your done lol

Thanks ill try that later. Are there any chances of a brick? Lol
Oh and I cab help out with this thread to cause I know a lot as well
Sent from my HTC_Amaze_4G using Tapatalk 2

sportsstar89 said:
A good place to start would be here http://forum.xda-developers.com/showthread.php?t=633246 it' lets you extract roms and a bunch of other things so you can see how a rom is constructed. /system/app is where the system apps are they can't be updated from market so that's where you would put superuser and stuff but user apps would go in /data/app which you can make using the kitchen i linked you too I made my first rom with it http://forum.xda-developers.com/showthread.php?t=1303850
Well ziggy first you take your amaze and put it in the oven for 1 Hour then you take it to a body of water and through it right in the middle and your done lol
Click to expand...
Click to collapse
Thanks sports i will try. If im gonna try and cook a rom, can i use a rom thats already made, much like how eclipse speed rom that he made using energy rom?
Sent from my iPad using Tapatalk HD

eggydrums said:
Thanks sports i will try. If im gonna try and cook a rom, can i use a rom thats already made, much like how eclipse speed rom that he made using energy rom?
Sent from my iPad using Tapatalk HD
Click to expand...
Click to collapse
Yes you can make roms from other roms. That's what devs do when they say that they based a Rom from another.
Sent from my epic amaze 4g

Dang my computer is too suckish to set up the kitchen :/
Sent from my iPad using Tapatalk HD

When I try and install the ROM, I get an error. I think it says, expected 4 args but got 3. something along those lines lol.

hasoon2000 said:
When I try and install the ROM, I get an error. I think it says, expected 4 args but got 3. something along those lines lol.
Click to expand...
Click to collapse
Your own rom?
Sent from my HTC_Amaze_4G using xda premium

hasoon2000 said:
When I try and install the ROM, I get an error. I think it says, expected 4 args but got 3. something along those lines lol.
Click to expand...
Click to collapse
Updater--script error?
Sent from a Galaxy Nexus?

Dark Nightmare said:
Updater--script error?
Sent from a Galaxy Nexus?
Click to expand...
Click to collapse
Yep that's what it is
Sent from my HTC_Amaze_4G using xda premium

sportsstar89 said:
Yep that's what it is
Sent from my HTC_Amaze_4G using xda premium
Click to expand...
Click to collapse
I tried making my own ROM. I looked at the updater-script. The kitchen makes it and add the MTD format type rather than EXT4. I have no clue how to fix it.
Sent from my HTC_Amaze_4G using Tapatalk 2

I have a few questions
1-what libs do you push so that the AOSP ics keyboard (or any other for that matter) to work
2- how do you set a default wallpaper for a sense rom, do you open up the Rosie apk or the htc resource... Because when I change the framework wallpaper it doesn't stick
3- what are some more examples of init.d scripts as I don't know many
These questions are relatively simple so don't scold me.....

hasoon2000 said:
I tried making my own ROM. I looked at the updater-script. The kitchen makes it and add the MTD format type rather than EXT4. I have no clue how to fix it.
Sent from my HTC_Amaze_4G using Tapatalk 2
Click to expand...
Click to collapse
The problem with the kitchen is it doesn't have an config script for the ruby so just take any updater script from any Rom and it'll work
Sent from my HTC_Amaze_4G using xda premium

EclipzeRemix said:
I have a few questions
1-what libs do you push so that the AOSP ics keyboard (or any other for that matter) to work
2- how do you set a default wallpaper for a sense rom, do you open up the Rosie apk or the htc resource... Because when I change the framework wallpaper it doesn't stick
3- what are some more examples of init.d scripts as I don't know many
These questions are relatively simple so don't scold me.....
Click to expand...
Click to collapse
1. I'm not quite sure try the latinime libs and input libs and i believe some of it is framework
2. customize folder i think just replace what the default wall paper is which a file with the same name
3. to Zipalign
Code:
LOG_FILE=/data/zipalign.log
if [ -e $LOG_FILE ]; then
rm $LOG_FILE;
fi;
echo "Starting Automatic ZipAlign $( date +"%m-%d-%Y %H:%M:%S" )" | tee -a $LOG_FILE;
for apk in /data/app/*.apk ; do
zipalign -c 4 $apk;
ZIPCHECK=$?;
if [ $ZIPCHECK -eq 1 ]; then
echo ZipAligning $(basename $apk) | tee -a $LOG_FILE;
zipalign -f 4 $apk /cache/$(basename $apk);
if [ -e /cache/$(basename $apk) ]; then
cp -f -p /cache/$(basename $apk) $apk | tee -a $LOG_FILE;
rm /cache/$(basename $apk);
else
echo ZipAligning $(basename $apk) Failed | tee -a $LOG_FILE;
fi;
else
echo ZipAlign already completed on $apk | tee -a $LOG_FILE;
fi;
done;
echo "Automatic ZipAlign finished at $( date +"%m-%d-%Y %H:%M:%S" )" | tee -a $LOG_FILE;
Calibrate Battery
Code:
SLEEP=120
if [ -e /data/.battery-calibrated ] ; then
exit 0
fi
(
while : ; do
LEVEL=$(cat /sys/class/power_supply/battery/capacity)
CUR=$(cat /sys/class/power_supply/battery/batt_current)
if [ "$LEVEL" == "100" ] && [ "$CUR" == "0" ] ; then
log -p i -t battery-calibration "*** LEVEL: $LEVEL CUR: $CUR***: calibrating..."
rm -f /data/system/batterystats.bin
touch /data/.battery-calibrated
exit 0
fi
# log -p i -t battery-calibration "*** LEVEL: $LEVEL CUR: $CUR ***: sleeping for $SLEEP s..."
sleep $SLEEP
done
) &

sportsstar89 said:
The problem with the kitchen is it doesn't have an config script for the ruby so just take any updater script from any Rom and it'll work
Sent from my HTC_Amaze_4G using xda premium
Click to expand...
Click to collapse
Can you give me some tips so I can make it work myself?

hasoon2000 said:
Can you give me some tips so I can make it work myself?
Click to expand...
Click to collapse
Well the problem is that it has the wrong mount points so you change MTD or yaffs to EXT4 and you'll need to change the partition numbers which you can compare on any other updater scrip I would need to see it to tell you more
Sent from my HTC_Amaze_4G using xda premium

Google amaze 4g mount points and also how to write updater-script, I found an excellent tutorial right here on xda that taught me to write a script and the mount points are helpful for the obvious reason, though there are some universal methods I found in peoples scripts that are much easier to write.
Sent from a Galaxy Nexus?

Related

[DISCUSSION]PerfectPeso by trettet!

Ok,this is weird.Why his topic was closed?
http://forum.xda-developers.com/showthread.php?t=1382033
I noticed that his website was blocked by SOPA.Why?The download links were mediafire links,no MU.Also Android is open source,and in his ROM it wasn't any paid app by default(i mean in system/app).What's going on?Is mediafire gonna be taken down?I noticed that it barely works.But why topic closed?
The reason is, maybe link was associate with megaupload...
Sent from my Galaxy Nexus using Tapatalk
he used mediafire links...
Marius Cristian said:
Ok,this is weird.Why his topic was closed?
http://forum.xda-developers.com/showthread.php?t=1382033
I noticed that his website was blocked by SOPA.Why?The download links were mediafire links,no MU.Also Android is open source,and in his ROM it wasn't any paid app by default(i mean in system/app).What's going on?Is mediafire gonna be taken down?I noticed that it barely works.But why topic closed?
Click to expand...
Click to collapse
i tot SOPA was shelved for the moment?
Sorry if this is OT.
But I would like to share some bugs I found while using 1.1A as I didn't upgrade to 1.4 as the links were down. Can you verify whether these are faced by any of you !
1. It takes time to wake up from the lock screen. ie even after a hard key press the screen wakes up after say 3-4 secs.
2. Data connection works with flaws. 2G/3G data seems to be buggy.
3. The notification power widget and power widget doesnt work properly. ie, even if i disable/enable Data/Orientation Lock the effect is not applied. I cant even change it in settings. Only solution is a reboot.
4. Incoming call button issues. (Solved in later versions)
Other than these, the rom is pretty stable.
umm I didn't had any of those bugs in v1.1a.actually it was one of the best version because of kernel, except few graphical bugs.anyway,look on last page/page before that of the rom,pm rosuvladut and ask him to upload rom v1.4 to 4shared or another.if he doesn't have it anymore send me a pm and I will upload v1.3 for you when I get home.i personally am lazy to upgrade to v1.4 because the changes are too insignificant.you can upgrade rom manager by yourself, instead of root browser use root explorer.about super charger I don't use it so for me v1.3=v1.4
anyone knows more about why his topic was closed? we could add other download links and that's it.
Sent from my LG-P500 using Tapatalk
I checked back in dev thread to see if any of the down links where updated. Was surprised to see no post by trettet about site being down, then noticed thread was locked. Hope all is well.
tread closed? why!
Anyone know why the notifications won't stop making noise until I view them...the sound is very annoying when it doesn't stop? I only want the notification sound once. Awesome ROM btw.
Sent from my LG-P500 using Tapatalk
i was about to flash 1.4 in my phone and then... closed thread, site down... =/
i have the link for pp1.4 posted by soberspine at mediafire:
http://www.mediafire.com/?udbvyy0j1oan0gv
but i don't have the fix (phone.apk) and gapps... can someone upload it?
also, where is trettet? do you think the thread was closed by him? or a forum admin closed it?
betoqm said:
i was about to flash 1.4 in my phone and then... closed thread, site down... =/
i have the link for pp1.4 posted by soberspine at mediafire:
http://www.mediafire.com/?udbvyy0j1oan0gv
but i don't have the fix (phone.apk) and gapps... can someone upload it?
also, where is trettet? do you think the thread was closed by him? or a forum admin closed it?
Click to expand...
Click to collapse
I asked the mod to close it down...because I'm quite discouraged of modders who actually copied my tweaks without even asking permission
EDIt:
anyways I'm tired of bug reports and fixing it and everything anyway
trettet said:
I asked the mod to close it down...because I'm quite discouraged of modders who actually copied my tweaks without even asking permission
Click to expand...
Click to collapse
talking about him!
does it mean you will not work on perfectpeso anymore?
i know have your work copied can be frustrating! but common, if i was you, i wouldn't give a sh*t... if there are modders copying your work, it means you have done a awesome job and we all recognize it!
again, we are all waiting for the next releases of perfectpeso!
betoqm said:
talking about him!
does it mean you will not work on perfectpeso anymore?
i know have your work copied can be frustrating! but common, if i was you, i wouldn't give a sh*t... if there are modders copying your work, it means you have done a awesome job and we all recognize it!
again, we are all waiting for the next releases of perfectpeso!
Click to expand...
Click to collapse
I will work on perfectpeso but won't be release on public, until Official CM7 Stable is out xD
@trettet could u please atleast give the links for the latest gapps :/
PHONEFIX.ZIP (v1.3 [ not sure ] and v1.4 [works perfectly]
Latest Gapps [works with all versions]
Aspee's Fix (works with v1.3 and v1.4)
As for the people who steal his work...you can all go to hell.
Trettet if you want I'll remove the files.I thought is nice for the people to enjoy your work.
trettet said:
I asked the mod to close it down...because I'm quite discouraged of modders who actually copied my tweaks without even asking permission
EDIt:
anyways I'm tired of bug reports and fixing it and everything anyway
Click to expand...
Click to collapse
NightlyfourE?
Sent from my LG-P500 using Tapatalk
manuvarghese said:
Sorry if this is OT.
But I would like to share some bugs I found while using 1.1A as I didn't upgrade to 1.4 as the links were down. Can you verify whether these are faced by any of you !
1. It takes time to wake up from the lock screen. ie even after a hard key press the screen wakes up after say 3-4 secs.
2. Data connection works with flaws. 2G/3G data seems to be buggy.
3. The notification power widget and power widget doesnt work properly. ie, even if i disable/enable Data/Orientation Lock the effect is not applied. I cant even change it in settings. Only solution is a reboot.
4. Incoming call button issues. (Solved in later versions)
Other than these, the rom is pretty stable.
Click to expand...
Click to collapse
Did you flash over without full wipe? Or changed patches now and then? I had these problem long ago bcos of one of above said reasons....a clean wipe has none of the above mentioned bugs .. I'm pretty sure of what I'm saying!
Sent from my LG-P500 using Tapatalk
androidusero1p500 said:
NightlyfourE?
Sent from my LG-P500 using Tapatalk
Click to expand...
Click to collapse
Why NightlyFourE I only use two tweak gov ( maxiumtweak and he removed it )+ remount in init.d
This
#!/system/bin/sh
# Governor Tweaks for Ondemand, Conservative, SmartassV2
# Ondemand
if [ -e /sys/devices/system/cpu/cpu0/cpufreq/ondemand/up_threshold ]; then
echo "85" > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/up_threshold;
#echo "30" > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/down_differential;
#echo "1" > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/io_is_busy;
#echo "1" > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/sampling_down_factor;
#echo "20000" > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/sampling_rate;
fi;
if [ -e /sys/devices/system/cpu/cpu1/cpufreq/ondemand/up_threshold ]; then
echo "85" > /sys/devices/system/cpu/cpu1/cpufreq/ondemand/up_threshold;
#echo "30" > /sys/devices/system/cpu/cpu1/cpufreq/ondemand/down_differential;
#echo "1" > /sys/devices/system/cpu/cpu1/cpufreq/ondemand/io_is_busy;
#echo "1" > /sys/devices/system/cpu/cpu1/cpufreq/ondemand/sampling_down_factor;
#echo "20000" > /sys/devices/system/cpu/cpu1/cpufreq/ondemand/sampling_rate;
fi;
if [ -e /sys/devices/system/cpu/cpufreq/ondemand/up_threshold ]; then
echo "85" > /sys/devices/system/cpu/cpufreq/ondemand/up_threshold;
#echo "30" > /sys/devices/system/cpu/cpufreq/ondemand/down_differential;
#echo "1" > /sys/devices/system/cpu/cpufreq/ondemand/io_is_busy;
#echo "1" > /sys/devices/system/cpu/cpufreq/ondemand/sampling_down_factor;
#echo "20000" > /sys/devices/system/cpu/cpufreq/ondemand/sampling_rate;
fi;
# Conservative
if [ -e /sys/devices/system/cpu/cpu0/cpufreq/conservative/up_threshold ]; then
echo "85" > /sys/devices/system/cpu/cpu0/cpufreq/conservative/up_threshold;
echo "80" > /sys/devices/system/cpu/cpu0/cpufreq/conservative/down_threshold; # 35 # 12 # 30 (higher will lead to noticable lags) # 35 # screen off: # 50 ## 35
echo "100" > /sys/devices/system/cpu/cpu0/cpufreq/conservative/freq_step; # more aggressive ramping up (50) # screen off: # 10
fi;
if [ -e /sys/devices/system/cpu/cpu1/cpufreq/conservative/up_threshold ]; then
echo "85" > /sys/devices/system/cpu/cpu1/cpufreq/conservative/up_threshold;
echo "80" > /sys/devices/system/cpu/cpu1/cpufreq/conservative/down_threshold; # 35 # 12 # 30 (higher will lead to noticable lags) # 35 # screen off: # 50 ## 35
echo "100" > /sys/devices/system/cpu/cpu1/cpufreq/conservative/freq_step; # more aggressive ramping up (50) # screen off: # 10
fi;
if [ -e /sys/devices/system/cpu/cpufreq/conservative/up_threshold ]; then
echo "85" > /sys/devices/system/cpu/cpufreq/conservative/up_threshold;
echo "80" > /sys/devices/system/cpu/cpufreq/conservative/down_threshold; # 35 # 12 # 30 (higher will lead to noticable lags) # 35 # screen off: # 50 ## 35
echo "100" > /sys/devices/system/cpu/cpufreq/conservative/freq_step; # more aggressive ramping up (50) # screen off: # 10
fi;
# SmartassV2
if [ -e /sys/devices/system/cpu/cpufreq/smartass/awake_ideal_freq ]; then
echo "800000" > /sys/devices/system/cpu/cpufreq/smartass/awake_ideal_freq;
if [ "`cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq`" -eq 200000 ]; then
echo "200000" > /sys/devices/system/cpu/cpufreq/smartass/sleep_ideal_freq;
else
echo "100000" > /sys/devices/system/cpu/cpufreq/smartass/sleep_ideal_freq;
fi;
echo "800000" > /sys/devices/system/cpu/cpufreq/smartass/sleep_wakeup_freq;
echo "85" > /sys/devices/system/cpu/cpufreq/smartass/max_cpu_load;
echo "80" > /sys/devices/system/cpu/cpufreq/smartass/min_cpu_load;
echo "200000" > /sys/devices/system/cpu/cpufreq/smartass/ramp_down_step;
echo "0" > /sys/devices/system/cpu/cpufreq/smartass/ramp_up_step;
fi;
Click to expand...
Click to collapse
And
#!/system/bin/sh
for k in $(busybox mount | grep relatime | cut -d " " -f3)
do
sync
busybox mount -o remount,noatime,nodiratime $k
done
for k in $(busybox mount | grep barrier | cut -d " " -f3)
do
sync
busybox mount -o remount,barrier=0 $k
done
Click to expand...
Click to collapse
And I have credit to trettet
If you think i coppy I will remove two this script
@eee I just asked cos there are no other roms except yours based on official cm.7. 2 with ics looks..
Sent from my LG-P500 using Tapatalk
androidusero1p500 said:
@eee I just asked cos there are no other roms except yours based on official cm.7. 2 with ics looks..
Sent from my LG-P500 using Tapatalk
Click to expand...
Click to collapse
I don't understand what you say

[KERNEL] [09-10-13] - SM-N9005 - SELinux Permissive - Working WiFi

KERNEL FOR SM-N9005 - SNAPDRAGON 800 MODEL
Successfully changed SELinux status to permissive. Able to restore apps with Titanium Backup with data without force closes.
This is the stock samsung kernel source, but changed the SELinux policy from enforcing to permissive.
In the settings app, it still shows as "Permissive", see the attached image.
Flash at your own risk. Please have an available flashable tar file of a working boot.img just in case, however it works fine on my phone!
Link to stock kernels: http://forum.xda-developers.com/showthread.php?t=2459328&highlight=stock+roms
Known Issues
Wifi and exfat external storage not working
WiFi not working. To fix: modify build.prop ro.securestorage.support=true - Change to false. WiFi works on reboot (Thanks to freeza)
ExFAT external storage not working. To fix: Use https://github.com/dorimanx/exfat-nofuse
Download Here: https://www.dropbox.com/s/8ze2xzk2mcbagyc/DJT_N9005_KERNEL.tar
TODO:
- Add ExFAT to kernel
- Add Busybox / init.d capability
- Add CPU overclocking
For other kernel devs, there is new feature in Snapdragon 800 mtd where you need a different version of mkbootimg tools.
More Information
Some more info:
In the build config specified by Samsung, there is the following:
Code:
CONFIG_SEC_RESTRICT_ROOTING=y
CONFIG_SEC_RESTRICT_SETUID=y
CONFIG_SEC_RESTRICT_FORK=y
CONFIG_SEC_RESTRICT_ROOTING_LOG=y
And the build notes for the kernel say this:
$ make VARIANT_DEFCONFIG=msm8974_sec_hlteeur_defconfig msm8974_sec_defconfig SELINUX_DEFCONFIG=selinux_defconfig
And if we look at the SELINUX Makefile:
Code:
ifeq ($(SEC_BUILD_OPTION_SELINUX_ENFORCE),true)
EXTRA_CFLAGS += -DCONFIG_ALWAYS_ENFORCE=true
endif
My guess is that because we are "supposed" to build with the SELinux flag, then the Makefile picks this up and sets ALWAYS ENFORCE to true. So I am now rebuilding kernel now to try it without that line.
it dose not work on my stock rom
After flashing over Omega ROM 1.0 i lost WIFI (could not activate it) and external storage access.
Still SELinux was indeed permissive and data restore with Titanium was working.
bubbl3 said:
After flashing over Omega ROM 1.0 i lost WIFI (could not activate it) and external storage access.
Still SELinux was indeed permissive and data restore with Titanium was working.
Click to expand...
Click to collapse
Thankyou I will look at fixing this. I also realised lost wifi.
Sent from my SM-N9005 using xda app-developers app
danieljamie said:
Thankyou I will look at fixing this. I also realised lost wifi.
Sent from my SM-N9005 using xda app-developers app
Click to expand...
Click to collapse
Woa, how can you able to flash kernel with locked bootloader ?, how do i create tar and boot.img from the zImage ?
Thanks
rheza02 said:
Woa, how can you able to flash kernel with locked bootloader ?, how do i create tar and boot.img from the zImage ?
Thanks
Click to expand...
Click to collapse
boot.img consists of the kernel and ramdisk. You need ramdisk compiled from source, or ripped from a current working boot.img.
Then use tool mkboot to package zImage and ramdisk into boot.img (not just any mkboot, there is a special one updated for usage with snapdragon 800).
Then just use tar command in linux: tar -cvf mykernel.tar boot.img
Then flash in odin
Does this work with SM-N900W8 version?
Sorry for Out of topic,
do you compile the boot.img with the dt.img ?
Thanks
rheza02 said:
Sorry for Out of topic,
do you compile the boot.img with the dt.img ?
Thanks
Click to expand...
Click to collapse
Yes...
Use this:
https://github.com/xiaolu/mkbootimg_tools
Can you please do it for SM-900 version also ?
Sent from my SM-N900 using XDA Premium 4 mobile app
How do we make the modules for wifi and external storage ?, I able to compile my own kernel now. but can't access external storage and wifi.
rheza02 said:
How do we make the modules for wifi and external storage ?, I able to compile my own kernel now. but can't access external storage and wifi.
Click to expand...
Click to collapse
I'm wondering the same thing brother. I want to open a thread regarding kernel compiling but don't know where to do it or where to get help. Feel so stuck.
Then my dev environment died on me and make started throwing me errors randomly after I did apt-get upgrade.
Sent from my SM-N9005 using xda app-developers app
danieljamie said:
I'm wondering the same thing brother. I want to open a thread regarding kernel compiling but don't know where to do it or where to get help. Feel so stuck.
Then my dev environment died on me and make started throwing me errors randomly after I did apt-get upgrade.
Sent from my SM-N9005 using xda app-developers app
Click to expand...
Click to collapse
Do you have google+ ?, can we chat while doing this. hehe!
rheza02 said:
Do you have google+ ?, can we chat while doing this. hehe!
Click to expand...
Click to collapse
Yeah I will send you a PM
Hi, I'm in the same boat as you guys. I have compiled a kernel successfully and while WiFi works, sdcard/exfat doesn't.
We need to figure out how to get to the bottom of this! Oddly enough, kernel modules are no longer in /system/lib/modules. I guess they're baked into the kernel?
feel free to add me on google+. my xda username @ gmail
freeza said:
Hi, I'm in the same boat as you guys. I have compiled a kernel successfully and while WiFi works, sdcard/exfat doesn't.
We need to figure out how to get to the bottom of this! Oddly enough, kernel modules are no longer in /system/lib/modules. I guess they're baked into the kernel?
feel free to add me on google+. my xda username @ gmail
Click to expand...
Click to collapse
How did you get wifi working???
Sent from my SM-N9005 using xda app-developers app
And what about Exynos kernel?
Code:
parentDir
|-- mkbootimg
|--/XXDEV-ramdisk/
+--/Kernel-folder/
Code:
makeKernel
Code:
#!/bin/sh
export KDIR=`readlink -f ../Kernel-folder/`
if [ -z ${1} ]; then
echo "Enter the device code"
exit 1;
else
export DEV=$1
fi
case $DEV in
XXDEV) export DEFCONFIG="XXDEV_defconfig";
export RDIR="XXDEV-ramdisk";;
*) echo "Not a valid device"
exit 2;;
esac;
cd $KDIR;
echo "Making $DEFCONFIG";
if [ -z $3 ]; then
make $DEFCONFIG ARCH=arm || exit 3;
nice -n 10 make modules -j4 ARCH=arm || exit 4;
nice -n 10 make -j4 ARCH=arm || exit 5;
else
echo "Bypassing kernel make."
fi
find -name '*.ko' -exec cp -av {} ../$RDIR/lib/modules/ \;
chmod 644 ../$RDIR/lib/modules/* ;
cd ..;
cd ./$RDIR
pwd;
find . | cpio -o -H newc | gzip -9 > ../$RDIR.cpio.gz
cd ..
./mkbootimg --kernel $KDIR/arch/arm/boot/zImage --ramdisk $RDIR.cpio.gz -o boot.img && echo "Made boot image."
tar cf ./Finished/Kernel-$2-$DEV.tar boot.img
echo "Made Kernel-$2-$DEV.tar"
exit 0;
Code:
parentDir/makeKernel XXDEV whateverVersionNumber
Now stop pestering me, I'm not a helpdesk. All of the above is easily found if you search for it.
I've managed to fix both sdcard(EXFAT) and WiFi

[Xperia P/U/Sola/Go] Better Internet Wi-Fi and 3G

Hello all! This is my first thread and here I'm presenting you better Internet weather you're on Wi-Fi or 3G.
Requirements:
1. Any ICS/JB ROM except CM.
2. Root.
The method is as follows:
1. Open Root Explorer.
2. Make your way to root>system>build.prop.
3. Tap and hold build.prop and tap "Open in Text Editor".
4. Add these lines to end of your build.prop:
Code:
#Better internet browsing & download speed
net.tcp.buffersize.default=4096,87380,256960,4096,16384,256960
net.tcp.buffersize.wifi=4096,87380,256960,4096,16384,256960
net.tcp.buffersize.umts=4096,87380,256960,4096,16384,256960
net.tcp.buffersize.gprs=4096,87380,256960,4096,16384,256960
net.tcp.buffersize.edge=4096,87380,256960,4096,16384,256960
net.tcp.buffersize.hspa=4096,87380,256960,4096,16384,256960
#3G Tweaks
ro.ril.hsxpa=2
ro.ril.gprsclass=10
ro.ril.hep=1
ro.ril.enable.dtm=1
ro.ril.hsdpa.category=10
ro.ril.enable.a53=1
ro.ril.enable.3g.prefix=1
ro.ril.hsupa.category=5
5. Press menu button and tap "Save and Exit".
6. Exit Root Explorer.
7. Re-boot phone.
8. Enjoy!
REMEMBER to hit THANKS better than saying!
cy56 said:
Hello all! This is my first thread and here I'm presenting you better Internet weather you're on Wi-Fi or 3G.
****ONLY FOR STOCK ICS***
This Mod is only for Stock ICS because this Mod is already present in Custom ROMs.
Requirements:
1. Stock ICS.
2. Root.
3. Unlocked Bootloader.
Click to expand...
Click to collapse
I'm sorry bro, why do we need unlocked bootloader for this?
Because I've tried this on locked bootloader and I've to flash my Stock FTF again I hadn't tried anymore due to my exams. Try if u can had this on locked bootloader.
And, sorry for late reply (if I did).
Sent from my ST25i using XDA Premium 4 mobile app
Why wouldn't it work on stock JB?
Sent from a polarized, modified, undying, amazingly talented and extremely naughty phone.
That's Work on locked Bootloader it's Works Good
Also try it on Xperia Sola Works Too
Thanks
:laugh:
Vtrendzzy said:
Why wouldn't it work on stock JB?
Sent from a polarized, modified, undying, amazingly talented and extremely naughty phone.
Click to expand...
Click to collapse
It works on JB too! I said for ICS because all JB custom ROMs already have this.
If your ROM doesn't have this, you can try this.... By the way I should change it to both ICS & JB.....
Sent from my ST25i using XDA-Developers Premium App.
REMEMBER to hit THANKS if I helped you, it's better than saying and doesn't costs nothing!
Work on kk?
Sent from my Xperia P using XDA Premium 4 mobile app
@cy56
Wouldn't it be much more simple to make a flashable zip that would reduce the how to install instructions to about 2 lines only?
Could some one make a zip of it to install with cwm?
That would help a lot lf people
Not CWM Flashable!
Potloodje said:
Could some one make a zip of it to install with cwm?
That would help a lot lf people
Click to expand...
Click to collapse
Hey! This is not CWM Flashable because if you make flashable ZIP and flash it, it'll replace your whole build.prop file and you'll get bootloop.
And, By the way, this method is so easy that anyone can do it. As I've provided whole process in step-by-step, you can do it on closed eyes! :victory: (PS: Don't try doing this closing your eyes :laugh: :laugh: )
Work on KK?
Sent from my Xperia Sola using Tapatalk
cy56 said:
Hey! This is not CWM Flashable because if you make flashable ZIP and flash it, it'll replace your whole build.prop file and you'll get bootloop.
Click to expand...
Click to collapse
Making a flashable zip that would not replace the whole build.prop is so easy that anyone can do it.
e.g. by executing this simple shell script:
Code:
#!/system/bin/sh
echo "\
line one\n\
line2\n\
lineN" >> /system/build.prop
Is that easy or what?
A bit too easy maybe as it would keep adding the lines at the bottom of build.prop every time it is executed, so something a bit more complicated is needed, like this
Code:
#!/system/bin/sh
BUSYBOX="/sbin/busybox"
SED="$BUSYBOX sed"
WC="$BUSYBOX wc"
#
COMMENT1="# YOUR COMMENT START"
COMMENT2="# YOUR COMMENT END"
MYLINES="\
$COMMENT1\n\
line1\n\
line2\n\
lineN\n\
$COMMENT2"
#
EXPECTEDLINES=`echo "$MYLINES" | $SED 's/'"$MYLINES"'/'"$MYLINES"'/' | $WC -l`
if [ "$EXPECTEDLINES" == "" ]; then exit 1 fi;
FOUNDLINES=`$SED -e '/'"$COMMENT1"'/,/'"$COMMENT2"'/!d' build.prop | $WC -l`
if [ "$FOUNDLINES" == "0" ]; then
echo "$MYLINES" >> build.prop
exit 0;
fi
exit 2;
And if you don't want to rely on CWM having busybox, add busybox to the zip and change
BUSYBOX="/sbin/busybox"
to
BUSYBOX=`dirname $0`"/busybox"
or just
BUSYBOX=`/tmp/busybox"
See? Anyone can do it
ChikeD said:
Making a flashable zip that would not replace the whole build.prop is so easy that anyone can do it.
e.g. by executing this simple shell script:
Code:
#!/system/bin/sh
echo "\
line one\n\
line2\n\
lineN" >> /system/build.prop
Is that easy or what?
A bit too easy maybe as it would keep adding the lines at the bottom of build.prop every time it is executed, so something a bit more complicated is needed, like this
Code:
#!/system/bin/sh
BUSYBOX="/sbin/busybox"
SED="$BUSYBOX sed"
WC="$BUSYBOX wc"
#
COMMENT1="# YOUR COMMENT START"
COMMENT2="# YOUR COMMENT END"
MYLINES="\
$COMMENT1\n\
line1\n\
line2\n\
lineN\n\
$COMMENT2"
#
EXPECTEDLINES=`echo "$MYLINES" | $SED 's/'"$MYLINES"'/'"$MYLINES"'/' | $WC -l`
if [ "$EXPECTEDLINES" == "" ]; then exit 1 fi;
FOUNDLINES=`$SED -e '/'"$COMMENT1"'/,/'"$COMMENT2"'/!d' build.prop | $WC -l`
if [ "$FOUNDLINES" == "0" ]; then
echo "$MYLINES" >> build.prop
exit 0;
fi
exit 2;
And if you don't want to rely on CWM having busybox, add busybox to the zip and change
BUSYBOX="/sbin/busybox"
to
BUSYBOX=`dirname $0`"/busybox"
or just
BUSYBOX=`/tmp/busybox"
See? Anyone can do it
Click to expand...
Click to collapse
Ohh man you really know a lot of programming. Can u teach me from basics? Pls
Sent from my ST27i using XDA Premium 4 mobile app
Or you can simply create a build entry
Hukanawa said:
Or you can simply create a build entry
Click to expand...
Click to collapse
Whazet?
@cy56
The net.tcp.buffersize props make absolutely no change at all as the are set by init.
The ro.ril props are not present at stock at all so at best they do no harm.
Never works for me....
ChikeD said:
Making a flashable zip that would not replace the whole build.prop is so easy that anyone can do it.
e.g. by executing this simple shell script:
Code:
#!/system/bin/sh
echo "\
line one\n\
line2\n\
lineN" >> /system/build.prop
Is that easy or what?
A bit too easy maybe as it would keep adding the lines at the bottom of build.prop every time it is executed, so something a bit more complicated is needed, like this
Code:
#!/system/bin/sh
BUSYBOX="/sbin/busybox"
SED="$BUSYBOX sed"
WC="$BUSYBOX wc"
#
COMMENT1="# YOUR COMMENT START"
COMMENT2="# YOUR COMMENT END"
MYLINES="\
$COMMENT1\n\
line1\n\
line2\n\
lineN\n\
$COMMENT2"
#
EXPECTEDLINES=`echo "$MYLINES" | $SED 's/'"$MYLINES"'/'"$MYLINES"'/' | $WC -l`
if [ "$EXPECTEDLINES" == "" ]; then exit 1 fi;
FOUNDLINES=`$SED -e '/'"$COMMENT1"'/,/'"$COMMENT2"'/!d' build.prop | $WC -l`
if [ "$FOUNDLINES" == "0" ]; then
echo "$MYLINES" >> build.prop
exit 0;
fi
exit 2;
And if you don't want to rely on CWM having busybox, add busybox to the zip and change
BUSYBOX="/sbin/busybox"
to
BUSYBOX=`dirname $0`"/busybox"
or just
BUSYBOX=`/tmp/busybox"
See? Anyone can do it
Click to expand...
Click to collapse
I tried it many times but it never works for me. But I tried a different method which doesn't required programming and that method never works for me thereby giving me "Infinite Bootloop"!
If someone wants to have flashable ZIP please contact him!​
Works for me!
ChikeD said:
Whazet?
@cy56
The net.tcp.buffersize props make absolutely no change at all as the are set by init.
The ro.ril props are not present at stock at all so at best they do no harm.
Click to expand...
Click to collapse
I don't know programming hence I don't know what each and every content does. I found this in many ROMs and they gave me better internet stability as in Stock ROM my downloads are usually halted so I shared this for those users who don't have this in their ROMs. I don't know the original creator of this so I can't thank him.
Try it!
jjssore said:
Work on KK?
Sent from my Xperia Sola using Tapatalk
Click to expand...
Click to collapse
KK Nightly's latest build already have some 3G and Wi-Fi tweaks different from this. If you don't have you can have a try!
But before trying make a backup of your current ROM from CWM.
cy56 said:
I don't know programming hence I don't know what each and every content does. I found this in many ROMs and they gave me better internet stability as in Stock ROM my downloads are usually halted so I shared this for those users who don't have this in their ROMs. I don't know the original creator of this so I can't thank him.
Click to expand...
Click to collapse
So how do you know it works, what difference does it make?
I think it is better not to post things you don't know about, unless it's a share/link to app or MOD someone did.
Maybe there are RMs it works, but ROMs have many other changes that may make it work.
cy56 said:
KK Nightly's latest build already have some 3G and Wi-Fi tweaks different from this. If you don't have you can have a try!
But before trying make a backup of your current ROM from CWM.
Click to expand...
Click to collapse
where i can find link kk nightly ? and any bugs?

ChEEtah STAbilizer [make your device run]

Cheetah stabilizer for your phones !!
this is a stabilizer that will run your phone at top speed,improve battery life and improve ur internet speed
all the roms are supported for this
best for samsung stock
it also removes bloatware from ur phone
Download!
functions
.improves multitasking performance
.improves battery life
.modified init.d script
.bolatware removal
..2080 Cache Velocity
Scripts init.d
.Auto hibernates unused bins
.Zipalign In Boot
.Clear the cache on boot
.Auto Zipalign in 48hrs
.Mata unused applications when the screen turns off (Sleep)
.Lowers the clock speed when the phone is asleep
if u like it then plz donate so that we can continue the developement of more tools and utilities for your phone
click here to donate -
thanks
XDA:DevDB Information
Cheetah V0.1, Tool/Utility for the Sony Xperia Z3
Contributors
Brawn_Sg, Brawn_Sg
Version Information
Status: Stable
Created 2015-07-19
Last Updated 2015-07-19
Brawn_Sg said:
this is a stabilizer that will run your phone at top speed,improve battery life and improve ur internet speed
all the roms are supported for this
best for samsung stock
it also removes bloatware from ur phone
Click to expand...
Click to collapse
Best for Samsung? Then why are you posting this here? Does it work for the Xperia Z3 Compact? If so, can you tell us what bloatware was removed?
Wonderful. An undocumented snake oil script, available only from a site well known to be compromised and peddling malware. (Dev-host has not been reliable/reputable for months, it's obviously under new ownership.)
Another take at V6 script?
Downloaded just for giggles and took a look inside.
TL;DR: Another "copy&paste everything that sounds cool together". DON'T USE!
The start of the install process inspires confidence:
cp /system/build.prop /data/malyrol/build.prop.bak
Click to expand...
Click to collapse
Right, I don't have "/data/malyrol/" folder in there. So much for backup.
echo "" >> /system/build.prop
echo "cheetah" >> /system/build.prop
echo "" >> /system/build.prop
Click to expand...
Click to collapse
Because putting random branding stuff in property file is so cooooool!
Then a lot of random stuff (some of it might do something, just not sure what, hopefuly not much). Lots of it will be hardware dependant (HAL specific&stuff) and i seriously doubt it's compatible with a Z3.
Now for some random "fun"
#!/system/bin/sh
### Clean-Up Junk Files
rm /data/local/*.apk
rm /data/local/tmp/*.apk
rm /data/*.log
rm /data/log/*.log
rm /cache/*
rm /cache/recovery/*
rm /data/system/dropbox/*.txt
rm /data/backup/pending/*.tmp
rm /data/tombstones/*
rm /sdcard/LOST.DIR/*
Click to expand...
Click to collapse
Just... wow...
Hope you didn't have your FOTA recovery in there... OOPS!
# file system speedup
/system/xbin/busybox mount -o remount,noatime,barrier=0,nobh /system;
/system/xbin/busybox mount -o remount,noatime /data;
/system/xbin/busybox mount -o remount,noatime,barrier=0,nobh /cache;
Click to expand...
Click to collapse
I certainly don't need my data to be safely stored, thank you!
AKA
MOAR SPEEEEED!
sysctl -w kernel.sched_latency_ns=18000000
sysctl -w kernel.sched_min_granularity_ns=2000000
sysctl -w kernel.sched_wakeup_granularity_ns=3000000
Click to expand...
Click to collapse
Who needs interactivity. Good for benchmarks I guess?
sysctl -w vm.drop_caches=3
Click to expand...
Click to collapse
W00T?! Let's hope it gets reset later. But why, god, why?
P.S. Don't see it reset anywhere... Let's hope it at least doesn't work
echo "0 4 * * 2 fstrim /cache" > /data/crontab/root
echo "0 5 * * 2 fstrim /data" >> /data/crontab/root
echo "0 6 * * 2 fstrim /system" >> /data/crontab/root
Click to expand...
Click to collapse
Hmm, does fstrim work on Z3? It actually does. So this part is actually useful (sort of, because Android already does that )
#!/system/bin/sh
/data/data/ccc71.at/binaries/arm/sysctl -w kernel.random.read_wakeup_threshold=1024
/data/data/ccc71.at/binaries/arm/sysctl -w kernel.random.write_wakeup_threshold=2048
Click to expand...
Click to collapse
Nope, no such binary there. So much for testing.
# Enable Linux Swap
swapon /dev/block/platform/msm_sdcc.1/mmcblk0p3
Click to expand...
Click to collapse
[email protected]:/dev/block/platform/msm_sdcc.1/by-name # ls -la |grep p3
lrwxrwxrwx root root 1970-11-18 01:50 s1sbl -> /dev/block/mmcblk0p3
Click to expand...
Click to collapse
Sure, who needs a bootloader??
I just hope android's "swapon" needs that magical command to create swap beforehand, or there's going to be a lot of sad smileys around there...
Of course some of this stuff is set and re-set a few times in various scripts... by various people... for various devices.... and android versions...
Zviratko said:
Downloaded just for giggles and took a look inside.
TL;DR: Another "copy&paste everything that sounds cool together". DON'T USE!
The start of the install process inspires confidence:
Right, I don't have "/data/malyrol/" folder in there. So much for backup.
Because putting random branding stuff in property file is so cooooool!
Then a lot of random stuff (some of it might do something, just not sure what, hopefuly not much). Lots of it will be hardware dependant (HAL specific&stuff) and i seriously doubt it's compatible with a Z3.
Now for some random "fun"
Just... wow...
Hope you didn't have your FOTA recovery in there... OOPS!
I certainly don't need my data to be safely stored, thank you!
AKA
MOAR SPEEEEED!
Who needs interactivity. Good for benchmarks I guess?
W00T?! Let's hope it gets reset later. But why, god, why?
P.S. Don't see it reset anywhere... Let's hope it at least doesn't work
Hmm, does fstrim work on Z3? It actually does. So this part is actually useful (sort of, because Android already does that )
Nope, no such binary there. So much for testing.
Sure, who needs a bootloader??
I just hope android's "swapon" needs that magical command to create swap beforehand, or there's going to be a lot of sad smileys around there...
Of course some of this stuff is set and re-set a few times in various scripts... by various people... for various devices.... and android versions...
Click to expand...
Click to collapse
I'm glad it was you who downloaded it "just for giggles", because your your entire dissection post actually cracked me up with laughter, with each & every annotation you made[emoji13] XD
A donation scam for a placebo effect at best, that's what I see.
Cheetahs are extinct in India and these placebos should join them.
Zviratko said:
W00T?! Let's hope it gets reset later. But why, god, why?
P.S. Don't see it reset anywhere... Let's hope it at least doesn't work
Click to expand...
Click to collapse
That might be a oneshot thing. I need to look through a script I have here for one of my benchmarking tests on a non-Android system. (I intentionally drop all FS caches to ensure run-to-run consistency for this particular test). IIRC "drop caches" is particularly nasty in that it drops everything - even if it is unwritten. (Last I looked, there wasn't a way to drop all read caches without also dropping all write caches - so make sure you sync beforehand!)
Sure, who needs a bootloader??
I just hope android's "swapon" needs that magical command to create swap beforehand, or there's going to be a lot of sad smileys around there...
Click to expand...
Click to collapse
Yeah I'm fairly certain "swapon" will only do something if it detects some sort of "magic" indicating a partition is swap. Still, in the event the bootloader were ever accidentally misdetected as being a swap partion - HOLY HELL THIS IS DANGEROUS!
Edit: Strange, how is this now in the Galaxy Pocket Neo forum when it used to be in the Z3 forum?
Entropy512 said:
That might be a oneshot thing. I need to look through a script I have here for one of my benchmarking tests on a non-Android system. (I intentionally drop all FS caches to ensure run-to-run consistency for this particular test). IIRC "drop caches" is particularly nasty in that it drops everything - even if it is unwritten. (Last I looked, there wasn't a way to drop all read caches without also dropping all write caches - so make sure you sync beforehand!)
Click to expand...
Click to collapse
drop_caches writes all the dirty pages if needed and drops the rest, no need to sync
Entropy512 said:
Yeah I'm fairly certain "swapon" will only do something if it detects some sort of "magic" indicating a partition is swap. Still, in the event the bootloader were ever accidentally misdetected as being a swap partion - HOLY HELL THIS IS DANGEROUS!
Click to expand...
Click to collapse
You need to do a "mkswap" beforehand, that writes the magic bytes to make it a viable swap partition. I wasn't specific on purpose because someone might actually try to "fix" it
Mod Edit
This would appear to be doing more harm than good.
Thread closed
malybru
Forum Moderator

How to create a script that drop_caches every 1 second?

sync && echo 3 > /proc/sys/vm/drop_caches
Just not sure how to make it run the script over and over again every 1 second?
chris1892006 said:
sync && echo 3 > /proc/sys/vm/drop_caches
Just not sure how to make it run the script over and over again every 1 second?
Click to expand...
Click to collapse
Put an executable script like this
Code:
#!/system/bin/sh
while:; do
sync && { echo 3 > /proc/sys/vm/drop_caches; }
sleep 1
done
into /etc/init.d directory
jwoegerbauer said:
Put an executable script like this
Code:
#!/system/bin/sh
while:; do
sync && { echo 3 > /proc/sys/vm/drop_caches; }
sleep 1
done
into /etc/init.d directory
Click to expand...
Click to collapse
What if I don't have an init.d directory for my rom? How do I install it? Meticulus never added it to the Carbon Rom 4.4.4 kitkat or his 5.1.1 rom for the YP-G70 Samsung Galaxy Player 5.0.
chris1892006 said:
What if I don't have an init.d directory for my rom? How do I install it? Meticulus never added it to the Carbon Rom 4.4.4 kitkat or his 5.1.1 rom for the YP-G70 Samsung Galaxy Player 5.0.
Click to expand...
Click to collapse
If Android is rooted, then you install INIT.D SCRIPTS SUPPORT app - see attachment
i received an error on sm manager
chris1892006 said:
i received an error on sm manager
Click to expand...
Click to collapse
Ah, as I can see suggested script contains a syntax error: a blank is missing between "while" and colon. Sorry for this.
Code:
while :;
Some infos:
https://bash.cyberciti.biz/guide/Infinite_while_loop
https://www.tecmint.com/clear-ram-memory-cache-buffer-and-swap-space-on-linux/
I keep getting syntax errors, can u test the script first and re post a working command possibly? this will work on any android device and is harmless.
chris1892006 said:
I keep getting syntax errors, can u test the script first and re post a working command possibly? this will work on any android device and is harmless.
Click to expand...
Click to collapse
Ran script in Android 7 emularor: NO ERRORS!
jwoegerbauer said:
Ran script in Android 7 emularor: NO ERRORS!
Click to expand...
Click to collapse
Thank you
I ran it like this in SM Manager and I get this error
#!/system/bin/sh
while :; do
sync && { echo 3 > /proc/sys/vm/drop_caches; }
sleep 1
done
Can you also suggest a way to free all memory every 1 second as well? There is this "Other" ram area of ram thats hogging all the ram.

Categories

Resources