Matthias Mobil Tech Weblog

Android – Google – Motorola – Polar

G1: Cyanogen 4.1.999(9) Current System Configuration

with 6 comments

As my G1 is running very smooth after a trying very different system configs, it is time to share all this.

1) Hardware

I switch to a 16Gb, Class 6 SD Card and folks, it makes such a difference. You can tweak you conf as much as you want… Horsepower beats nothing.

2) Upgrade to the new Cyanogen releases

Only one comment – Do a fresh clean install! Wipe userdata, clean your ext partitions.. all this good stuff will make it easy and prevent most of the issues posted in different forums aka FC’s and unresponsiveness.

3) SD Card Partition

As written in a previous artikel, I went for FAT32, 500MB EXT 4 (!!!) and initially 64MB Linux Swap. Couple of comments:

Use EXT4 for ext partition!
I increased the size of my linux swap to 128MB (why – later)

4) System Configuration

I did play around with SWAPPER and other tools, but then went to use the variant with USER.CONF and USERINIT.SH from XDA forum. The main settings to tweak are:

  • COMPCACHE (compache)
  • SWAP_FILE (swap file on sd card fat32 partition)
  • LINUX_SWAP (linux swap partition)
  • SYS_WM (virtual memory setting)
  • PROC_CPU (cpu clock settings)

I tried all kinds of combination, but finally I’m using only LINUX_SWAP and PROC_CPU. COMPCACHE and all other stuff did slow the G1 down compared to this.

4.1) LINUX_SWAP

#Linux swap parameters
linux_swap{
linux_swap_en=1 # enable(1) or disable(0) linux swap
linux_swap_partition=/dev/block/mmcblk0p3 # swap partition device
swappiness=60 # default 60

As I use a large linux swap partition, I can increase the swappiness to 60. This gives me the following output on the FREE command:

total used free shared
Mem: 98140 96392 1748
Swap: 124992 38168 86824
Total: 223132 134560 88572

Not bad at all! Other report could performance on smaller LINUX_SWAP partitions or even degraded performance on part size bigger then 64MB… Try for yourself. This conf is probably a bit slower when initially loading apps, but when switching between different apps already loaded … quick.

4.2) PROC_CPU

#cpu clock
proc_cpu{
proc_cpu_en=1 # enable(1) or disable(0) user cpu configurations
# freqency options
scaling_min_freq=128000 # default 245760
scaling_max_freq=528000 # default 528000
sampling_rate=2000000 # default 2000000 depending on kernel version
powersave_bias=200 # default 0, (200 since CM3.9.6+ )
up_threshold=40 # default 45, percent cpu usage before going up a speed step
}

So on higher use (treshold=40) the G1 runs full speed 528Mhz. Otherwise it scales down to 245Mhz. My G1 gives me the following information on frequency use:

128000 – 17767
245760 – 244540
384000 – 110545
528000 – 57316

So full throttle when needed and slowing down when not – Means if you use your G1 you get good speed and if not you conserve battery.

5) Activate your Configuration

First, push or copy your file onto your G1. Now go via terminal or adb to the directory /system/sd where you stored the 2 files user.conf and userinit.sh and execute in terminal sh userinit.sh -s and check your config results via sh userinit.sh -i.

6) Summary

With the mentioned tweaks, I have the best G1 software configuration I ever had before. No FC’s at all ! Let’s wait on the next Cyanogen release

Matthias

user.conf
userinit.sh

Written by Matthias

17. October 2009 at 07:51

6 Responses

Subscribe to comments with RSS.

  1. Hello Matthias, nice post. I’m trying your settings. Could you please post your user.conf file? I would check if everything is ok on my conf. Thanks

    Roberto

    17. October 2009 at 12:12

    • Post edited, links to the user.conf and userinit.sh now at bottom of page.

      Matthias

      17. October 2009 at 13:07

  2. Thanks for it. I applied everything you said, but (using your user and userinit files) I can’t get my swap partiotion working:

    # free
    total used free shared buffers
    Mem: 98140 96372 1768 0 148
    Swap: 24528 7268 17260
    Total: 122668 103640 19028

    Any idea about that?

    Thanks in advance

    thilahute

    18. October 2009 at 02:47

    • Forget one thing in the article: Did you execute the userinit.sh script?

      1) Go via terminal or adb to the directory /system/sd where you stored the 2 files user.conf and userinit.sh.
      2) Execute in terminal sh userinit.sh -s

      This will fix it.

      Matthias

      19. October 2009 at 06:12

  3. Hello from Russia!
    Can I quote a post in your blog with the link to you?

    Polprav

    23. October 2009 at 00:40

    • Sure, go ahead.

      Matthias

      23. October 2009 at 08:37


Leave a Reply