Custom Image in Samsung Devices

In this article, I want to share my experience with successfully installing a custom ROM on my Samsung Galaxy A7 Lite(SM-T220). The process will be similar to that of other Samsung devices, too. If you want to make your android device faster without Samsung preinstalled apps, it is good idea to consider installing custom OS in your device.

My preferred operating system is Ubuntu, so I have this on my Ubuntu system, the process should be similar to other Linux variant operating systems.

Ubuntu Environment Setup

  • Install core Android and Samsung flashing dependencies on Ubuntu
sudo apt install dab, fastboot, p7zip-full, libusb
  • Download odin4 binary tool from the link below (or can be used another links)

https://github.com/Adrilaw/OdinV4/releases

The downloaded zip file is extracted and made executable. The executable binary is copied into /usr/local/bin folder so that odin4 command can be accessed from anywhere.

chmod +x odin4
sudo mv odin4 /usr/local/bin
  • Add dev rules for USB for Samsung devices in Ubuntu. Create/append a file /etc/udev/rules.d/51-android.rules with the following content:
SUBSYSTEM=="usb", ATTR{idVendor}=="04e8", MODE="0666", GROUP="plugdev"
  • [optional?] To prevent USB communication timeout errors with Samsung Download Mode.
sudo rmmod cdc_acm

Unlocking Bootloader & Download Mode

  • Enable Developer Options, and then USB Debugging & OEM Unlocking from stock Adroid settings.
  • Boot into Download Mode (Vol Up+Vol Down + USB Cable connected to Ubuntu), and then long press Volume Up to unlock bootloader.
  • You can use command “adb devices” to check if he device is properly connected. In any case if the device bootloader not roperly unlocked, you can simply use the following command: “adb reboot download”. This will reboot in download mode.
  • If the device is showing as “unauthorized”, then you check the tablet and allow USB debugging.
  • The adb server can be restarted using “adb kill-server; adb start-server”

Flash custom TWRP Recovery

  • Download TWRP Recovery from this link: https://github.com/gta7lite/teamwin_device_samsung_gta7lite/releases
  • Run this command: “sudo odin4 -a TWRP_v2.2_gta7lite.tar”. Make sure it successfully flashed. In case any problem, check the bootloader is properly unlocked.
  • Do force reboot (Power+ Vol Down) and then immediately Power+ Vol Up to catch to recovery mode. (Note: if you are late to press Power+ Vol Up, then stock Android could overwrite TWRP. If so, before booting stock Anroid, do force reboot and to go recovery mode)

TWRP Fastboot Mode

  • From TWRP recovery mode, boot into Fastboot Mod (Reboot > Fastboot) to access the device’s dynamic partition layout via terminal.
  • Run these commands to clear system space and partition to make room for the new OS. “fastboot erase system; fastboot erase product; fastboot resize-logical-partition product 0x0

Download, Flash & Boot

The initial boot could take 3-5 minutes, so have patience!

Congratulations! You have successfully installed custom OS into your Samsung device!!!

Related Posts

Leave a Reply

Your email address will not be published. Required fields are marked *