yashsingh1/xdaforums huggingface dataset:
[Nexus 7 (2013) Android Development] ipdev:
Hi all. 🙂

I updated my main flo tonight. 🙃

I was able to clean(ish)/dirty(ish) update from Lineage 19.1 to 20 on my main flo. 😁

I have a second flo for testing and mostly clean flash it.

I normally clean flash my deb while testing builds. 😉​

I patched the 20230322 boot image with Magisk.

- Pulled the magisk patched boot image to my computer.

- Rebooted into recovery (TWRP).

- TWRP -> Advanced, Wipe (system and caches).

This way no addon.d (backup) scripts would run.​

- Rebooted to recovery and installed the L20 build and LiteGapps (core).

- Rebooted to bootloader and booted the Magisk patched L20 boot image.

- Then used the direct install method to make Magisk permanent.

Hope it helps others to update from L19.1 to L20.

Cheers all. :cowboy:
[Nexus 7 (2013) Android Development] AlesUlrych:
Hi,

today I did a new clean install (factory reset),

then install ROM + GAAPS + Magisk.

Factory reset I did due to corrupted google service that failed to connect to the internet. Probably a bug from the testing days. :)

Everything went as it should. After the install I reinstalled Magisk, activated Zygysk, reinstalled the Universal SafetyNet Fix 2.4.0 Mod extension + rebooted

Just a small warning for those who will do this as well. Google services loaded apparently gradually, because at first I couldn't even start the google account login option, then when I could it crashed while entering the password, but after a few restarts I could log in normally.

Now everything works, programs installed, device certified.

Thanks again to @followmsi and other people for the amazing work they put in to running the new system on this great albeit old tablet.
[Nexus 7 (2013) Android Development] TamD:
It is pretty amazing that we are still getting builds for our older, and much loved N7's. Thank you to everyone involved!!!

I did a dirty install of the LOS20 yesterday. So far no real problems.

Had to reinstalled Magisk (Modules seem to still be intact)

The Lawnchair 2 launcher (behaved badly) and is not compatible with Android 13. So, installed the Magisk (unofficial) Lawnchair 12, which is Android 13 compatible and seems to work well.

I may end up doing a clean install. in the near future.... but I am in the middle of a great book and don't want to interrupt that! lol
[Nexus 7 (2013) Android Development] followmsi:
LineageOS 20.0

Just one day later and we have the first "HotFix" build :)

March Feature and Security upgrade did mess up a lot ...

Had to add seccomp policy for mediaextractor to fix camera.

Some more fixes for the broken hwui .. which was feezing apps and system.

For exmaple scrolling thru Spotify app did kill system hwui on previous (0322) build.

lineage-20.0-20230323-UNOFFICIAL-flo.zip

lineage-20.0-20230323-UNOFFICIAL-deb.zip

Enjoy Android 13 :p
[Nexus 7 (2013) Android Development] TamD:
Wow! I have "earned a new achievement on XDA!" "Reacter: Level 2!" Which actually seems more like a mental diagnosis than an achievement....
[Nexus 7 (2013) Android Development] TamD:
Update: Two days later and LOS20 is running like a top.

The most exciting thing for me is that the Banking app that would not allow me to photograph a check for deposit actually works now! It has not worked since LOS 14! Super pleased!

Thank you!
[Nexus 7 (2013) Android Development] followmsi:
LineageOS 19.1 - March 2023 - FINAL 19.1 BUILDS

This are my last 19.1 builds for flo/deb.

Added a few changes to device tree and kernel sources.

All my last builds will be uploaded to Androidfilehost ..

lineage-19.1-20230324-UNOFFICIAL-flo.zip

lineage-19.1-20230324-UNOFFICIAL-deb.zip

The manifest has been updated as well ..

https://github.com/followmsi/manifests/tree/flo-deb-lineage-19.1

Bye bye .. Android 12 :p
[Nexus 7 (2013) Android Development] followmsi:
ElementalX kernel for Android 13

It's some kind of tradition to build EX kernel for the latest Android version ..

For the new kernel version I have merged all the changes since last EX kernel build.

Also the latest lineage kernel changes are inlcuded.

Pls use latest TWRP to install the kernel.

ElementalX-N7-7.02-Thirteen-20230325-AK3.zip

(inside KERNEL subfolder)

In case you want to go back to "stock" kernel ..

flo-deb-followmsi-kernel-thirteen-20230325-AK3.zip

(inside KERNEL subfolder)

Sources:

https://github.com/followmsi/flo_elementalx/tree/ElementalX-7.02-Thirteen

https://github.com/followmsi/android_kernel_google_msm/tree/followmsi-13

Big thanks to @osm0sis for AK3.

Enjoy :p
[Nexus 7 (2013) Android Development] TamD:
I recently installed the SmartPack Kernel Manager.

Could someone please explain the main pros & cons of flashing the Custom ElementalX Kernel vs using the SmartPack Kernel Manager (EX Kernel/Franco Kernel Manager or the like) or refer me to some link that would educate me (and others who may be as baffled as myself).

Thank you. :)
[Nexus 7 (2013) Android Development] osm0sis:
Nowadays I wouldn't consider using SmartPack, FKM or EXKM; there's a great free alternative:

[DEV] Kernel Flasher

Kernel Flasher is an Android app to flash, backup, and restore kernels. Features Flash partition images and AK3 kernel zips Backup and Restore kernel partitions Mount, Map, and Resize vendor_dlkm Save dmesg, logcat, and ramoops Check for kernel...

xdaforums.com
[Nexus 7 (2013) Android Development] TamD:
The features that I was liking with the Kernel Managers was the ability to manage things like modifying the CPU Governor....

I was not necessarily wanting a flashing tool.

I was under the impression that ElementalX Kernel was an actual kernel, not a flashing tool.

More confused than ever......
[Nexus 7 (2013) Android Development] osm0sis:
Ah, yes, well I'm sure there are open source/free device tweaking apps out there as well...

EX Kernel is a kernel for a number of devices, was a kernel for this device, and EXKM is the paid Kernel Manager app by the same developer. It does allow tweaking settings and flashing zips, just like FKM. I don't think either are very actively developed anymore.

Looks like MTG is expecting an Android 11+ based recovery, where the fstab mounts the ROM to /mnt/system to avoid breaking the recovery's own /system/bin. I'll see how hard it is to work around. 🤠

Also still hoping @Nikhil will bless us with some arm Go GApps at some point since an old device like this is pretty much the exact use case for Android Go. 🤞
[Nexus 7 (2013) Android Development] TamD:
Hey osmOsis.

Thank you for the response.

I installed SmartPack, downloaded from F-droid. It was free and open source, which are two of my favorite things.

So, if I am understanding what you are saying.... Ex Kernel that followmsi posted above does not allow you to tweak settings, but does tweaks by default, and EXKM allows you to make your own tweaks?
[Nexus 7 (2013) Android Development] osm0sis:
followmsi's bring-up of flo's EX Kernel to Android 13 exposes roughly the same kernel features/settings as the old official EX Kernel for this device. Then you can either modify them with a script, or an app like FKM, EXKM, or something else free.

I honestly wouldn't recommend anything by the SmartPack guy, dude charges money on the Play Store to install the Magisk busybox...
[Nexus 7 (2013) Android Development] TamD:
Thank you for the info.

I hear what you are saying. I'm degoogled. So do not frequent Play Store. I did find it interesting that SmartPack is paid for on Play Store but not on F-Droid.

So, is it safe to say that you recommend that I install followmsi's updated EX Kernel and then tweak it with either a script (intimidating for me) or a kernel manager?

Thank you for your input....
[Nexus 7 (2013) Android Development] osm0sis:
If you choose to install the updated kernel then I'd recommend figuring out what tweaks you want, perhaps with the help of a kernel manager app, but then try to put your final desired tweaks into a script, since that's the lighter weight option on such an old device.
[Nexus 7 (2013) Android Development] TamD:
That sounds like great advice.

Thank you so much for taking the time to walk me through this.

Best Regards, TamD
[Nexus 7 (2013) Android Development] Endurero:
Hello, thank you very much for your post, I could install it greatly and it works really good. Although, it took me a lot of time, because I am not an expert in this matter. Maybe would be goof adding a guide for people with less experience? Maybe linking a post of how to install TWRP as not everyone knows how to do it.
[Nexus 7 (2013) Android Development] clarkgable:
I haven't been able to update apps on Play Store since this last build, at times it states I'm offline when I am not and I am able to access the internet through other apps. Is anyone else experiencing similar?
[Nexus 7 (2013) Android Development] AlesUlrych:
Yes, I do. I have also dealt with this and the only way I have solved it is to do a Factory reset and then install. Everything works after that incl. Google Store as I wrote earlier.
[Nexus 7 (2013) Android Development] doxts:
Thanks for still supporting the N7 2013. I took some time to test LOS 20 on my device (deb). So far, everything works as expected for my use case. Trebuchet problems are gone (widget + apps reload) and it feels more fluid than with LOS 19. Only thing I noticed is I can't install Google News and Webex app using LiteGapps (maybe it has something to do with that, I'll try to test another package). I very much appreciate your work! 💯
[Nexus 7 (2013) Android Development] jdefgts:
Is there a gapps package for android 13 that supports the Google setup package that offers to restore from a Google drive backup.? Any info would be helpful. The LiteGapps_arm_13.0_v2.8_official.zip does not seem to do that for me.
[Nexus 7 (2013) Android Development] osm0sis:
MTG's installer actually worked great for me. I'm using my flo2flox'd official TWRP, which could make a difference, but I think it might just be that you formatted system and rebooted to recovery first before flashing the ROM, so maybe needed another reboot to recovery before GApps.

Looks like the OS version upgrade makes update_engine/addon.d wipe/remove all existing scripts anyway, so it's automatically a "clean dirty" install by default. 👍
[Nexus 7 (2013) Android Development] Spielmops:
Swipe statusbar to change brightness is not working. It was working with LOS 19.

Spielmops
[Nexus 7 (2013) Android Development] followmsi:
Revert "SystemUI: Port statusbar brightness control"

Needs to be refactored after QPR2

Revert "SystemUI: Port statusbar brightness control" · LineageOS/android_frameworks_base@2919024

Needs to be refactored after QPR2 This reverts commit 54bf717dee23e09971506bd656f292cd650d1b25. Change-Id: I888ba4bc5b2070e60419753c7c5bba9b6b79850c

github.com
[Nexus 7 (2013) Android Development] philsner:
FIrst of all thanks for the continuing support of the Nexus7! I'm trying to install the latest 20.0 + Recovery LiteGapps as recommended. Everything works fine in recovery and while installing both lineage and gapps (twrp 3.7.0_9-0_followmsi) But the Google Services keep stop working right after booting up. Is there anything I missed?

Edit: I installed Magisk to use the Magisk version of LiteGapps. This seems to work!
[Nexus 7 (2013) Android Development] followmsi:
LiteGapps are OK .. but it's good to have more gapps packages available.

Quickly made a custom MindtheGapps package for flo/deb devices !

To be installed using "my" TWRP. (3.7.0)

The "addon" script seems to be working well.

This means .. Gapps will be automatically re-installed when installing new ROM.

Tested on flo device only !

Pls have a test yourself ..

MindTheGapps-13.0.0-arm-20221025_095826_flo.zip

Cheers
[Nexus 7 (2013) Android Development] osm0sis:
What's the difference from the standard MTG arm 20221025?
[Nexus 7 (2013) Android Development] ipdev:
I was wondering the same.

I assumed it had to do with the mounting so I compared install scripts.

The easiest way to show the changes was just to push it to github. 🙃

example - [github] - commit

Not quite a dynamic installer script anymore. 😉

Cheers. :cowboy:

PS.

I haven't had time to try followmsi's MTG-flo build yet.
[Nexus 7 (2013) Android Development] Mr.Conkel:
Coming back every so often to see devs STILL making it happen for such a good device. Love to see A13 on a almost 10 year old device running pretty well considering. Good stuff!
[Nexus 7 (2013) Android Development] followmsi:
You both are the gapps and script experts ;)

"My" TWRP is copying "recovery.fstab" as "twrp.fstab" into recovery ..

Like "official" flo TWRP too.

For this reason the MTG sctipt/function (get_block_for_mount_point) does not find the correct SYSTEM_BLOCK.. for mounting.

Yes. . I dirty "hardcoded" the correct flo/deb path .. "quick and dirty" ;)

( SYSTEM_BLOCK=/dev/block/platform/msm_sdcc.1/by-name/system )

As I know .. TWRP still mounts to "/system" .. and Lineage recovery mounts to "/mnt/system".

Yes .. Also changed "SYSTEM_MNT" to make it work on flo/deb devices !

All in your github diff .. (y)

Now I have added "print_ui" function into MTG addon script ..

ui_print "Backup MindTheGapps .."

ui_print "Restore MindTheGapps .."

To actually see in recovery when/if gapps are getting backuped/restored.

For this reason I have changed the "/system/addon.d/addond_tail" script ..

Actually taken fron Magisk addon script. ;)

# update-binary|updater <RECOVERY_API_VERSION> <OUTFD> <ZIPFILE>
OUTFD=$(ps | grep -v 'grep' | grep -oE 'update(.*) 3 [0-9]+' | cut -d" " -f3)

ui_print() {
echo -e "ui_print $1\nui_print" >> /proc/self/fd/$OUTFD
}

This is part of new V2 version from today ..

MindTheGapps-13.0.0-arm-20221025_095826_flo_V2.zip

Pls go ahead and optimize the scripts ..

Maybe I will rename "twrp.fstab" into "recovery.fsatb" .. for next TWRP build.

On gitlab they do have newer prebuilts .. and other changes for arm .. maybe you can update some prebuilts .. the current package is from 20221025.

MindTheGapps / vendor_gapps · GitLab

GitLab.com

gitlab.com

The V2 version is my last custom MindTheGapps package for flo/deb ..

Cheers
[Nexus 7 (2013) Android Development] osm0sis:
@followmsi would you be able to add the GPU OC from EX to your included kernel? It's probably the only thing anyone's interested in from it anymore.

I was tinkering with it and found the OC'd GPU along with the unreleased Adreno beta drivers really helped with the smoothness of animations.

Last thing I noticed helped, and actually helped dramatically, was I switched the I/O scheduler from cfq to noop! Much more fluid System UI, Launcher and app start times/responsiveness. 😁

Edit: Widget resizing/scaling seems a bit wonky on the large screen, but otherwise the ROM seems a fair amount more stable for use than previous builds (though I noted the final 19.1 also seemed quite good before I moved to 20!)
[Nexus 7 (2013) Android Development] TamD:
Great tips. Thank you. Any other tinkering suggestions....
[Nexus 7 (2013) Android Development] followmsi:
Thanks for feedback and testing. (y)

Here you are .. added GPU OC and some more EX stuff into "my" kernel.

Commits · followmsi/android_kernel_google_msm

Linux kernel for Google MSM devices. Contribute to followmsi/android_kernel_google_msm development by creating an account on GitHub.

github.com

flo-deb-followmsi-kernel-thirteen-20230401-AK3.zip

(inside KERNEL subfolder)

Changed to "noop" scheduler in device tree too.

Will start full test build later on ..

What about "unreleased Adreno beta drivers" ?

Cheers

EDIT:

Quick off-topic comment to MTG installer .. :)

TWRP does rename "twrp.fstab" into "recovery.fstab" while booting .. for this reason MTG installer should find fstab .. but as it looks like it can't read the BLOCK_SYSTEM correctly .. it does work the "hardcoded" way ,,, like said before .. pls feel free to adjust/optimize the MTG scripts.
[Nexus 7 (2013) Android Development] followmsi:
New builds ..

Added some EX kernel stuff and switched to noop io scheduler.

Pls use kernel manager app like "kernel adiutor" to change kernel settings.

lineage-20.0-20230401-UNOFFICIAL-flo.zip

lineage-20.0-20230401-UNOFFICIAL-deb.zip

Enjoy Android 13 :p
[Nexus 7 (2013) Android Development] RBS95:
Hi, I'm not familiar with rooting on Android. Looking to upgrade my Nexus 7 onto the latest android version so I can use Twitch etc. The instructions on the first page are very bare and hard to follow if you don't have existing knowledge. Can anybody link me to a more comprehensive set of instructions or a tutorial?
[Nexus 7 (2013) Android Development] osm0sis:
The original thread for the updated Adreno drivers, for more background info on them if you're interested: https://xdaforums.com/t/marshmallow...drivers-for-nexus-7-updated-10-11-15.3228000/

They are v145 instead of the stock included v127 drivers, and improved benchmark scores and general smoothness noticeably!

I tested them pretty extensively back when this and the Nexus 5 were modern devices, and they unfortunately went in and out of being stable with their later builds, and then Qualcomm never bothered to push any final builds to Google for release, so the Adreno Beta program was the only place they ever saw the light of day.

According to past me the final stable beta build was from February 2016:

https://xdaforums.com/t/marshmallow...pdated-09-12-15.3228002/page-15#post-73325141

I mirrored all the packages I could find for posterity here: https://androidfilehost.com/?w=files&flid=312875

Would love to see the February ones included in the ROM if you find them stable enough on your device. 😁

The official MTG worked fine on my flo2flox'd official TWRP, so might just be something quick you could add to your TWRP tree to get it working.

The changes my AK3 zip performs are pretty straightforward:

# cmdline changes

patch_cmdline androidboot.hardware androidboot.hardware=flox; # change "flo" to "flox"
replace_string $split_img/header bootdevice androidboot.hardware=flox "androidboot.hardware=flox androidboot.bootdevice=msm_sdcc.1"; # add bootdevice support (placement in cmdline matters)

# begin ramdisk changes

# default.prop
patch_prop default.prop ro.build.product flox; # change "flo" to "flox"

# etc/*.fstab
for i in recovery twrp; do
replace_string etc/$i.fstab bootdevice platform/msm_sdcc.1 bootdevice global; # change "/dev/block/platform/msm_sdcc.1" to "/dev/block/platform/bootdevice"
insert_line etc/$i.fstab /vendor after by-name/system "/vendor ext4 /dev/block/bootdevice/by-name/vendor"; # add /vendor support
done;

# fstab.flo
replace_string fstab.flo bootdevice platform/msm_sdcc.1 bootdevice global; # change "/dev/block/platform/msm_sdcc.1" to "/dev/block/platform/bootdevice"
insert_line fstab.flo /vendor after by-name/system "/dev/block/bootdevice/by-name/vendor /vendor ext4 ro,barrier=1 wait"; # add /vendor support

# end ramdisk changes

I'd say just ignore the flox-specific ones, e.g. where flo only gets changed to flox, and add the remaining fixes for profit?

Edit:

Just tried 0401 and the only other thing that looks like it's missing from the kernel are the updated TCP congestion algorithms. I believe westwood and bbr are considered the best currently from kdrag0n's research: https://docs.google.com/spreadsheet...xMNz9pgS9OLKcFHssIBlj9xXI/edit#gid=1926845420

Would be great to have those, and then no more need for EX bring-ups on this device. :p

Edit 2:

Oh, and any way to hook up this old kernel's Double Tap 2 Wake function to the usual Lineage Settings option?
[Nexus 7 (2013) Android Development] followmsi:
Same "hacks" .. but fresh synced sources from gtilab.

MindTheGapps-13.0.0-arm-20230401_153356-flo.zip

Inside the "MindTheGapps" subfolder !

Cheers
[Nexus 7 (2013) Android Development] followmsi:
Thanks for the links to the adreno drivers ...

Are they really stable ? ;)

Can make test build with the Feb 2016 version included .. no problem.

For me "offical" TWRP devices are listed on twrp.me websie .. can*t find the sources for "offical" flo2flox version on teamwin github too .. anyway ..

You basically add "bootdevice" to cmdline and replace in fstab.

Will test this ..

As the MTG sources are on my machine I made also normal build .. just with "print_ui" in addon script .. but no flo customizations.

Cheers
[Nexus 7 (2013) Android Development] followmsi:
Pls post linkt to network related commits in original EX kernel ... Thanks

Not sure about DT2W ,, personally don't like it .. too much energy for nothing ;)

Cheers
[Nexus 7 (2013) Android Development] osm0sis:
I've found them pretty stable over the years, with stock and CM and now Lineage. Give them a try and see what you think! 🙂

Yeah there's no official flox, but taking official flo and running my flo2flox AK3 script above on it is what I'm referring to. 👍

TCP Congestion Control is just some switches in the defconfig. Here is basically what we want, but from an OP9Pro kernel: https://github.com/engstk/op9/commit/cc75e300d8e2522ae16950691578aba8fba8bd3a

I'd also suggest making the default westwood or bbr. 🤘

DT2W is already in the kernel, just asking to have it more easily exposed to the end user by having it be a toggle in Settings like it is on modern devices with Lineage. 🤞
[Nexus 7 (2013) Android Development] followmsi:
Ok .. let's test the adreno stuff in next build.

Tested the "bootdevice" in TWRP .. does not work for me.

TWRP does not find/mount partitions anymore.

Need to check what I made wrong .. or whats missing.

Ok .. just enabling westwood .. but no special patches for it.

bbr is not in flo EX kernel .. disabled all this stuff years ago .. on other devices too.

I will enable for next build .. and switch default from cubic to westwood.

I know about DT2W .. disabled in my kernel.

Do you have an idea on how to make it work for flo ?

Actually don't want to spent much time on this topic.

Anyway .. for today I spent enough time for flo ..
[Nexus 7 (2013) Android Development] osm0sis:
The main thing I noted for bootdevice was that it had to come after hardware in the final cmdline, i.e.:

androidboot.hardware=flo androidboot.bootdevice=msm_sdcc.1

Then the fstab changes in recovery.fstab, twrp.fstab and fstab.flo from "platform/msm_sdcc.1" to "bootdevice" should work if the TWRP base is up-to-date with the latest official.

DT2W is currently present in your kernel but disabled by default, please leave it at least present... As for how to hook it up to the Lineage Settings > Display > Tap to wake toggle, I'm not sure, but I assume it would be just swapping out whatever command Settings sends under the hood to instead use the old flo implementation.

e.g., to enable it I have this in my boot script:

echo 1 > /sys/android_touch/doubletap2wake;

Edit:

My current boot script if anyone's interested. ;)

/data/adb/post-fs-data.d/000bootsettings:

#!/system/bin/sh

for i in /sys/block/*/queue; do
echo 512 > $i/nr_requests;
echo 256 > $i/read_ahead_kb;
echo 2 > $i/rq_affinity;
echo 0 > $i/rotational;
done;

echo 585000000 > /sys/class/kgsl/kgsl-3d0/max_gpuclk;

echo 1 > /sys/android_touch/doubletap2wake;
echo 1 > /sys/kernel/fast_charge/force_fast_charge;

echo 128 > /proc/sys/kernel/random/read_wakeup_threshold;
echo 256 > /proc/sys/kernel/random/write_wakeup_threshold;

echo westwood > /proc/sys/net/ipv4/tcp_congestion_control;
echo 1 > /proc/sys/net/ipv4/tcp_low_latency;

for i in /sys/class/net/*; do
echo 100 > $i/tx_queue_len;
done;
[Nexus 7 (2013) Android Development] followmsi:
Today it's a (hardcore) flo day ;)

Thanks .. found the issue in TWRP .. typo .. added too much "platform".

But .. as to change all fstab and cmdline .. I simply used a good old symlink.

on fs
wait /dev/block/platform/msm_sdcc.1
symlink /dev/block/platform/msm_sdcc.1 /dev/block/bootdevice

And - Yes .. Unmodified MTG installer will work now !

Already uploaded the new TWRP versions to gdrive ...

twrp-3.7.0_9-1-flo_followmsi.img

twrp-3.7.0_9-1-deb_followmsi.img

Removed all the "_flo" MTG versions from gdrvie too,

Pls use and test ..

MindTheGapps-13.0.0-arm-20230401_160426.zip

Last but not least I have added all the "westwood" stuff into kernel too ..

flo-deb-followmsi-kernel-thirteen-20230401-AK3.zip

Yes .. DT2W will be kept in kernel .. but disabled.

Need to check how to trigger from settings .. we will see.

Cheers