this post was submitted on 31 Aug 2023
597 points (97.3% liked)

Open Source

31218 readers
241 users here now

All about open source! Feel free to ask questions, and share news, and interesting stuff!

Useful Links

Rules

Related Communities

Community icon from opensource.org, but we are not affiliated with them.

founded 5 years ago
MODERATORS
 

geteilt von: https://feddit.de/post/3048730

Github link: https://github.com/Dakkaron/Fairberry

Here's a video of it in action: https://www.youtube.com/watch?v=iDb8_ld9gOQ

I've been using it for almost two years now, and I'm not going back.

It's based on a spare Blackberry Q10 keyboard and a custom Arduino-compatible board that reads the keyboard matrix and outputs it as USB HID to the phone. From the viewpoint of the phone, it's just a regular USB keyboard, so no special software is needed.

But I do use a custom virtual keyboard to have just two rows of symbols that are not natively on the keyboard, as I didn't want to add another layer of rarely used symbols that I'd have to memorize.

(On the image you can see Ubuntu with XFCE4 running on it. I chose Ubuntu because it's what was easiest to get running in a chroot jail on the phone. I'm using VNC to display the GUI. I even managed to get FEX (x86/x64 emulator) and Wine running, so it runs x86/x64 Linux and Windows apps.)

you are viewing a single comment's thread
view the rest of the comments
[–] [email protected] 3 points 1 year ago (2 children)

Do you know if Linux is installable on any phone that can be unlocked? Last time I tried Linux on a phone was Ubuntu touch on a nexus 4.

[–] [email protected] 6 points 1 year ago (1 children)

Kinda, yes and no, depinding on what you mean.

Native desktop Linux on bare metal, that's not possible, afaik. At least I have never seen anyone do that, so I don't think that's possible. Only very specific phones that are designed for this (e.g. the Pinephone) can do this.

Specialized phone Linux distros like Ubuntu Touch or PostmarketOS can be installed on any phone that someone ported the OS to. This is by far not every phone, but there are some phones where that is possible.

Running a real desktop Linux in a chroot jail is something every rooted phone is able to do. Here, the phone's regular Linux kernel is used to run the userland of the desktop Linux in a separated file system. From the user's viewpoint this is real Linux, but the Kernel that is used is the Android kernel. Also, the whole Android userland is running at the same time. This means, you can e.g. see (and kill) Linux processes from Android and vice versa. You can access the UI of the chrooted Linux using either a VNC or an X11 app, and the CLI either over SSH or directly over a command from the Android CLI.

The last option is using e.g. Termux to run a desktop Linux in a proot jail. This works similar to chroot, but doesn't require root. The downsides are that you don't have root inside the desktop Linux and afaik it only works until Android 11. Otherwise you get similar results as with chroot, only slower and without requireing root.

I went with the chroot option, which works great. I even managed to get FEX (an x86/x64 emulator) to run, which, together with Wine even allows me to run Windows programs on my phone (slowly).

[–] [email protected] 1 points 1 year ago

Termux used to rock but nowdays installing stuff is very hit or miss.

[–] [email protected] 2 points 1 year ago

Android already contains Linux, and you can run a GNU operating system such as Ubuntu on that existing Linux, which is what OP is doing.