[DEV] CM7 Developers Thread

Search This thread

dalingrin

Inactive Recognized Developer
Nov 6, 2007
1,433
2,756
Please limit this thread to development comments and questions!
The users thread is for all other posts.
When in doubt, post in the users thread.


After many long nights of banging our heads against keyboard, the CM7 port is finally shaping up.
In addition to nightly releases, we may from time to time be releasing test builds here for your feedback and enjoyment. If you find issues please feel free to post here in this thread. Leave all other feedback for the user thread.

Where to get progress news:

I will tweet progress from time to time.
Twitter: @dalingrin

We are usually in #nookie on freenode.

You can always check the Cyanogen git@ http://github.com/cyanogenmod

Current Issues

DO NOT FORMAT YOUR SD CARD IN CM7. DUE TO A VOLD ISSUE THIS WILL FORMAT YOUR /BOOT INSTEAD OF THE SD CARD!
****Should be fixed in nightly 13****

-Standy battery life is not as good as stock
Because of a kernel bug CM7 does not fully sleep. The result
is ~1% battery drain per hour while the screen is off. With normal use I usually go
1 - 2 days between charging.
***fixed in 2.6.32 builds***

-A few apps do not scale to full screen
In order to get Market and Maps to work fully the lcddensity has to be
set to something other than 160 causing a few apps not to scale properly.

-Wifi slow to reconnect at times
****fixed****


-Video playback is slow
****fixed****

-Default rotary lockscreen does not fit screen
****fixed****

-Market partially works
****fixed****

-Bluetooth does not work
****Update**** Bluetooth now works in CM7.
Bluetooth is working seemingly perfect except for the range. Unfortunately, the range is terrible.
Depending on the device you are paried with, the range is between 1-5ft. Any ideas on how to
fix the range issue would be much appreciated.

-Do not use SetCPU profiles
If you enable SetCPU profiles it will become a runaway process eating 100% cpu.
Setting your cpu clock can be done in Cyanogenmod Settings. Under Performance->CPU Settings

-Internal storage partition is not mounted on boot and is not shareable via USB
****fixed****


Download and Install

MUST USE 3.0.1.0+ RECOVERY:
This is installable ONLY with an ext4 aware Clockwork Mod Recovery.

*** Also it is critical to be aware that installing CM7 will write to the internal emmc of your device. You are advised NOT to try it. But if you choose to do so, understand you do so entirely at your own risk. Read sections 15-17 of the GPL for the gist of this disclaimer. There is no warranty or claim of usefulness or fitness for any particular purpose. No one but you shall accepts responsibility for what may happen if you download or try to use this development software. ***


Download for CM7:

Nightlies
:
http://mirror.teamdouche.net/?device=encore

Install instructions:
http://xdaforums.com/showpost.php?p=11452450&postcount=19
 
Last edited:

fattire

Inactive Recognized Developer
Oct 11, 2010
2,281
6,473
www.eff.org
Developer Tips

(Standard do-at-your-own-risk-and-responsibility disclaimers apply.)

* For those developers building from source:

In $OUT, you'll find a few files:

recovery.img --> rename to uRecRam
kernel --> rename to uRecImg

Now you've got the ext4 clockworkmod for mmc built from source.

* Also, there's also a script in $OUT called:

sd_ramdisk_packer.sh

Assuming this works, it should repack your $OUT/root (mmc ramdisk) into a uRamdisk that can be used with a bootable SDcard. The stuff in /system would go in the /system partition of the SD card (p2).

The result: a bootable CM7 on SD. It may not be wise to distribute as Cyanogenmod for encore is a fast-moving target-- unless you plan to create a new one every day or something.

* If you don't like the buttons at the top for some reason, there's the SoftKeys app as well as Button Savior.

* There is a slightly-themed u-boot.bin in device/bn/encore/prebuilt/boot/. It is simply a recompiled u-boot from BN's source.​

encoreboot.png


Info about emmc geometry

If your emmc is hosed and you want to start COMPLETELY from scratch, understand that the underlying geometry (before any partitions are created) of your emmc must be set up correctly on OMAP machines such as the nook before any partitions are created.

You can read more about that stuff here. If you are booted into an "emergency" SD card and have a totally hosed emmc, you can use fdisk to format /dev/block/mmcblk0 to the correct geometry, and then create the partitions one at a time, with a vfat partition as your /boot partition (p1). Then put mlo, u-boot.bin, uImage, uRamdisk, uRecImg, and uRecRam in /boot (p1) and you should have a bootable system.

Read the link above about SD/MMC formatting for OMAP3. Your nook is an OMAP3621, so you gotta get that geometry right, otherwise it won't boot. Luckily, the instructions on using fdisk are pretty good.

More info:

your emmc: /dev/block/mmcblk0
your sd: /dev/block/mmcblk1

Partition Info

the partitions you should have created are at:

/dev/block/mmcblk0p1 == /boot
/dev/block/mmcblk0p5 == /system
etc

/boot, /rom, and /media are of type "vfat"
/system, /data, and /cache are of type "ext4"

/factory (p3) isn't used by cm7

partition 4 is just there to allow you to create partitions 5-8

Sample instructions for copying files from cm7 update.zip on local computer to emmc /boot

You should be able to copy those four files simply by getting the lastest cm7, unzipping it on your computer, then once you boot into your bootable SD card, do:

Code:
COMPUTER> adb shell
# mkdir /data/bootmountpoint
# mkdir /data/systemmountpoint
# mount /dev/block/mmcblk0p1 /data/bootmountpoint
# mount /dev/block/mmcblk0p5 /data/systemmountpoint
# exit
COMPUTER> adb push mlo /data/bootmountpoint/
COMPUTER> adb push u-boot.bin /data/bootmountpoint/
COMPUTER> adb push uImage /data/bootmountpoint/
COMPUTER> adb push uRamdisk /data/bootmountoint/
COMPUTER> adb push  my/path/to/sdcard/system /data/systemmountpoint/
 
Last edited:

foxdl99

Senior Member
Aug 1, 2010
252
7
North East, MD
I can mount SD card find from my PC on Ubuntu.

Some apps don't show up on search, only one worth noting right now is Dolphin browser. I can find all kinds of add-ons, but not the app itself.

The lockscreen defaulted to the slider, but when I rebooted it went back to rotary. I went to settings and changed it back to slider.

Edit: Also to note is when I first launch the market, I get a force close on search function unless I use menu->search first. Will try fix permissions. Edit: fix permissions doesn't work, I must use menu->search the first time.

Edit 2: Beautiful Widgets shows up in market but says it isn't there when I try to install.
 
Last edited:

faceman66

Senior Member
Feb 3, 2011
125
82
I had no trouble mounting SD to my PC (windows 7 64). I don't remember which now, but many apps showed in market, allowed me to install, but when I tried to 'open' from their market page I was told they weren't there - just opening my app drawer showed them and they worked fine. Something in market for that one.
 

lafester

Senior Member
Feb 11, 2007
3,399
648
going to try it out now... thanks dalingrin :)
i notice the file name is the same as the first test release. hopefully i have the right file.

-edit-

so yes i did have the correct file. lockscreen fix works and am still able to change it to rotary although it 'appears' to be set on rotary already.
market works... so far i have not found anything missing.
i have not been able to connect to usb. first connect got me a failed driver install and i don't see any usb mounting option in settings. -edit- just tried again and now it works? probably a windows thing.
Fixes that need testing

-USB storage mounting
We need folks to test mounting your sd card from within CM7 onto your computers.

-Market Access
This build contains a partial fix for Android market filters. I don't expect all apps to be available yet but I'm not sure what is and not available in the current build.

-Default lockscreen
I have submitted a patch upstream to change the default lockscreen from rotary to the traditional slider. This is because the rotary lockscreen does not scale for the nook. This patch required changing some mechanics in CM and needs testing. In particular, it needs to be verified that the initial lockscreen is the traditional slider but can still be changed in Cyanogenmod Settings.
 
Last edited:

jkurl

Senior Member
Jan 20, 2011
635
106
Fairfield, Ca
here is a problem I have noticed. When I try to buy and app I get a force close and I cannot purchase an app.


UPDATE: I installed the newest market 2.3.2 and it does the same thing. I did the wipe cache, force stop on market and framework services, rebooted and still cannot purchase apps. Gotta be something in the build that is causing it to stop. I can download free apps just fine and the apps I already purchased.
 
Last edited:

tubbymac

Member
Feb 19, 2011
15
4
I flashed the update from the original version that thecubed released and can report the following market bugs:

Astrid, Facebook, and Flixster do not show up in the market.

In the market, clicking on All Games / Top Free leads to a loading circle that never completes (no results ever get shown).
 

FletchF

Senior Member
Aug 15, 2010
229
25
So there seem to be 2 different RC1s (both called the same thing) plus a single nightly. Which one should we be testing?
 

Narfx

Senior Member
Jul 23, 2010
227
13
A Coruña
These are the only apps I use I can't see in the market:

imdb
minimalistic text
google maps and street view
simi clock
wolframalpha
speedtest.net

I tried adb pushing all of them but wolfram from my htc desire. Imdb, minimalistic text and simi clock work, speedtest and google maps force close.

I also pushed Cyanbread.apk to /system/app and selected it from theme manager, it also seems to work great.

In the market, clicking on All Games / Top Free leads to a loading circle that never completes (no results ever get shown).
That only happens sometimes for me. Most of the times it works without problems.


(edit) Oh, and mounting the sd card also works ok.
 

Top Liked Posts

  • There are no posts matching your filters.
  • 97
    Please limit this thread to development comments and questions!
    The users thread is for all other posts.
    When in doubt, post in the users thread.


    After many long nights of banging our heads against keyboard, the CM7 port is finally shaping up.
    In addition to nightly releases, we may from time to time be releasing test builds here for your feedback and enjoyment. If you find issues please feel free to post here in this thread. Leave all other feedback for the user thread.

    Where to get progress news:

    I will tweet progress from time to time.
    Twitter: @dalingrin

    We are usually in #nookie on freenode.

    You can always check the Cyanogen git@ http://github.com/cyanogenmod

    Current Issues

    DO NOT FORMAT YOUR SD CARD IN CM7. DUE TO A VOLD ISSUE THIS WILL FORMAT YOUR /BOOT INSTEAD OF THE SD CARD!
    ****Should be fixed in nightly 13****

    -Standy battery life is not as good as stock
    Because of a kernel bug CM7 does not fully sleep. The result
    is ~1% battery drain per hour while the screen is off. With normal use I usually go
    1 - 2 days between charging.
    ***fixed in 2.6.32 builds***

    -A few apps do not scale to full screen
    In order to get Market and Maps to work fully the lcddensity has to be
    set to something other than 160 causing a few apps not to scale properly.

    -Wifi slow to reconnect at times
    ****fixed****


    -Video playback is slow
    ****fixed****

    -Default rotary lockscreen does not fit screen
    ****fixed****

    -Market partially works
    ****fixed****

    -Bluetooth does not work
    ****Update**** Bluetooth now works in CM7.
    Bluetooth is working seemingly perfect except for the range. Unfortunately, the range is terrible.
    Depending on the device you are paried with, the range is between 1-5ft. Any ideas on how to
    fix the range issue would be much appreciated.

    -Do not use SetCPU profiles
    If you enable SetCPU profiles it will become a runaway process eating 100% cpu.
    Setting your cpu clock can be done in Cyanogenmod Settings. Under Performance->CPU Settings

    -Internal storage partition is not mounted on boot and is not shareable via USB
    ****fixed****


    Download and Install

    MUST USE 3.0.1.0+ RECOVERY:
    This is installable ONLY with an ext4 aware Clockwork Mod Recovery.

    *** Also it is critical to be aware that installing CM7 will write to the internal emmc of your device. You are advised NOT to try it. But if you choose to do so, understand you do so entirely at your own risk. Read sections 15-17 of the GPL for the gist of this disclaimer. There is no warranty or claim of usefulness or fitness for any particular purpose. No one but you shall accepts responsibility for what may happen if you download or try to use this development software. ***


    Download for CM7:

    Nightlies
    :
    http://mirror.teamdouche.net/?device=encore

    Install instructions:
    http://xdaforums.com/showpost.php?p=11452450&postcount=19
    30
    ENCORE 2.6.32 BETA QUICK FAQ
    ----------------------------


    WHAT'S THIS?

    Tonight, we can report to the American people and to the world, the CM7 team has conducted an operation that killed the "Sleep of Death" responsible for the senseless battery consumption of thousands of encore devices.

    Or put another way, the CM7 for encore team is proud to release a beta .32 kernel to play with. Try at your own risk.​


    WHO IS RESPONSIBLE FOR THIS?

    Verygreen, FatTire, and Dalingrin did most of the work on this update. Verygreen worked tirelessly on 2.6.32 and 2.6.35 ports of the kernel. An extra special thanks should go to him.
    We hope to use his work to eventually get newer 2.6.35+ kernels for the Nook Color.​


    WHY DO I CARE ABOUT THE .32 KERNEL? HOW'S IT BETTER THAN THE .29 KERNEL?

    It's .03 better, obviously.

    Beyond the sleep improvements, most benefits are "behind the scenes" technical fixes.

    Still, you may notice that the On/Off animation now works and that you experience subtle performance benefits that come from a new kernel. For a generic writeup of .32 features (much of which doesn't apply to the encore), see:

    http://kernelnewbies.org/Linux_2_6_32


    SO WHAT WORKS?

    * basic CM7
    * sound
    * accelerometer
    * backlight
    * wifi
    * EXPERIMENTAL bluetooth (uses new uim/kim method and .bts files)
    * video w/overlay
    * Screenshots
    * usb mounting to your computer
    * sdcard support


    WHAT DOESN'T WORK?

    * Sleep while while charging or connected to USB
    Workaround: Settings->Applications->Development->Stay Awake

    Maybe more, you tell us. Is it stable? Can you make it crash/reboot?

    Probably. This is a beta for a reason.​


    CAN I DROP THE UIMAGE KERNEL FILE INTO A 2.6.29 CM7 SYSTEM?

    No.​


    WHY NOT?

    There are several changes to the installation which make .32 incompatable with previous CM7 installations. Among them are:

    * The kernel's orientation is now native to the encore's screen. No android rotation is needed
    * The WIFI module is different
    * The method of installing BT is different.
    * The GFX (2D acceleration) drivers are different​


    IS THIS .32 KERNEL OVERCLOCKED?

    Not by default. The clock options are the same as the .29 kernel... for now.​


    WHAT ARE THE CHANGES TO BLUETOOTH?

    Bluetooth now uses the wilink driver with a "shared-transport" system that allows both bluetooth and the FM radio to work. Right now, the FM radio isn't enabled at all, as reports say the hardware support (antenna) is not connected. However, this new system makes it at least conceivably possible to use.

    Also, the new system utilizes Texas Instrument's .bts (bluetooth script) method for installing the bt firmware.​


    SO DOES THIS FIX THE BT RANGE ISSUE?

    This is all brand new-- Bluetooth range has not been extensively tested. That is for you to test.

    There are several versions of TI's bluetooth initialization script, called the "bts" script. You can get them here:

    https://gforge.ti.com/gf/project/wilink_drivers/

    The .bts files (such as TIInit_7.2.31.bts) may be placed in:

    /system/etc/firmware

    and will automatically be loaded when needed. Try different versions and experiment to see if some work better others. (Watch the log and dmesg to verify that the bts script is running properly)​


    CAN I MAKE THE FM RADIO WORK?

    The encore device is reported to not have a physical antenna connection to allow the FM radio to function.

    However, this is unexplored territory. If you are a developer and would like to experiment, you may notice that TI makes the following additional firmware files available:

    fm_rx_init_1273.2.bts
    fm_tx_init_1273.2.bts
    fmc_init_1273.2.bts

    These scripts are now potentially loadable into the wifi chip. To make CM7 believe that there is a working FM radio, add to the board file:

    https://github.com/CyanogenMod/android_device_bn_encore/blob/gingerbread/BoardConfig.mk

    the following line:

    BOARD_HAVE_FM_RADIO := true

    And recompile. Good luck!​

    IS THE BRAINFUCK SCHEDULER (BFS) INCLUDED?

    Not yet. We're investigating whether this would be worthwhile.​


    WHERE CAN I GET SOME OF THE KERNEL SOURCE FOR THIS BETA TEST?



    WHAT HAPPENED TO VERYGREEN'S 32 PORT?

    When BN released their .32 kernel, portions were migrated to Verygreen's in-progress .32 kernel source, which in turn was a modification of the .32 kernel from omapzoom.com. At the same time, fixes that were in verygreen's repository were migrated over to the BN source.

    Thus, the CM7 team ended up with *TWO* working versions of the .32 kernel.

    After some discussion, it was decided (for now) to use the source that originated from BN. This will hopefully free us to move to 2.6.35+ quicker.​
    17
    Some eye catching changes in CM7 as of late,

    Not entirely sure if these changes are what I think they are... hardware acceleration in Gingerbread?
    http://review.cyanogenmod.com/6831
    http://review.cyanogenmod.com/7062

    And an update to the Nook kernel, from Dalingrins twitter it seems it may only be one change having to do with USB support...

    http://review.cyanogenmod.com/6995

    any thoughts?

    We are in the middle of merging OMAPZoom framework changes primarily for OMAP4 device support(3D, new DSP, etc) but much of it affects the Nook as well. Media playback should improve somewhat for the Nook. Thus far I have new DSP codecs working but the overlay still needs some work.

    The kernel commit that was finally merged is just some kernel clean up to eliminate possible causes of instability and SOD. No new features yet.

    My 1st priority is to get the OMAPZoom framework changes merged because it affects multiple devices. After that I will focus back on the kernel hopefully figure out SoD and such.

    Longer term, TI has been working on an OMAP3 2.6.35 kernel finally and I would like to look into that for the Nook down the road.
    13
    Beta testers come free, I'm using Firefox 8.0 alpha1 as my primary browser just to illustrate and have participated in beta testing Windows Vista and Windows 7; As far as employing developers, the "upline" Cyanogen Mod team is made up of around 10 members plus about 5 maintainers for the Nook. I'd imagine that about 5-6 full time employed developers could handle that workload(someone correct me if I'm wrong) at about $90,000 a year per developer, that's about half a million a year for a team. B&N 2010 revenue was 6.92 billion dollars just for example, I think they can afford a few full time developers, not to mention the much bigger companies like Samsung and Motorola.

    Even with that said, Google does a good deal of the work, it seems companies must spend more time stripping out the features Google includes in AOSP than implementing useful features...

    Maybe I'm missing something, but it seems to me that these companies could be doing a much better job with their Android ports, considering what some hobbyist and skilled developers produce in their free time...

    One thing that I think the big OEMs need to change is how they organize their device development. If you look at how CM works, it is one source for all devices. All devices use the same branch. Instead of hacking up the Android framework to get feature X to work on device Y, we make it work in a device agnostic way. This is something that Samsung and others don't seem to always do. They have separate trees/branches for even the same devices(all the galaxy S variants). The end result is a mess and it makes it much more difficult to get timely updates to your devices. Additionally, some random person may decide to contribute a new feature to Android and with very little effort all CM devices reap the benefits(such as the recent boot speed up). Fixing problems at the device level can be more difficult than hacking the framework in the short term but in the long term it makes maintaining and improving Android much easier.

    I haven't been a part of CM for that long but I am definitely proud of how a small group of folks that work on something part time have been able to achieve what they have. While it can be aggravating that CyanogenMod gets kanged so much with little or no credit, I guess its better than no one wanting your work.
    11
    Developer Tips

    (Standard do-at-your-own-risk-and-responsibility disclaimers apply.)

    * For those developers building from source:

    In $OUT, you'll find a few files:

    recovery.img --> rename to uRecRam
    kernel --> rename to uRecImg

    Now you've got the ext4 clockworkmod for mmc built from source.

    * Also, there's also a script in $OUT called:

    sd_ramdisk_packer.sh

    Assuming this works, it should repack your $OUT/root (mmc ramdisk) into a uRamdisk that can be used with a bootable SDcard. The stuff in /system would go in the /system partition of the SD card (p2).

    The result: a bootable CM7 on SD. It may not be wise to distribute as Cyanogenmod for encore is a fast-moving target-- unless you plan to create a new one every day or something.

    * If you don't like the buttons at the top for some reason, there's the SoftKeys app as well as Button Savior.

    * There is a slightly-themed u-boot.bin in device/bn/encore/prebuilt/boot/. It is simply a recompiled u-boot from BN's source.​

    encoreboot.png


    Info about emmc geometry

    If your emmc is hosed and you want to start COMPLETELY from scratch, understand that the underlying geometry (before any partitions are created) of your emmc must be set up correctly on OMAP machines such as the nook before any partitions are created.

    You can read more about that stuff here. If you are booted into an "emergency" SD card and have a totally hosed emmc, you can use fdisk to format /dev/block/mmcblk0 to the correct geometry, and then create the partitions one at a time, with a vfat partition as your /boot partition (p1). Then put mlo, u-boot.bin, uImage, uRamdisk, uRecImg, and uRecRam in /boot (p1) and you should have a bootable system.

    Read the link above about SD/MMC formatting for OMAP3. Your nook is an OMAP3621, so you gotta get that geometry right, otherwise it won't boot. Luckily, the instructions on using fdisk are pretty good.

    More info:

    your emmc: /dev/block/mmcblk0
    your sd: /dev/block/mmcblk1

    Partition Info

    the partitions you should have created are at:

    /dev/block/mmcblk0p1 == /boot
    /dev/block/mmcblk0p5 == /system
    etc

    /boot, /rom, and /media are of type "vfat"
    /system, /data, and /cache are of type "ext4"

    /factory (p3) isn't used by cm7

    partition 4 is just there to allow you to create partitions 5-8

    Sample instructions for copying files from cm7 update.zip on local computer to emmc /boot

    You should be able to copy those four files simply by getting the lastest cm7, unzipping it on your computer, then once you boot into your bootable SD card, do:

    Code:
    COMPUTER> adb shell
    # mkdir /data/bootmountpoint
    # mkdir /data/systemmountpoint
    # mount /dev/block/mmcblk0p1 /data/bootmountpoint
    # mount /dev/block/mmcblk0p5 /data/systemmountpoint
    # exit
    COMPUTER> adb push mlo /data/bootmountpoint/
    COMPUTER> adb push u-boot.bin /data/bootmountpoint/
    COMPUTER> adb push uImage /data/bootmountpoint/
    COMPUTER> adb push uRamdisk /data/bootmountoint/
    COMPUTER> adb push  my/path/to/sdcard/system /data/systemmountpoint/