Add docs
This commit is contained in:
+23
@@ -0,0 +1,23 @@
|
||||
# Building the images
|
||||
|
||||
This process **needs** to be done on a machine already running NixOS, as it heavily leverages Nix, the package manager.
|
||||
|
||||
# Host setup
|
||||
Ensure you have the following options enabled in your host:
|
||||
|
||||
```nix
|
||||
boot.binfmt = {
|
||||
registrations.aarch64-linux = {
|
||||
interpreter = "${pkgs.pkgsStatic.qemu-user}/bin/qemu-aarch64";
|
||||
fixBinary = true;
|
||||
matchCredentials = true;
|
||||
wrapInterpreterInShell = false;
|
||||
magicOrExtension = ''\x7fELF\x02\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\xb7\x00'';
|
||||
mask = ''\xff\xff\xff\xff\xff\xff\xff\x00\xff\xff\xff\xff\xff\xff\xff\x00\xfe\xff\xff\xff'';
|
||||
};
|
||||
};
|
||||
|
||||
nix.settings.extra-platforms = ["aarch64-linux"];
|
||||
```
|
||||
|
||||
A build of the images can then be triggered by **just build-images** or **nix run**, which will produce build artefacts under ./images. boot.img and rootfs.sparse.img are ready for flashing!
|
||||
@@ -0,0 +1,77 @@
|
||||
# NixOS 25.11 for Xiaomi Pad 6 (pipa)
|
||||
|
||||
  
|
||||
|
||||
An experimental NixOS setup for the Xiaomi Pad 6
|
||||
|
||||
## Overview
|
||||
|
||||
This repo is my personal project to configure and make NixOS usable on the Xiaomi Pad 9.
|
||||
|
||||
### Key Features
|
||||
* **Relatively small** Considering this setup is based on stripped down Gnome including Firefox and some smaller packages, the rootfs comes out to abou 7.6 GB.
|
||||
* **Fully declarative** As one would expect from [NixOS](https://nixos.org/).
|
||||
|
||||
---
|
||||
|
||||
## Prerequisites
|
||||
|
||||
Before flashing this OS, ensure you have the following:
|
||||
|
||||
1. **Unlocked Bootloader:** Your Xiaomi Pad 6 must have its bootloader unlocked.
|
||||
2. **Android Platform Tools:** `fastboot` installed on your host machine.
|
||||
|
||||
---
|
||||
|
||||
## Installation
|
||||
|
||||
**WARNING:** This process will overwrite your `boot`, `cust` and `userdata` partitions. All existing Android data will be destroyed. Back up your files before proceeding.
|
||||
|
||||
1. Reboot your tablet into Fastboot mode (Hold Power + Volume Down).
|
||||
2. Connect the tablet to your PC via USB.
|
||||
3. Flash the Mu Silicium, boot and root filesystem images:
|
||||
|
||||
```bash
|
||||
# Single boot instructions:
|
||||
|
||||
# Flash Mu Silicium
|
||||
fastboot flash boot_ab silicium.img
|
||||
|
||||
# Flash the UEFI boot partition
|
||||
fastboot flash cust boot.img
|
||||
|
||||
# Flash the Btrfs root filesystem image
|
||||
fastboot flash userdata rootfs.sparse.img
|
||||
|
||||
# IMPORTANT! Do not forget to erase dtbo_b! Otherwise your device will not boot:
|
||||
fastboot erase dtbo_ab
|
||||
|
||||
# ALSO VERY IMPORTANT! DO NOT reboot via the power button. Let the tablet completely write the images to UFS:
|
||||
fastboot reboot
|
||||
```
|
||||
Reference: [Fedora Pocketblue installation instructions](https://pocketblue.github.io/devices/xiaomi-pipa/).
|
||||
|
||||
### For dual booting
|
||||
|
||||
#### You will need to split up userdata into 3 partitions:
|
||||
* userdata (for Android)
|
||||
* boot (1GB)
|
||||
* rootfs
|
||||
|
||||
### Default credentials:
|
||||
* Username: `nixos`
|
||||
* Password: `nixos`
|
||||
|
||||
## Disclaimer
|
||||
|
||||
**Use at your own risk.**
|
||||
|
||||
This software is provided "as is", without warranty of any kind. Flashing custom operating systems and modifying device partitions carries inherent risks.
|
||||
|
||||
By choosing to use this project and flash these images, you acknowledge and agree that:
|
||||
* **You are solely responsible** for any modifications made to your device.
|
||||
* I am **not responsible** for bricked devices, hardware damage, bootloops, or voided warranties.
|
||||
* This process will **completely and permanently wipe** your `userdata`, `cust` and `boot` partitions. I am **not responsible for any lost data**.
|
||||
* It is strictly your responsibility to back up any critical files, photos, or data before proceeding.
|
||||
|
||||
Please thoroughly review the installation instructions and ensure you understand the process before executing any `fastboot` commands.
|
||||
Reference in New Issue
Block a user