[FIX][STOCK][4.0.4][14/07]Working Camera + Video on 4.0.4 with non-stock kernels

Status
Not open for further replies.
Search This thread

Tungstwenty

Senior Member
Nov 1, 2011
1,830
4,512
Obsolete

This workaround was only relevant some time ago while custom kernels did not yet have updated sources from Samsung to work on 4.0.4 ROMs. This is no longer the case so this info is completely irrelevant now.


There are plenty of people complaining about camera and video playback problems when using custom kernels on the newest 4.0.4 builds such as XXLQ5 or XWLPM .
I tried a few things and managed to find a fix for it.


Installation
Just take the CWM zip file and apply it on your ROM. It will leave a backup of the 2 files that will be replaced.

Removal
The Restore zip can be "installed" to remove the patched files and put back the original ones that were kept on your device.


Tested and working both for Camera preview and Video playback, on XWLPM.


Note: This is a temporary fix until the kernel devs have enough information to properly update their code, and when that happens this fix can be uninstalled.
 

Attachments

  • I9100-404-CameraFix-CustomKernels.zip
    202.9 KB · Views: 8,128
  • I9100-404-CameraFix-CustomKernels_Restore.zip
    149.3 KB · Views: 3,610
Last edited:

The Undertakerr

Senior Member
Apr 23, 2011
319
175
Heyy Tungstwenty, another great fix by you!

Well done, it works great! Now also videoplayback works fine with siya on 4.0.4!

Now the only thing left not working on 4.0.4 with Siya is the bluetooth...

Thanks again!
 
  • Like
Reactions: cdaarif

danieldmm

Senior Member
Dec 18, 2008
5,191
12,054
France
Hi @Tungstwenty
Time to go OUT of stock Kernel XWLPM and move to Siyha Kernel, thanks a lot my friend...
Cheers
 
Last edited:

The Undertakerr

Senior Member
Apr 23, 2011
319
175
Thanks again for the fix.

But I found a mayor problem with custom 4.0.3 kernels on 4.0.4 firmware.

This bug is, to my opinion, so big, it's not worth anymore to use a custom 4.0.3kernel on 4.0.4...

I tested this with all Siya kernels 3.3.2 and above.

Try this to reproduce this bug:

1)Put on your wifi
2) Reboot your device with wifi on.
3) Go to: settings-display-brighteness/ Try to change a value, and see if it sticks.
It doesn't. For example: I had it on autobrightness. Can't get it off autobrighteness anymore, with wifi turned on.

But it is not only brighteness settings. Other settings cannot be made also with wifi on. For example put lockscreentext on your lockscreen. You can't; it doesn't show on the lockscreen. And probably many other settings have the same problem..

When I turn off wifi, and reboot, all off a sudden I can make the changes, and they stick.

Then i flashed CFroot 4.0.4 kernel. Now I can make changes with wifi on...

Can anybody try and see if they can reproduce this issue?

Thanks in advance...

EDIT: SOLVED by doing a wipe.

It must have been some old data from the nandroid data backup I restored.

Normally I don't post stuff like this if I'm not completely sure.

But the strange part of this story remains that I did had the above issues with one kernel and not with the other.
So I guessed it was kernel related.
This turned out to be a false conclusion.
 
Last edited:
  • Like
Reactions: cdaarif

Prophet16

Senior Member
Feb 23, 2012
164
18
Fremont, CA
Thanks again for the fix.

But I found a mayor problem with custom 4.0.3 kernels on 4.0.4 firmware.

This bug is, to my opinion, so big, it's not worth anymore to use a custom 4.0.3kernel on 4.0.4...

I tested this with all Siya kernels 3.3.2 and above.

Try this to reproduce this bug:

1)Put on your wifi
2) Reboot your device with wifi on.
3) Go to: settings-display-brighteness/ Try to change a value, and see if it sticks.
It doesn't. For example: I had it on autobrightness. Can't get it off autobrighteness anymore, with wifi turned on.

But it is not only brighteness settings. Other settings cannot be made also with wifi on. For example put lockscreentext on your lockscreen. You can't; it doesn't show on the lockscreen. And probably many other settings have the same problem..

When I turn off wifi, and reboot, all off a sudden I can make the changes, and they stick.

Then i flashed CFroot 4.0.4 kernel. Now I can make changes with wifi on...

Can anybody try and see if they can reproduce this issue?

Thanks in advance...
I actually had that happen to me when i was on Neat Rom. Don't know what caused it but I ended up switching roms.
 

Tungstwenty

Senior Member
Nov 1, 2011
1,830
4,512
Thanks again for the fix.

But I found a mayor problem with custom 4.0.3 kernels on 4.0.4 firmware.

This bug is, to my opinion, so big, it's not worth anymore to use a custom 4.0.3kernel on 4.0.4...

I tested this with all Siya kernels 3.3.2 and above.

Try this to reproduce this bug:

1)Put on your wifi
2) Reboot your device with wifi on.
3) Go to: settings-display-brighteness/ Try to change a value, and see if it sticks.
It doesn't. For example: I had it on autobrightness. Can't get it off autobrighteness anymore, with wifi turned on.

But it is not only brighteness settings. Other settings cannot be made also with wifi on. For example put lockscreentext on your lockscreen. You can't; it doesn't show on the lockscreen. And probably many other settings have the same problem..

When I turn off wifi, and reboot, all off a sudden I can make the changes, and they stick.

Then i flashed CFroot 4.0.4 kernel. Now I can make changes with wifi on...

Can anybody try and see if they can reproduce this issue?

Thanks in advance...

EDIT: SOLVED by doing a wipe.

It must have been some old data from the nandroid data backup I restored.

Normally I don't post stuff like this if I'm not completely sure.

But the strange part of this story remains that I did had the above issues with one kernel and not with the other.
So I guessed it was kernel related.
This turned out to be a false conclusion.
Just did the test now and when I was about to post the results I saw your edit :)

I'm using 3.3.3d XWLPG and installed a minimal deodexed XWLPM as a secondary ROM to work on this fix.
I did the steps you mentioned (for brightness level and for lockscreen owner info) and didn't manage to find any problems, so I'm glad it now works for you as well.

BTW, was it a full wipe or wipe cache/dalvik?
 

The Undertakerr

Senior Member
Apr 23, 2011
319
175
Just did the test now and when I was about to post the results I saw your edit :)

I'm using 3.3.3d XWLPG and installed a minimal deodexed XWLPM as a secondary ROM to work on this fix.
I did the steps you mentioned (for brightness level and for lockscreen owner info) and didn't manage to find any problems, so I'm glad it now works for you as well.

BTW, was it a full wipe or wipe cache/dalvik?

I'm getting offtopic here, because it has nothing to do with your camera fix:)

But I'm still investigating the matter now as we speak.

When on Siya, only a full wipe solves the problem I have above.

Because I'm curious(And lazy), I restored my Nandroid Data backup again(XWLPG nandroid with Siya 3.3.2) I only restore data.
Then I have the above problem again.

Now the strange part: Also Dorimanxx Kernel solves my problem.

So this thing I have, seems to be contained to SIYA kernel.
When I flash back to Siya, I have the problem again.(All new Siya versions tested)
Flashing then to any other Kernel, problem solved again.

But Siya can't be the problem also, because when I fully wipe also Siya will work.

I'm going further back to an older Siya to try if it makes any difference, but I think this will become one of the "android secrets" I will never find the cause of...

Sorry for the offtopic.
 

Tungstwenty

Senior Member
Nov 1, 2011
1,830
4,512
I'm getting offtopic here, because it has nothing to do with your camera fix:)

But I'm still investigating the matter now as we speak.

When on Siya, only a full wipe solves the problem I have above.

Because I'm curious(And lazy), I restored my Nandroid Data backup again(XWLPG nandroid with Siya 3.3.2) I only restore data.
Then I have the above problem again.

Now the strange part: Also Dorimanxx Kernel solves my problem.

So this thing I have, seems to be contained to SIYA kernel.
When I flash back to Siya, I have the problem again.(All new Siya versions tested)
Flashing then to any other Kernel, problem solved again.

But Siya can't be the problem also, because when I fully wipe also Siya will work.

I'm going further back to an older Siya to try if it makes any difference, but I think this will become one of the "android secrets" I will never find the cause of...

Sorry for the offtopic.
I don't think it's offtopic :)

This is indeed very strange, but here's a possible explanation:
The custom kernels (Siyah, Dorimanxx, ...) each have their own tweaks; they're not exactly the same. While they might share lots of common changes and improvements, they do have different things hence the word "custom".
There's a possibility that the sequence of events to make the camera work is contained not only on the binaries (the ones in the zip file I posted), but also on some cached data that was already picked up when you first ran the camera app, which invoked a service, which in turn invoked a library, etc. Later, when reopening the camera, now with the "fixed" binaries, there might still be bad data that a particular kernel is not expecting. Even if you came from Siyah when initially running the camera app, the original libraries might have cached strange data that the kernel will no longer recognize even after the binaries are now in line with the kernel. And another kernel might have code that is lenient enough to still work with it.

I have been fiddling with the bluetooth part to try to make it work, and this was exactly one of my steps. Whenever attempting code changes, I wiped all the data to make sure the device is starting fresh and if it doesn't work, it isn't due to bad starting data but only the code.
Unfortunately, none of the several things I tried worked and I don't think it's very likely I'll find a solution for bluetooth.
 

Krendelrus

Senior Member
Nov 17, 2010
716
473
I have been fiddling with the bluetooth part to try to make it work, and this was exactly one of my steps. Whenever attempting code changes, I wiped all the data to make sure the device is starting fresh and if it doesn't work, it isn't due to bad starting data but only the code.
Unfortunately, none of the several things I tried worked and I don't think it's very likely I'll find a solution for bluetooth.

thanks a lot for the camera fix :) now I can use official 4.0.4 more often with my favourite kernel - Siyah
 

Tungstwenty

Senior Member
Nov 1, 2011
1,830
4,512
I have been fiddling with the bluetooth part to try to make it work, and this was exactly one of my steps. Whenever attempting code changes, I wiped all the data to make sure the device is starting fresh and if it doesn't work, it isn't due to bad starting data but only the code.
Unfortunately, none of the several things I tried worked and I don't think it's very likely I'll find a solution for bluetooth.

Man Bluetooth don't work my LQ5 with siyah 3.3.3d kernel. Plz work n fix this.

This is just a fix for Camera + Video. I know bluetooth is also not working but as I posted before, I tried to fix it as well but don't think it's doable without changing the kernels. Kernel devs will have to find a way to fix it.
 

The Undertakerr

Senior Member
Apr 23, 2011
319
175
In the Galaxy Note forums it appears that hardcore has fixed the bluetooth in 4.0.4 sammy roms
It seems to be a kernel issue like Tungstwenty said earlier



maybe his fix will work for S2 4.0.4 roms too

link to his site/news article
link to the newest hardcore note kernel source code

Thanks for the above info!

Best to repeat this message in the Siya thread, and/or send Gokhanmoral this info by PM. He might be able to use Hardcore's sources to fix bluetooth in Siya kernel...


Edit: I see you allready did that. Thanks again! Maybe soon we can have working bluetooth with a custom kernel, that would be great!
 
Last edited:
  • Like
Reactions: Krendelrus
Status
Not open for further replies.

Top Liked Posts

  • There are no posts matching your filters.
  • 61
    Obsolete

    This workaround was only relevant some time ago while custom kernels did not yet have updated sources from Samsung to work on 4.0.4 ROMs. This is no longer the case so this info is completely irrelevant now.


    There are plenty of people complaining about camera and video playback problems when using custom kernels on the newest 4.0.4 builds such as XXLQ5 or XWLPM .
    I tried a few things and managed to find a fix for it.


    Installation
    Just take the CWM zip file and apply it on your ROM. It will leave a backup of the 2 files that will be replaced.

    Removal
    The Restore zip can be "installed" to remove the patched files and put back the original ones that were kept on your device.


    Tested and working both for Camera preview and Video playback, on XWLPM.


    Note: This is a temporary fix until the kernel devs have enough information to properly update their code, and when that happens this fix can be uninstalled.
    4
    Thanks! :)

    Yesterday I decided to have a new look at what Krendelrus shared.
    Even though hardcore's patch doesn't contain a direct fix for BT, I did dig into the N7000 sources from Samsung that he's using.
    Since the BT chip is the same I decided to try replacing our driver with N7000's and it turns out they were more recent I guess and include the stuff that I9100 4.0.4 ROMs were expecting from the kernel.
    4
    I'm getting offtopic here, because it has nothing to do with your camera fix:)

    But I'm still investigating the matter now as we speak.

    When on Siya, only a full wipe solves the problem I have above.

    Because I'm curious(And lazy), I restored my Nandroid Data backup again(XWLPG nandroid with Siya 3.3.2) I only restore data.
    Then I have the above problem again.

    Now the strange part: Also Dorimanxx Kernel solves my problem.

    So this thing I have, seems to be contained to SIYA kernel.
    When I flash back to Siya, I have the problem again.(All new Siya versions tested)
    Flashing then to any other Kernel, problem solved again.

    But Siya can't be the problem also, because when I fully wipe also Siya will work.

    I'm going further back to an older Siya to try if it makes any difference, but I think this will become one of the "android secrets" I will never find the cause of...

    Sorry for the offtopic.
    I don't think it's offtopic :)

    This is indeed very strange, but here's a possible explanation:
    The custom kernels (Siyah, Dorimanxx, ...) each have their own tweaks; they're not exactly the same. While they might share lots of common changes and improvements, they do have different things hence the word "custom".
    There's a possibility that the sequence of events to make the camera work is contained not only on the binaries (the ones in the zip file I posted), but also on some cached data that was already picked up when you first ran the camera app, which invoked a service, which in turn invoked a library, etc. Later, when reopening the camera, now with the "fixed" binaries, there might still be bad data that a particular kernel is not expecting. Even if you came from Siyah when initially running the camera app, the original libraries might have cached strange data that the kernel will no longer recognize even after the binaries are now in line with the kernel. And another kernel might have code that is lenient enough to still work with it.

    I have been fiddling with the bluetooth part to try to make it work, and this was exactly one of my steps. Whenever attempting code changes, I wiped all the data to make sure the device is starting fresh and if it doesn't work, it isn't due to bad starting data but only the code.
    Unfortunately, none of the several things I tried worked and I don't think it's very likely I'll find a solution for bluetooth.
    2
    Are all kernels based on update 6 fully compatible (no camera/bt problems etc) with 4.04 stock roms? I know NEAK is but which others?
    Update 6 sources show camera/video + bluetooth problems on 4.0.4 stock roms. Custom kernels based on them will therefore have those issues.

    The camera/video fix in this thread solves that part for any custom kernel.
    As for bluetooth, I fixed that on Siyah kernel itself (version 3.4.1) - a driver needed to be replaced. I'm not sure if other custom kernels have also included that change. If so, bluetooth should work on those as well in addition to Siyah.
    2
    Thanks for the above info!

    Best to repeat this message in the Siya thread, and/or send Gokhanmoral this info by PM. He might be able to use Hardcore's sources to fix bluetooth in Siya kernel...


    Edit: I see you allready did that. Thanks again! Maybe soon we can have working bluetooth with a custom kernel, that would be great!
    I just replied in the Siyah thread. I looked at the sources (patch / diff, really) and there's nothing there related with bluetooth changes, unfortunately.