yashsingh1/xdaforums huggingface dataset:
[Galaxy S II Android Development] JaLoou:
IMHO, the main target must be at least some implementation Camera2 API that side camera apps become able to get raw media data provided by 10 bit Bayer (not 8 but 10 bit per every color component) algorithm from the smartphone camera.

If such target will be reached then it will be a great step beyond for our old smartphone.

I hope then specific camera apps (like A Better Camera app by Almalence with DRO mode enabled) will analize automatically 10 bit raw media by CPU producing more colourful sometimes stunning photos on our old Galaxy S2 include some improvements for dark conditions.
[Galaxy S II Android Development] rINanDO:
New build is up!

Build #3 2018-11-14

Overall state: Stable-ish

Android build: 9.0.0-r16

Updated sources

Fixed Camera rear & front, picture and video recording!

Wakeup via Home button (including offline charging)

Memory optimization (800mb available like we have in Oreo)

In previous build we had 700mb memory available because of HWC1.4.

It seems this was not neccessary for fimc/camera issues which are fixed now.

Known issues:

Graphical glitches and crashes

Sometimes slow responsive after wakeup

Download here: lineage-16.0-20181114-UNOFFICIAL-i9100.zip
[Galaxy S II Android Development] MaddogIT:
Downloading... I will try this evening :)
[Galaxy S II Android Development] Catfish78:
Hello,

after reading the cam is working, i have tried to - clean - flash the build of 11/14/2018, getting all time an error 7. Formatted partitions didnt change anything, redownloaded many times with different OS (LineageOS 15.1 on the running phone, Linux and Win 10). Used with TWRP 3.0.2 and the newest one. What could i try to get it on my i9100?

Regards
[Galaxy S II Android Development] linusdan:
I have this problem also in the builds of the projects I do, including the novelty I'm trying to bring is paused because of it. Looking for solutions.

For the flash, you will have to do the process manually.

1. Extract the ZIP file.

2. In com/google/android/updater-script, delete the line 'assert' until 'getprop' and save;

Compress the files again as zip (except the subfolder) of the extract and be happy :)

If you got a little confused, see these instructions:

Https://android-fix.com/android-errors/61-status-error-7-twrp.html
[Galaxy S II Android Development] ran000:
Have not any problems of such type here.
[Galaxy S II Android Development] rINanDO:
New build is up!

Not much done, only fixed SIM Pincode issue :)

Build #18 2019-10-06

Overall state: Stable

Android build: 9.0.0-r46

Required recovery: TWRP 3.3.1-1

- Updated sources

- Fixed SIM Pincode

Known issues:

- Call recording only records microphone

Please report if there are more issues.

Downloads

i9100-LOS-16.0-Emulated-Storage.pit

i9100-LOS-16.0-Emulated-Storage-TWRP-3.3.1-1.tar.md5

i9100-LOS-16.0-Emulated-Storage-TWRP-3.3.1-1.img

Download LineageOS 16.0 SU (arm) addon/removal here

lineage-16.0-20191006-UNOFFICIAL-i9100.zip

lineage-16.0-20191006-UNOFFICIAL-i9100_magisk_boot.img
[Galaxy S II Android Development] ol1ver:
First, I have to say, I was really impressed with the stability, it was up for 2 weeks maybe even more. With the reboot I decided it was a good idea to update to the latest version. Was using it for a few days of uptime, and the problems described are still here (not saving certain settings such as display timeout, PUK code thing) but all was good.

As I was watching a youtube video or something using firefox, suddenly, my phone rebooted. Ok, fine it crashed, it happens sometimes, but then I kept getting a bootloader logo screen loop. Booting into twrp shows the trwp logo, and after about 4 seconds it reboots again. I tried to see if it was the power button being pressed to long (measured resistance along the pads, cleaned it etc) but nothing.

Going into download mode works fine, it sits there just waiting for hours, no problem.

I have charged it full (The charge-app works fine), left the battery out for a few days, but same behavior. I haven't got the time to hook up a UART (need some level shifters and what not) so haven't looked at the real output.

If anybody has any thought what could be going on, and how to recover it, that'd be great. It almost looks like some watchdog timer that expires or something.

Anyhow, as I managed to fix my n7100, I moved my sim card over and lo and behold, after each boot, I also get the PUK code message.

Could it be, that after build #13 something changed the simcard? If the problem moves with the simcard, it can only be caused by the simcard, right? I am using android 9 from comico on the n7100, but I find it hard to imagine for it to be a custom ROM issue that both roms (albeit similar) share.

Just some food for thought, and cry for help.
[Galaxy S II Android Development] Catfish78:
Hello,

i had some builds ago an issue nearly like your one. I thought at first the flash memory of the phone was dead, and changed the board. Some months later i just reflashed the other board with a newly downloaded build - and it runs fine. Could it be that your downloaded twrp or LOS is corrupt? I found out that downloading with Linux seems to work better. Maybe under Win 10 the issue is gone with the new Edge Insider browser on Chromium base.

Regards
[Galaxy S II Android Development] abdulhkeem:
A big thanks to rINanDO for keeping this phone alive to this version of android and actually speedy the few last builds, and all who helped to solve the PIN issue!
[Galaxy S II Android Development] ze7zez:
Compare the checksum given on the server and calculated after downloading, and maybe your dilemmas will end.
[Galaxy S II Android Development] rINanDO:
Hi ol1ver,

There is nothing wrong with your SIMCard. My guess is that the Android framework has updated their SIM PIN behaviour after build #13. It tries to retrieve the remaining attempts by sending NULL to the RIL (normally it would send your entered PIN). It expects in return the remaining attempts (which should be 3). But our legacy RIL doesn't support this and returns an error. The frameworks retries this 2 times and eventually our Legacy RIL response with SIM locked, PUK required..... I fixed this in the libsecril-shim, capturing this RIL command and simulate the amount of attempts to match the updated behaviour.
[Galaxy S II Android Development] JaLoou:
Hello.

Thanks rINanDO for the implementation of the super bright screen mode. Hope the users of this custom ROM will be happy with it outdoor at sunny days.

But I steel do not use this custom ROM waiting when it will give yet more significant improvements over Samsung's official firmware with Android 4.1.2.

And I have some additional suggestions:

1) as I little know the call recording API was removed from newest versions of Android OS.

So, may it is possible to extract the call recording API from some old Android version (for example, from 4.1.2 due to it works fine there) and insert it to this custom ROM?

2) I was consulted in one of Samsung's retail stores about Samsung Galaxy S2 and a smartphone repair specialist there did answered me that since Samsung Galaxy S7 the Samsung's flagman devices are able to record videous by a file size more than 4GB and that for Galaxy S2 the ability to record videous by size more than 4GB depends on a firmware only but not on a hardware.

So, my question is: Samsung Galaxy S2 with this custom ROM is able to record long videous by a file size more 4GB (for example, 2 hours of FullHD video) on an external microSD card formatted in exFAT?

If it is not able yet then please remove the obsolete 4GB limitation in this custom ROM.

I had checked Samsung Galaxy S2 works fine with an external 256GB microSD card. So, there is not a reason for a file size limit on external microSD cards today.

Moreover, everyone can increase easy the quality of videorecordings on our old Galaxy S2 by removing the default bitrate limitation and setting the bitrate limit to 20Mb/s in the video settings in the menu of Open Camera app by Mark Harman. Recorded mp4 files will become bigger but the quality of details in they will be better too.

So, there is a good reason to remove 4GB file size limitation on Samsung Galaxy S2.

P.S.: a) The camera trick with the video bitrate is sufficient for using in good light conditions only because in dark environments it starts to use the high bitrate for record noises extensively.

b) The bitrate limit can be effectively set up to 80Mb/s, the recorded files will become giantic with almost lossless video quality but it will be trouble to play them on old Galaxy S2 and the users will need any other compatible device (a modern smartphone, a computer...) for watch they.
[Galaxy S II Android Development] trylogic:
Good afternoon. Please tell me where to get the microGAPPS to make PlayMarket work?
[Galaxy S II Android Development] ran000:
Find it here: https://opengapps.org/
[Galaxy S II Android Development] trylogic:
After installing these GAPPS, the system does not boot.
[Galaxy S II Android Development] guest4711:
Did you install the right version? Armv7, pico?
[Galaxy S II Android Development] ran000:
No problem here with latest build ( +magisk ) and open_gapps-arm-9.0-pico-20191006 from https://opengapps.org/
[Galaxy S II Android Development] trylogic:
I don't know... There is ARM & ARM64. ARM7 don't see.
[Galaxy S II Android Development] guest4711:
Yes, arm (without 64) is ok.
[Galaxy S II Android Development] trylogic:
How much time does it take you after installation to boot the system?

I'm to instal open_gapps-arm-9.0-pico-20191010.zip, but system don't boot. Whithout GAPPS everything is loading fine. I can’t understand what the problem is.
[Galaxy S II Android Development] ran000:
I could not tell exactly - 5-7 min, no more then 10 min. And, to be clear, latest time it was dirty flash.

I can only suggest to check md5sum for all downloads.
[Galaxy S II Android Development] trylogic:
Please tell me in what sequence do you install the firmware? What are the steps? Maybe I missed something.
[Galaxy S II Android Development] ran000:
I have followed the instruction, which rINanDO described for Build #14 ( https://xdaforums.com/galaxy-s2/development-derivatives/pie-i9100-t3850588/page56 ), with additional step for Magisk, which was described for Build #16 ( https://xdaforums.com/galaxy-s2/development-derivatives/pie-i9100-t3850588/page66 )
[Galaxy S II Android Development] Little Rooster:
I power off the phone.

Battery at 100%

After 5 days the battery is empty.

Why? What is draining the battery when it is powered off??

How do I power off the phone completey??

The hardware is ok. When I install Android 4.1.2 the battery keeps the power for many weeks.
[Galaxy S II Android Development] JaLoou:
Thanks for the very useful warning.

I have a suspicion that some custom ROM development can be supported hiddenly by big strong criminal regimes for spying to people and even for impacting them.

Currently I'm also remaining with Android 4.1.2 yet.
[Galaxy S II Android Development] K9100ii:
And that's what's been happening! People are discussing these bugs! While also potentially having bad batteries. Now you're overreacting again. Do this stuff in your "bugs" thread, not in a ROM thread where no one wants/needs your insults which actually break XDA rules. Don't reply here please, only reply if you have something but this type of stuff to say. Also, get a new phone for a "bugless" experience, and maybe trash the threads for that phone in a few years. Unless it's completely bootloader locked, which would be great for you.

[MENTION=2222292]rINanDO[/MENTION], I feel bad for you having to deal with this. Sorry. :(
[Galaxy S II Android Development] Little Rooster:
This is probably possible, but other reasons besides the rom, too.

I have Magisk and Riru Exposed installed. There can be the reason, too.

By the way, Google "find device" is installed on this rom by default, and it can't be turned off. It always re-enables itself. Maybe parts of it keep running also when the phone is powered off.

[MENTION=9549206]TALUAtXDA[/MENTION]

The battery is not the issue, because the battery keeps power for month.

I have tested without any phone, and I have tested with Android 4.1.2

No draining there.
[Galaxy S II Android Development] mirhl:
Find my device must be disabled from "device administrator".

And "quick" poweroff discharge could even be something with offline charging bugging off and keeping the cpu actually awake.

5 days is probably the battery life you would normally get with saving enabled and data turned off.

Criminal wizards is a pretty tinfoil-ish theory.
[Galaxy S II Android Development] MaRtYy01:
Im on 6 days standby with 2h 30mins sot and still have 49% left. I usually go down to 50% with 3h of sot so only 30 mins of sot have been drained for me in idle. However Im on airplane mode with microg,not full gapps. Who knows,maybe gapps drain the battery,maybe RIL,maybe a 3rd party app.

edit: I just noticed you said when phone is off...dead battery imo or its some sort of a mobo/kernel problem? Does the battery drain when its not connected to the phone?
[Galaxy S II Android Development] K9100ii:
This is what my experience is a lot like, except I get slightly less SOT. I also use MicroG but I have WiFi on while I'm using it and don't have airplane mode on. I also have Greenify and use LineageOS privacy guard to disallow apps from running on boot or in background (if this gets respected depends on the app). The point about it being a motherboard is important, there are reports of Galaxy S2's draining battery when they're off and they get hot, and if I recall correctly, it was a faulty capacitor (filter?) to do with charging. Removing it fixed the issue and didn't really affect anything else, if anything, while fixing the issue.
[Galaxy S II Android Development] lee.wp14:
20191010 seems causing bootloop, try 20191006 instead.

https://sourceforge.net/projects/op...open_gapps-arm-9.0-pico-20191006.zip/download

20191009 also seems to be causing bootloop, a redmi note 7 user complained in other forum.

Not sure what's going on with these.
[Galaxy S II Android Development] Little Rooster:
The battery and Mobo is not the issue, because the battery keeps power for month.

I have tested the battery without phone, and I have tested with Android 4.1.2

No draining there.

[MENTION=4900593]mirhl[/MENTION]

"Find my device must be disabled from "device administrator". "

I can not disable it there. It is greyed out and the button is set ON.

After reboot it always is set to ON by itself.

"And "quick" poweroff discharge could even be something with offline charging bugging off and keeping the cpu actually awake."

What can I do??

btw., the phone powers off in 2 seconds. But mostly it doesn't boot after powering off. First I have to remove the battery, mostly. Then it needs around 4 minutes to see the homescreen, and around 2 more minutes until boot is really completed.

So I am quiet sure the phone does not power off completely and something is draining the battery and maybe it's also the reason that the phone does not boot. (it keeps hanging at the battery logos. Changing between the original samsung battery logo and the lineage battery logo)
[Galaxy S II Android Development] MaRtYy01:
I don't have the same problem. Used a stopwatch,it takes mine ~3.5 seconds to power off then I can power it on almost instantly,it stays on the samsung galaxy s2 gt-i9100 with the yellow triangle bootlogo for around 17 seconds,then it loads the system for about 1min 30 secs and then stays on black screen for about 15 secs until the system ui and everything else loads. So about 2 mins in total. I think you can try repartitioning again,then reinstalling the rom clean with microg this time(gapps cause problems imo) and then report the results. If its still the same you either got a hardware problem,as we simply cant have the exact same phone doing the exact same things and get different results, or an old bootloader,if you didnt update to the latest stock rom before flashing. However I cant confirm how true is my statement about the bootloader,I know it works like this for some phones,not sure about S2 tho.
[Galaxy S II Android Development] Little Rooster:
1. press power until Samsung logo starts: 0:12 min

2. Samsung logo ends: 0:48 min (36 sec)

3. Black Screen until Linage Logo: 0:51 min (3 sec)

4. Linage system load logo until: 2:52 min (121 sec)

5. black screen until (Nova launcher) homescreen: 3:00 min (8 sec)

6. Time until weather and Calender widget is loaded: 4.55 min (115 sec) **

7. slow side swiping until 5.55 min (60 sec)

8. power off: 2-5 sec

The particular times can change, but all in all it always needs 6 minutes until the system works in a flow.

Sometimes it keeps hanging on the Settings site. must power off.

Magisk and Riru Xposed framework is installed !!!

** after Standby it always needs around 1 minute until the empty widgets are reloaded.

Crazy. On android 4.1.2 the widgets stay instant.

---------- Post added at 04:31 PM ---------- Previous post was at 04:27 PM ----------

ps:

Please disable location service and then disable "Find my device" admin rights and let me know if it "Find my device" admin rights keeps off afer reboot.
[Galaxy S II Android Development] K9100ii:
Thats extremely long in my honest opinion. By the way, "find my device" doesn't exist on installs without GAPPS.
[Galaxy S II Android Development] mirhl:
What Rooster says is true.

I can also trigger the phone "dying off" until battery is removed, when I quickly plug on and off the usb cable after shutdown (as I was saying offline charging gets corrupted).

Not sure about his details though. 4 minutes of boot could be a very worn off emmc?

As for find my device, other suggesttions could be trying to first disable it from the security/google settings (there is a specific option for that).

Or trying to boot in safe mode.
[Galaxy S II Android Development] Little Rooster:
Damn.

In which part of the Gapps is it included? Must delete it, but need Calendar, PlayStore and location Service.
[Galaxy S II Android Development] SethGeckoXDA:
Installed build #18 yesterday and downloaded the Signal messenger app. When trying to link a device in the app, I was not able to scan the QR code. Looks like it did not automatically focus. I was able to work around it by taking a screenshot of the QR code and zooming in on it on the computer.
[Galaxy S II Android Development] js-xda:
Installed above build today (no Magisk or GAPPS but usual wipe of cache/Dalvik). Thank you for your effort - PUK issue appears to be solved!

No clue where related to: Shortly after, the phone rebooted once but so far not reproducible or even possible to link to a certain action. Will monitor and share if observed again.

Wondering on another aspect and could not find clear info searching a bit (maybe using the wrong terms):

What is the link between the release (e. g. r46) and the security patch level? I thought each monthly update triggers a new release but now the release has not changed (also e. g. for my SM-G901F on LOS 16) since August while stating on both patch level of September. Is this something specific to LineageOS or AOSP or ...?
[Galaxy S II Android Development] DevisG79:
Does someone know how to update magisk to v20? Do I have to select and patch boot image in Magisk?
[Galaxy S II Android Development] gotzinger:
Boot loop.

I have boot loop with 1006 version with and without installing open_gapps-arm-9.0-pico-20191013.zip.
[Galaxy S II Android Development] hollaho:
Try Gaaps from 2019-10-06 or earlier, see also the post below:
[Galaxy S II Android Development] DevisG79:
What is the problem of formatting data in twrp? It doesn`t work. I wanted to make a clean flash. So I started again with Odin. Now it boots. To avoid confusion:

If then I want to update next time the rom: In twrp I flash rom and then magisk boot.img to boot partition. Is that enough or do I have to flash twrp.img again selecting recovery partition?

For clean flash I would wipe cache, dalvik/art cache, system and data and then flash rom+magisk and reboot. Is that correct?
[Galaxy S II Android Development] ol1ver:
Hi thanks for the thought, but as I don't have windows, I doubt this is the issue :) also it ran fine for a few days and them BOOM crash, reboot; fail.

Also, it took down a few partitions, which shouldn't be related? The bootloader and download mode still work (small binaries loaded from eMMC?) whereas twrp and android do not anymore. TWRP isn't 'that' big, but still big enough. OR it tries to scan/mount the /system partition that is corrupt and causes to crash as well?

Need a serial adapter first, and a bootable SD-card second. But one that doesn't "just randomly restores stuff", but one that actually boots and gives me a shell :)
[Galaxy S II Android Development] ol1ver:
Thanks for the indepth explanation; a link to the git commit would have made it perfect ;)

I guess [MENTION=7105282]ComicoX[/MENTION] needs to cherry-pick that patch to fix the same issue ...

---------- Post added at 08:26 AM ---------- Previous post was at 07:51 AM ----------

One thing I previously mentioned, is that certain settings do not persist over a reboot. Display sleep timeout for example. I set it to 2 minutes, and after reboot it is at its default of 15 seconds again. Now, it could be that my eMMC is dead and some things do not get saved properly; but other settings are persistent and kept, so that's unlikely.

A nother setting is the 'developer mode -> terminal' setting which adds the terminal to list of apps. After reboot, it needs to be re-enabled again.

Has anybody else noticed these volatile settings?
[Galaxy S II Android Development] mirhl:
This.

I already complained about it plenty of times in the years (even in this thread, see page 41). When the device attempts to mount a corrupted partition it crashes with fire.

I have even testcases but nobody seems to care.

EDIT: settings not saving may be you just need to run e2fsck
[Galaxy S II Android Development] m4v3r0ne:
Hey there, how would one implement this fix into a different ROM because we've got the very same issue on a ROM for the Galaxy S3 which is otherwise great but keeps killing SIM cards...?

Is there an easy way, say just edit a couple lines of text or even just copy a file over from your ROM?

Thanks for any advice.
[Galaxy S II Android Development] K9100ii:
Finding the commits is very easy.

https://github.com/rINanDO/android_hardware_samsung/commit/d728ee240b0bc29d90b5b1ace77f8f96b8091f82

https://github.com/rINanDO/android_...mmit/bead14adae2f9f67d9027f7fcb04aee628ea0554

They will likely need to be adapted.

Also, for corruption issues, it could be either a dead eMMC, the filesystem getting corrupted in which case a fsck is needed, the ancient F2FS driver doing its thing corrupting things unrecoverably or something else I'm missing. I used to run F2FS for my S2, but it corrupted itself. e2fsck errored out. I had a TWRP backup from earlier on my SD card, so I copied everything from /sdcard to the real SD card, formatted /data and /cache as ext4, selected "Use rm -rf instead of formatting" in settings, restored the backup, deselected the setting for formatting in Settings on TWRP, rebooted and copied eveything backed up from /sdcard on the real SD card to /sdcard when booted. If this is possible depends on if you have or have not got a backup. There is not much difference in usage with ext4 vs F2FS, only the glorious benchmark scores will be lower.
[Galaxy S II Android Development] gotzinger:
I have boot loop without Gapps too.

---------- Post added at 05:12 PM ---------- Previous post was at 05:10 PM ----------

What is lineage-16.0-20191006-UNOFFICIAL-i9100_magisk_boot.img? Is it root? How can I install it?
[Galaxy S II Android Development] gotzinger:
Boot loop.

I have installed lineage-16.0-20191006-UNOFFICIAL-i9100.zip with open_gapps-arm-9.0-pico-20191006.zip according to instructions on the first page. After first start I see only blue animated logo and nothing happens.
[Galaxy S II Android Development] SethGeckoXDA:
So, no bootloop anymore? If you see the animated logo, you should give it a few moments. First startup may take up to 10 - 15 minutes.