Super PreKernel

for the moment see this apps thread on Precentral.net/forums for details:
http://forums.precentral.net/palm-pre-tips-information-resources/242785-super-prekernel-app-download-tutorial-video.html

This is a free app that I developed along with Caj2008 and Unixpsycho from Precentral.net/forums. The purpose of this app is to make installing kernels and luna patches easier. People found installing script files a little too cumbersome and installing kernels in ipk’s was not working consistently. That is how Super PreKernel came to be!

This app will determine what kernel or luna patches you currently have. If you dont have any, great, then you can select from the options available within the app. You can install these kernels/luna patches:

—800mhz kernel
—720mhz kernel
—600mhz luna patch
—550mhz luna patch

This app is meant to compliment the CPUScaler apps. Once you use this app to install a kernel or luna patch, use the CPUScaler apps to choose your frequency or scaling scheme. CPUScalerUltimate will tell you your current frequency so you can know if your kernel installed properly.

To install this app you can use WOSQI or preware. If you are using WOSQI make sure to install each package individually. Here is the link for the download page and the preware feed:

http://www.l337tech.com/webos/apps

make sure to install both the super prekernel application and the superkernelinstaller service.

If you appreciated any of my help, enjoy any of my apps that I give away for free, or want to see more development from me, think about making a donation. Thanks!





Hope you enjoy your pre now that you converted it into a Super Pre!

thanks,

number1pete

Webos CPUScaler Application for Palm PRE – Toggles CPU Scaling

CPUScaler 1.1.1 – for use with the regular Palm Pre kernel capable of 125-600mhz
and
CPUScalerUber 1.1.1 – for use with kernels capable of 125-800mhz
and
CPUScalerUltimate 2.1.2 – for use with the regular Palm Pre kernel and/or kernels capable of 125-800mhz. It also displays cpu info, up time, load averages, battery temperature, and current stick settings. It can make your current cpu settings “stick” on reboot.
***If you enjoy this product, think about making a donation. ###This product will not work completely without a compatible kernel installed (see near bottom of page for list of compatible kernels).

cpuscalercomparison_2_1_0

Please read this entire post before installing!!!

Running your phone at very high or very low frequencies may cause problems with your phone. You have been warned. I am not responsible for anything that happens to your phone or anything your phone is/was affecting. Use at your own risk.

To install the new version you must uninstall the old CPUScaler app and its service with WOSQI or Preware!! Then you can download and install the new CPUScaler app and its service with WOSQI or Preware.

You must have a compatible kernel installed for the version of CPUScaler that you are using for the app to perform properly

This app was developed to give a Palm Pre user the ability to turn cpu scaling on and off with the touch of a button, and changes are made on the fly. The latest version also allows the user to set the cpu to a constant speed of their choosing. There are also other scaling options now if you don’t want to use the standard 500–>600mhz.

This app is only for the Palm PRE! This does not work on the palm PIXIE!

To install you have to you WOSQI (webos quick install) or Preware. To completely uninstall you have to use WOSQI or Preware!

It is very important that you remove all cpu effecting patches or code before you install any version of CPUScaler. This includes any scaling, luna setting, userspace, or smart reflex patches or scripts. Some other patches have demonstrated conflicts.

First lets talk about how to install the app. You need to download two ipk files. The cpuscaler service and the cpuscaler app. Here are the links to each:
You can use Preware for the free “Lite Versions” by copy and pasting:
http://www.l337tech.com/webos/apps
into Preware and call it “L337Tech.com-webos-free”.

CPUScaler 1.1.1 – for use with the regular Palm Pre kernel capable of 125-600mhz
com.l337tech.cpuscaler_1.1.2_all.ipk
com.l337tech.cpuscalerapp_1.1.1_all.ipk

CPUScalerUber 1.1.1 – for use with kernels capable of 125-800mhz
com.l337tech.cpuscaleruber_1.1.1_all.ipk
com.l337tech.cpuscalerappuber_1.1.1_all.ipk

CPUScalerUltimate 2.1.2 – for use with the regular Palm Pre kernel and/or kernels capable of 125-800mhz. It also displays cpu info, up time, and load averages.
***If you enjoy this product, think about making a donation. ###This product will not work completely without a compatible kernel installed (see bottom of post for list of compatible kernels).
CPUScalerUltimate Download Page

Now you need to make sure you have the latest version of WOSQI and WebOS Doctor in the same folder together. Open WOSQI and add the two ipk files you just downloaded to the install queue. Now hit install and accept the statement about l337tech requesting access to run a script. The script is just a post install script to move the cpu scaler service to the correct folder. Now you should have everything you need installed and ready to go. Alternatively you can now use Preware. The free “Lite Versions” are available by a custom feed mentioned above and the CPUScalerUltimate version is available on a private custom feed supplied on purchase. Once the custom Preware feed has been added, installation is as easy as clicking on the packaged you want installed. Preware will also alert you if you need to update any versions of CPUScaler that you have on your Pre. Simply hit the update button to upgrade to the latest version.

To use the app simply open it up and select an option by pressing won of the buttons. You will know if the button worked if you a notification at the bottom of the screen pop up. If you have CPUScalerUltimate, navigate to the stats page and verify that the settings you selected were applied. If you have any other version of CPUScaler you can use the “Set Speed 250mhz” or “Set Speed 125mhz” and see if scrolling around is uber slow. Now you can go ahead and close the app and your cpu will be scaling (or not scaling) until you reboot or shutdown your phone. If you ever reboot your phone will go back to default processor settings so you will need to open the app back up and hit scale on again. If you have the CPUScalerUltimate version and hit the “Make Settings Stick On Reboot” button then the settings that you “stuck” will be applied at reboot. To turn stick settings off just hit the “Scale And Speed Off” button. If you choose to a “Set Speed” option the speed will remain constant until you reboot or enter/exit a application developed with the SDK (typically 3D games). You will want to re enable the desired “Set Speed” option once you exit the SDK app.

To uninstall the app and its service completely you have to use WOSQI or Preware. Simply go to device management in WOSQI and select CPUScaler and an service called “Service to scale the cpu”. Now that the two apps are selected hit uninstall. CPUScaler and its service should be completely removed from your device now. For Preware, navigate to installed packages and look for CPUScaler and its service. Click them and hit remove.

New features and abilities have been added. Currently it still has the recommended setting for cpu scaling that is disused in detail in this thread. But basically it changes some parameters in the kernel to get it to scale from 500-600mhz depending on the load. See the end of the article for the exact commands used for the “scale 500–>600mhz” setting. The set speed options simply uses the userspace scaling governor to set the cpu at a speed and keep it there till you tell it otherwise or enter/exit an SDK developed application (Palm uses the userspace scaling governor default).

I, Casey Broome, or L337tech.com are not responsible for any damage this app could or may cause to your phone or anything your phone is or may effect. This app should only be used by people that understand the risk of running the cpu beyond its default settings. It is true that Palm sets the cpu to 600mhz during PDK gameplay (usually 3D games), but Palm also sets the processor back to 500mhz when you quit the game.

To upgrade you CPUScaling app to the latest version you must uninstall the old app and service first! Then you can download and install the latest version.

I just want to reiterate that if anything goes wrong once you hit one of the scaling or set speed option buttons simply restart, shutdown, or pull the battery. You phone will go back to default settings.

The TI cortexA8 processor in your phones is rated to run at 600mhz but an early batch of processors were “bad” and degraded rapidly when set to 600mhz or higher. This caused Palm to down clock all the Pre’s even though many people have a “good” processor that are more than capable of long term 600mhz use. This can be seen with the people that have tried scaling before. Some people’s phone love it and never have one problem. Other people have problems such as random reboots and hangs when using a scaling patch.

If you appreciated any of my help, enjoy any of my apps that I give away for free, or want to see more development from me, think about making a donation. Thanks!





Acknowledgments:
I would like to give my thanks to DrewPre for the great help creating and compiling the java service, and rwitby from WebOS Internals for help packaging up the java service. I would also like to thank unixpsycho and caj2008 from precentral forums for creating an amazing kernel that allows the pre to run at speeds between 125-800mhz. CPUScalerUber would not be possible with out it. I have donated to DrewPre and rwitby for their help.

Code used for “scale on”:
echo ondemand > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
echo 600000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
echo 500000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq
echo 11 > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/up_threshold
echo 1000000 > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/sampling_rate
echo 1 > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/powersave_bias

Good luck everyone and happy scaling!

number1pete

cpuscalerappultimate_2_1_0cpuscalerappultimate_uber_2_1_0cpuscalerappultimate_scalingoptionscpuscalerappultimate_setspeedoptionscpuscalerappultimate_stats1cpuscalerappultimate_stats4cpuscalerappultimate_notify_2_1_0cpuscalerappultimate_splash_2_1_0

CPUScalerUltimate version 2.1.2 added features:
-added cpu temperature support if you are using webos internals uber-kernel
-added new refresh stats button for easier stats refreshing

CPUScalerUltimate version 2.1.0 added features:
-you can choose to “stick” your current cpu settings so they are applied at reboot
-displays current stick setting on the stats page
-displays battery temperature on the stats page

CPUScalerUltimate version 2.0.0 features:
-works with any kernel (some features are dependent on certain kernels)
-displays lots of cpu info
-displays up time and load averages
-quicker loading of app
-cleaned up UI
-no annoying ad pop-ups

CPUScaler version 1.1.1 features:
-added notifications to notify the user when the cpu has been scaled or set speed
-cleaned up the UI, scaling and set speed option now have their own drawer
-changed the code in the cpuscaler service to utilize my new parameters that fix the issues of scaling going out of the range of the min and max scaling frequency
-fix preware install problem for the service
com.l337tech.cpuscaler_1.1.2_all.ipk
com.l337tech.cpuscalerapp_1.1.1_all.ipk

CPUScaler version 1.1.0 features:
-added ability to choose many more scaling options via a “more options” button
-added ability to choose setting the cpu to a constant speed (using userspace governor)
-added many constant speeds that you can set the cpu to
-added ability scroll the app
-fixed problem where app did not reset all the cpu setings back to default when you hit “Scale and Speed off”
-fixed problem where app rotated in landscape mode
-added custom splash screen
-added ability to hide the more speed and scaling options via “more options” button
-changed the up_threshold to 11% to keep the CPU scaled during phone calls
com.l337tech.cpuscaler_1.1.0_all.ipk
com.l337tech.cpuscalerapp_1.1.0_all.ipk

CPUScaler version 1.0.0 features:
-turn cpu scaling on with a button (500–>600mhz scaling)
-turn cpu scaling off with a button (resets cpu settings to Palm default)
com.l337tech.cpuscaler_1.0.0_all.ipk
com.l337tech.cpuscalerapp_1.0.0_all.ipk
——————————-
Compatible kernels for CPUScaler
1. Palm Pre default kernel in WebOS 1.4.1
——————————-
Compatible kernels for CPUScalerUber
For options that operate between 125mhz and 600mhz these kernels are compatible:
1. Palm Pre default kernel in WebOS 1.4.1
2. Custom 125–800mhz kernel customized by Unixpsycho and Caj2008, see this thread. Caj2008 has performed extensive alpha testing on this kernel.
For options that operate between 125mhz and 800mhz these kernels are compatible:
1. Custom 125–800mhz kernel customized by Unixpsycho and Caj2008, see this thread. Caj2008 has performed extensive alpha testing on this kernel.
——————————–

———————————————————————————–
###List of compatible kernels for CPUScalerUltimate

For options that operate between 125mhz and 600mhz these kernels are compatible:
1. Palm Pre default kernel in WebOS 1.4.1
2. Custom 125–800mhz kernel customized by Unixpsycho and Caj2008, download from this thread. Caj2008 has performed extensive alpha testing on this kernel.

For options that operate between 125mhz and 800mhz these kernels are compatible:
1. Custom 125–800mhz kernel customized by Unixpsycho and Caj2008, see this thread. Caj2008 has performed extensive alpha testing on this kernel.

A kernel built by unixpsycho/caj2008 and packaged by L337tech into an easy install ipk for WebOS 1.4.0 and 1.4.1 is supplied via download page with purchase of CPUScalerUltimate (look for it in the install instructions)..
————————————————————————————

***Terms of Purchase
By clicking on the “buy now” paypal link you have agreed to these terms of purchase. When purchasing an item on this page, you are buying the product it refers to “as is”. The product that a “buy now” paypal link is referring to is typically found directly above. You are not buying future versions of the product. The product is not guaranteed to be updated. The product is not guaranteed to work with future versions of WebOS or future versions of the Palm Pre. This product might never be updated. You can download any product found on the download page including future versions of the product if you bought a previous version of the product. You agree to keep the download link and download page confidential. Sharing this information or downloading without purchase can lead to legal action. This product will not work completely without a compatible kernel installed. You are not buying or may never recieve support for this product. Installation and proper functionality is not guaranteed. This product may not work with your Palm Pre in its current configuration. This product changes all the time. I, Casey Broome, or L337tech.com are not responsible for any damage this app could or may cause to your phone or anything your phone is or may effect. This app should only be used by people that understand the risk of running the cpu beyond or below its default settings. Information about this product found on this page or other pages managed by myself may not depict the product exactly in its current state.

Palm Pre Hack To Significantly Extend Battery Life

Okay, we at L337Tech have replace our iPhones out of sheer bordem (had iphone for 2 years and am now bored with it). We now have Palm Pre’s. I love my Palm Pre but was not happy with the battery life. Luckily the Palm Pre is the easiest phone to hack ever. Heck, to access developer mode you type in the konami code, come on thats awesome!! I wrote some code that uses power saving features built into the linux operating system used by the Pre. This has literally increased my battery life by 40%. It is only a matter of time before Palm sees this and writes their own power saving script. But as of right now the Pre has now power saving features so use my code.

This is basically a repost of the work i did in the forums of PreCentral.net

Okay i have been doing extensive testing. I believe i have solved most of the problems related to cpu scaling.

noted problems:
1. Video playback flickers and can be choppy
3. Phone freezes usually in standby or some other low state like listening to pandora in standby.
2. Can force the phone to have a 250mhz minimum instead of 125Mhz minimum

Fixes:
Two new scaling schemes. The first uses 1 second sampling rates and an 11% cpu utilization speed up threshold. The second method uses powersave_bias to turn on the 250mhz minimum (this will cause the phone to quit going down to 125Mhz, it goes down to 250Mhz instead during standby or other lowly states)

The fist scheme fixes video playback and phone freezes during lowly states, but does not fix the 250Mhz minimum problem so you phone will use 125Mhz for its lowly state.

The second scheme fixes phone freezes during lowly states like standby and Pandora, and makes 250Mhz the minimum cpu frequency. This method does not fix video playback flickering issues.

Here is the code:

First scheme (my favorite and the one im currently using)
assumes you are at root@castle:/#

echo ondemand > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
echo 500000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
echo 250000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq
echo 11 > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/up_threshold
echo 1000000 > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/sampling_rate

Second scheme (not my favorite because of video flicker and other reasons i will explain latter but it does utilize the 250mhz low state which is a little snappier than 125Mhz)
assumes you are at root@castle:/#

echo ondemand > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
echo 500000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
echo 250000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq
echo 11 > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/up_threshold
echo 10000000 > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/sampling_rate
echo 1 > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/powersave_bias

The main problem with the methods people were doing before is that the chip was switching between low and high state several times over the course of a few second no matter if they were playing a video or pandora. The first scheme above fixes that issue. The second scheme still suffers from this but i tried to lessen its severity by changing the sampling rate to 10 seconds (in reality it seems like 2 seconds durring testing). 10 seconds was the lowest i could go without it wanting to change states from low to high several times in a few seconds. There is something wrong with the powersave_bias function that makes it switch states faster than the sampling rate. I am looking into possible workarounds.

I would have liked to make the speed up threshold 5% but the lowest the up_threshold function would let me choose is 11%. 5% is usually low enough to have the phone running full power during pandora. Your phone is almost always lower than 5% during standby or when not doing anything on your phone.

If you want these codes to stick after a reboot then you will need to prepare a script in vi editor inside you pre’s linux system in the format similar to how they did it at pre dev wiki here

scroll down the page till you see how they made it stick. Just change the code to the codes in the post, but you need to change the format slightly. If you dont know how to do this then you do not need to be trying anything mentioned in this post.

And as always i am not responsible for any damage this may cause you. But the consensus is that the ondemand scaling function is pretty harmless to your phone. Freezes are fixed by unplugging you battery. If you want to be extra careful then just run these codes without making a script. That way when you reboot everything goes back to defaults from palm for the cpu.

If anyone can get powersave_bias stable let me know what you did. I was using trans_table in the /cpufreq/stats folder and also time_in_state within the same folder. Another usefull tool is cpuinfo_cur_freq within the /cpufreq folder. Also use top command to monitor your cpu utilization, this command can be executed anywhere within linux.

I have decided to include some code that will help anyone if they decide to do their own testing of cpu scaling and power save bias. Here is the code I use for testing:

current speed
cat /sys/devices/system/cpu/cpu0/cpufreq/cpuinfo_cur_freq
time in different frequencies
cat /sys/devices/system/cpu/cpu0/cpufreq/stats/time_in_state
number of switches between power states
cat /sys/devices/system/cpu/cpu0/cpufreq/stats/trans_table
current sampling rate
cat /sys/devices/system/cpu/cpu0/cpufreq/ondemand/sampling_rate
current up threshold
cat /sys/devices/system/cpu/cpu0/cpufreq/ondemand/up_threshold
current power save bias
cat /sys/devices/system/cpu/cpu0/cpufreq/ondemand/powersave_bias
current max freq
cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
current min freq
cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq

turn off power save bias
echo 0 > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/powersave_bias

overclocking
echo 550000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
echo 600000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
echo 1500000 > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/sampling_rate

good luck

-L337Tech

Intel e4300 Temperature Problems

For all those people who swear their e4300 doesn’t have a temperature problem, but programs like Coretemp and Everest like to tell you otherwise, here is a short clip proving software measurements are not always correct on certain Core 2 Duo’s. We attached a thermal probe to the cpu’s die and measured temperature accurate to 0.1 degree. The motherboard and therefore software was reading temperatures that were way too high. We recommend physically measuring your Core 2 Duo’s temperature manually before buying any expensive cooling equipment. This video was shot with a crappy point and shoot camera so pardon the quality.

-L337Tech