Getting Waydroid to work on the Pinephone Pro
#1
Went to a lot of trouble to get Waydroid running on the Pinephone Pro. Seems to be running pretty smooth now (as smooth as it will run without hardware acceleration anyways).

Waydroid is technically not supported yet on the Pro. Hardware acceleration is broken, so you have to disable it due to a Mesa / Android conflict. I am on Mobian Bookworm, so this post outlines what I did to get it working on Mobian Bookworm specifically. Your instructions might vary slightly on different distros or builds of Mobian.

Note: You will be editing your U-boot config file here if you are on Mobian. Doing this wrong can make your device not boot correctly. I’m not responsible for bricked devices if you break your config. The Mobian resource below has all of these instructions save for the hardware acceleration disabling. I’d recommend using the listed instructions over mine. The only thing in this post not included in either of these links is the hardware acceleration disabling.

Refer to these instructions:

Mobian specific, I used the desktop install method and not source compiling: https://wiki.mobian-project.org/doku.php?id=waydroid

Use the Ubuntu/Debian desktop specific instructions here: https://docs.waydro.id/usage/install-on-desktops

After you install the Waydroid package via the instructions, do not use
Code:
sudo waydroid init

until you have done the Mobain specific instructions on the mobian page. This will cause Waydroid to not work for some reason. I got gbinder errors doing this, but your milage may very.


Mobain Specific Install Instructions


Add this to the bottom of “/etc/gbinder.conf” [NOTE: My file was named anbox.conf and it still worked]

Code:
[General]
ApiLevel = 29

-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
This is Mobian specific. I do not believe you need this on other distros. Refer to the Mobian wiki page linked above for this step. 
Add this line to U_BOOT_PARAMETERS in “/etc/default/u-boot”:
Code:
psi=1
after vt.global_cursor_default=0

Be very careful here. If you add this config wrong you might break u-boot. Please use the listed Mobain wiki resource here and ensure you add this correctly. I’m not responsible for bricked devices if this goes wrong. I triple checked my config versus the listed code on the Mobian wiki before running the next command.


After you are sure your config is written properly, run
Code:
sudo u-boot-update
and reboot the phone.
------------------------------------------------------------------------------------------------------------------------------------------------------------------
Almost done now. You need to disable hardware acceleration as of this post to make Waydroid work on the PPP.

Make the following changes in “/var/lib/waydroid/waydroid_base.prop”:

Change the value of ro.hardware.gralloc to "default" as shown:

Code:
ro.hardware.gralloc=default


Change the value of ro.hardware.egl to "swiftshader" as shown:


Code:
ro.hardware.egl=swiftshader


Save and exit the file.

--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
This is it, now run:

Code:
systemctl enable waydroid-container.service


Now you can run
Code:
sudo waydroid init

At this point it will install the LineageOS image and other dependencies. After this is compete, if you did everything correctly, you should be able to run
Code:
waydroid session start
in the terminal and get Waydroid to work. The Mobain guide says starting via the Phosh app drawer will start the session. You can try it this way, but it takes around 20 seconds to get anything more than a blank screen. Seems spotty and slow to me, so if it doesn’t do it consistently I will add a comment to this post with a bash script to auto start the session on boot.

You can now launch the Waydroid app via the Phosh app drawer, and you are done!

Hope this helped you. Please refer to the documentation above for 99% of the instructions. Only thing I added to them was the hardware acceleration disabling.
  Reply
#2
I could not execute waydroid in PPP
I think I removed it but
7 icons on the desktop
Calculator
Calendar
Clock
Contacts
Files
Gallery
Settings
 And I do not know how to remove
Then on my Manjaro mobile plasma
Any idea?
  Reply
#3
(03-06-2022, 08:27 AM)Emilio Wrote: I could not execute waydroid in PPP
I think I removed it but
7 icons on the desktop
Calculator
Calendar
Clock
Contacts
Files
Gallery
Settings
 And I do not know how to remove
Then on my Manjaro mobile plasma
Any idea?
If you want to try reinstalling Waydroid, try checking out the section on here called "Hide Desktop Entries" from the Arch wiki. Looks like you can set it to hide them. 
https://wiki.archlinux.org/title/desktop...op_entries

If you want to remove Waydroid for good, There are commands here to wipe all of the configs and whatnot which should wipe them (I am not 100% on that though). 
https://docs.waydro.id/usage/install-on-desktops

Sorry if that doesn't help, I did not have to remove any icons or anything during my install.
  Reply
#4
Hello

I try to install waydroid on mobian (on SD) with tow-boot on SPI.

After insert psi=1 in /etc/default/u-boot, i launch sudo u-boot-update, then i reboot PPP.
But psi=1 doesn't appear with the command cat /proc/cmdline

Any suggestions ?
  Reply
#5
(04-02-2022, 10:24 AM)cbz Wrote: Hello

I try to install waydroid on mobian (on SD) with tow-boot on SPI.

After insert psi=1 in /etc/default/u-boot, i launch sudo u-boot-update, then i reboot PPP.
But psi=1 doesn't appear with the command cat /proc/cmdline

Any suggestions ?

Hmm, I did not have this issue. It showed up first time for me after the reboot. Make sure the file is saved and cat the config file before you run sudo u-boot-update to make sure it is in the u-boot config. I suppose it is possible the phone isn't saving your changes for whatever reason. If you didn't use sudo to write the file that could be the culprit. Just be careful updating the config too many times, let me know how it goes.
  Reply
#6
I previously managed to get Waydroid to run on the PPP by disabling 'Hardware acceleration' in Waydroid when setting it up, although please forgive me I can't remember the required command right now. If no one can find it, I'll see if I can find that command tomorrow. Smile
  Reply
#7
(04-14-2022, 05:44 PM)PineFLOWn Wrote: I previously managed to get Waydroid to run on the PPP by disabling 'Hardware acceleration' in Waydroid when setting it up, although please forgive me I can't remember the required command right now. If no one can find it, I'll see if I can find that command tomorrow. Smile

On Arch:
Code:
( sudo echo "ro.hardware.gralloc=default" ; sudo echo "ro.hardware.egl=swiftshader" ) >>/var/lib/waydroid/waydroid_base.prop
  Reply
#8
(04-14-2022, 07:47 PM)brb78 Wrote:
(04-14-2022, 05:44 PM)PineFLOWn Wrote: I previously managed to get Waydroid to run on the PPP by disabling 'Hardware acceleration' in Waydroid when setting it up, although please forgive me I can't remember the required command right now. If no one can find it, I'll see if I can find that command tomorrow. Smile

On Arch:
Code:
( sudo echo "ro.hardware.gralloc=default" ; sudo echo "ro.hardware.egl=swiftshader" ) >>/var/lib/waydroid/waydroid_base.prop

That's how I got it working on Mobian as well Smile
  Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Tow-Boot, a new U-Boot option for Pinephone Pro and other devices Ulfnic 55 12,443 06-14-2022, 06:45 AM
Last Post: brb78
  Getting hdmi out to work reliably? emole 3 297 05-27-2022, 05:30 PM
Last Post: hockleyj
Rainbow Waydroid on Pinephone Pro (solution for users) MadameMalady 6 817 05-16-2022, 09:55 PM
Last Post: Emilio
  F-Droid on a pinephone pro? gilwood 2 262 05-15-2022, 02:26 PM
Last Post: biketool
  Wireshark development on a PinePhone Pro realrichardsharpe@gmail.com 2 254 04-28-2022, 04:48 AM
Last Post: wibble
  GAPPS (Waydroid) on the Pinephone Pro jarbear82 3 820 04-27-2022, 01:05 PM
Last Post: TheBlindEarthican
  Waydroid on PinePhone Pro PPP (Stock Manjaro Plasma) mhedhli 6 1,349 04-25-2022, 11:27 AM
Last Post: TheBlindEarthican
  Getting Started with the PinePhone Pro fxc 0 308 04-10-2022, 06:32 AM
Last Post: fxc
  PinePhone Pro Jumpdrive pvxf2647 3 693 03-27-2022, 12:27 PM
Last Post: Barugon
  Flash Pinephone Pro image from SD card to eMMC? jcun4128 9 1,707 03-11-2022, 09:09 AM
Last Post: fxc

Forum Jump:


Users browsing this thread: 1 Guest(s)