Jump to content

BQ Aquaris X5 (bq-paella): Difference between revisions

From postmarketOS Wiki
Lazzardo (talk | contribs)
No edit summary
Al3x (talk | contribs)
bq-paella: Remove video tutorial (outdated and private)
 
(78 intermediate revisions by 20 users not shown)
Line 2: Line 2:
| manufacturer = BQ
| manufacturer = BQ
| name = Aquaris X5
| name = Aquaris X5
| codename = bq-picmt, bq-paella
| codename = bq-paella
| image = File:bq-picmt.jpg|thumb|133px
| image = File:P_20200429_093001.jpg|thumb|133px
| imagecaption = BQ Aquaris X5 Cyanogen Edition running weston on postmarketOS downstream
| imagecaption = BQ Aquaris X5 running Plasma Mobile on postmarketOS mainline
| releaseyear = 2015
| releaseyear = 2015
| originalsoftware = Android 7.1.2, CM 13.1
| category = community
| chipset = Qualcomm MSM8916T Snapdragon 412
| originalsoftware = Android (CyanogenOS)
| originalversion = 5.1 (CyanogenOS 12.1)
| chipset = Qualcomm Snapdragon 412 (MSM8916v2)
| cpu = Quad-core 1.4 GHz Cortex-A53
| cpu = Quad-core 1.4 GHz Cortex-A53
| gpu = Adreno 306
| gpu = Adreno 306
Line 13: Line 15:
| display = 720 x 1280 (IPS LCD capacitive touchscreen, 16M colors)
| display = 720 x 1280 (IPS LCD capacitive touchscreen, 16M colors)
| memory = 2GB / 3GB
| memory = 2GB / 3GB
| architecture = armv7
| architecture = aarch64
<!-- the following status_* questions should be answered with Y - yes, P - partial, N - no, or left blank (for untested or unknown) -->
| type = handset
| status_usbnet = Y
| status_usbnet = Y
| status_flashing = P
| status_flashing = Y
| status_touch = P
| status_touch = Y
| status_screen = Y
| status_screen = Y
| status_wifi = Y
| status_wifi = Y
| status_xwayland = <!-- Showing X11 applications in a Wayland compositor (Weston, KWin, ...) works? -->
| status_xwayland = Y
| status_fde = <!-- When installing with full disk encryption, can you type in the password with the on screen keyboard? -->
| status_fde = Y
| status_mainline = <!-- Instead of a Linux kernel fork, it is possible to run mainline. -->
| status_mainline = Y
| status_battery = <!-- Charging the battery with charging-sdl is possible -->
| status_battery = Y
| status_3d = <!-- Hardware accelerated 3D graphics (e.g. with freedreno) -->
| status_3d = Y
| status_accel = <!-- The sensor that measures proper acceleration works -->
| status_accel = Y
| status_audio = <!-- Using the device's speakers/headphone jack works -->
| status_audio = Y
| status_bluetooth = <!-- It's possible to pair and use other devices via the bluetooth protocol -->
| status_bluetooth = Y
| status_camera = <!-- Taking photos and videos works. -->
| status_camera =
| status_gps = <!-- The Global Positioning System sensor works.  -->
| status_gps = Y
| status_mobiledata = <!-- Connecting to the Internet via cellular network. -->
| status_mobiledata = Y
| status_sms = <!-- Sending and receiving short messages works as intended. -->
| status_sms = Y
| status_calls = <!-- Talking to other people over the cellular network. -->
| status_calls = Y
| status = <!-- Text displayed in the "not booting" table on the Devices page , e.g "kernel compiles, doesn't boot" -->
| status_nfc = -
| status_irtx = -
| status =
| genericdevice=Generic MSM8916 (qcom-msm8916)
| optionalgenericdevice = yes
| booting = yes
| booting = yes
 
| pmoskernel = Mainline
<!-- you can also use these lines if you need to:
| whet_dhry = 913.7 <!-- NOTE: RESULT WITH FDE, PLEASE RE-TEST AND SUMBIT W/O IT; ALSO RE-TEST AFTER CPU WILL FINALLY RUN ON 1.4 GHZ -->
if the device haven't originally ran Android OS, e.g. Nokia N900
| status_otg = Y
| n-android =  ✔
}}{{Based on SoC|Qualcomm_Snapdragon_410/412_(MSM8916)|Snapdragon 412}}
Version of the kernel that pmos is running
| pmoskernel = 3.x.x
see Unixbench page on wiki
| whet_dhry = 0.0
Is OTG available, not used in wiki
| status_otg = -
-->
}}
 
== Contributors ==
== Contributors ==
* [[User:Lazzardo]]
* [[User:Lazzardo|Lazzardo]]


== Maintainer(s) ==
== Maintainer(s) ==
<!-- Only if this device doesn't run on linux-postmarketos yet! -->
* [[User:Lazzardo|Lazzardo]]
<!-- This person needs to be willing to answer questions from users of this device -->
* [[User:Lazzardo]]


== Users owning this device ==
== Users owning this device ==
{{Device owners}}
{{Device owners}}
<!-- autogenerated, use {{Owns device|devicepage|notes}} on your profile page -->
<!-- use _ instead of spaces in device page name, e.g. {{Owns device|HTC_Desire_(htc-bravo)|custom notes}}-->
<!-- you may need to purge page cache to see changes (more->purge cache)-->
<!-- you can use {{My devices}} on your profile page to show table with all your devices -->


== How to enter flash mode ==
== How to enter flash mode ==
'''bq-paella:'''
The device is available in two variants: The normal edition from BQ and a special Cyanogen Edition that runs CyanogenOS. The hardware seems to be identical, but the firmware is different. How to enter Fastboot/Recovery mode depends on the firmware that is currently installed.
 
=== BQ bootloader ===
* '''Recovery''': Power on the device with both <code>Power</code> and <code>Volume Up</code> buttons.
* '''Fastboot''': Power on the device with both <code>Power</code> and <code>Volume Down</code> buttons.
 
=== Cyanogen bootloader ===
* '''Recovery''': Power on the device with both <code>Power</code> and <code>Volume Down</code> buttons.
* '''Recovery''': Power on the device with both <code>Power</code> and <code>Volume Down</code> buttons.
* '''Stock fastboot''': Power on the device with both <code>Power</code> and <code>Volume Up</code> buttons.
* '''Stock fastboot''': Power on the device with both <code>Power</code> and <code>Volume Up</code> buttons.
Line 70: Line 67:


== Installation ==
== Installation ==
'''bq-picmt:'''
=== Unlock bootloader ===
To unlock your bootloader boot into Android, [https://developer.android.com/studio/debug/dev-options#enable enable Developer Options from the settings] and enable "Allow OEM unlock". Then boot into Fastboot and use <code>fastboot oem unlock</code>. You might need to use <code>fastboot oem unlock-go</code>. ('''Note:''' All your data will be erased!)
 
=== Firmware ===
It is recommended to flash to latest firmware from BQ before using postmarketOS. You can download it here: [https://github.com/JonnyMe/aquaris-x5-firmware/releases/download/v1.0/5.2.0_20180228-1305-picmt-user-637-Fastboot-FW.zip 5.2.0_20180228-1305-picmt-user-637-Fastboot-FW.zip] <del>[https://storage.googleapis.com/otas/2015/Smartphones/X5/Android_N/5.2.0_20180228-1305-picmt-user-637-Fastboot-FW.zip 5.2.0_20180228-1305-picmt-user-637-Fastboot-FW.zip]</del>.
 
First flash the early boot firmware:
 
$ fastboot flash sbl1 sbl1.mbn
$ fastboot flash sbl1bak sbl1.mbn
$ fastboot flash tz tz.mbn
$ fastboot flash tzbak tz.mbn
$ fastboot flash hyp hyp.mbn
$ fastboot flash hypbak hyp.mbn
$ fastboot flash rpm rpm.mbn
$ fastboot flash rpmbak rpm.mbn
$ fastboot flash modem NON-HLOS.bin
 
As a next step you also need to flash a Linux/Android bootloader (<code>aboot</code>). There are two different versions available:
 
* '''BQ bootloader:''' Can only boot downstream kernel
* '''Cyanogen bootloader:''' Can boot both downstream and mainline kernel
 
Therefore, you should flash the Cyanogen bootloader for postmarketOS. You can download it here: [https://github.com/JonnyMe/aquaris-x5-firmware/releases/download/v1.0/cm-13.1.4-ZNH2KAS5FE-paella-signed-fastboot-a6851b4fbe.zip cm-13.1.4-ZNH2KAS5FE-paella-signed-fastboot-a6851b4fbe.zip] <del>[https://storage.googleapis.com/support-files.bq.com/Bootloader/Cyanogen%20OS/cm-13.1.4-ZNH2KAS5FE-paella-signed-fastboot-a6851b4fbe.zip cm-13.1.4-ZNH2KAS5FE-paella-signed-fastboot-a6851b4fbe.zip]</del>
 
$ fastboot flash aboot emmc_appsboot.mbn
$ fastboot flash splash splash.img


By now the way I flashed the device and having it working was following [[Installation from recovery mode]] guide and using the adb sideload method
The bootloader has a splash screen with black background.


'''bq-paella:'''
{{note|'''Note:''' After flashing a new bootloader you should reboot the device to make sure the new bootloader is running.}}


The only tested procedure by now is:
=== postmarketOS ===
# installing [https://github.com/msm8916-mainline/lk2nd lk2nd] following the [https://github.com/msm8916-mainline/lk2nd#building Building] section (just needed the first time)
The mainline kernel depends on an alternative bootloader ([https://github.com/msm8916-mainline/lk2nd lk2nd]). It does not replace the stock bootloader, but provides its own Fastboot interface. When using the mainline kernel you should always use lk2nd for flashing, not the stock Fastboot mode.
# follow the [[Installation_guide]] and stop before '''Installation and flashing''' section
# then run <code>pmbootstrap install</code>
# then run <code>pmbootstrap export</code>
# there will be now in <code>/tmp/postmarketOS-export</code> a <code>boot.img-*</code> file and a <code>bq-paella.img</code> file
# then from lk2nd run <code>fastboot flash boot boot.img</code> and <code>fastboot flash system bq-paella.img</code>


== Status ==
# Install [https://github.com/msm8916-mainline/lk2nd#installation lk2nd]. (Just needed the first time).
Currently work is separated based on firmware installed, if you installed the Cyanogen Edition firmware will be referred as bq-paella, if you installed the BQ Android firmware it will be referred as bq-picmt. So here is a summary for both:
#* '''Warning:''' lk2nd is installed to the <code>boot</code> partition, '''not''' the <code>aboot</code> partition you flashed earlier!


'''bq-picmt:''' runs on downstream kernel
When you have lk2nd installed and running, follow [[Qualcomm_Snapdragon_410/412_(MSM8916)#Installation]].


Works:
==== Downstream ====
USB Network,
There is an alternative device port using the downstream kernel, <code>bq-paella-downstream</code>. It can be selected by entering the name in <code>pmbootstrap init</code>.
WiFi,
Display,
weston,
weston-calibrator


Buggy:
{{note|'''WARNING:''' The downstream kernel is entirely '''unmaintained''' and only intended for testing features for the mainline kernel. DO NOT USE IT UNLESS YOU KNOW WHAT YOU ARE DOING!}}
ts_calibrate: to make screen get touches I incrementally have to touch screen with one finger and then with that finger on screen touch the crosshair, then for the second two fingers and crosshair, for the third three fingers and crosshair...don't know why but it started happening when I replaced my broken screen with a new one, if someone has this device with original screen can check if the same issue is present or not


Modem doesn't work, in dmesg I get DATA5_CNTL error relative to no such device
== Using as a daily driver ==
Audio routing seems to work properly now, so you can make a call without switching anything in settings.
You need to watch battery drain as this soc, has no working CPU suspend mode.


'''bq-paella:''' runs on mainline kernel
Make sure you have checked [https://gitlab.postmarketos.org/postmarketOS/pmaports/-/issues?scope=all&state=opened&label_name%5B%5D=device-bq-paella bq-paella issues] and fully read [[Qualcomm_Snapdragon_410/412_(MSM8916)]], as it contains information about important bugs related generally to this SoC (they are not mentioned directly here).


Works:
Cellular networking requires the package <code>msm-modem-uim-selection</code> and setting <code>/etc/conf.d/msm-modem-uim-selection</code> to <code>sim_wait_time=30</code>, this will automatically detect a sim card in one of the slots and activate it.
USB Network,
== Pictures ==
WiFi,
Bluetooth


<gallery>
File:P 20200521 144800.jpg|thumb|left|xeyes running on Weston on bq-paella
File:P 20200521 144422.jpg|thumb|left|FDE, osk-sdl running on bq-paella
File:EsBLYj1VgAATpGw.jpeg|thumb|left|phosh running on bq-paella
File:EsBLYk2UcAAeMLt.jpeg|thumb|left|GNOME Settings running on bq-paella
File:EsBLYnuUcAAT-2N.jpeg|thumb|left|GNOME Terminal on bq-paella
File:EsBNMN8UwAAO363.jpeg|thumb|left|GNOME Clocks on bq-paella
File:EsBLYmRVoAA7ZjJ.jpeg|thumb|left|Wi-Fi on bq-paella
File:EsBNMMqVEAA3LBg.jpeg|thumb|left|Bluetooth on bq-paella
File:EsBNMMRVcAAn9i3.jpeg|thumb|left|Firefox with WebGL on bq-paella
File:Bq-paella-gtk-spotify-spot.jpg|thumb|left|Spot, a GTK Spotify client, running on bq-paella
File:Bq-paella-fractal.jpg|thumb|left|Fractal, a GTK Matrix client, running on bq-paella
File:Sxmo-bq-paella.jpg|thumb|left|Sxmo running on bq-paella
File:Bq-paella-appgrid.jpg|thumb|left|Custom app grid on bq-paella
File:Lollypop.jpg|thumb|left|Lollypop playing music on bq-paella
File:Bq-paella-lockscreen-lollypop.jpg|thumb|left|Custom lockscreen with Lollypop player on bq-paella
File:Bq-paella-retroarch.jpg|thumb|left|RetroArch on bq-paella
</gallery>


== See also ==
== See also ==
Initial merge request [https://gitlab.com/postmarketOS/pmaports/-/merge_requests/1134]
* {{MR|1134|pmaports}} Initial merge request
<!--
* {{MR|1319|pmaports}} Moving to community
Link to related GitLab issues or merge requests like the following (replace CHANGEME with the ID, e.g. 1234):
* [https://web.archive.org/web/20210131121111/https://twitter.com/pojntfx/status/1355851049798688769 Chromium running with full hardware acceleration]
* {{MR|CHANGEME|pmaports}} Initial merge request
* {{issue|CHANGEME|pmaports}} Some related issue
You can also add normal web links:
* [https://redmine.replicant.us/projects/replicant/wiki/GalaxyS2I9100 Replicant wiki page]
-->
<!--
If you manage to get your device packages merged, uncomment links below and change DEVICE_CODENAME with the actual one.
* [https://gitlab.com/postmarketOS/pmaports/tree/master/device/testing/device-DEVICE_CODENAME Device package]
* [https://gitlab.com/postmarketOS/pmaports/tree/master/device/testing/linux-DEVICE_CODENAME Kernel package]
-->

Latest revision as of 14:02, 2 December 2024

Note This page is about the dedicated port of this device. There is also an optional generic port available for this device - see Generic MSM8916 (qcom-msm8916).
BQ Aquaris X5
BQ Aquaris X5 running Plasma Mobile on postmarketOS mainline
BQ Aquaris X5 running Plasma Mobile on postmarketOS mainline
Manufacturer BQ
Name Aquaris X5
Codename bq-paella
Released 2015
Type handset
Hardware
Chipset Qualcomm Snapdragon 412 (MSM8916v2)
CPU Quad-core 1.4 GHz Cortex-A53
GPU Adreno 306
Display 720 x 1280 (IPS LCD capacitive touchscreen, 16M colors)
Storage 16GB / 32GB
Memory 2GB / 3GB
Architecture aarch64
Software
Original software Android (CyanogenOS)
Original version 5.1 (CyanogenOS 12.1)
postmarketOS
Category community
Pre-built images yes
postmarketOS kernel Mainline
Unixbench Whet/Dhry score 913.7
Optional Generic Port Generic MSM8916 (qcom-msm8916)
Features
Flashing
Works
USB Networking
Works
Internal storage
No data
SD card
No data
Battery
Works
Screen
Works
Touchscreen
Works
Multimedia
3D Acceleration
Works
Audio
Works
Camera
No data
Camera Flash
No data
Connectivity
WiFi
Works
Bluetooth
Works
GPS
Works
Modem
Calls
Works
SMS
Works
Mobile data
Works
Miscellaneous
FDE
Works
USB OTG
Works
HDMI/DP
No data
Sensors
Accelerometer
Works
Magnetometer
No data
Ambient Light
No data
Proximity
No data
Hall Effect
No data
Haptics
No data
Barometer
No data

Contributors

Maintainer(s)

Users owning this device


How to enter flash mode

The device is available in two variants: The normal edition from BQ and a special Cyanogen Edition that runs CyanogenOS. The hardware seems to be identical, but the firmware is different. How to enter Fastboot/Recovery mode depends on the firmware that is currently installed.

BQ bootloader

  • Recovery: Power on the device with both Power and Volume Up buttons.
  • Fastboot: Power on the device with both Power and Volume Down buttons.

Cyanogen bootloader

  • Recovery: Power on the device with both Power and Volume Down buttons.
  • Stock fastboot: Power on the device with both Power and Volume Up buttons.
  • lk2nd Fastboot: Power on the device. After it vibrates, hold Volume Down.

Installation

Unlock bootloader

To unlock your bootloader boot into Android, enable Developer Options from the settings and enable "Allow OEM unlock". Then boot into Fastboot and use fastboot oem unlock. You might need to use fastboot oem unlock-go. (Note: All your data will be erased!)

Firmware

It is recommended to flash to latest firmware from BQ before using postmarketOS. You can download it here: 5.2.0_20180228-1305-picmt-user-637-Fastboot-FW.zip 5.2.0_20180228-1305-picmt-user-637-Fastboot-FW.zip.

First flash the early boot firmware:

$ fastboot flash sbl1 sbl1.mbn
$ fastboot flash sbl1bak sbl1.mbn
$ fastboot flash tz tz.mbn
$ fastboot flash tzbak tz.mbn
$ fastboot flash hyp hyp.mbn
$ fastboot flash hypbak hyp.mbn
$ fastboot flash rpm rpm.mbn
$ fastboot flash rpmbak rpm.mbn
$ fastboot flash modem NON-HLOS.bin

As a next step you also need to flash a Linux/Android bootloader (aboot). There are two different versions available:

  • BQ bootloader: Can only boot downstream kernel
  • Cyanogen bootloader: Can boot both downstream and mainline kernel

Therefore, you should flash the Cyanogen bootloader for postmarketOS. You can download it here: cm-13.1.4-ZNH2KAS5FE-paella-signed-fastboot-a6851b4fbe.zip cm-13.1.4-ZNH2KAS5FE-paella-signed-fastboot-a6851b4fbe.zip

$ fastboot flash aboot emmc_appsboot.mbn
$ fastboot flash splash splash.img

The bootloader has a splash screen with black background.

Note Note: After flashing a new bootloader you should reboot the device to make sure the new bootloader is running.

postmarketOS

The mainline kernel depends on an alternative bootloader (lk2nd). It does not replace the stock bootloader, but provides its own Fastboot interface. When using the mainline kernel you should always use lk2nd for flashing, not the stock Fastboot mode.

  1. Install lk2nd. (Just needed the first time).
    • Warning: lk2nd is installed to the boot partition, not the aboot partition you flashed earlier!

When you have lk2nd installed and running, follow Qualcomm_Snapdragon_410/412_(MSM8916)#Installation.

Downstream

There is an alternative device port using the downstream kernel, bq-paella-downstream. It can be selected by entering the name in pmbootstrap init.

Note WARNING: The downstream kernel is entirely unmaintained and only intended for testing features for the mainline kernel. DO NOT USE IT UNLESS YOU KNOW WHAT YOU ARE DOING!

Using as a daily driver

Audio routing seems to work properly now, so you can make a call without switching anything in settings. You need to watch battery drain as this soc, has no working CPU suspend mode.

Make sure you have checked bq-paella issues and fully read Qualcomm_Snapdragon_410/412_(MSM8916), as it contains information about important bugs related generally to this SoC (they are not mentioned directly here).

Cellular networking requires the package msm-modem-uim-selection and setting /etc/conf.d/msm-modem-uim-selection to sim_wait_time=30, this will automatically detect a sim card in one of the slots and activate it.

Pictures

See also