Thanks to visit codestin.com
Credit goes to Github.com

Skip to content

ftomitar/oilsky-m308

Repository files navigation

🇧🇷 Portuguese

Oilsky M308

Root/Debloat Oilsky M308 (MTK)

The Oilsky M308 is a portable digital audio player (DAP) running Android 9.0, focused on high fidelity audio but fully capable of being optimized into a dedicated, lightweight, streamlined player.


📦 Oilsky M308 Specifications

Specification Details
Product Name HiFi MP3 Player Oilsky M308
System Android 9.0
Processor 8 cores @ 1.5GHz
Memory 2GB RAM + 16GB storage
Screen 2.8 inches
Resolution 480 × 640
Video Formats AVI, MKV, RMVB, MP4, MPG, MOV
Image Formats JPEG, BMP, GIF, PNG
Audio Formats MP3, WAV, APE, FLAC, AAC, ALAC, DSF, DFF, ISO, DTS
Audio Support 44.1, 48, 88.2, 96, 176.4, 192 kHz / 16 or 24 bits
Bluetooth V4.1 (LDAC, SBC, AAC)
DSD Up to DSD512
DAC/AMP ESS9018Q2M + MAX97720
Output Power 0.95V@32Ω (28mW@32Ω), 1.9V@600Ω (6mW@600Ω)
Headphone Jack Standard 3.5mm (max 125mW/32Ω)

Warning: These operations may brick your device. I take no responsibility for any damage.


📂 Repository Structure


⚡️ Table of Contents

  1. Prerequisites
  2. Backing Up boot.img with mtkclient
  3. Patching boot.img with Magisk
  4. Using the Ready Magisk Boot Image (Optional)
  5. Flashing the Patched boot.img with fastboot
  6. System Optimization (RAM/CPU)
  7. Magisk Modules & Hi-Res Audio
  8. System Debloat & Battery Saving
  9. Restoring the Original boot.img
  10. References

Prerequisites

  • Python installed
  • mtkclient (link)
  • ADB and Fastboot installed
  • Magisk APK (official link)
  • Compatible Oilsky M308 firmware
  • Unlocked bootloader (fastboot oem unlock)
  • USB debugging enabled

1. Backing Up boot.img with mtkclient

Power off the device, unplug USB, and prepare for BROM mode.

On your PC, run:

python mtkclient.py r boot boot.img
# mtkclient will wait for device connection.

Connect the device without pressing any buttons. mtkclient will back up the boot partition as boot.img. Keep this file safe!


2. Patching boot.img with Magisk

  1. Transfer the boot.img to your device (USB, adb push, or SD card).
  2. Install and open the Magisk app.
  3. Tap Install > Uncheck recovery mode > Next > Method > Select and Patch a File > choose your boot.img.
  4. Magisk will generate magisk_patched-XXXXX.img.
  5. Copy this file back to your PC.

2.1. Using the Ready Magisk Boot Image (Optional)

If you want to use a pre-patched boot image, one is available at:

WARNING: Always back up your original boot image before flashing any new image! Using an image from another firmware or device may cause irreparable brick.


3. Flashing the Patched boot.img with fastboot

On your PC:

adb reboot bootloader
fastboot flash boot magisk_patched-XXXXX.img
fastboot reboot

System Optimization (RAM/CPU)

For an even lighter system, try:

  • Launcher: Pie Launcher (super lightweight)
  • Music Player: Poweramp (lets you force Hi-Res output and view audio processing details)

Additional scripts can be found in data/adb/services.d/ (see: 99-powersave.sh, 99-reduce-priority.sh).


Magisk Modules & Hi-Res Audio

Special thanks to reiryuki for the original scripts.


System Debloat & Battery Saving

Note: The debloat.sh script is extremely aggressive and is designed to turn the device into a simple, dedicated player! Install your launcher and other apps first, or adjust the scripts as needed.

As root, copy the scripts from data/adb/services.d to the same location on your device. These scripts, run on every boot, will disable Google services, force airplane mode, reduce process priority, and disable various background services. Feel free to edit them to your needs.


Restoring the Original boot.img

To restore your original boot:

fastboot flash boot boot.img

Always keep a backup of your original boot.img to avoid bricks.


References

About

Debloat Oilsky M308

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages