Skip to content

Pinephone Modem SDK: Tools to build your own bootloader, kernel and rootfs

License

Notifications You must be signed in to change notification settings

wart-github/pinephone_modem_sdk

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Pinephone Modem SDK

(nearly) Free custom firmware for your Pinephone's modem!

This repository contains all the tools you need use to make your own Modem userspace for your Pinephone.

Latest release: Version 0.4.5

Latest (testing): Version 0.4.7

Current Status:

  • LK Bootloader: Working

    • On reset, the bootloader enters into fastboot mode automatically for 2 seconds, and boots normally unless instructed to stay (leave the command fastboot oem stay running while rebooting the modem to make it stop at fastboot).
    • Custom fastboot commands:
    • fastboot reboot-bootlader: Reboot to fastboot
    • fastboot oem stay: Stay in fastboot instead of booting normally
    • fastboot oem reboot-recovery: Reboot to recovery mode
    • fastboot oem getmfg: Try to identify the modem from the partition table
  • CAF Kernel: Working

  • Audio: Working, needs fine tunning (No internal ring indication on outgoing calls for carriers who don't send it themselves)

  • Call volume: May need some tweaking to the ALSA UCM configuration file. You can do this by editing /usr/share/alsa/ucm2/PinePhone/VoiceCall.conf. These values seem to work well: * cset "name='AIF2 DAC Playback Volume' 90%" * cset "name='AIF2 ADC Capture Volume' 90%" * A reboot is required after changing this configuration file. * Feel free to play around with the values, default value is '160' for both items (without '%' sign). Mine sounds loud enough at both extremes with 90% and 80% respectively

  • GPS: Working

  • Sleep / Power management: Working (New current measurement and profiling required after latest changes)

  • System images:

    • root_fs: Default system image. Includes a minimal root filesystem and one application replacing the entire Qualcomm / Quectel stack. Some functions are not yet functional
    • recovery_fs: Minimal bootable image to be flashed into the recovery partitions to retrieve logs and make changes to the root image
  • Custom AT Commands: Please see this document

Features not available on stock firmware:

  • Non persistent storage: There's no way of corrupting your modem firmware from a bad shutdown
  • Automatic time synchronization from the carrier into the userspace
  • Minimum clock frequency is set to 100Mhz, either awake or sleeping (stock is 800MHz awake and 400Mhz sleep), making the modem run cooler
  • Different sampling rates available at runtime without requiring a reboot (missing companion app in the pinephone to make use of them)
  • 0 binary blobs in the userspace. Only closed source running on the modem are TZ Kernel and ADSP firmware

TODO

  1. [Testing] Find and fix the last remaining USB port reset cause(s)
  2. Find fixes to support dynamic rate settings in the Pinephone
  3. Finish and tidy up the AT command handling stuff
  4. Allow bootloader PIN lock to prevent accidental flashing
  5. Companion app to update the firmware / manage modem settings / retrieve logs
  6. Add support for the PinePhone Pro
  7. [Testing] Fix audio when doing conferences (audio is cut off when hanging up the first call)

Contribution is always welcome! Feel free to share any issue or something that you think may be interesting to have!

Related Repositories

This project depends on the following repositories:

Make sure you have your recoveries ready just in case:

Documentation

I'm really bad at documentation, but you have some docs here

About

Pinephone Modem SDK: Tools to build your own bootloader, kernel and rootfs

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Languages

  • Python 81.9%
  • Shell 11.2%
  • Makefile 6.9%