Google Pixel 3a: Difference between revisions

From Maemo Leste Wiki
Jump to navigation Jump to search
Line 173: Line 173:


Rotation is currently chaotic, it is recommanded to lock the device in portrait mode using Orientation Lock Applet and allow automatic landscape rotation for specific apps in transitions.ini file if needed (until a proper rotation fix).
Rotation is currently chaotic, it is recommanded to lock the device in portrait mode using Orientation Lock Applet and allow automatic landscape rotation for specific apps in transitions.ini file if needed (until a proper rotation fix).
=== Video recording (testing) ===
Both back and front cameras work (more or less) and it is already possible to record some videos using gst-launch and libcamera:
<pre>
sudo apt install libcamera-tools
sudo apt install gstreamer1.0-libcamera
sudo apt install gstreamer1.0-plugins-ugly
</pre>
First test to show video stream: (sudo needed ATM)
<pre>
sudo gst-launch-1.0 -e libcamerasrc camera-name="/base/soc@0/cci@ac4a000/i2c-bus@1/camera@1a" ! queue ! videoconvert ! autovideosink
</pre>
Then, to record a video: (sudo needed ATM)
'''(i2c-bus@0 for back and i2c-bus@1 for front camera)'''
<pre>
sudo gst-launch-1.0 -e libcamerasrc camera-name="/base/soc@0/cci@ac4a000/i2c-bus@1/camera@1a" ! video/x-raw,framerate=17/2 ! queue ! videoconvert ! x264enc tune=zerolatency bitrate=4000 speed-preset=ultrafast ! h264parse ! mp4mux ! filesink location=videotest.mp4
</pre>
That is only an example and a WIP. Lot of parameters need to be added or modified.
'''Note: libcamera-tools provides qcam which can be used to take some pictures. Colors are a bit wrong and rotation seems not calibrated properly.


== Remaining issues ==
== Remaining issues ==

Revision as of 19:37, 23 September 2026

Google Pixel 3a
Manufacturer Google
Codename Pixel 3a/3a XL, Google sargo/bonito
Release Date 2019
Category Supported
Specifications
SoC 2 x 2 GHz, 6 x 1.7GHz
DRAM 4GB
Hardware Features
LCD 1080x2220 OLED
Video adreno 615
Audio yes
Network yes
Storage 64GB
USB (Host/OTG) Micro USB C
Camera yes
Sensors yes
Battery Capacity 3000/3700mAh
Software Features
Kernel 6.12
Charging Yes
Touchscreen Yes, multitouch
Screen Yes
3D acceleration Yes
Vibration motor Yes
Audio Yes
Phone calls Yes
SMS Yes
Wifi Yes
IrDA No
2G/3G data Yes, ModemManager only
4G data Yes, ModemManager only
Bluetooth Yes
FM transmitter No
FM receiver No
Accelerometer Yes
Proximity Sensor Yes
GPS Yes, ModemManager only
A-GPS Yes, ModemManager only
Front Camera Yes, qcam only
Back Camera(s) Yes, qcam only
Idle Power Consumption 280mW
Stand by time 40/50h

Installation

WIP

WARNING: Flashing Maemo Leste to your device will erase your Android installation and all the data contained in it.

It is recommended to upgrade Android to the latest available version and install all system updates before installing Maemo-leste, because Maemo-leste uses FW files from Android partitions for enabling various peripherals, as mentioned in Mobian wiki


Install fastboot and last android-sdk-platform-tools on your computer.


Flash mode

WIP

To enter flash mode (fastboot):

Hold "Volume Down" and "Power" buttons until fastboot appears.

Then connect your PC and your phone through USB.

Bootloader setup

WIP

Device bootloader needs to be unlocked: from Android, go to "About phone" page in Settings app. Then, click 7 times on the build number to enable developer settings. From Setting main page, go to "System", "Developer options" and enable OEM unlocking.

Before flashing Maemo Leste, you need to unlock the bootloader in fastboot mode with this command:

fastboot flashing unlock

Installation with fastboot

WIP

Fastboot (useful) commands:

fastboot getvar current-slot
fastboot set_active a

or

fastboot set_active b


Download necessary img's files here (.tar.xz archive includes both sargo and bonito img's files)

From fastboot menu:

fastboot flash boot <boot.img>

fastboot flash userdata <excalibur-sdm670.img>

fastboot oem uart enable

fastboot reboot

Warning: TODO it is confusing how to use fastboot flash boot/boot_a/boot_b command. Needs clarifications.


Note: The bootloader on the Pixel 3a appends console=null to the kernel cmdline by default, which hides the boot logs on the screen. A custom manufacturer fastboot command can configure console=tty0: 'fastboot oem uart enable'

Tweaks

WIP

First boot

Recommanded useful apps

coolkbd, brightness applet, orientation lock applet

Firefox(-esr) tips

To activate touchscreen scrolling:

Edit

/usr/share/applications/hildon/firefox-esr.desktop

modify "Exec" line

Exec=bash -c 'MOZ_USE_XINPUT2=1 /usr/bin/firefox-esr'

To modify scaling and fit to Pixel 3a screen in portrait mode, go to "about:config" and edit

layout.css.devPixelsPerPx 0.8

Mobile data (workaround)

Ofono doesn't handle qrtr properly unfortunately, however it is possible to run ModemManager just for mobile data, as a workaround.

(Note: network-manager package is needed)

See PMOS page Mobile data

and ModemManager init script

That works fine even with ofono running at the same time.

Portrait VS Landscape

Almost all apps can run in portrait mode with hildon-desktop, however few apps like osso-addressbook or chromium need to be added by-hand in transitions.ini whitelist:

/usr/share/hildon-desktop/transitions.ini

Some apps can be also locked in landscape mode if needed (blacklist). It is particulary useful for video apps like smplayer.

Rotation is currently chaotic, it is recommanded to lock the device in portrait mode using Orientation Lock Applet and allow automatic landscape rotation for specific apps in transitions.ini file if needed (until a proper rotation fix).

Video recording (testing)

Both back and front cameras work (more or less) and it is already possible to record some videos using gst-launch and libcamera:

sudo apt install libcamera-tools
sudo apt install gstreamer1.0-libcamera
sudo apt install gstreamer1.0-plugins-ugly

First test to show video stream: (sudo needed ATM)

sudo gst-launch-1.0 -e libcamerasrc camera-name="/base/soc@0/cci@ac4a000/i2c-bus@1/camera@1a" ! queue ! videoconvert ! autovideosink

Then, to record a video: (sudo needed ATM)

(i2c-bus@0 for back and i2c-bus@1 for front camera)

sudo gst-launch-1.0 -e libcamerasrc camera-name="/base/soc@0/cci@ac4a000/i2c-bus@1/camera@1a" ! video/x-raw,framerate=17/2 ! queue ! videoconvert ! x264enc tune=zerolatency bitrate=4000 speed-preset=ultrafast ! h264parse ! mp4mux ! filesink location=videotest.mp4

That is only an example and a WIP. Lot of parameters need to be added or modified.

Note: libcamera-tools provides qcam which can be used to take some pictures. Colors are a bit wrong and rotation seems not calibrated properly.

Remaining issues

Mobile data not working with ofono (qrtr implementation).

Rotation accuracy.

GPS with geoclue implementation for Maemo location apps.

Phone calls work nicely with ofono/sphone, however incoming calls work only if you make an outgoing call first (after boot).

Current draw is a bit high out of the box. fixed in newer kernel. (6.12 patched kernel is available however)