http://forum.xda-developers.com/wiki/index.php?title=Linux_on_Raphael
http://xdandroid.com/wiki/Main_Page
 Linux on Raphael
 | Contents [hide]  ·                                 1 Linux  on Raphael and Diamond  ˜                                                 1.3.1 Quick  beginners guide  ˜                                                 1.3.2 Here  are the complete steps for working DATA connection on DIAMOND.... | 
 Linux  on Raphael and Diamond
  This page is meant for people who want to know the progress on getting Linux (and Android) to work on the Raphael and Diamond devices.  It was suggested in this  forum thread to  make a wiki page, which I found to be a good idea. We're on this with some great people now. In case you feel you can help out, you  can find us using IRC on #htc-linux on  Freenode.
 Index
  - Current  state - HowTo - FAQ - DIAM  & RAPH hardware difference and configurations - Build  Your Own - Useful  links - Progress
 
 
 Please note that Android on the Diamond and Raphael is still in very primitive stages. You can run Android, but device drivers are not working  properly or even not at all. Below you'll see what works and what doesn't.
 Also make sure to follow the discussion in the forum thread "Linux  and Android on HTC Diamond".
 Function ||
Status ||  Devices ||   Comment  Boot ||
OK ||  All ||   .  Graphical interface ||
OK ||  All ||   .  Touch screen ||
OK ||  All ||   Need calibration during boot; calibration data can also be supplied through a kernel boot option  R/W Access to AT serial channel ||
OK ||  RAPH110 ||   .  R/W Access to DATA serial channel ||
Partial ||  All ||   Working, but unstable. Location dependant, it seems.  R/W Access to GPS serial channel ||
NO ||  All ||   5 seconds after the channel is accessed, the system freezes. probably some watchdog.  SD Storage Access ||
Partial ||  RAPH110, RAPH120, DIAM110 ||   Internal Storage (DIAM series) & SD (RAPH series)  Hardware keyboard ||
Partial ||  RAPH series ||   Latest build has an initial driver for the keyboard, which mostly works. Keys match RAPH100, not 110.  LEDs  ||
Partial ||  All ||   Works for the RAPH100. DIAM series doesn't work yet  Navipad  ||
Partial ||  All ||   Rotating left/right works, but it's still a little rough.  Hardware buttons ||
Partial ||  All ||  ˜                     On/Off Rotates  Android display orientation between portrait and landscape mode (DIAM100)
 ˜                     Home Menu
 ˜                     Up Up
 ˜                     Left Left
 ˜                     Right Right
 ˜                     Back Back
 ˜                     Center Enter/Select
 ˜                     Send Send
 ˜                     Down Down
 ˜                     End End  (Home, configurable in spare parts app)
 ˜                     Volume Up/Down Volume  Up/Down
 Stylus detection ||
OK ||  All ||   To be confirmed  USB Host Mode ||
? ||  All ||   ?  USB ||
Partial ||  All ||   Android function implemented.  usbnet is working. (Usb charging also works. Must be connected into usb port and charging in WM first then booted into android). ADB too  WiFi  ||
Partial ||  All ||   Work in progress. (lacking correct initialisation, works when enabled in wince)   Raph100 wifi works using phhusson files. Still has some bugs but majority of wifi works.  Bluetooth ||
Yes ||  All ||   Build release is to be done.  GPS ||
NO ||  All ||   see R/W Access to GPS serial channel  GPRS/EDGE/3G/HSUPA ||
Partial ||  All ||   GPRS data connection are confirmed working for both Raphael and Diamond devices. Same for RAPH110. (Fuze)  Audio Routing (Phone) ||
Yes ||  All ||   Making and receiving calls works in Android. Microphone support is working.  SMS/MMS ||
OK/NO ||  All ||   Send/Recieve SMS works  Power Management ||
Yes ||  All ||   Basic power management implemented - Can only charge during WM and then booted into android. touch screen turns off, on shutdown, phone powers off instead of crashes.  Camera: front/back ||
NO/NO ||  All ||   .  Accelerometer ||
OK ||  All ||   Linux / Android  FM Radio ||
NO ||  All ||   .  Light Sensor ||
WIP ||  All ||   Light sensor works in babijoee's Android 1.6 donut pack. Flashing a light into light sensor the screen definantly goes up and covering the light sensor causes the screen to dim.  
 
  #HowTo
  Quick  beginners guide
  1. Download one of the prebuilt Android packages for the HTC Raphael.
 2. Unpack it to the root folder of the SD card of your phone.
 3. Make sure the right startup.txt or default.txt for your type of phone is in the  root folder. In most prebuilt packages files for different types of phones are located in a startups or startup-config folder. Copy the right file from this folder to the root folder and rename it to  STARTUP.TXT or DEFAULT.TXT.
 4. Browse on your phone tot the root folder of your SD card en start haret.exe and  follow the instructions.
 
 Here  are the complete steps for working DATA connection on DIAMOND....
  1. Edit the default.txt and change the values according to our network provider for ppp.apn , ppp.username , ppp.password . If ur  service provider dont ask for username/password then u can use 'none'. It should look something like this: set cmdline "bla  bla ppp.apninternet ppp.username=none ppp.password=none"
 2. Connect data on WM using any application and dont disconnect the DATA. (U can update  wheather ....)
 3. Now boot into Android. and make setting for APN and save it.  Dont worry it will not display in apn but it actually saves 
 4. Now search for network in settings. and manually select your network.
 5. Long press the END key and select AIRPLANE mode.. Then again long press the END key off the airplane mode.
 6. After a while u will see the E/G symbol near the network strength symbol.. Now your data connection ready to use. You can use any application. I tested andorid market/ syncing mobile/  youtube (audio/video working) net radio etc etc.
 
 
 Different models of HTC Touch Diamond (DIAM series) and HTC Touch Pro (RAPH series) use different hardware. Here's a short list of known differences:
 Phone model ||
 mtype ||    msmsdcc_id** ||      imgdevname ||        imgdevnum ||          msmts_calib  DIAM100 ||
 1805 ||    -- ||      /dev/mmcblk0 ||        0 ||          msmts_calib=0x7A.0x5E.0x35A.0x37F  DIAM300 ||
 1805 ||    -- ||      -- ||        -- ||          same as -100  DIAM500 ||
 1805(2040 w/MrPippy's images ||    -- ||      -- ||        -- ||          same as -800  RAPH100 ||
 1910 ||    -- ||      /dev/mmcblk0p1 ||        1 ||          msmts_calib=0x6D.0x5D.0x340.0x375  RAPH101 ||
 ? ||    -- ||      ? ||        1 ||          msmts_calib=?  RAPH120 ||
 1910 ||    -- ||      /dev/mmcblk0p1 ||        1 ||          msmts_calib=0x7e.0x63.0x35f.0x386  RAPH500 ||
? 2182 ?||    -- ||      /dev/mmcblk0? ||        ? ||          msmts_calib=???  RAPH800 ||
 2039 ||    -- ||      /dev/mmcblk0p1 ||        1 ||          msmts_calib=0x81.0x393.0x358.0x7D  ˜                                 msmsdcc_id  is no longer required and should not be specified on the command line. SD controller id is automatically detected based on MTYPE (so be sure you specify it correctly in default.txt for your device)
 ˜                     
 ˜                                             a  lot of end users have been having trouble mounting their sd cards. Lavender.t came up w/a solution that I'm posting here now
 think  one way is to have mdev -s detect your partition automatically and then we make it into init. what you can do is, after boot:
 mkdir  /proc
 mkdir /sys
 mount -t proc proc /proc
 mount -t sysfs  sysfs /sys
 mount -t tmpfs  tmpfs /dev
 mdev -s
 after  running the above, do a "ls -l /dev/mmc*". this should have the mmcblk0p? with the correct minor code. and you should be able to mount on that device.
 
 
 I see a lot of users supplying this to their default/startup.txt without having any idea what it does. "Mdev -s" will create mmcblkp?, is  a wild card to mount any device named mmcblkp with 1 additional character, in this case a numberthe last line should be "mount /dev/mmcblkp /sdcard"  for it to actually do something so the code should look more like
 
 
 mkdir /proc
 mkdir /sys
 mount -t proc proc /proc
 mount -t sysfs  sysfs /sys
 mount -t tmpfs  tmpfs /dev
 mdev -s
 mount /dev/mmcblkp* /sdcard
 
 
 
 Again, this is assuming you're having trouble mounting your partitions, if you aren't this is basically useless for you. This is pure*nix info, nothing android specific.
 
 
 
 In order to run Linux on your phone, you need
 ˜                     A boot loader
We use HaRET. [[| http://www.handhelds.org/moin/moin.cgi/HaRET | (More on HaRET here..) ]] The source for HaRET can be obtained from CVS.This
is a snapshot from ˜                     A kernel
 [[| http://www.stdev.org/2008/11/01/GettingStartedWithAndroidOnTheHTCDiamond.aspx |  This page ]] ([[|http://www.wuala.com/Linux+and+Android+on+HTC+Diamond/Android+1.0/build_kernel.html?lang=de|Mirror from Google Cache]]) is a step-by-step recipe for building a Linux kernel the Diamond or Raphael. (There are separate configs for Raphael and Diamond now:  htcraphael_defconfig and htcdiamond_defconfig) You will need the tool chain to cross compile to arm. How to get and install this tool chain is also described. It checks out [[| http://git.linuxtogo.org/?p=groups/mobile-linux/kernel.git;a=shortlog;h=refs/heads/htc-msm-2.6.25 |  this repository ]] which will typically not contain the latest experimental or investigative/diagnostic code that gets posted around  the forum.
 ˜                     User space (initrd and/or mountable file system on internal storage)
 There are a couple of different flavors around: busybox, angstrom / X11, android. The one that has the most interest right now is android. You can find a  step by step recipe to build android here. This  produces an init ramdisk and 2 (yaffs) file system images: system and data. It also leaves the unpacked trees (next to the images in ./out/target/product/generic/) you can then copy to your SD card, use  to make an initrd, use to make one or more  fs images, ... 
 (I dont have the environment set up to build any other than android, add if you like)
 Want network-enabled Angstrom booting from an ext2 partition on an SD card on your Raphael? The files you'll need are zipped up here.  Unpack the zip and move the default.txt, zImage-jobo and haret executable to your device, and unpack the  tar.gz into the root of the first partition of your microSD card. boot as usual - it comes up as 192.168.0.202 over USB, expecting your linux machine on 192.168.0.200. username root, no password.
 You get a 30-second delay before mounting the root fs to calibrate the touchpad, and the screen goes blank (except the vkeyb) for much of the boot, but it works!
 
 
 ˜                     Research
 ˜                     HOWTO  build your own kernel -  borrowed from the Kaiser.
 ˜                     Latest  builds @ Connect-UTB -  Thanks to Untouchab1e
 ˜                     [[| http://www.wuala.com/Linux+and+Android+on+HTC+Diamond |  Latest builds @ Wuala Usergroup ]] - Currently searching a new maintainer as I have switched to another device - contact me,  if interested
 ˜                     Latest  builds @ Balsat (Balsat  is moving and its been a long move. Hopefully it will be back up.)
 2009-10-08 
 ˜                     An experimental build with wifi and bluetooth working has been released by phhusson get it here:
    http://husson.hd.free.fr/Android-diam-bt-wifi.7z     Quote by phhusson:     "It is based on 090909 from connect utb, and don't try any other image, it won't work.     Unless you know what you do, you won't be able to get wifi by using only 3 of the zImage, initramfs, rootfs, system.     WiFi can't be stopped (or you can somehow, but it won't restart while still consuming some extra power), and sometime,     wifi won't start, just reboot (or unload the wl1251_sdio driver from the console).     Bluetooth has only 115200 baudrate, handfree won't work. A2DP might work, but because of the available rate,     it don't think it will."     Quote by Jan.Pekar:     Link above seems to be broken, but try this page (build 20091115 has many positive votes)     http://glemsom.anapnea.net/android/special-diamond-raphael-wifi-bluetooth/ or     http://glemsom.anapnea.net/android/htc-msm-android/ (newer builds)  
 2009-09-18 
 ˜                     Backlight brightness control has been implemented.
    Note: Currently working on some devices.  2009-09-17 
 ˜                     Panel power on/off working now, this should save even more battery.
 
 2009-09-13 
 ˜                     Power Management improved,CPU completely powers down on sleep
 2009-09-06 
 ˜                     Microphone support
 ˜                     A simple Power Management is implemented.
 ˜                     GPRS data connections reported working.
 2009-09-03 
 ˜                     Audio
 ˜                     GPU
  now reportedly working.   Download pack from http://www.megaupload.com/?d=O7Q39LOZ and latest zImage from http://cs-alb-pc3.massey.ac.nz/vogue/files/?C=M;O=D  2009-06-09 
  Quotation of Jobo:   So it looks like we now have:  ˜                     mmc  for all devices (now together with good color),
 ˜                     correct colors for all devices (now together with mmc),
 ˜                     touch screen pressure size for all devices (but not yet confirmed for -800)
 ˜                     battery  for -100, maybe also for -500, needs some twiddling for -800 (
 2009-03-01 
  RAPH800 color issue has been identified, and can be fixed by changing mdp.c, line 235 to this: 
 
 
       dma2_cfg ||= DMA_DSTC0G_6BITS || DMA_DSTC1B_5BITS || DMA_DSTC2R_5BITS;  
 Still waiting to confirm what implications this has on RAPH100.  2009-02-19 ?:? ||
   I'm no expert, but here is what I can glean from the release notes at Wuala: The move to Linux 2.6.27 is finally done. Other than that, the visible changes arent that significant, but incomming calls now work, although there is still no sound and the microphone doesnt work yet either (which is now the current area of focus, so expect progress soon).  Having used the latest revision, I know it supports SMS in and out, and therefore the radio.  Touch based navigation is nearly perfect, there's a pretty good capacitive button/touch area driver, rotation, physical, and virtual keyboards all work.  As do most of the Developer demos.  Attempting to shut down Android still crashes the phone.  I had to update this page, because not all hope is lost, and you don't have to sift through a multi-hundred page thread to find that out.  WATCH THIS SPACE!  ;)  
 2009-01-07 
  Hardware buttons on the navi pad have been mapped as well as volume up/down buttons. The keyboard slider switch rotates android display orientation between portrait and landscape.   
 [1]   
 We can't yet tell Home from Send or Back from End as that requires control of the touch sensitive part (which is being worked on..)   
 Home/Send Send, Up  Menu, Center Enter/Select, Down  Back, Back/End End, Volume Up/Down  Volume Up/Down  
 2008-12-30 
  lavender.t figured out how to run [[| http://forum.xda-developers.com/showpost.php?p=3101531&postcount=1203|Android 1.0 ]] on our Diamonds. It's still in a primitive stage but it should boot up fine. If you have any questions, first check the Questions and Answers, then the forum. If you still can;t find the answer you may post it.   How to install:
 
    # Download this file diam-20081229.tar.gz| Mirror   # You also need a copy of Haret.exe.   # Unpack diam-20081229.tar.gz to your computer (e.g. your dekstop).   # Create a folder on your Diamond's Internal Storage named 'tmp' and put the three files from the 'imgs' folder from the zip, along with the three files in the root of the zip (initrd...gz, default.txt and zImage) and the 'haret-0.5.2' executable into that folder. Look at the first screenshot to see what should be in the 'tmp' folder.   # Start haret from your Diamond.   # When nothing is happening ond screen anymore type '/init.android' (without the quotes) and press enter.   # Android should now boot!   Questions and Answers
 
 
    Q: How to get back to the homescreen when I've opened a program?
 
    A: At this moment there is only a softbutton solution: 
 
     If you go to the 'Spare Parts' App and change the "End Button Behaviour' to "Go To Home" that will change the "End" key on the soft keyboard to go back to the home page.
 
    Q: When in Android, why does my screen often go black and become unresponsive?
 
    A: The screen is going to sleep. The default setting for this is 1 minute. Until it is figured out how to wake the screen, you can change the default 1 minute value by going  into the Settings application and change the sleep timeout value, under the Display application. 
 
    Q: When I try to boot Android 1.0 it says '_mmcblk0: unknown partition table_' and then stops booting.
 
    A: Try launching Haret with Activesync through USB connected, when you get past the place you got stuck before it's ok to remove the USB cable.
 
    Q: It's not working on my Touch Pro.
 
    A: Thanks to [[| http://forum.xda-developers.com/showpost.php?p=3105104&postcount=1232|LordKiwi ]] it does work but with a modified [[| http://members.upc.nl/m.hoek9/initrd.droid.cpio.gz|initrd.droid.cpio ]] Mirror. Just put all the files in 'tmp' on your Storage Card.
 
    Q: The Vogue has a fully working Android 1.0, why don't we have one and when will it come?!
 
    A: Please stop asking these kind of questions since nobody knows. A lot of people are working their butts off just for you so be patient, it will be here when it's done.
 
    Screenshots:
 
    [2] [3] [4]   [5] [6][7]   pauldgroot  2008-12-05 
  I've created two new linload (.exe) version with the latest kernel available in linuxtogo git.  ˜                     20081204-01_raph_diam_android_v0.8.exe|||mirror| (extracted|||mirror)  Newest kernel has RAPH800 (Sprint raphael/diamond) support. However, colors are still messy.
 ˜                     20081204-01_raph_diam_angstrom_usb.exe|||mirror| (extracted|||mirror)  New Angstrom console initrd with USB support (also RAPH800). You need a Linux PC (kernel 2.6.25 or higher) to use the USB functionality. You must boot this .exe with USB cable in, otherwise USB is not initialized. Follow on-screen  instructions after loading (also see screenshot below).
 2008-12-02 
  The wiki hasn't been updated for a while now and people have been starting to wonder if it is up-to-date, abandoned and so on. Well, don't worry, it's still being maintained. There just hasn't been any significant progress lately. If you want to watch the progress more closely, you can read this thread.  2008-11-07 
  I put up a screenshot of Android on the Sprint Touch Pro so you could see what I mean by colors are messed up. -bertramt   [11]  2008-11-06 
  hillsdale was able to get Android 0.8 booting on the Sprint Touch Pro.  Colors are still messed up, and it is still very beta code.  Hopefully somebody can get his diff imported into the git branch.  Hillsdale's patch can be found here: http://pastebin.com/m7aefaeb8. Remember, use at your own risk.  -bertramt  2008-11-05 
  Kernel was updated to include some touchscreen changes to make it work properly (instead of having to mirror all actions). Also updated the initrd:  ˜                     When booting, it now pauses in console to allow you to calibrate the touchscreen. Follow the on-screen instructions to do so.
   Re-enabled some services that I had previously disabled. With this GSM magically works in android. You can now receive calls (and probably also make calls). Speaker and mic don't work though*, so you can't have a conversation. Also note that you can (untested, but hinted by rl2000) hangup a phone call by pressing the 'end' key on the virtual keyboard.   Regarding the SPRINT versions of Diamond/Touch Pro; so far we have determined it's the msm_fb driver that doesn't seem to detect a framebuffer device and thus not create a tty0 to do the 'console handover'. Not sure why yet. There's been some testing with druidu's framebuffer code on which it seems to boot all the way to shell. So we've pretty much determined msm_fb driver is the cause of the Sprint issues - now we just need to solve it (easier said than done though...). :)   raph_20081105-01_android_v0.8_touchscreen_fix.exe| (all my raph_*.exe loaders should also work on Diamond). (mirror)   Also just a thanks to rl2000 for giving me some webspace to put my loaders on. My DSL isn't fast enough by far for all you guys. :)   grtz, netripper  2008-11-04 
  I promised to put up some pictures and a link to the android v0.8 experimental linload. So here you go.   [12] [13] [14]  2008-11-03 
  I'm a little bit late with this update, but better late than never. Since a little while people have managed to run Android v0.8 on their Diamond / Raphael. Nothing huge, but it's nice to see the GUI up and running. You can even play around a little bit, but as the touch screen driver is not finished yet, it's not so handy to use yet. I'll add a few pictures later. I'll also add a link to a linload version (=all in one .exe) to see the Android GUI.   On another note. There has been some experimentation with reading the NAND and even though (spurious) data could be read, windows mobile didn't boot anymore. Something was accidentally written to the NAND. Luckily the device could be saved by reflashing an OS ROM, but it could just as easily have written something in the SPL area of the NAND, which would permanently brick the device. Advice is not to play around with the NAND unless you really know what you're doing. The NAND is only 256 MB large and thus cannot contain the "Internal Storage" for the Diamond. For the people interested, the NAND device is a samsung_k9k2g08 (at least on Diamond, not checked for Raphael).   Next steps should be fixing the touchscreen driver to return calibrated results and getting the SD card to work, which hopefully is also the interface to the internal storage on Diamond.   Hope you're up to speed again. :)  2008-10-29 
  Last yesterday evening/night dcordes took the lead in merging my (netripper) code and druidu's code and shape it into a decent package. pH5 has added a branch for us on linuxtogo git to make life easier. Branch is named [[| http://git.linuxtogo.org/?p=groups/mobile-linux/kernel.git;a=shortlog;h=refs/heads/htc-msm-2.6.25|htc-msm-2.6.25 ]]. It's a direct copy of the android-msm-htc-2.6.25 branch that is available on git.android.com. A machine definition has been added (HTCRAPHAEL) which will both boot the Raphael and Diamond, so when booting with haret, use mtype 1910 from now on. To get started, you can refer to the kaiser kernel building instructions. Make sure to rename 'htc-msm' in that guide to 'htc-msm-2.6.25'. :) Update: Also make sure to create a proper .config with make htcraphael_defconfig ARCH=arm before compiling your kernel.   [[| http://www.netripper.com/raphael/raph_20081029-00_cleanups.exe|Here ]]'s a link to the .exe that boots this kernel for both Raphael and Diamond, and find the non-linload version here. When you use the latter one, modify the default.txt to change last line from 'ramboot' to 'bootlinux'.   Note that this version is just a cleanup and a bit of stability improvement - no new spectacular things.  2008-10-28 
  Just for some fun I modified the framebuffer logo. ;) It's a simple 80x80 224 color bitmap.   Diamond/Raphael branded Tux  2008-10-27 
  Linux boots all the way on Diamond/Raphael. We booted into a shell using an initrd cooked by NetRipper (with a busybox and some init scripts). I, druidu, wrote a touchscreen driver and an on-screen virtual keyboard using the touchscreen driver, and it all works very well. Check out the pics (courtesy of NetRipper). You can try the linload version on your [[| http://octav.oricum.ro/android/Diamond_Linux.exe|Diamond ]] or Raphael   Raphael touchscreen with virtual keyboard 1!   Raphael touchscreen with virtual keyboard 2!   Raphael touchscreen with virtual keyboard 3!  2008-10-23 
  How about this - we got even further in the boot process. Hardware-wise we're not much further, we just disabled some drivers to get to boot it further. However, we do now use the framebuffer code which is also available in the HTC Dream / G1. Here's a picture with famous Tux. :D   Tux on framebuffer!  2008-10-22 
  Pictures of the framebuffer in action! Lovely! You'll see it already has support for colors. Credits to druidu.   [[| http://www.netripper.com/raphael/pics/20081022_framebuffer1.jpg|1 ]] 2  2008-10-22 
  First let's sum up what's been done already, hoping winot to forget anything. HaRET was updated to include basic MSM7xxxA support. As base for kernel development  
0 件のコメント:
コメントを投稿