Tested SM-P580, SM-T580, SM-P585
This post is designed to gather information found across this forum to give a step-by-step guide for obtaining a custom recovery TWRP and Root to 2016 Samsung Tab A tablets.
Credit to the software authors, original post creators (especially jcadduono and ashxy) and all those who contributed to the discussions to clarify all the issues.
Here is my set of instructions to gain TWRP and Root on the Tab A (WIFI) SM-P580, SM-T580, and SM-P585
Flashing a custom recovery to your device will trip the Knox warranty bit on your phone. Check with your mobile provider to see if they will still cover warranty on Knox bit triggered devices. If you understand this risk, continue on. You generally don't have to worry, as it's incredibly hard to brick a Samsung device, and physical damage warranties should be exempt from Knox triggering. [credit: jcadduono]
If you prefer Magisk to chainfire supersu, please see the modification described in https://forum.xda-developers.com/showpost.php?p=73719123&postcount=82
c. Original firmware
a. While running your tablet in Android, go to Settings -> About device. Tap 7 times on Build number to enable Developer options. [credit: jcadduono]
b. Now go to Settings -> Developer options. (above About device). You need to enable OEM unlock, otherwise you might end up with boot problems or be unable to flash later on. Do not ever turn off Developer Options or OEM unlock. Doing so will cause your device to refuse to boot and require a full factory restore. [credit: jcadduono]
c. Turn off your tablet.
d. Get a micro SD card
e. Copy SuperSU and dm-verity script onto microSD card
f. Install microSD card into Tablet
g. Install Samsung USB Drivers on Windows machine
h. Unzip ODIN (1a) and Original firmware (1c) on your Windows computer
i. While tablet is off, plug in usb cable between tablet and Windows computer
3. REFLASH ORIGINAL FIRMWARE (Optional)
a. Enter Download mode, press and hold Home, Down Vol, and Power until you see the Warning screen of the downloader mode. Press Vol up to continue
b. Open up ODIN, confirm that ODIN can see your tablet, click AP button on Odin. In popup, select AP_[blah blah].tar.md5 (whatever AP file you downloaded in step 1c). After selecting the file, Odin will check the signature of the file you downloaded and appear to freeze up. Let it finish, and it will report: <OSM> Checking MD5 finished Sucessfully.. <OSM> Leave CS..
c. Then click Start. The screen of the tablet should show a progress bar as your tablet is being restored to its original firmware.
d. At this point, you need to let the tablet reboot into Android. If ODIN doesn't do this itself, reboot into to download mode (home, vol down, power), then select Vol down to reboot. After a while, you will be greeted with the Welcome screen where you can select your language.
e. Power off the tablet using the power button
4. FLASH TWRP
a. Enter Download mode (press and hold Home, Down Vol, and Power) until you see the Warning screen of the downloader mode. Press Vol up to continue
b. (Re) Open up ODIN, confirm that ODIN can see your tablet,
c. Important We do not want the tablet to automatically reboot after installing TWRP. If the tablet does reboot into Android before completing the steps in Section 4 and 5, there is a good chance the stock recovery will overwrite TWRP. So click the Options tab on the left and deselect Auto Reboot. After doing that, click the Log tab so you can monitor progress
d. Click AP button on Odin. In popup, select twrp-[blah blah].img.tar (downloaded in step 1d), click Start. You will see the progress bar on your tablet. Watch the log window of Odin and wait for the message "<OSM> All threads completed. (succeed 1 / failed 0)"
5. ENTER TWRP AND CONFIGURE
a. At this point, from the last section, you should still be in Download mode on the tablet. It is important that, after flashing TWRP, to go straight to TWRP without letting the Android System reboot. To do this, Hold [Volume Down] + [Home] + [Power] to get out of Download mode and immediately swap to [Volume Up] (while still holding [Home] + [Power]) when the screen blanks. [credit: jcadduono]
b. In a few secs, you will see the TWRP first screen, you can let go of all the buttons.
c. If you don't see then TWRP boot splash try again from the start of 4. FLASH TWRP.
d. Swipe to Allow Modifications. (For some reason, TWRP has some issues with the touchscreen for some tablets. If you experience this, expect to make several swipes or taps until it properly registers. You have succeeded when you see the classic 8-button main screen of TWRP. Indeed, throughout your use of TWRP, expect that touches will often not properly register, and just keep trying until it does.)
e. Click Wipe then Format Data (do not just Wipe data), type yes and let it complete. (It is also a good practice, though not always necessary, to Wipe the Cache and Dalvik Cache whenever you make changes to the system. They are always rebuilt as needed. Now is as good a time as any.) Then click back until you get to the 8-button main screen of TWRP.
f. Click the Mount button. Select Storage button, and confirm that the Internal Storage shows non-zero MB. If it is, you know that the /data partition is now mounted properly. However, since we put the needed scripts on the microSD, go ahead and select Micro SD Card as our storage. Click Back until you are back at the 8-button main screen.
g. Click the Install button, install the SuperSU zip file you downloaded in step 1e and copied to your microSD. It will finish and say Updating partition details… …done. Click Back to get back to the install screen (do not reboot yet).
h. Install the no-verity zip file from step 1f. When it completes, you can press the Reboot System button and let your tablet reboot into Android. You can also disconnect the usb cable connecting the tablet from the computer. The tablet may reboot itself once or twice, let it do its thing, and eventually you will see the Samsung Welcome! Screen, where you can select your language.
6. CONFIRM DATA ACCESS IN TWRP
a. Before going into configuring your tablet, go ahead and turn off the tablet and re-enter TWRP (Home, Vol up, Power).
b. *Important* Since you will not be changing your system partition, this time, when you get to the "Keep System Read only?" screen, click the Keep Read Only button.
c. In the 8-button screen of TWRP, click Mount, click Select Storage. Confirm that the Internal Storage is greater than zero MB. If it is, congratulations, you have TWRP installed with /data mounted. At this point, you might want do a backup. If you want your TWRP backup to be on your microSD card, select it now while still in the Select Storage dialog.
d. Do a backup.
e. Reboot to System
7. FUTURE USE OF TWRP
a. Unless you are planning to make changes to the System, continue to choose the Read Only System when you return to TWRP. If you need to make changes to System, e.g. flash a new ROM, go back to Step 5 and install the ROM just before Step 5g
8. Click the Thanks button if my guide helped you.