1. Check out our companion app, Forums for Android! Download from Google Play

Root [DEV] WIP CM9 (Camera) [updated 2/23/2013]

Discussion in 'Android Devices' started by g60madman, Oct 15, 2012.

  1. BSydz

    BSydz Well-Known Member

    Mar 31, 2012
    The Mitten
    Ok, so I have successfully integrated a camera wrapper in to the code and have made some real progress. I need to make some more changes to the kernel, I believe, but I am definitely making progress. Here is the logcat:

    Code (Text):
    1. D/OpenGLRenderer(  378): Flushing caches (mode 1)
    2. V/CameraHolder( 9566): open camera 0
    3. D/QcomCamera( 9590): HAL_get_camera_info: loading libcamera at 0x7000e9c0
    4. I/QualcommCameraHardware( 9590): HAL_getCameraInfo: cameraId=0,orientation=90
    5. I/CameraService( 9590): Opening camera 0
    6. D/QcomCamera( 9590): loading libcamera at 0x7000e9c0
    7. I/QualcommCameraHardware( 9590): openCameraHardware: call createInstance cameraId=0
    8. I/QualcommCameraHardware( 9590): createInstance: E
    9. I/QualcommCameraHardware( 9590): QualcommCameraHardware constructor E
    10. V/QualcommCameraHardware( 9590):  Storing the current target type as 3
    11. V/QualcommCameraHardware( 9590): constructor EX
    12. I/QualcommCameraHardware( 9590): createInstance: created hardware=0x18900
    13. I/QualcommCameraHardware( 9590): startCamera E
    14. V/QualcommCameraHardware( 9590): Camera device FD: 16
    15. D/OpenGLRenderer(  378): Flushing caches (mode 0)
    16. V/QualcommCameraHardware( 9590): loading liboemcamera at 0x7000ebf0
    17. I/QualcommCameraHardware( 9590): startCamera: camsensor name mt9p111, flash 1,orientation 0
    18. I/QualcommCameraHardware( 9590): startCamera X
    19. I/QualcommCameraHardware( 9590): initDefaultParameters E
    20. V/QualcommCameraHardware( 9590): native_set_parm: fd 16, type 1, length 88
    21. E/mt9p111 ( 9590): Inside mt9p111_process_start
    22. F/libc    ( 9590): Fatal signal 8 (SIGFPE) at 0x00002576 (code=0)
    23. E/mt9p111 ( 9590): [user] mt9p111_video_config, sfd = 15
    24. F/libc    ( 9590): Fatal signal 11 (SIGSEGV) at 0x00000168 (code=1)
    25. W/Camera  ( 9566): Camera server died!
    26. E/CameraHolder( 9566): fail to connect Camera
    27. E/CameraHolder( 9566): java.lang.RuntimeException: Fail to connect to camera service
    28. E/CameraHolder( 9566):     at android.hardware.Camera.native_setup(Native Method)
    29. E/CameraHolder( 9566):     at android.hardware.Camera.<init>(Camera.java:320)
    30. E/CameraHolder( 9566):     at android.hardware.Camera.open(Camera.java:280)
    31. E/CameraHolder( 9566):     at com.android.camera.CameraHolder.open(CameraHolder.java:131)
    32. E/CameraHolder( 9566):     at com.android.camera.Util.openCamera(Util.java:321)
    33. E/CameraHolder( 9566):     at com.android.camera.Camera$4.run(Camera.java:1251)
    34. E/CameraHolder( 9566):     at java.lang.Thread.run(Thread.java:856)
    35. I/DEBUG   (10084): debuggerd: Oct 18 2012 20:09:00
    36. V/camera  ( 9566): surfaceChanged. w=480. h=640
    37. I/CameraService(10087): CameraService started (pid=10087)
    38. D/QcomCamera(10087): HAL_get_number_of_cameras: loading libcamera at 0x7000e9c0
    39. V/QualcommCameraHardware(10087): HAL_getNumberOfCameras:
    40. D/QcomCamera(10087): HAL_get_number_of_cameras: numCameras:2
    41. D/OpenGLRenderer( 9566): Flushing caches (mode 0)


    SumGuy and Poweredge99 like this.
  2. g60madman

    g60madman Guest
    Thread Starter

    I got about 5 1/2 hours last night from 9:00pm-2:30am. I am a little tired but still going!

    What code are you using for camerahal? Do you have a link? These look the same errors I am getting with the MTDEV-CM9. Also are you building from g60 github or mtdev-cm9 github? Sorry for all the questions, I just haven't tested camerahal yet. I am focusing on all the hardware to make sure it's all in working order before I mess with the camera.
    nwaves likes this.
  3. BSydz

    BSydz Well-Known Member

    Mar 31, 2012
    The Mitten
    I found this and had to make a lot of modifications to the code and boardconfig.mk to get it to build. https://github.com/Dorregaray. I was searching for the thread that had all the logs about the camera, so I'm not sure if they are the same errors or not, I couldn't remember if it got that far in to the process before the camera server died. I am building from I think the last mantera cm9 code. I haven't pulled a new CM9 in a while, so I was just using what was on my HD. I know alot has changed, I just figured that if the camera works it will work across the board.

    EDIT: I also integrated the the kernel to build with the ROM, and it seems to make the kernel a lil bigger.
  4. g60madman

    g60madman Guest
    Thread Starter

    You maybe spinning your wheels. This is the whole reason I started from the beginning as there is a lot of code I am not 100% we need. Right now there is only (4) repos we really need to make the phone work besides the camera of course, and possible tethering as I have not tested it yet.

    android_frameworks_base - RIL/3G, MMS, Headset
    android_hardware_qcom_gps - GPS
    android_hardware_libhardware_legacy - Wi-Fi
    android_hardware_msm7k - GPS

    If you take mantera's device files and try to build them with vanilla (unedited code) CM9 code the phone will not boot. After I reconfigured our device files they will build properly with the vanilla code and the phone does boot. So my suggestion would be to grab my code and try the camera fixes on it.

    $ repo init -u git://github.com/g60madman/android.git -b ics

    $ repo sync

    Just want to save you the pain I have felt for the last few months as I have tried over 100 builds with no movement at all on the camera, accept the nice little error you are getting in the logcat.
    BSydz likes this.
  5. djboi2011

    djboi2011 Well-Known Member

    Sep 14, 2011
    college student -_-
    You guys are putting in major work!...I'm trying to sell my triumph so i can replace the screen on my GNex, wouldn't really matter if it doesn't happen cuz u guys are bringing a (almost) fully functional cm9!
    g60madman likes this.
  6. Brinko

    Brinko New Member

    Jun 25, 2012
    Has anyone built his yet? I'm interested in testing it out (I get bored too easy and need to tinker) but I don't have the resources to build it myself (32-bit ubuntu running on a laptop).
  7. g60madman

    g60madman Guest
    Thread Starter

    Once I get Wi-Fi nailed down and MMS I will be posting a beta test ROM so everyone can test it out. Right now with the issues I am having it's not worth using yet as a daily, but it's close I should have more this weekend.
  8. Brinko

    Brinko New Member

    Jun 25, 2012
    Thanks for the heads up! MTDEV-CM9 has been my daily for a while and I have no complaints, but this new project definitely has me excited.
  9. havikx

    havikx Well-Known Member

    Mar 26, 2011
    Dorregaray is the dev who just got cam working on HP touch pad. Good work on his part considering its a web os device turned android. Lots of people thought that would be impossible to fix for lack of code/support. No drivers.

    I thought someone would look at his work and see if any part of the code helps MT.
  10. norosesnoskies


    Oct 16, 2012
    Long Island, NY
    would there be another beta build coming very soon?
  11. SumGuy

    SumGuy Active Member

    Apr 7, 2012
    Hey man, not to sound rude at all, but I feel it is Unwritten Rule Numero Uno to never ask for ETAs. It's like asking:

    "Are we there yet?"

    "No we're not, and I don't know when we'll be but we'll get there when we get there."

    So just sit back and watch Gangam Style three or four more times. I know I perviously stated that I no longer use the phone but it has become my mini-tablet and Netflix device, but these guys have lives, wives, families, jobs, sh*t to do, and personal times (...that sounded wrong didn't it?). Once again I'm not trying to sound rude, I apologize if I am.
  12. activeservo

    activeservo Well-Known Member

    Oct 6, 2011
    Southern California
    Hi g60, You are making great progress and I cant wait for the working release!! I was just wondering when you test the gps do you leave it off to conserve battery and turn it on right before you use it or do you always leave gps on so it can lock quicker?
  13. g60madman

    g60madman Guest
    Thread Starter

    By default it's always one in the top menu. Once it locks which takes about 30 seconds it seems to still have to find a lock again once you use it again. Even though it's on its not using battery until you trigger a service to use it. I want to spend more time on GPS to see if there is any more we can do to make it work better. Clearly the Sharp Froyo ROM has proven it's possible. I just don't know if it's more kernel or more CM code that is allowing for it.
    Inc0gnit0 and calitrippin like this.
  14. g60madman

    g60madman Guest
    Thread Starter


    I have released a test ROM if everyone could please test everything on it GPS, Wi-fi, SMS, MMS (Still not working for me), games, you name it. This will help to make sure I am making progress on this ROM. Please post back your findings.

    3G: (1-10 scale 10 being perfect)
    GPS Locks: (1-10 scale 10 being perfect)
    Wifi: (1-10 scale 10 being perfect)
    MMS: (1-10 scale 10 being perfect)
    SMS: (1-10 scale 10 being perfect)
    Speed: (1-10 scale 10 being perfect)
    Battery Life: (1-10 scale 10 being perfect)
    Tethering WiFi/USB: (1-10 scale 10 being perfect)
    Video Performance: (1-10 scale 10 being perfect)
    Your personal thoughts of the ROM:
    Inc0gnit0, Davegrow and calitrippin like this.
  15. rdoac

    rdoac Well-Known Member

    Oct 12, 2012
    Rockford, IL
    Just had a quick try with this as I was about to reflash my phone to cm7 -1015 version anyway. However, when it wanted to sign me into the google stuff, I had a little win7 style waiting circle a little bit to the left of where my finger wanted to go, I had to put my finger on it and drag it to where I wanted to click to click something. It made signing in to Google etc too hard. Am I missing something? Do I need to calibrate the touchpad or is this just something to do with being a really dev version?

    Went to cm9 from 10-13 in slight frustration. Am quite happy to blame myself or the phone instead of the G60 on this..
    dsmryder likes this.
  16. g60madman

    g60madman Guest
    Thread Starter

    Nope it looks like my last build something went wrong :(

    Edit: It's going to take some time but I will get it fixed. Must have had a bad repo sync.

    Edit: ROM is now posted and working. Sorry about that guys. Please let the testing begin.
    rdoac likes this.
  17. g60madman

    g60madman Guest
    Thread Starter

    bump :)
    bob-st, Inc0gnit0 and Poweredge99 like this.
  18. Dimensions

    Dimensions Member

    Aug 22, 2012
    New York
    BUMP. Glad to see this happening; I hope the camera comes to a resolution. I've been quite busy lately; Ubuntu 10 doesn't work on my rig (Graphics Driver Problems). 12 does, I still need to reinstall it. I'm booked up with classes, internships, etc. Learning C this year although it's once a week. If you need my help, questions, or requests, feel free to message me. I'm keeping a close eye on this thread. ;)
  19. JTAKER

    JTAKER Well-Known Member

    Apr 8, 2012
    Anyone know how I could free up some more space for Google Now? Currently at 25 MB of free space. Need at least 30.
  20. Brinko

    Brinko New Member

    Jun 25, 2012
    Wow I'm loving Apollo. Thanks for adding that, I've never used it before. I haven't ran into any problems yet!
  21. bob-st

    bob-st Well-Known Member

    Dec 30, 2010
    Got it installed. This is my first time using cm9.

    So far everything that is supposed to work works.

    MMS works but seems sluggish. Not sure if it is the rom or VM.

    The only bug that I've noticed is that the 3g arrows and the signal power bars icons overlap a little.

    Will give more feedback later.
  22. ajones23

    ajones23 Well-Known Member

    Feb 18, 2012
    Auto Accessories
    Thanks G60 for this new rom,im going to try it out later.Thanks for all youre hard work,my MT runs alot smoother on MTDEV CM7 AND CM9. Thanks.;)
  23. g60madman

    g60madman Guest
    Thread Starter

    Delete /system/media/video files that should free up 10mb I still need to clear more out of the ROM only been focused on getting everything working.
  24. andr2d2

    andr2d2 Well-Known Member

    Jul 8, 2012
    Would love to colaborate with someone to make a custom splash image for this Rom. Lets try to come up with something!!. I think MTDEV's efforts to put this thing together deserves something special!! I personally like the one Cornfed Chris made a whilr back but we could improve it somewhat. We could add something like like" brought to you by Team MTDEV or just MTDEV. We could also include somehow the screen names of the devs. Just an idea
  25. g60madman

    g60madman Guest
    Thread Starter

    Yeah seems to be solid I have had no issues at all with it. It actually has grown on me quite a bit.

Share This Page