nyuuzyou/wikis huggingface dataset:
Kobo Clara 2E (kobo-clara2e)

== Contributors ==
* Andi
== Users owning this device ==
== How to enter flash mode ==
== Installation ==
An original Kobo Clara 2E SD card or a copy (e.g. via dd) is recommended. The unpartitioned space at the beginning of the SD card contains the E-ink panel waveform information. This information is device batch specific and is copied to /lib/firmware/imx/epdc/epdc.fw on boot.
Replacing internal µSD
Internal µSD card can be replaced by something bigger.
A recommended practice to install software is to clone the SD card and keep the old one as backup or have at least the hidden waveform partition in place. before doing pmbootstrap install
So basically pull out µSD and connect to your PC and do:
 dd if=/dev/sdX of=clara2e-backup.img
replace with something bigger (in reality only the waveform is needed but for simplicity) and do:
 dd if=clara2e-backup.img of=/dev/sdX
and then use that sdcard with pmbootstrap install --sdcard
== Variants A/B ==
There are two variants of the device differencing in the PMIC used for the display. A has SY7636 and B has JD9930.
The latter does not store the Vcom voltage needed contrary to the chips in the other ebook readers which
all store the volatge non-volatile. The voltage differs a bit per device batch.
== Bluetooth/WLAN ==
Bluetooth depends on the resources being enabled by the WLAN driver.
== See also ==
Kobo Glo HD (kobo-glo-hd)

== Status ==
Working on mainlining here
Analysis of original software: this device is shipped with Linux 3.0.35, which may be acceptable to port. However, the mainlining effort mentioned above as well as the successful mainline port of the Kobo Clara HD (kobo-clara) shows promise for this device. This device is also shipped with u-boot 2009.08, which is extremely old, meaning that we will likely need to mainline u-boot support. Some work has been started here which is heavily based on the work already done on the Kobo Clara HD. There are reports of having the Tolino Shine 2HD u-boot pmaport worked (which is 2020.10 based). 
== See also ==
* u-boot and kernel source
* blog with hw details info
== Almost identical device ==
* Tolino_Shine_2HD_(tolino-shine2hd) - has the same chipset (Freescale i.MX6 Solo Lite) and boots with the original Kobo Glo HD SD card, according to this blog post (in German). it also has a mainlined dts. PostmarketOS images for that device seem to basically work here.
** Differences seen: less buttons, according to code analysis, led is at a different position.
Kobo Nia

== Contributors ==
* Andi
* Kuratius
== Users owning this device ==
* Kuratius
* Szybet
== Warning == 
There seem to be different versions out there, Kobo Nia Rev. A and Revision C.
Kobo Nia A is known to have issues with touchscreen reads if the data is read during a screen refresh; doing so introduces jitter and warps the coordinates in the corners towards the center. This makes it very hard to use onscreen keyboards for example.
It is currently not known if revision C has the same issue.
== Installation ==
An original Kobo Nia SD card or a copy (e.g. via dd) is recommended. The unpartitioned space at the beginning of the SD card contains the E-ink panel waveform information. This information is device specific and is copied to /lib/firmware/imx/epdc/epdc.fw on boot. See the for more information.
=== Replacing internal µSD ===
Internal µSD card can be replaced by something bigger. 
A recommended practice to install software is to clone the SD card and keep the old one as backup or have at least the hidden waveform partition in place. before doing pmbootstrap install
So basically pull out µSD and connect to your PC and do:
 dd if=/dev/sdX of=nia-backup.img
replace with something bigger (in reality only the waveform is needed but for simplicity) and do:
 dd if=nia-backup.img of=/dev/sdX
and then use that sdcard with pmbootstrap install --sdcard
== Hardware ==
=== Wireless ===
The Kobo Nia contains a wifi chip.
=== Display ===
=== USB ===
By default the USB port is in gadget mode. This enables rdnis (USB networking) and storage when plugged into a PC.
The USB can be changed to host mode, allowing a keyboard or storage to be plugged in. This requires a Micro USB OTG adapter. As root, you can change the USB role.
 echo gadget > /sys/bus/platform/devices/ci_hdrc.0/role
Note: For some devices, external power may be required via the USB adapter.
=== UART ===
== Software ==
=== GUI support ===
==== Display servers ====
==== Display managers ====
Note that this device is heavily RAM limited, even more so than the Kobo Clara. Most DEs will struggle.
==== Plasma Desktop ====
Does not run, looks like it's short on RAM.
==== Other ====
Mobile DEs need to be tested, but they likely require GPU acceleration.
== See also ==
=== Applications ===
* InkBox, Open-source Alpine based firmware for Kobo E-readers, mirror on Github.
=== Other ===
* Archived Kobo Firmware
* E-reader information
* Some installation notes/mainlining status information
* Electronic Paper Displays (EPD) / E-ink introduction
* E-ink waveforms
Kosagi Fernvale (kosagi-fernvale)

Available from sysmocom (commercial side of osmocom project): http://shop.sysmocom.de/products/fernvale-mt6260-reverse-engineering-development-kit-dvt2
Mediatek 6260 based board designed through reverse engineering efforts detailed here: https://www.bunniestudios.com/blog/?p=4297
MT6260 Datasheet available here: https://drive.google.com/file/d/14UcrFRB3rYW2bjttFZ7GA4zAi_HL-yjZ/view?usp=sharing
User:Unrznbl is working on porting osmocom-bb (open source 2G baseband firmware) to fernvale and other MT626x based devices such as DZ-09_Watch and SIM800_Modules.
==See also==
Offical Site
LETV U2 (letv-lba-011-hk)

== Contributors ==
== Users owning this device ==
==Current State==
Non-Booting Device
== How to enter flash mode ==
== Installation ==
== See also ==
== Pictures ==
File:Back of letv-lba-011-hk.jpeg|thumb|left|Back of letv-lba-011-hk
File:Front pcb of letv-lba-011-hk.jpeg|thumb|left|Front pcb of letv-lba-011-hk
File:Back pcb of letv-lba-011-hk.jpeg|thumb|left|Back pcb of letv-lba-011-hk(it has a custom power cable soldered.)
LG Bello II (lg-x150)

== Contributors ==
* MrHeating
== Maintainer(s) ==
== Users owning this device ==
== How to enter flash mode ==
Turn the device off and then press and hold and buttons until the selection appears. Select fastboot with and accept with .
== Installation ==
See #456 Alternative flasher method (using netcat).
Not all partitions can really be written to, even if there is enough space. I'm still figuring things out.
All other methods mentioned in Porting documentation (05.03.2020) worked so far. NFS not tested.
== See also ==
* Initial merge request
LG Fx0 (lg-madai)

LG Fx0, also known as LGL25, is a smartphone manufactured by LG Electronics. Fx0 was originally available only in Japan, sold by KDDI. The hardware is similar to LG G2 mini (lg-g2m) while Firefox OS is pre-installed instead of Android.
There are two known versions of Fx0. The original, SIM-locked and non-rooted version was available from the official sales channel. Later, the SIM-free and rooted version appeared in aftermarket. The rooted (SIM-free) version is strongly recommended if you try postmarketOS on Fx0.
== Contributors ==
* peremen
* MasanoriOgino
== Users owning this device ==
== How to enter flash mode ==
To enter the LG download mode, unplug the device from the USB, power off, and hold while connecting to the USB . You will see the DOWNLOAD MODE line if succeeded.
If lk2nd is installed, hold while booting to enter fastboot mode. Note that you can enter the LG download mode even if lk2nd is installed.
== Installation ==
You need to erase the LAF partition to enable the LG download mode. Given that there is no KDZ or TOT file for this device available, it does not make sense to keep the LAF partition for flashing.
To backup the LAF partition, you need a working su on the device. On adb shell:
$ su
# dd if=/dev/block/platform/msm_sdcc.1/by-name/laf of=/sdcard/laf.img
# dd if=/dev/zero of=/dev/block/platform/msm_sdcc.1/by-name/laf
Then, on the host:
$ adb pull /sdcard/laf.img
Now, you can enter the LG download mode. While it provides some fastboot commands, it is unstable and lacks important features. lk2nd provides a more stable and full-fledged fastboot implementation. Download lk2nd-msm8226.img from the latest release of lk2nd.
We recommend to backup the boot partition before installing lk2nd.
$ # On adb shell:
$ su
# dd if=/dev/block/platform/msm_sdcc.1/by-name/boot of=/sdcard/boot.img
$ # On the host:
$ adb pull /sdcard/boot.img
Then, enter the LG download mode and flash lk2nd.
$ fastboot flash boot lk2nd-msm8226.img
$ fastboot reboot
You should backup the system and userdata partitions, at least.
$ fastboot fetch system system.img
$ fastboot fetch userdata userdata.img
Read and follow the general installation guide to continue installation.
== Components ==
* UART: According to service manual UART is provided as a part of JTAG connector, unpopulated by default and only accessible after opening the case. The Pin 14 (lower right, bigger pad than others) is MSM_UART_TX, which needs to be hooked up to the RX of the UART adapter.
* Wi-Fi: Qualcomm WCNSS. Note that the LG source code archive lacks the prima driver, which is used in Firefox OS. According to dmesg in Firefox OS, it is version v3.2.3.172. Porting the prima driver from LineageOS kernel makes Wi-Fi work, but it seems that NetworkManager seems not like this configuration.
* Display: no backlight adjustment yet, also had to change the visual to RGB565 to get a working Xfce4.
* Given the sorry quality and lower version of stock LG kernel, maybe mainlining could be worth?
== See also ==
* 
* 
* Kernel source (mirrored from LG OSS Center when it was alive)
LG G2 mini (lg-g2m)

== Users owning this device ==
== How to enter flash mode ==
* Recovery mode: Power on the device by holding and , once the screen turns on release the buttons and hold them again shortly after. Select "Yes" at the factory reset screen. If you have TWRP installed it won't actually wipe your phone. 
* Download/Bootloader mode: Hold down and connect the device to a computer with a USB cable while it is in a powered off state. If you erased the laf partition the phone will boot into fastboot mode.
== Unlocking the bootloader ==
 
# Make sure you are on Android Lolipop firmware (V20b tested). A link to the firmware can be found here
# Download and install bkerler's EDL tool from here or clone it like below. The latest master branch does not work for this phone, so we reset working commit d5ff2d4
#:
$ git clone https://github.com/bkerler/edl.git && cd edl
$ git reset --hard d5ff2d474a185a0c0df09c74dfa24eb7cfe6e9e5
# Download necessary files for unlocking the bootloader from here
# Reboot to EDL from Android
#:
$ adb reboot edl
# Dump all partitions from the phone and back it up. You can delete userdata.bin to save space on your computer
#:
$ edl rl dump_lg-g2m --genxml
# Write the patched aboot to the phone with files from the GitHub repo
#:
$ edl w aboot aboot_d620r_patched.bin --memory emmc --loader 008050e100000000_cc3153a80293939b_fhprg.bin
# (Optionally) Flash TWRP
#:
$ edl w recovery twrp-3.1.1-0-g2m.img --memory emmc --loader 008050e100000000_cc3153a80293939b_fhprg.bin
# Reset the phone by removing the battery or with
#:
$ edl reset --loader 08050e100000000_cc3153a80293939b_fhprg.bin
== Installation ==
/* Not yet */
== See also ==
GSMArena page
LG G3 Beat (lg-d722)

This port is still in its very early stages.
== Contributors ==
* ckie
== How to enter flash mode ==
Press volume down and power button with the device initially off then release and hold again, accept the factory reset which will not actually run a factory reset if TWRP is installed.
 
== Installation ==
LG G3 Europe
== See also ==
* Initial merge request
* 
*
LG G4 International (lg-h815)

== Contributors ==
* kamnxt (Mostly on Reddit, u/kamnxt)
* maccraft123
* FuchtelJockel
== Maintainer(s) ==
* kamnxt
* FuchtelJockel
== Device owners ==
== What is TODO ==
* Identify and make use of UART(candidate is 3,5" jack)
* Mainline it
* test UsU Devices
== How to enter flash mode ==
On the v20p bootloader enter fastboot from TWRP or Android.
From Android:
* adb reboot bootloader
From TWRP:
# Press and hold both power and volume down buttons.
# After LG logo appears release the power button for one second then hold it again.
# If you have flashed TWRP on it, just ignore warnings about deleting data.
# After booting to TWRP choose "Reboot", then "Bootloader" options to enter fastboot mode
On the v29a bootloader:
# press volume down button
# plug in USB cable, keep holding volume down button
== Installation ==
* Unlock bootloader
* Build using pmbootstrap
* Enter fastboot on phone
$ pmbootstrap init
$ pmbootstrap install
$ pmbootstrap flasher flash_rootfs
$ pmbootstrap flasher flash_kernel
# fastboot reboot
== Feature matrix ==
 	Mainline kernel	Android kernel
Booting 	Working 	Working
USB Network 	Working 	Working
Flashing 	Working 	Working
Storage 	Working 	
Touchscreen 	 	Working
Display 	 	Partial
WiFi 	 	
XWayland 	 	Working
FDE 	 	
Battery 	 	Working
Hardware Acceleration	 	
Accelerometer 	 	
Audio 	 	
Bluetooth 	 	
Camera 	 	
GPS 	 	
Mobile data 	 	
SMS 	 	
Calls 	 	
USB OTG 	 	
== /sys tunables ==
/sys/class/graphics/fb0/blank
0 - Touchscreen enabled
1 - Touchscreen disabled
/sys/class/leds/lcd-backlight/brightness
0 - Screen at 0% of brightness
255 - Screen at 100% of brightness
== Photos ==
TODO
== Links ==
* Subreddit: reddit.com/r/lgg4
* XDA Forum: https://forum.xda-developers.com/g4
* LineageOS Kernel: https://github.com/LineageOS/android_kernel_lge_msm8992
* Almost-mainline Kernel: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/4344 (the initial MR)
LG G7 ThinQ (lg-judyln)

__NOTOC__
== Contributors ==
* Jenneron
* Newbyte
== Users owning this device ==
== Installation ==
See LG_V35_ThinQ_(lg-judyp)#Installation.
Alternatively, you can flash to the userdata partition but WARNING: this will erase your user data and likely make any Android installation installed on the other slot unusable.
This will probably boot/run faster and you won't need to use an SD card, but on the other hand if you do this it will be harder to make changes to the root filesystem whenever pmos won't boot.
You will likely have to use EDL to flash `boot.img` as fastboot does not seem to flash or boot (At least on my device)
$ # boot into fastboot mode
$ fastboot erase dtbo_b # or dtbo_a if you are using slot A but it probably matters little since we are about to overwrite userdata
$ pmbootstrap init
$ pmbootstrap install
$ # At this point you may want to edit your kernel config. 
$ # At the time of writing the "ipa" module (QCOM_IPA; Device Drivers -> Network device support -> Qualcomm IPA support) would crash my G7
$ pmbootstrap kconfig edit linux-postmarketos-qcom-sdm845 # optional
$ pmbootstrap build --force linux-postmarketos-qcom-sdm845 # only if you changed the config
$ pmbootstrap flasher flash_rootfs --partition userdata
$ pmbootstrap flasher flash_kernel --partition boot_b # or boot_a if you are using slot A
$ fastboot --set-active=b
$ fastboot reboot
== Support status ==
=== GPU ===
GPU is not working likely due to the lack of a display panel driver, Basic framebuffer works though.
== See also ==
* Close to mainline kernel with device-specific patches
== External Links ==
* Kernel sources
* Kernel package
* judyln device package
LG G8X ThinQ (lg-mh2lm)

== Contributors ==
* MollySophia
== Users owning this device ==
== Preparation ==
== Installation ==
$ fastboot erase dtbo_b # you can use dtbo_a for a slot
$ pmbootstrap init
$ pmbootstrap install --sdcard=/dev/sdX # where /dev/sdX is your SD card
$ # boot into fastboot mode
$ pmbootstrap flasher flash_kernel --partition boot_b # or boot_a
== See also ==
* GSMARENA
LG G Pad 8.3 LTE (lg-altev)

== Contributors ==
* JosiahWI
== Users owning this device ==
== How to enter flash mode ==
Does not have fastboot. There is a "download mode", but it is not fastboot and I cannot figure out what it does. Have not tried sideloading with recovery mode.
Enter download mode by simultaneously holding volume up and power buttons, then quickly plug in micro-USB while still holding buttons. Release buttons when download mode box appears on screen. It is not backlit much and may be hard to see.
== Installation ==
== See also ==
LG G Watch (lg-dory)

=== Contributors ===
* drebrez
== Device info ==
* Full phone specifications
== Additional info ==
=== Entering "Fastboot mode" ===
Turn on your watch and swipe from the top left corner (so that'd be where 11 would be on the watch) as soon as you see the LG logo.
=== Flash system image ===
It's important to remember to flash the system image to `userdata` as the system partition is not big enough for PostmarketOS.
pmbootstrap flasher flash_rootfs --partition userdata
=== Accelerometer ===
Enable the accelerometer with echo 1 > /sys/bus/i2c/drivers/lis3dsh_acc/4-001e/enable_device
Read accelerometer measurements with evtest /dev/input/event1
=== Partition layout ===
/ # fdisk -l
Found valid GPT with protective MBR; using GPT
Disk /dev/mmcblk0: 7634944 sectors, 3728M
Logical sector size: 512
Disk identifier (GUID): 98101b32-bbe2-4bf2-a06e-2bb33d000c20
Partition table holds up to 24 entries
First usable sector is 34, last usable sector is 7634910
Number Start (sector) End (sector) Size Name
 1 1024 3071 1024K sbl1
 2 3072 4095 512K rpm
 3 4096 5119 512K tz
 4 5120 6143 512K sdi
 5 6144 7167 512K aboot
 6 7168 9215 1024K sbl1b
 7 9216 10239 512K rpmb
 8 10240 11263 512K tzb
 9 11264 12287 512K abootb
 10 12288 16383 2048K imgdata
 11 16384 17407 512K metadata
 12 17408 50175 16.0M misc
 13 50176 82943 16.0M persist
 14 82944 127999 22.0M laf
 15 128000 173055 22.0M boot
 16 173056 218111 22.0M recovery
 17 218112 219135 512K ssd
 18 219136 220159 512K DDR
 19 220160 744447 256M system
 20 744448 1268735 256M cache
 21 1268736 7633919 3108M userdata
 22 7633920 7634910 495K grow
== Links ==
* 
* 
* Android Wear 6.0.1 Release 0.1 Kernel
* AsteroidOS device page
== Photos ==
File:LG_G_Watch_Dory_-_weston.jpg|thumb|left|postmarketOS demo menu (XWayland)
LG Joy (lg-h220)

== Contributors ==
* drebrez
== Maintainer(s) ==
* drebrez
== Additional info ==
=== Entering "Factory data reset mode" ===
# Turn off the device
# Press and hold + 
# Release when LG logo appears
# While still pressing , press and hold again
# Release when Factory Data Reset menu appears
=== Entering "LG Download mode" ===
# Turn off the device
# Press and hold 
# Connect the USB cable
# Release when Download mode appears
== Links ==
* Full phone specifications
LG K10 (lg-m216)

== Users owning this device ==
== Unlocking the bootloader ==
# Clone this repository that includes LGLAF script for communication with LG devices in download mode (make sure to enable developer mode first from android).
# Follow instructions listed in lglaf github page, power off the device and enter download mode connecting device via USB as peripheral while holding button.
# Download aboot_patched.img from here and flash it to aboot partition, running the following commands in a terminal:
 $ cd lglaf && python partitions.py --wipe aboot
 $ python partitions.py --restore /path/to/aboot_patched.img aboot
# Power off the device and download TWRP from here. Then, enter download mode again as shown above and flash TWRP image to recovery partition, running the following commands in a terminal:
 $ cd lglaf && python partitions.py --wipe recovery
 $ python partitions.py --restore /path/to/twrp-3.5.2_9-0-m216.img recovery
# After turning off the device, you can enter recovery mode holding + until the LG logo appears, then release both and press them again. Finally, choose Yes twice in the next screens. Once TWRP screen appears, you'll be able to flash bootloader images using this known custom recovery.
== How to enter flash mode ==
Once lk2nd image has been flashed to boot partition using TWRP, you can get to flash mode just turning the device on. The screen should display lk2nd menu.
== Mainline installation ==
Follow the Installation_guide.
Download lk2nd from https://github.com/msm8916-mainline/lk2nd and flash it to the device.
Follow Qualcomm_Snapdragon_410/412_(MSM8916)#Installation.
== See also ==
* Initial merge request
* Development kernel tree
LG K40 AT&T (lg-mmh4x)

== Contributors ==
* BenTheTechGuy
== Users owning this device ==
== How to enter flash mode ==
The LG K40 doesn't have a useful recovery mode (it's just a factory reset button), and fastboot doesn't exist at all on the device; the only useful mode is Download Mode, but that requires a signed image to flash.
Luckily, the mtkclient tool can make use of vulnerabilities in the MediaTek SoC itself in order to unlock the bootloader and flash images. In the below examples, the command mtk is used, but if you installed from source, you'll need to run python mtk inside the repo.
To enter into a mode that mtkclient can be used in, follow these steps:
# Power off the device.
# Run an mtkclient command, like mtk printgpt.
# While mtkclient waits for the device, hold and plug it into the computer.
# mtkclient should output a lot of text at this point. The button can be released.
# As long as mtkclient did its job properly, the command will succeed. Now, other commands can be run with mtkclient.
== Unlocking the bootloader ==
# Enable developer options, and OEM Unlocking from there.
# Follow the steps in #How to enter flash mode.
# Erase the userdata partition: mtk e metadata,userdata,md_udc
# Unlock the bootloader: mtk da seccfg unlock
# Reset mtkclient: mtk reset
# The bootloader should now be unlocked. From here, the device can be unplugged and powered on to go through setup.
== Installation ==
# Run pmbootstrap init. DRM is not supported yet, so Xfce4 is the best graphical option for now.
# Run pmbootstrap install.
# Follow the steps in #How to enter flash mode.
# Run pmbootstrap flasher flash_kernel.
# Run pmbootstrap flasher flash_rootfs.
== Status ==
What doesn't work:
* WiFi: Haven't attempted to figure out how MTK's proprietary WiFi setup works on MT6765. Hoping the mainline effort gets there first.
* Modem: Same
* FDE: osk-sdl crashes with the following message and the device reboots: ERROR: Mode 720 x 1440 not available: f (!!!) *** UNIMPLEMENTED [fusion_get_fusionee_pid] *** [fusion.c:4147](*) FBDev/Mode: Setting 720x1440 RGB32 When set to use a 16 bit pixel format, osk-sdl hangs before it can reach this point, and the screen shows a corrupted version of its previous contents. The device reboots shortly after.
* Battery: Always reports 0; the device will reboot after a short time if not plugged in, even if the battery is full.
* Sensors: Not detected and don't know where to start getting it working.
== See also ==
* Initial merge request
* 
* 
* Device Info