[Samsung Galaxy Tab A series ROMs, Kernels, Recover] agreenbhm:
Hello world, I have successfully built LineageOS 19.1 with Gapps for the SM-T500 (Tab A7 10.4 2020) using Andy Yan's LOS GSIs. Lineage is current as of 3/24/2022. I have also compiled TWRP version 3.6.1, based on Android 11 (previous release was Android 10-based). I have attempted to make this install as painless as possible. Please read the notes below carefully. WARNING: you are responsible for your own actions, so please be careful. If you brick something, that's on you.

Update to latest stock ROM as of 3/24/2022 (T500XXU3BVB3).

Unlock bootloader using steps described in this thread. Make sure that after your device wipes and reboots after the bootloader is unlocked that you go through the setup wizard again and back into Developer Settings and enable OEM Unlocking. I think you need to connect to wifi for this option to appear, so if you don't see it try that.

Boot to download mode, then install VBMeta Disabler via Odin.

Reboot to download mode, then install TWRP via Odin.

Reboot to download mode again, then install LineageOS via Odin.

Boot to TWRP, push "fix_brightness.sh" to the device and run it, then format data.

That should be all that is necessary. If you get stuck in a loop with TWRP where you can't boot to system (seems to happen regularly to me) I included a script in TWRP that should get you out. From the TWRP cli run the command "exit_twrp". It will say "out of space" when finished (instantly). Then reboot to system. If for some reason that still doesn't work and you boot back to TWRP, repeat.

Known Issues:

OS-encrypted storage (Internal Data) not able to be decrypted in TWRP.

TWRP touchscreen seems to be unresponsive for several seconds upon first booting into TWRP. Just patiently wait a few seconds and try again.

You'll see errors in TWRP about /keyrefuge, etc. Ignore that. I believe it's related to the inability to decrypt internal storage using FBE.

Installing Gapps (Nik and Flame) doesn't work, but no worry because the ROM includes Gapps :)

Security: by default this ROM has root access and USB debugging (adb) is enabled unsecured. Anyone can plug into it and have full root access. So disable USB debugging if you don't want that! TWRP is the same way, though data is encrypted. Someone could install malware into your system partition though. In short, this is for hobbyists, not someone with security concerns.

Sources:

Device tree for TWRP from my Github; branch TWRP-11 specifically: https://github.com/agreenbhm/android_device_samsung_gta4lwifi

Kernel sources from Samsung: https://opensource.samsung.com/uploadSearch?searchValue=Sm-t500#

Files:

LineageOS 19.1 Beta2

TWRP 3.6.1 Beta 5

VB Meta Disabler

Brightness Fix

Updates:

You can update this ROM yourself by installing a new GSI to the system partition.

Download new GSI from here onto Micro SD card: https://sourceforge.net/projects/andyyan-gsi/files/lineage-19.x/

Boot into TWRP

Run command: blockdev --setrw /dev/block/mapper/system

Run command: dd if=/external_sd/<your_downloaded_gsi.img> of=/dev/block/mapper/system bs=1M

Wait for dd command to finish, then reboot into system. Don't forget to use "exit_twrp" command if you keep booting into TWRP.