nyuuzyou/wikis huggingface dataset:
Xiaomi Redmi 3S (xiaomi-land)

== Contributors ==
* Alikates
== Users owning this device ==
== How to enter flash mode ==
With the phone powered off, hold and buttons simultaneously. Release when you feel a vibration and the fastboot screen shows up.
== Installation ==
* Follow the Installation guide
$ pmbootstrap init # choose Vendor: qcom Device codename: msm89x7
$ pmbootstrap install
$ pmbootstrap flasher flash_lk2nd
$ pmbootstrap flasher flash_rootfs
== UART pinout ==
On the back of the board. These pins are only 0.5mm and have solder mask on them, be careful.
== See also ==
Category:Devices with known UART pinout
Xiaomi Redmi 3 (xiaomi-ido)

== Contributors ==
* lawl
== What works ==
* Boots
* USB Networking
* osk-sdl works to unlock root partition
* battery
* weston starts and display works, but touch screen doesn't work yet
== What does not work ==
* Touch screen doesn't work in libinput (used by weston etc.)
* everything else is untested
== See also ==
* Initial merge request
* 
*
Xiaomi Redmi 4A (xiaomi-rolex)

== Contributors ==
* Nrdnandan
== Maintainer(s) ==
* Nrdnandan
== Users owning this device ==
== How to enter into bootloader (fastboot) ==
* Shutdown the phone completely.
* Press and button simultaneously to enter fastboot mode.
== How to enter into recovery mode ==
* Shutdown the phone completely
* Press and button simultaneously to enter the recovery (MI or Custom).
== Installation ==
* Follow the Installation guide and your device wiki page.
$ pmbootstrap init # choose Vendor: qcom Device codename: msm89x7
$ pmbootstrap install
$ fastboot flash boot lk2nd.img # Build lk2nd from msm8916-mainline/lk2nd repo checkout to this commit 28d411bc032d28fce95188bbb21aeaa8be147677
$ pmbootstrap flasher flash_rootfs
== Bootloader original status ==
*The bootloader in new Xiaomi devices are locked. To unlock it, you need to go to https://en.miui.com/unlock/download_en.html and follow the instructions as given.
== See Also ==
* GSMArena page
* Initial merge request
* 2nd attempt merge request
Xiaomi Redmi 4X (xiaomi-santoni)

== Contributors ==
* pinoaffe
* asriel-danctnix
* Danct12
== Maintainer(s) ==
* Danct12
== Users owning this device ==
== Components ==
Parts 	Components 	In Torvalds tree?
Chipset 	MSM8940 	No
GPU 	Adreno 505 	Yes (a5xx_gpu.c)
Touch Screen 	FT5X06 	Yes (edt-ft5x06.c)
Fingerprint Sensor 	FPC1020/Goodix 	No
Accelerometer + Gyroscope	ICM20607/BMI120	No/Yes (bmi160_i2c.c)
ALSPS 	STK3X1X 	Yes (stk3310.c)
Magnetometer 	YAS537 	Yes (yamaha-yas530.c)
Sound 	AW87319 	No
Notifications LED 	AW2013 	Yes (leds-aw2013.c)
Front Camera 	OV5675 	Yes (ov5675.c)
Back Camera 	S5K3L8 	No
== Bootloader Unlocking ==
Like other Xiaomi devices, the user will have to acquire the bootloader unlock key: https://en.miui.com/unlock
The device will not unlock if the device isn't 7 days old (from the time when your device connects to internet and powered on)
If unlock fails at "Can't get info", start unlock process, disconnect USB and reconnect it once the counter hits 99%.
== Key combinations for entering Recovery/Fastboot ==
=== Recovery ===
* Turn the device off (or restart also works)
* Hold both volume buttons (+ and -) and power button
* Keep holding until you got to recovery.
=== Fastboot ===
* Same as recovery, but this time hold the volume down key instead of both keys.
== Installation ==
* Follow the Installation guide
$ pmbootstrap init # choose Vendor: qcom Device codename: msm89x7
$ pmbootstrap install
$ pmbootstrap flasher flash_lk2nd
$ pmbootstrap flasher flash_rootfs
== Serial Connection (UART)==
The Serial Connection of the santoni has been tested only on reception mode, with 3.3v TTL to USB FT232RL. This example is an output when starting to fastboot.
Warning: the test point is very small, try to solder only if you're an expert on soldering or you may break the motherboard wirings.
Wiring: (Santoni TX --> FT232RL RX) and (Santoni GND --> FT232RL GND)
File:santoni-uart-1.png|frame|left|UART connected to GPIO 4,5
File:santoni-uart-2.png|frame|left|UART connected to GPIO 4,5
File:santoni-uart-3.png|frame|left|UART connected to TP29 (TX) and TP30 (RX)
File:santoni-uart-4.png|frame|left|Location of TP29 on front side of motherboard
File:santoni-uart-5.png|frame|left|Location of TP30 on front side of motherboard
File:santoni-uart-6.jpg|frame|left|Location of TP29 and GND
File:santoni-uart-7.jpg|frame|left|Example of connection, in this case RX is not used.
File:santoni-uart-8.jpg|frame|left|All the wiring done.
== Photos ==
File:Pmos_msm-318_santoni.png|thumb|left|Weston with msm-3.18 upstream kernel
File:Santoni-chargingsdl.png|thumb|left|charging-sdl on Xiaomi Redmi 4X
File:Youtube-santoni.jpg|thumb|left|YouTube on Redmi 4X
File:Santoni_mainline_boot_log.jpg|thumb|left|Redmi 4X booting mainline kernel
== See also ==
* GSMArena page
* Official TWRP image for Redmi 4X (santoni)
* Xiaomi Redmi 4X Official Kernel Source
* Pull request !335 for osk-sdl
* Arch Linux on Santoni with 3.18 kernel (historic)
Category:Devices with known UART pinout
Xiaomi Redmi 4 Standart (xiaomi-prada)

== Installation ==
* Follow the Installation guide
$ pmbootstrap init # choose Vendor: qcom Device codename: msm89x7
$ pmbootstrap install
$ fastboot flash boot lk2nd.img # Build it from msm8916-mainline/lk2nd
$ pmbootstrap flasher flash_rootfs
== Device Notes ==
=== Sensors ===
Connected to i2c-gpio
Sensor 	Model 	Status
Accelerometer/Gyroscope	bosch,bmi120 (bosch,bmi160) 	Works
Light/Proximity 	liteon,ltr559 (liteon,ltr501)	Works
Magnetometer 	yamaha,yas537 (yamaha,yas530)	Works
=== UART ===
The working voltage is 1.8 V.
Warning: the test points are very small, soldering is not recommended. It's probably better to just hold a wire with a hard thin end with your hands.
== How to enter flash mode ==
[Power] + [Vol-] to fastboot mode
== Users owning this device ==
== Maintainer(s) ==
* User:NekoCWD
== See also ==
* mainline kernel sources
* lk2nd sources
Category:Devices with known UART pinout
Xiaomi Redmi 5A (xiaomi-riva)

== Contributors ==
* Barnabas Czeman
== Maintainer(s) ==
* Barnabas Czeman
== Users owning this device ==
== How to enter flash mode ==
 Shutdown the phone completely
 Hold and until fastboot logo
== Installation ==
* Follow the Installation guide
$ pmbootstrap init # choose Vendor: qcom Device codename: msm89x7
$ pmbootstrap install
$ pmbootstrap flasher flash_lk2nd
$ pmbootstrap flasher flash_rootfs
=== Wifi ===
To connect to a wifi network simply run:
$ sudo nmtui
And connect to your prefered wifi network using the terminal UI.
Note: Use the wlan0 interface.
== Notes ==
- Some desktop environment will result in a blank. LXQT or SXMO UI is Recommended to use.
- KDE Mobile DE may be struggling running on this device
== See also ==
* Initial merge request
* Specs on GSMArena.com
* 
* 
*
Xiaomi Redmi 5 (xiaomi-rosy)

== Status ==
Got lk2nd running.
== Maintainer(s) ==
* Bczeman
== Contributors ==
== Users owning this device ==
== Installation ==
* Follow the Installation guide
$ pmbootstrap init # choose Vendor: qcom Device codename: msm8953
$ pmbootstrap install
$ pmbootstrap flasher flash_lk2nd
$ pmbootstrap flasher flash_rootfs
== See also ==
* Initial merge request
* Mainline kernel source
* 
*
Xiaomi Redmi 5 Plus (xiaomi-vince)

== Maintainer(s) ==
* M0Rf30
== Users owning this device ==
== Installation ==
* Follow the Installation guide
$ pmbootstrap init # choose Vendor: qcom Device codename: msm8953
$ pmbootstrap install
$ pmbootstrap flasher flash_lk2nd
$ pmbootstrap flasher flash_rootfs
=== How to enter flash mode ===
* Stock Fastboot: Power on the device with both and buttons
* lk2nd Fastboot: Power on the device. After it vibrates, hold 
* Recovery: Power on the device with both and buttons
== Audio ==
Speaker is not supported yet.
== Parts ==
=== Modem ===
Modem works with ipa-lite since 6.7.0
=== Smart Speaker ===
To use the speaker, the device relies on:
Vendor 	Model
Texas Instruments	tas2557 (some useful commits 1
2)
Seems to be very similar to tas2559
=== Fingerprint ===
Two drivers are available within downstream kernel.
These are not supported yet in mainline kernel.
Vendor 	Model
Fingerprint Cards AB	FPC1020 (some useful commits 12)
Goodix 	GF3208
=== Sensors ===
Type 	Vendor 	Model
Accelerometer / Gyroscope	STMicroelectronics	LSM6DSL (on some variants) 1
Accelerometer / Gyroscope	Bosch 	BMI120 (on some variants) 1
Magnetometer / Compass 	Asahi Kasei 	AK09918C 1
Ambient Light / Proximity	Liteon Opto 	LTR579 ALS / PS (same ALS registers of Liteon LTRF216A 1 with no PS part)
Hall 	ROHM Semiconductor	BU52061NVX (works as gpio key)
=== Touchscreen ===
Type 	Vendor 	Supported
RMI4 	Synaptics	Yes
NT36672	Novatek 	Partially (disabled in dts)
NT36672 can be enabled from lk2nd, manual build is needed.
https://github.com/msm8916-mainline/lk2nd/blob/main/lk2nd/device/dts/msm8953/msm8953-xiaomi-vince.dts#L23-L47
//touchscreen-compatible = "syna,rmi4-i2c";
touchscreen-compatible = "novatek,nt36525-i2c";
== Serial UART ==
Getting UART output on this device should be pretty straightforward, because pins for serial transfer (TX and RX) are exposed directly on motherboard and are even labeled.
See also: Serial debugging
== See also ==
* Initial merge request
* ALSA msm8953-snd-card-mtp UCM
* Mainline kernel source
* Downstream kernel source
* 
* 
* 
Category:Devices with known UART pinout
Xiaomi Redmi 6A (xiaomi-cactus)

== Contributors ==
* jdr
== Maintainer(s) ==
* jdr
== Users owning this device ==
== How to enter flash mode ==
* Shutdown the phone completely
* Press Volume down(-) and Power button simultaneously to enter the fastboot mode.
== Bootloader original status ==
*The bootloader in new Xiaomi devices are locked. To unlock it, you need to go to https://en.miui.com/unlock/download_en.html and follow the instructions as given.
== Installation ==
The following steps boots postmarketOS.
* pmbootstrap flasher flash_rootfs
* pmbootstrap flasher flash_kernel
* pmbootstrap flasher boot
== Plasma Mobile ==
Need to modify the file /usr/bin/startplasmamobile
Add --framebuffer --fb-device /dev/fb0 to arguments of startplasma-wayland
Like this:
startplasma-wayland --framebuffer --fb-device /dev/fb0 --xwayland --lockscreen --inputmethod maliit-keyboard --exit-with-session=/usr/lib/libexec/startplasma-waylandsession
This ensures that the Plasma Mobile is rendered using a frame buffer.
== Current boot status ==
Currently (Linux 4.9.117, edge, 01 Nov 2023) on Plasma Mobile (both using framebuffer and not), Gnome Mobile and Phosh phone boots up, successfully shows loading animation, resizes system partition on first boot, starts SSHd (so you can SSH into) but after that loading animation stops and desktop environment doesn't show up.
Xfce4 works out-of-the-box.
Here is an output of startplasma-wayland:
qt.qpa.wayland: Creating a fake screen in order for Qt not to crash
The Wayland connection broke. Did the Wayland compositor die?
The Wayland connection broke. Did the Wayland compositor die?
kdeinit5: Communication error with launcher. Exiting!
Error: could not determine $DISPLAY.
Error: Can not contact kdeinit5!
org.kde.startup: "kdeinit5_shutdown" () exited with code 255
startplasma-wayland: Shutting down...
startplasmacompositor: Shutting down...
startplasmacompositor: Done.
== See also ==
* Kernel Source Code
* Initial merge request
Xiaomi Redmi 6 (xiaomi-cereus)

== Contributors ==
* jerin
== Maintainer(s) ==
* jerin
== Users owning this device ==
== How to enter flash mode ==
* Shutdown the phone completely
* Press Volume down(-) and Power button simultaneously to enter the fastboot mode.
* To enter BootROM mode, press and hold all buttons together, for mtkclient flashing.
== Bootloader original status ==
* The bootloader in new Xiaomi devices are locked. To unlock it, you need to go to https://en.miui.com/unlock/download_en.html and follow the instructions as given.
* A token from the the official unlock tool is required for some devices, unlocking via mtkclient does not work to the token verified not being present in devinfo partition. See bkerler#mtkclient#110 
== Installation ==
The following steps boots postmarketOS.
$ pmbootstrap flasher flash_rootfs
$ pmbootstrap flasher flash_kernel
== Plasma Mobile ==
WIP
== See also ==
* Kernel Official Source (same as cactus)
* Kernel Source (with history) 
* Initial merge request:
Xiaomi Redmi 7A (xiaomi-pine)

== Contributors ==
* Hitechshell
== Users owning this device ==
== How to enter flash mode ==
* Fastboot: Power on the device with both and buttons.
* Recovery: Power on the device with both and buttons; and while holding , release .
== lk2nd ==
lk2nd is supported with msm8916-mainline/lk2nd for installation custom dtbo.img is needed.
Prebuilt images can be found here https://github.com/barni2000/dtbo-lk2nd/releases
$ fastboot flash dtbo dtbo-xiaomi-pine.img
$ fastboot flash boot lk2nd.img
== Installation ==
Use pmbootstrap to build your own installation image.
$ pmbootstrap init
$ pmbootstrap flasher flash_kernel
$ pmbootstrap flasher flash_rootfs --partition userdata
== Working UIs ==
* i3 (i3wm)
* LXQt
* MATE
* Plasma (plasma-desktop)
* SXMO (dwm)
* Xfce4
== Rotate screen ==
create file /etc/X11/xorg.conf.d/00-display-rotate.conf
and put this 
Section "Device"
 Identifier "LCD"
 Option "Rotate" "CW"
EndSection
also for rotate touchscreen you need to create udev file:
/etc/udev/rules.d/98-touchscreen-cal.rules
ATTRS{name}=="fts_ts", ENV{LIBINPUT_CALIBRATION_MATRIX}="0 1 0 -1 0 1"
== See also ==
* Initial merge request
* TWRP for Xiaomi SDM439 Devices
* Lineageos wiki page
* lk2nd
Xiaomi Redmi 7 (xiaomi-onclite)

== Maintainer(s) ==
* Bczeman
== Users owning this device ==
== How to enter flash mode ==
Volume Down + Power boots the phone into fastboot mode.
== Installation ==
Follow the usual Installation guide but stop before flashing.
Download dtbo.img here. Enter fastboot mode and and flash the downloaded image to the dtbo partition:
$ fastboot flash dtbo dtbo.img
$ pmbootstrap init # choose Vendor: qcom Device codename: msm8953
$ pmbootstrap install
$ pmbootstrap flasher flash_lk2nd
$ pmbootstrap flasher flash_rootfs
== Mainline Status ==
=== What works ===
* Jack Detection (Headset Mic detection is not working)
* Touch (focaltech only)
* leds
* USB
* GPU
* Wifi/BT
* Buttons
* SD Card Reader
* Haptics
=== Partial ===
* Mobile data
=== Modem ===
Modem works since 6.7.2
==== Display ====
Texas Instruments TPS61163A display regulator is not supported.
==== Audio ====
awinic aw87329 speaker codec driver is missing. Maybe it could be applied from downstream.
=== Not works ===
* Charging (missing charging driver)
* Battery (missing driver, there is a WIP driver)
* Sensors (waiting for new smgr driver, needs some trace from android)
* OTG not works
== See also ==
* Kernel source
* 
* 
*
Xiaomi Redmi 9C (xiaomi-angelica)

== Contributors ==
== Users owning this device ==
== How to enter flash mode ==
=== Bootloader Unlocking ===
Like other Xiaomi devices, the user will have to acquire the bootloader unlock key: https://en.miui.com/unlock
The device will not unlock if the device isn't 7 days old (from the time when your device connects to internet and powered on, and linked with Mi Account)
=== Recovery mode ===
* Turn the device off (or restart also works)
* Hold and button
* Once you feel vibration and phone turns on, release button
* Keep holding until you get to recovery.
=== Flashing (Download, Fastboot) mode ===
* Same as recovery, but this time hold the and keys.
== Installation ==
== See also ==
Xiaomi Redmi 9 (xiaomi-lancelot)

Currently touch screen is not working on these device as only the button devices seem to emit events.
== Contributors ==
* koutakun
== Maintainer(s) ==
== Users owning this device ==
== How to unlock phone ==
https://wiki.lineageos.org/devices/lancelot/install#unlocking-the-bootloader (requires windows only application).
NOTE: apps allows to install correct drivers for fastboot.
== How to enter flash mode ==
Power + volume down while it is off, then you can flash it using pmbootstrap flasher flash_kernel; pmbootstrap flasher flash_rootfs --partition=super; pmbootstrap flasher flash_vbmeta (must be OEM unlock for this, see above).
NOTE: Fastboot entered via on my phone, fastboot entered via adb reboot fastboot run into different fastboot implementation (showed blue word FASTBOOTD instead of orange FASTBOOT), which did not have implemented certain oem commands, the log from windows application showed error when running fastboot oem device-info command.
Xiaomi Redmi Note 12 Pro (4G) (xiaomi-sweet k6a)

== Contributors ==
* vilez
== Maintainer(s) ==
* vilez
* Largely the sm7150-mainline team
== Users owning this device ==
== Port status ==
Mainline kernel boots but touchscreen dont work properly
== Flash modes ==
* Fastboot mode: + (adb reboot bootloader)
* Fastbootd mode: adb reboot fastboot
* Recovery mode: + (adb reboot recovery, fastboot reboot recovery)
=== Other ===
* Mainline kernel fork: https://github.com/sm7150-mainline/linux
* Pmaports fork: https://github.com/sm7150-mainline/pmaports
Xiaomi Redmi Note 3 (xiaomi-kenzo)

= How to install =
== Fastboot Mode ==
Hold down and buttons simultaneously for a few seconds, until Fastboot Mode screen appears.
== Installation ==
First build the image:
$ pmbootstrap init
$ pmbootstrap install
Then in order to flash it put your device in fastboot mode, and plug it in USB. Then do:
$ pmbootstrap flasher flash_rootfs
$ pmbootstrap flasher flash_kernel
To connect to a Wi-Fi network simply run:
$ sudo nmtui
And connect to your prefered wifi network using the terminal UI.
== UI options ==
Nothing works, even console.
= Community info =
== Maintainers ==
* None
== Old maintainers ==
* IdanHoro
== Users owning this device ==
== See also ==
* Initial merge request
* 
* 
* 
* Proprietary vendor blobs
Xiaomi Redmi Note 4G (xiaomi-dior)

== Contributors ==
* Edwin0cheng
== Maintainer(s) ==
== Users owning this device ==
== How to enter flash mode ==
* Entering fastboot: hold + buttons until fastboot mode is displayed on the screen.
* Entering recovery: hold + buttons. The default is Mi Recovery. TWRP is needed for installation, which can be obtained here
== Installation ==
To flash this device, the boot partition have to be flashed by fastboot:
:$ pmbootstrap export
:$ fastboot flash:raw boot /tmp/postmarketOS-export/boot.img-xiaomi-dior
However, rootfs could be flash by pmbootstrap normally:
:$ pmbootstrap flasher flash_rootfs
And its system partition is quite small (800mb), to flash a large distribution (e.g. xfce4), you have to:
1. Split the boot and root partitions (hint: you can use pmbootstrap install --split instead of losetup tricks):
sudo losetup /dev/loop0 /tmp/postmarketOS-export/xiaomi-dior.img
sudo dd if=/dev/loop0p1 of=boot_partition.img
sudo dd if=/dev/loop0p2 of=root_partition.img
sudo losetup -d /dev/loop0
2. Flash the boot partition to system partition:
:$ fastboot flash system boot_partition.img
3. Use the netcat method to flash to user partition:
https://gitlab.postmarketos.org/postmarketOS/pmbootstrap/-/issues/456
== Additional info ==
This original implementation of framebuffer device do not support framebuffer console and X-Windows, we patched all missing pieces such that it works. So xfce4 and FbKeyboard works now. 
However, due to lacking of DRM driver, all drm related UI are not workings.
== See also ==
* Initial merge request
Xiaomi Redmi Note 4 (MediaTek) (xiaomi-nikel)

== Contributors ==
* User:InfiniteCoder
== Users owning this device ==
== How to enter flash mode ==
=== Bootloader Unlocking ===
Like other Xiaomi devices, the user will have to acquire the bootloader unlock key: https://en.miui.com/unlock
The device will not unlock if the device isn't 7 days old (from the time when your device connects to internet and powered on, and linked with Mi Account)
=== Recovery mode ===
* Turn the device off (or restart also works)
* Hold and button
* Once you feel vibration and phone turns on, release button
* Keep holding until you get to recovery.
=== Flashing (Download, Fastboot) mode ===
* Same as recovery, but this time hold the and keys.
=== BROM mode ===
* Turn the device off (or restart also works)
* Recommended to disconnect the battery
* Hold and buttons
* Connect USB. You might also need to press and hold 
From there can be flashed with SP Flash Tool or mtkclient without even unlocking the bootloader
== Installation ==
== See also ==
* GSMArena page
* XDA forum
* Only known working kernel source
* Lineage OS kernel and RC files
Xiaomi Redmi Note 4 (xiaomi-mido)

== Maintainer(s) ==
* User:Bczeman
== Contributors ==
* User:Kiciuk
== Users owning this device ==
== Device Notes ==
=== Touchscreen ===
* focaltech variant is enabled.
* goodix variant is added but disabled in dts. For enable custom lk2nd build is needed and goodix touchscreen-compatible should be selected. https://github.com/msm8916-mainline/lk2nd/blob/main/lk2nd/device/dts/msm8953/msm8953-xiaomi-common.dts#L73-L92.
// touchscreen-compatible = "edt,edt-ft5406";
touchscreen-compatible = "goodix,gt917d";
=== Modem ===
Modem works with ipa-lite since 6.7.2, but mobile data is not working on all variants yet, calls and sms are working.
=== Display Panels ===
LCD Vendor 	IC Vendor 	Supported?
BOE 	Novatek NT35532 	Yes
Tianma 	Novatek NT35596 	Yes
Tianma 	otm1911 	Yes
BOE 	IlItek ili9885 	Need testing
EBBG(Foxconn)	Synaptics r63350	Yes
=== Camera ===
Camera Sensor 	Package vendor 	Supported?
Sony IMX258 	Ofilm/qtech/sunny	imx258.c in mainline - need testing
Samsung S5K3L8 	Ofilm/qtech/sunny	It was added to 6.7.5 and configuration is merged in megapixels.
Samsung S5K5E8 	Ofilm/qtech/sunny	No support for now
Omnivision ov13855	Ofilm/qtech/sunny	No support for now
=== Battery ===
Battery Vendor 	Supported?
Desay lisheng 4v4	Yes
Sunwooda atl 	Yes
=== Sensors ===
Bosch BMI160 is supported since 6.6.8
All sensors are handled by remote processor and exposed via QMI, they all will work once proper driver lands in mainline.
=== IR led ===
IR led support is landed in 6.7.2.
It can be used with: # ir-ctl -S rc5:0x1e01
=== GPS ===
Qualcomm_Snapdragon_450/625/626/632_(MSM8953)#GPS
== Installation ==
* Follow the Installation guide
$ pmbootstrap init # choose Vendor: qcom Device codename: msm8953
$ pmbootstrap install
$ pmbootstrap flasher flash_lk2nd
$ pmbootstrap flasher flash_rootfs
=== How to enter flash mode ===
* Stock Fastboot: Power on the device with both and buttons
* lk2nd Fastboot: Power on the device. After it vibrates, hold 
* Recovery: Power on the device with both and buttons
== Focaltech touch buttons ==
Touchscreen reports buttons as ABS_X values. 
You can map it to key events via python script
== See also ==
* Kernel source
* 
* 
*
Xiaomi Redmi Note 5A

== Contributors ==
* Flafflar
== Users owning this device ==
== Installation ==
* Follow the Installation guide
$ pmbootstrap init # choose Vendor: qcom Device codename: msm89x7
$ pmbootstrap install
$ pmbootstrap flasher flash_lk2nd
$ pmbootstrap flasher flash_rootfs
== How to enter flash mode ==
While the phone is off, hold the + buttons together for a few seconds.
== How to enter EDL mode ==
EDL mode (Emergency Download Mode) is a special mode in Qualcomm devices that allows, among other things, flashing firmware even when the phone is completely bricked. This might come useful in case something goes extremely wrong and the device won't even boot to fastboot.
To boot into EDL, you must first disassemble the device in order to expose the motherboard points required. This phone is very easy to disassemble, you can search for videos on YouTube if necessary. Once you have removed the back case and disconnected the battery, find the points shown below on the motherboard:
These are the test points that enable EDL mode. With the battery disconnected, use a metal tweezer or a small wire to short these two points. While keeping them sorted, plug the phone to a computer. The device should show up as "Qualcomm HS-USB QDLoader 9008". You can now use this tool to download firmware to your device.
== See also ==
* 
*