This repository contains some slightly adjusted versions of the Infinitime application, bootloader and reloader (based on wasp-os), to run on the P8a and P8b (and of course, the PineTime as well) smartwatch.
The P8b has a magnetic charging bay, with the two gold contacts in the center top. The P8a uses a charging clip, with the contacts in the center as well. The PineTime uses a magnetic charging bay, with the contacts shifted to one corner.
The (at least the one I have) P8b uses a different SPI flash chip. The bootloader is configured to accept a range of chips.
In addition, the touch driver is a bit different. The P8 touch driver cannot wake up from sleep mode, so instead the accelerometer is used to detect taps and double taps to wake up. The touch driver configuration set in the factory may also vary. A compile time variable is provided. See the file HardwareVariants.md
for more info.
This firmware fork is able to broadcast the 12-bit accelerometer sensor data using a sampling rate of 200 Hz instead of 10 Hz. A companion Android app to read these values in real-time can be found here: https://github.com/StarGate01/PineTimeAcc .
The P8b watch comes without an external low frequency crystal. This is a problem, because precise timing is required for Bluetooth connections. However, the NRF52 can be configured to use its internal RC clock to generate the low frequency clock.
The wasp-os bootloader as well as the mcuboot bootloader are configured to use this LFRC source. Wasp-os uses the Nordic softdevice, which takes care of properly configuring and calibrating the LF RC source. Mcuboot does not perform any calibration, however it does not require Bluetooth at all.
Usage of the LFRC source in InfiniTime and its Nimble stack is now implemented with proper calibration in my p8b fork.
If you don't want to compile the firmware yourself, you can download binaries on the release page.
Requirements for compilation:
If you use Nix, a flake.nix
is provided.
Run scripts/init.sh
to set up the repositories, do not clone this repo with all recursive submodules. This loads all the required submodules, and downloads the newt and python packages.
Use the scripts in scripts/
, run e.g. build_all.sh moy-ton5
to build all the firmware for the P8b watch. The Wasp reloader factory package will package the builds of mcuboot and the Infinitime minimal recovery loader.
All scripts accept either pinetime
, the moy-
designators, or p8
as the first argument (Default: pinetime
). This argument configures the target hardware platform.
You can change the compile time parameters in build_infinitime.sh
if your smartwatch has a different hardware configuration.
See the file HardwareVariants.md
for detailed configuration options for different watches.
Note: NRF connect sometimes seems to overload the connection, if it fails use another tool listed (or look at https://wiki.pine64.org/wiki/PineTime#Companion_Apps)
In general, sometimes the Bluetooth connection crashes, maybe due to interference. Just try again.
Do this at your own risk
Step 0
HardwareVariants.md
to figure out which build is right for you.Step 1
DaFlasherFiles/DaFitBootloader23Hacked.bin
Step 2
DaFlasherFiles/FitBootloaderDFU2.0.1.zip
Step 3
wasp-os/build-p8/bootloader-daflasher.zip
(P8b variant)Step 4
scripts/load_wasp_reloader.sh p8
) or NrfConnect (or DaFlasher?)wasp-os/build-p8/reloader-factory.zip
(P8b variant w/ mcuboot & Infinitime recovery loader)Step 5
Step 6
Step 7
Step 8
Step 9
scripts/load_infinitime.sh
) or NRFConnect or GadgetBridge (or DaFlasher?)InfiniTime/build/src/pinetime-mcuboot-app-dfu-1.8.0.zip
Step 10
Step 11
Do this at your own risk
For OTA
wasp-os/build-p8/bootloader.hex
(P8b variant)For Development
InfiniTime/build/src/pinetime-app-1.8.0.hex
(P8b variant without bootloader)pinetime-mcuboot-bootloader/p8b
at StarGate01/pinetime-mcuboot-bootloader, fork of InfiniTimeOrg/pinetime-mcuboot-bootloader
InfiniTime/p8b
at StarGate01/InfiniTime, fork of ildar/InfiniTime/p8, fork of InfiniTimeOrg/InfiniTime
wasp-os
at daniel-thompson/wasp-os
DaFlasherFiles
at atc1441/DaFlasherFiles.git