[Streak 5 Android Development] hunderteins:
a little status update

There are basically two ways to implement camera on ICS. With a native camera.qsd8k.so as proposed of zivan56 or a basic wrapper around the gingerbread libcamera.so/liboemcamera.so as proposed of zbwu86 or rapmv78.

zivan65s-way is nice, cause I don't get force closing, but problem is that you need to reverse engineer every function from your gingerbread libraries and implement them new. Even when I get it to take a photo, I have to go the same way again for preview, focus, zoom, etc. The others achive very fast the full functionallity of gingerbread in ics.

So I got zbwu86 and rapmv78 wrappers to load even with our special libcamera (patching Overlay.patch into libui.so) and CameraService is starting.

I/CameraService( 98): CameraService started (pid=98)
E/QualcommCameraHardware( 98): camera_get_number_of_cameras
D/PrintK ( 98): <6>[pcm_out.c:pcm_open] open
D/PrintK ( 98): <6>[q6audio.c:q6audio_init] codecs

Problem here is, when I call the most basic function HAL_openCamera() I get SIGFPE (floating point exception) in libc for that I have no clue.

D/QualcommCameraHardware( 582): openDualCamera: E
D/QualcommCameraHardware( 582): openDualCamera: ov5642 is found
D/PrintK ( 582): <6>msm_camera: sensor_store: sensor ov5642 found
D/QualcommCameraHardware( 582): openDualCamera: X, 1
D/QualcommCameraHardware( 582): createInstance: E
E/QualcommCameraHardware( 582): Sensor name ov5642 is found
D/PrintK ( 582): <6>msm_camera: msm_camio_enable: turn on camera power
D/PrintK ( 582): <6>vreg_enable: wlan enabled
D/PrintK ( 582): <6>vreg_enable: gp5 enabled
D/PrintK ( 582): <6>vreg_enable: msme2 enabled
D/PrintK ( 582): <6>vreg_enable: gp3 enabled
D/PrintK ( 582): <6>msm_camera: ov5642_reg_init(403): 70 ms
D/PrintK ( 582): <6>msm_camera: ov5642_reg_init(424): 130 ms
D/PrintK ( 582): <6>msm_camera: __msm_open: sensor ov7690 power down
D/PrintK ( 582): <6>msm_camera: ov5642_sensor_init: 1D sensor
W/PrintK ( 582): msm_get_sensor_info: sensor_name ov5642
D/QualcommCameraHardware( 582): initDefaultParameters E
D/PrintK ( 582): <6>msm_enqueue: queue event new max is 1
E/mm-camera( 582): cam_conf: sensor name:ov5642 and length:6
E/mm-camera( 582): cam_conf: open sensor name ov5642
W/PrintK ( 582): msm_get_sensor_info: sensor_name ov5642
F/libc ( 582): Fatal signal 8 (SIGFPE) at 0x00000246 (code=0)
D/PrintK ( 582): <6>msm_enqueue: queue control new max is 1
D/QualcommCameraHardware( 582): findSensorType: sensorType is 5mp
D/QualcommCameraHardware( 582): filterPictureSizes: supportedPictureSizesCount=6
D/QualcommCameraHardware( 582): ctrlCmd.value = 30
D/QualcommCameraHardware( 582): Maximum zoom value is 30
D/QualcommCameraHardware( 582): initDefaultParameters X
D/QualcommCameraHardware( 582): createInstance: X created hardware=0xe1c0
D/QualcommCameraHardware( 582): ~QualcommCameraHardware E
D/QualcommCameraHardware( 582): ~QualcommCameraHardware X
E/PrintK ( 582): <3>msm_get_stats: error -512
D/PrintK ( 582): <6>msm_camera: ov5642_release()
D/PrintK ( 582): <6>msm_camera: msm_camio_disable: turn off camera power
D/PrintK ( 582): <6>vreg_disable: gp3 disabled
D/PrintK ( 582): <6>vreg_disable: msme2 disabled
D/PrintK ( 582): <6>vreg_disable: gp5 disabled
D/PrintK ( 582): <6>vreg_disable: wlan disabled

It has nothing to do with how I call the libcamera.so, cause I get a nice "2" when I call HAL_getNumberOfCameras(); So the calling paradigm works. Maybe I need to call something before HAL_openCamera() on the Streak, the others (HD2, Ace etc) don't need. Is someone stumbled over something like this when working in framework?

I'll also check the sources for differences in gingerbread dsc and ics dsc-kernel. [MENTION=1695125]_n0p_[/MENTION] any idea?

I attached sources for hello_camera, a minimal test program that calls HAL_openCamera() so I don't have to touch the device on every test.

have fun,

hunderteins.