Compare commits
134 Commits
fix-displa
...
rei/develo
Author | SHA1 | Date | |
---|---|---|---|
e54d78a04b | |||
8f32478141 | |||
b002fddc29 | |||
ea62510eb6 | |||
a4598ed63e | |||
72a020127f | |||
|
373289c072 | ||
|
350bca3965 | ||
|
94cd2ba563 | ||
|
ecb3cd3e31 | ||
|
d55ec42b17 | ||
|
a1385cb481 | ||
|
de62620de1 | ||
|
7e169ee4aa | ||
|
955dda60c5 | ||
|
6cfb45e280 | ||
|
c6026aa617 | ||
|
254c85246e | ||
|
4a40d29279 | ||
|
41c461d1f6 | ||
|
17cedd6629 | ||
|
1d34e83c97 | ||
|
9e18c23aac | ||
|
12d4bc4139 | ||
|
17079fb114 | ||
|
c2b15b1446 | ||
|
7bc692eea4 | ||
|
36740498db | ||
|
5f28f89df2 | ||
|
35dcf8c860 | ||
|
f95147cf0e | ||
|
91a3e98276 | ||
|
8a71f2b9e0 | ||
|
8999158528 | ||
|
977936e8e2 | ||
|
03a2059e87 | ||
|
702f65d3ee | ||
|
20ac1cd374 | ||
|
03a510bd18 | ||
|
7f45538eb5 | ||
|
718fbdab98 | ||
|
0ce4183640 | ||
|
87a69fe52d | ||
|
0fabba1c9a | ||
|
a2218dd4ad | ||
|
619477cbd1 | ||
|
cc2d5c39ce | ||
|
dd313eb419 | ||
|
9b216bb16f | ||
|
1ffca52715 | ||
|
c77f923a33 | ||
|
83b3a2a469 | ||
|
123c801f17 | ||
|
831f93cd92 | ||
|
34506be06e | ||
|
6171c9d45d | ||
|
a6fcdec0f8 | ||
|
443408312a | ||
|
324927f2b7 | ||
|
db0f909b46 | ||
|
8485cdb54d | ||
|
4cb07bac53 | ||
|
c9f23c11b3 | ||
|
f56788465d | ||
|
78267eec40 | ||
|
a2057ebc6f | ||
|
b6b322efdd | ||
|
f7e8caa04a | ||
|
4fba1ac5ce | ||
|
27e598f3fa | ||
|
8b2e1c69f2 | ||
|
95a970a75d | ||
|
2ccf88c03c | ||
|
331de8ce8e | ||
|
4e2b0b1f10 | ||
|
d967ed7d90 | ||
|
ef17f2f981 | ||
|
e39f183efe | ||
|
b9fbee1007 | ||
|
43443eda74 | ||
|
1c0d9ef383 | ||
|
c006f05c99 | ||
|
9d3671561f | ||
|
a75912dd97 | ||
|
1d4fd9c27f | ||
|
77645b20b2 | ||
|
451d755e3d | ||
|
9535c1e651 | ||
|
ac0dc5ff47 | ||
|
875b9c4bc5 | ||
|
3005fe8710 | ||
|
4116baf72e | ||
|
09b852d8f0 | ||
|
c94e0d53bb | ||
|
015f17cd25 | ||
|
dedb397ae0 | ||
|
ae2b9d30d6 | ||
|
beddfc346d | ||
|
2b9418c7f8 | ||
|
8160748733 | ||
|
6dac0a62f4 | ||
|
4229386501 | ||
|
09a50dcc15 | ||
|
8b470d33a1 | ||
|
8061822f0c | ||
|
b31fbb4adb | ||
|
54df828665 | ||
|
b7b1af1c4c | ||
|
2e42b90009 | ||
|
b6807ee3ca | ||
|
36cb7c82f3 | ||
|
34858d0a6c | ||
|
f82aa71eb0 | ||
|
aa32159c00 | ||
|
5e83a862db | ||
|
28ccf15e13 | ||
|
3bf6b1cb16 | ||
|
d7441d18be | ||
|
129dd97b51 | ||
|
5a13c5215c | ||
|
f84a0a3897 | ||
|
ed91b5a998 | ||
|
68a7016080 | ||
|
ff73f67d6f | ||
|
943a48f189 | ||
|
82a4f9aa68 | ||
|
2607c3d799 | ||
|
b498e1d633 | ||
|
78365548f7 | ||
|
78cab3604d | ||
|
8f436e1d74 | ||
|
4761fcb63a | ||
|
ea14c580ca | ||
|
a1db9fca13 |
@ -8,9 +8,9 @@ AlignConsecutiveDeclarations: false
|
||||
AlignEscapedNewlines: Right
|
||||
AlignOperands: Align
|
||||
AlignTrailingComments: true
|
||||
AllowAllArgumentsOnNextLine: true
|
||||
AllowAllArgumentsOnNextLine: false
|
||||
AllowAllConstructorInitializersOnNextLine: true
|
||||
AllowAllParametersOfDeclarationOnNextLine: true
|
||||
AllowAllParametersOfDeclarationOnNextLine: false
|
||||
AllowShortBlocksOnASingleLine: Never
|
||||
AllowShortCaseLabelsOnASingleLine: false
|
||||
AllowShortFunctionsOnASingleLine: None
|
||||
@ -83,6 +83,8 @@ IndentGotoLabels: true
|
||||
IndentPPDirectives: BeforeHash
|
||||
IndentWidth: 2
|
||||
IndentWrappedFunctionNames: false
|
||||
# Requires Clang >= 15, could also cause incorrect code formatting:
|
||||
# InsertBraces: true
|
||||
JavaScriptQuotes: Leave
|
||||
JavaScriptWrapImports: true
|
||||
KeepEmptyLinesAtTheStartOfBlocks: true
|
||||
|
37
.github/workflows/format.yml
vendored
Normal file
@ -0,0 +1,37 @@
|
||||
name: Code formatting
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
branches: [ master, develop ]
|
||||
paths:
|
||||
- '**.cpp'
|
||||
- '**.h'
|
||||
- '!src/libs/**'
|
||||
- '!src/FreeRTOS/**'
|
||||
|
||||
jobs:
|
||||
test-format:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
with:
|
||||
fetch-depth: 1000
|
||||
|
||||
- name: Configure git
|
||||
run: |
|
||||
git fetch origin "$GITHUB_BASE_REF":"$GITHUB_BASE_REF" --depth=1000
|
||||
|
||||
- name: Install clang-format
|
||||
run: |
|
||||
sudo apt-get update
|
||||
sudo apt-get -y install clang-format-12
|
||||
|
||||
- name: Check formatting
|
||||
run: tests/test-format.sh
|
||||
|
||||
- name: Upload patches
|
||||
uses: actions/upload-artifact@v3
|
||||
if: failure()
|
||||
with:
|
||||
name: Patches
|
||||
path: ./*.patch
|
22
.github/workflows/lv_sim.yml
vendored
@ -1,24 +1,15 @@
|
||||
# GitHub Actions Workflow to build Simulator for PineTime Smart Watch LVGL Interface
|
||||
|
||||
# Name of this Workflow
|
||||
name: Build PineTime LVGL Simulator
|
||||
|
||||
# When to run this Workflow...
|
||||
on:
|
||||
|
||||
# Run on all branches
|
||||
push:
|
||||
branches: []
|
||||
|
||||
# Also run this Workflow when a Pull Request is created or updated in the "master" and "develop" Branch
|
||||
branches: [ master, develop ]
|
||||
pull_request:
|
||||
branches: [ master, develop ]
|
||||
|
||||
# Steps to run for the Workflow
|
||||
jobs:
|
||||
build:
|
||||
|
||||
# Run these steps on Ubuntu
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
@ -34,6 +25,10 @@ jobs:
|
||||
sudo apt-get update
|
||||
sudo apt-get -y install libsdl2-dev
|
||||
|
||||
- name: Install lv_font_conv
|
||||
run:
|
||||
npm i -g lv_font_conv@1.5.2
|
||||
|
||||
#########################################################################################
|
||||
# Checkout
|
||||
|
||||
@ -60,15 +55,12 @@ jobs:
|
||||
#########################################################################################
|
||||
# Build and Upload simulator
|
||||
|
||||
# For Debugging Builds: Remove "make" option "-j" for clearer output. Add "--trace" to see details.
|
||||
# For Faster Builds: Add "make" option "-j"
|
||||
|
||||
- name: Build simulator executable
|
||||
run: |
|
||||
cmake --build build_lv_sim
|
||||
|
||||
- name: Upload simulator executable
|
||||
uses: actions/upload-artifact@v2
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: infinisim
|
||||
name: infinisim-${{ github.head_ref }}
|
||||
path: build_lv_sim/infinisim
|
||||
|
169
.github/workflows/main.yml
vendored
@ -3,168 +3,45 @@
|
||||
# Based on https://github.com/JF002/InfiniTime/blob/master/doc/buildAndProgram.md
|
||||
# and https://github.com/JF002/InfiniTime/blob/master/bootloader/README.md
|
||||
|
||||
# Name of this Workflow
|
||||
name: Build PineTime Firmware
|
||||
|
||||
# When to run this Workflow...
|
||||
on:
|
||||
|
||||
# Run this Workflow when files are updated (Pushed) in the "master" and "develop" Branch
|
||||
push:
|
||||
branches: [ master, develop ]
|
||||
|
||||
# Also run this Workflow when a Pull Request is created or updated in the "master" and "develop" Branch
|
||||
pull_request:
|
||||
branches: [ master, develop ]
|
||||
|
||||
# Steps to run for the Workflow
|
||||
jobs:
|
||||
build:
|
||||
|
||||
# Run these steps on Ubuntu
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
container:
|
||||
image: infinitime/infinitime-build
|
||||
steps:
|
||||
|
||||
#########################################################################################
|
||||
# Download and Cache Dependencies
|
||||
|
||||
- name: Install cmake
|
||||
uses: lukka/get-cmake@v3.18.3
|
||||
|
||||
- name: Check cache for Embedded Arm Toolchain arm-none-eabi-gcc
|
||||
id: cache-toolchain
|
||||
uses: actions/cache@v2
|
||||
env:
|
||||
cache-name: cache-toolchain-9-2020-q2
|
||||
with:
|
||||
path: ${{ runner.temp }}/arm-none-eabi
|
||||
key: ${{ runner.os }}-build-${{ env.cache-name }}
|
||||
restore-keys: ${{ runner.os }}-build-${{ env.cache-name }}
|
||||
|
||||
- name: Install Embedded Arm Toolchain arm-none-eabi-gcc
|
||||
if: steps.cache-toolchain.outputs.cache-hit != 'true' # Install toolchain if not found in cache
|
||||
uses: fiam/arm-none-eabi-gcc@v1.0.4
|
||||
with:
|
||||
# GNU Embedded Toolchain for Arm release name, in the V-YYYY-qZ format (e.g. "9-2019-q4")
|
||||
release: 9-2020-q2
|
||||
# Directory to unpack GCC to. Defaults to a temporary directory.
|
||||
directory: ${{ runner.temp }}/arm-none-eabi
|
||||
|
||||
- name: Check cache for nRF5 SDK
|
||||
id: cache-nrf5sdk
|
||||
uses: actions/cache@v2
|
||||
env:
|
||||
cache-name: cache-nrf5sdk
|
||||
with:
|
||||
path: ${{ runner.temp }}/nrf5_sdk
|
||||
key: ${{ runner.os }}-build-${{ env.cache-name }}
|
||||
restore-keys: ${{ runner.os }}-build-${{ env.cache-name }}
|
||||
|
||||
- name: Install nRF5 SDK
|
||||
if: steps.cache-nrf5sdk.outputs.cache-hit != 'true' # Install SDK if not found in cache
|
||||
run: |
|
||||
cd ${{ runner.temp }}
|
||||
curl https://developer.nordicsemi.com/nRF5_SDK/nRF5_SDK_v15.x.x/nRF5_SDK_15.3.0_59ac345.zip -o nrf5_sdk.zip
|
||||
unzip nrf5_sdk.zip
|
||||
mv nRF5_SDK_15.3.0_59ac345 nrf5_sdk
|
||||
|
||||
- name: Check cache for MCUBoot
|
||||
id: cache-mcuboot
|
||||
uses: actions/cache@v2
|
||||
env:
|
||||
cache-name: cache-mcuboot
|
||||
with:
|
||||
path: ${{ runner.temp }}/mcuboot
|
||||
key: ${{ runner.os }}-build-${{ env.cache-name }}
|
||||
restore-keys: ${{ runner.os }}-build-${{ env.cache-name }}
|
||||
|
||||
- name: Install MCUBoot
|
||||
if: steps.cache-mcuboot.outputs.cache-hit != 'true' # Install MCUBoot if not found in cache
|
||||
run: |
|
||||
cd ${{ runner.temp }}
|
||||
git clone --branch v1.7.2 https://github.com/mcu-tools/mcuboot
|
||||
|
||||
- name: Install imgtool dependencies
|
||||
run: |
|
||||
pip3 install --user -r ${{ runner.temp }}/mcuboot/scripts/requirements.txt
|
||||
|
||||
- name: Install adafruit-nrfutil
|
||||
run: |
|
||||
pip3 install --user wheel
|
||||
pip3 install --user setuptools
|
||||
pip3 install --user adafruit-nrfutil
|
||||
|
||||
#########################################################################################
|
||||
# Checkout
|
||||
|
||||
# This workaround fixes the error "unsafe repository (REPO is owned by someone else)".
|
||||
# See https://github.com/actions/checkout/issues/760 and https://github.com/actions/checkout/issues/766
|
||||
# The fix in "actions/checkout@v2" was not sufficient as the build process also uses git (to get the current
|
||||
# commit hash, for example).
|
||||
- name: Workaround permission issues
|
||||
run: git config --global --add safe.directory "$GITHUB_WORKSPACE"
|
||||
- name: Checkout source files
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
submodules: recursive
|
||||
|
||||
- name: Show files
|
||||
run: set ; pwd ; ls -l
|
||||
|
||||
#########################################################################################
|
||||
# CMake
|
||||
|
||||
- name: CMake
|
||||
run: |
|
||||
mkdir -p build
|
||||
cd build
|
||||
cmake -G Ninja -DARM_NONE_EABI_TOOLCHAIN_PATH=${{ runner.temp }}/arm-none-eabi -DNRF5_SDK_PATH=${{ runner.temp }}/nrf5_sdk -DUSE_OPENOCD=1 -DBUILD_DFU=1 ../
|
||||
|
||||
#########################################################################################
|
||||
# Make and Upload DFU Package
|
||||
# pinetime-mcuboot-app.img must be flashed at address 0x8000 in the internal flash memory with OpenOCD:
|
||||
# program image.bin 0x8000
|
||||
|
||||
# For Debugging Builds: Remove "make" option "-j" for clearer output. Add "--trace" to see details.
|
||||
# For Faster Builds: Add "make" option "-j"
|
||||
|
||||
- name: Make pinetime-mcuboot-app
|
||||
run: |
|
||||
cmake --build build --target pinetime-mcuboot-app
|
||||
|
||||
- name: Build
|
||||
shell: bash
|
||||
env:
|
||||
SOURCES_DIR: .
|
||||
run: /opt/build.sh all
|
||||
# Unzip the package because Upload Artifact will zip up the files
|
||||
- name: Unzip DFU package
|
||||
run: |
|
||||
# Unzip the package because Upload Artifact will zip up the files
|
||||
unzip build/src/pinetime-mcuboot-app-dfu*.zip -d build/src/pinetime-mcuboot-app-dfu
|
||||
|
||||
- name: Upload DFU package
|
||||
uses: actions/upload-artifact@v2
|
||||
run: unzip ./build/output/pinetime-mcuboot-app-dfu-*.zip -d ./build/output/pinetime-mcuboot-app-dfu
|
||||
- name: Upload DFU artifacts
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: pinetime-mcuboot-app-dfu
|
||||
path: build/src/pinetime-mcuboot-app-dfu/*
|
||||
|
||||
#########################################################################################
|
||||
# Make and Upload Standalone Firmware
|
||||
|
||||
- name: Make pinetime-app
|
||||
run: |
|
||||
cmake --build build --target pinetime-app
|
||||
|
||||
- name: Upload standalone firmware
|
||||
uses: actions/upload-artifact@v2
|
||||
name: InfiniTime DFU ${{ github.head_ref }}
|
||||
path: ./build/output/pinetime-mcuboot-app-dfu/*
|
||||
- name: Upload MCUBoot image artifacts
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: pinetime-app.out
|
||||
path: build/src/pinetime-app*.out
|
||||
|
||||
#########################################################################################
|
||||
# Make but don't Upload the Recovery Firmware to be sure it builds correctly
|
||||
|
||||
- name: Make pinetime-recovery
|
||||
run: |
|
||||
cmake --build build --target pinetime-recovery
|
||||
|
||||
#########################################################################################
|
||||
# Finish
|
||||
|
||||
- name: Find output
|
||||
run: |
|
||||
find . -name "pinetime-app.*" -ls
|
||||
find . -name "pinetime-mcuboot-app.*" -ls
|
||||
|
||||
# Embedded Arm Toolchain and nRF5 SDK will only be cached if the build succeeds.
|
||||
# So make sure that the first build always succeeds, e.g. comment out the "Make" step.
|
||||
name: InfiniTime MCUBoot image ${{ github.head_ref }}
|
||||
path: ./build/output/pinetime-mcuboot-app-image-*.bin
|
||||
|
2
.vscode/launch.json
vendored
@ -52,7 +52,7 @@
|
||||
"servertype": "openocd",
|
||||
"runToMain": true,
|
||||
// Only use armToolchainPath if your arm-none-eabi-gdb is not in your path (some GCC packages does not contain arm-none-eabi-gdb)
|
||||
"armToolchainPath": "${workspaceRoot}/../gcc-arm-none-eabi-9-2020-q2-update/bin",
|
||||
"armToolchainPath": "${workspaceRoot}/../gcc-arm-11.2-2022.02-x86_64-arm-none-eabi/bin",
|
||||
"svdFile": "${workspaceRoot}/nrf52.svd",
|
||||
"configFiles": [
|
||||
"interface/stlink.cfg",
|
||||
|
@ -1,5 +1,5 @@
|
||||
cmake_minimum_required(VERSION 3.10)
|
||||
project(pinetime VERSION 1.8.0 LANGUAGES C CXX ASM)
|
||||
project(pinetime VERSION 1.9.0 LANGUAGES C CXX ASM)
|
||||
|
||||
set(CMAKE_C_STANDARD 99)
|
||||
set(CMAKE_CXX_STANDARD 14)
|
||||
@ -66,7 +66,7 @@ execute_process(COMMAND git rev-parse --short HEAD
|
||||
OUTPUT_VARIABLE PROJECT_GIT_COMMIT_HASH
|
||||
RESULT_VARIABLE PROJECT_GIT_COMMIT_HASH_SUCCESS)
|
||||
|
||||
string(STRIP ${PROJECT_GIT_COMMIT_HASH} PROJECT_GIT_COMMIT_HASH)
|
||||
string(STRIP "${PROJECT_GIT_COMMIT_HASH}" PROJECT_GIT_COMMIT_HASH)
|
||||
|
||||
message("PROJECT_GIT_COMMIT_HASH_SUCCESS? " ${PROJECT_GIT_COMMIT_HASH_SUCCESS})
|
||||
|
||||
|
@ -15,7 +15,7 @@ Fast open-source firmware for the [PineTime smartwatch](https://www.pine64.org/p
|
||||
- [Gadgetbridge](https://gadgetbridge.org/) (Android)
|
||||
- [AmazFish](https://openrepos.net/content/piggz/amazfish/) (SailfishOS)
|
||||
- [Siglo](https://github.com/alexr4535/siglo) (Linux)
|
||||
- [InfiniLink](https://github.com/xan-m/InfiniLink) **[Experimental]** (iOS)
|
||||
- [InfiniLink](https://github.com/InfiniTimeOrg/InfiniLink) **[Experimental]** **[Unmaintained, looking for developers/maintainers]** (iOS)
|
||||
- [ITD](https://gitea.arsenm.dev/Arsen6331/itd) (Linux)
|
||||
|
||||
## Development
|
||||
|
@ -9,14 +9,14 @@ Integrating a BLE stack for the OTA functionality would have used to much memory
|
||||
|
||||
When it is run, this bootloader looks in the SPI flash memory if a new firmware is available. It there is one, it *swaps* the current firmware with the new one (the new one is copied in the main flash memory, and the current one is copied in the SPI flash memory) and run the new one. If the new one fails to run properly, the bootloader is able to revert to the old one and mark the new one as not working.
|
||||
|
||||
As this bootloader does not provide any OTA capability, it is not able to actually download a new version of the application. Providing OTA functionality is thus the responsability of the application firmware.
|
||||
As this bootloader does not provide any OTA capability, it is not able to actually download a new version of the application. Providing OTA functionality is thus the responsibility of the application firmware.
|
||||
|
||||
# About MCUBoot
|
||||
MCUBoot is run at boot time. In normal operation, it just jumps to the reset handler of the application firmware to run it. Once the application firmware is running, MCUBoot does not run at all.
|
||||
|
||||
![MCUBoot boot sequence diagram](../doc/bootloader/boot.png "MCUBoot boot sequence diagram")
|
||||
|
||||
But MCUBoot does much more than that : it can upgrade the firmware that is currently running by a new one, and it is also able to revert to the previous version of the firmware in case the new one does not run propertly.
|
||||
But MCUBoot does much more than that : it can upgrade the firmware that is currently running by a new one, and it is also able to revert to the previous version of the firmware in case the new one does not run properly.
|
||||
|
||||
To do this, it uses 2 memory 'slots' :
|
||||
- **The primary slot** : it contains the current firmware, the one that will be executed by MCUBoot
|
||||
@ -40,7 +40,7 @@ This chapter describes degraded cases that are handled by our bootloader and tho
|
||||
Case | Current bootloader | Solution
|
||||
-----|--------------------|----------------------------------------------
|
||||
Data got corrupted during file transfer | [OK] Application firmware does a CRC check before applying the update, and does not proceed if it fails. | N/A
|
||||
New firmware does not run at all (bad file) (1) | [NOK] MCU executes unknown instructions and will most likely end up in an infinite loop or freeze in an error handler. The bootloader does not run, it can do nothing, the MCU is stucked until next reset | [OK] The bootloader starts the watchdog just before running the new firmware. This way, the watchdog will reset the MCU after ~7s because the firmware does not refresh it. Bootloader reverts to the previous version of the firmware during the reset.
|
||||
New firmware does not run at all (bad file) (1) | [NOK] MCU executes unknown instructions and will most likely end up in an infinite loop or freeze in an error handler. The bootloader does not run, it can do nothing, the MCU is stuck until next reset | [OK] The bootloader starts the watchdog just before running the new firmware. This way, the watchdog will reset the MCU after ~7s because the firmware does not refresh it. Bootloader reverts to the previous version of the firmware during the reset.
|
||||
New firmware runs, does not set the valid bit and does not refresh the watchdog | [NOK] The new firmware runs until the next reset. The bootloader will be able to revert to the previous firmware only during the next reset. If the new firmware does not run properly and does not reset, the bootloader can do nothing until the next reset | [OK] The bootloader starts the watchdog just before running the new firmware. This way, the watchdog will reset the MCU after ~7s because the firmware does not refresh it. Bootloader reverts to the previous version of the firmware during the reset.
|
||||
New firmware does not run properly, does not set the valid bit but refreshes the watchdog | [NOK] The bootloader will be able to revert to the previous firmware only during the next reset. If the new firmware does not run properly and does not reset, the bootloader can do nothing until the next reset | [~] Wait for the battery to drain. The CPU will reset the next time the device is charged and will be able to rollback to the previous version.
|
||||
New firmware does not run properly but sets the valid bit and refreshes the watchdog | [NOK] The bootloader won't revert to the previous version because the valid flag is set | [~] Wait for the battery to drain. The CPU will reset the next time the device is charged. Then, the bootloader must provide a way for the user to force the rollback to the previous version
|
||||
|
1
bootloader/ota-dfu-python/.gitignore
vendored
Normal file
@ -0,0 +1 @@
|
||||
__pycache__
|
@ -236,7 +236,7 @@ class BleDfuControllerSecure(NrfBleDfuController):
|
||||
self._dfu_send_command(Procedures.EXECUTE)
|
||||
self._wait_and_parse_notify()
|
||||
|
||||
print("Init packet successfully transfered")
|
||||
print("Init packet successfully transferred")
|
||||
|
||||
# --------------------------------------------------------------------------
|
||||
# Send the Firmware image to peripheral device.
|
||||
@ -319,5 +319,5 @@ class BleDfuControllerSecure(NrfBleDfuController):
|
||||
self._dfu_send_command(Procedures.EXECUTE)
|
||||
self._wait_and_parse_notify()
|
||||
|
||||
# If everything executed correctly, return amount of bytes transfered
|
||||
# If everything executed correctly, return amount of bytes transferred
|
||||
return obj_max_size
|
||||
|
@ -106,7 +106,6 @@ macro(nRF5x_setup)
|
||||
${NRF5_SDK_PATH}/external/freertos/source/stream_buffer.c
|
||||
${NRF5_SDK_PATH}/external/freertos/source/tasks.c
|
||||
${NRF5_SDK_PATH}/external/freertos/source/timers.c
|
||||
${NRF5_SDK_PATH}/components/libraries/timer/app_timer_freertos.c
|
||||
)
|
||||
|
||||
# freertos include
|
||||
@ -335,7 +334,6 @@ endmacro(nRF5x_addAppFIFO)
|
||||
# adds app-level Timer libraries
|
||||
macro(nRF5x_addAppTimer)
|
||||
list(APPEND SDK_SOURCE_FILES
|
||||
"${NRF5_SDK_PATH}/components/libraries/timer/app_timer.c"
|
||||
)
|
||||
endmacro(nRF5x_addAppTimer)
|
||||
|
||||
|
@ -7,7 +7,7 @@ Cmake script for projects targeting Nordic Semiconductor nRF5x series devices us
|
||||
The script makes use of the following tools:
|
||||
|
||||
- nRF5x SDK by Nordic Semiconductor - SoC specific drivers and libraries (also includes a lot of examples)
|
||||
- JLink by Segger - interface software for the JLink familiy of programmers
|
||||
- JLink by Segger - interface software for the JLink family of programmers
|
||||
- nrfjprog by Nordic Semiconductor - Wrapper utility around JLink
|
||||
- arm-non-eabi-gcc by ARM and the GCC Team - compiler toolchain for embedded (= bare metal) ARM chips
|
||||
|
||||
@ -15,11 +15,11 @@ The script makes use of the following tools:
|
||||
|
||||
1. Download this repo (or add as submodule) to the directory `cmake-nRF5x` in your project
|
||||
|
||||
1. Search the SDK `example` directory for a `sdk_config.h`, `main.c` and a linker script (normally named `<project_name>_gcc_<chip familly>.ld`) that fits your chip and project needs.
|
||||
1. Search the SDK `example` directory for a `sdk_config.h`, `main.c` and a linker script (normally named `<project_name>_gcc_<chip family>.ld`) that fits your chip and project needs.
|
||||
|
||||
1. Copy the `sdk_config.h` and the project `main.c` into a new directory `src`. Modify them as required for your project.
|
||||
|
||||
1. Copy the linker script into the root of your project. Rename it to just `gcc_<chip familly>.ld` For example:
|
||||
1. Copy the linker script into the root of your project. Rename it to just `gcc_<chip family>.ld` For example:
|
||||
|
||||
```
|
||||
gcc_nrf51.ld
|
||||
|
@ -51,16 +51,16 @@ Puncover is really easy to install:
|
||||
- `python -m virtualenv venv`
|
||||
- `source venv/bin/activate`
|
||||
- Install : `pip install .`
|
||||
- Run : `puncover --gcc_tools_base=/path/to/gcc-arm-none-eabi-9-2020-q2-update/bin/arm-none-eabi- --elf_file /path/to/build/directory/src/pinetime-app-1.1.0.out --src_root /path/to/sources --build_dir /path/to/build/directory`
|
||||
- Run : `puncover --gcc_tools_base=/path/to/gcc-arm-11.2-2022.02-x86_64-arm-none-eabi/bin/arm-none-eabi- --elf_file /path/to/build/directory/src/pinetime-app-1.1.0.out --src_root /path/to/sources --build_dir /path/to/build/directory`
|
||||
- Replace
|
||||
* `/path/to/gcc-arm-none-eabi-9-2020-q2-update/bin` with the path to your gcc-arm-none-eabi toolchain
|
||||
* `/path/to/gcc-arm-11.2-2022.02-x86_64-arm-none-eabi/bin` with the path to your gcc-arm-none-eabi toolchain
|
||||
* `/path/to/build/directory/src/pinetime-app-1.1.0.out` with the path to the binary generated by GCC (.out file)
|
||||
* `/path/to/sources` with the path to the root folder of the sources (checkout directory)
|
||||
* `/path/to/build/directory` with the path to the build directory
|
||||
- Launch a browser at http://localhost:5000/
|
||||
|
||||
### Analysis
|
||||
Using the MAP file and tools, we can easily see what symbols are using most of the flash memory. In this case, unsuprisingly, fonts and graphics are the largest use of flash memory.
|
||||
Using the MAP file and tools, we can easily see what symbols are using most of the flash memory. In this case, unsurprisingly, fonts and graphics are the largest use of flash memory.
|
||||
|
||||
![Puncover](./memoryAnalysis/puncover-all-symbols.png)
|
||||
|
||||
@ -150,7 +150,7 @@ You can then display the file using objdump:
|
||||
hexdump ram.bin -v | less
|
||||
```
|
||||
|
||||
The stack is positionned at the end of the RAM -> 0xFFFF. Its size is 8192 bytes, so the end of the stack is at 0xE000.
|
||||
The stack is positioned at the end of the RAM -> 0xFFFF. Its size is 8192 bytes, so the end of the stack is at 0xE000.
|
||||
On the following dump, the maximum stack usage is 520 bytes (0xFFFF - 0xFDF8):
|
||||
|
||||
```
|
||||
|
@ -13,7 +13,7 @@ The service UUID is 00010000-78fc-48fe-8e23-433b3a1942d0
|
||||
|
||||
## Characteristics
|
||||
## Flags (UUID 00010001-78fc-48fe-8e23-433b3a1942d0)
|
||||
All included icons are from pure-maps, which provides the actual routing from the client. The icon names ultimately come from the mapbox project "direction-icons", See https://github.com/rinigus/pure-maps/tree/master/qml/icons/navigation See the end of this document for the full lsit of supported icon names.
|
||||
All included icons are from pure-maps, which provides the actual routing from the client. The icon names ultimately come from the mapbox project "direction-icons", See https://github.com/rinigus/pure-maps/tree/master/qml/icons/navigation See the end of this document for the full list of supported icon names.
|
||||
|
||||
## Narrative (UUID 00010002-78fc-48fe-8e23-433b3a1942d0)
|
||||
This is a client supplied string describing the upcoming instruction such as "At the roundabout take the first exit".
|
||||
|
@ -1,5 +1,5 @@
|
||||
# Build a stub for PineTime using NRF52-DK
|
||||
[NRF52-DK](https://www.nordicsemi.com/Software-and-Tools/Development-Kits/nRF52-DK) is the official developpment kit for the NRF52832 SoC from Nordic Semiconductor used in the PineTime.
|
||||
[NRF52-DK](https://www.nordicsemi.com/Software-and-Tools/Development-Kits/nRF52-DK) is the official development kit for the NRF52832 SoC from Nordic Semiconductor used in the PineTime.
|
||||
|
||||
This development kit can be very useful for PineTime development:
|
||||
* You can use its embedded JLink SWD programmer/debugger to program and debug your code on the PineTime
|
||||
|
@ -1,7 +1,7 @@
|
||||
# How to flash InfiniTime using the SWD interface
|
||||
Download the files **bootloader.bin**, **image-x.y.z.bin** and **pinetime-graphics-x.y.z.bin** from the release page:
|
||||
|
||||
![Image file](imageFile.png)
|
||||
![Image file](gettingStarted/imageFile.png)
|
||||
|
||||
The bootloader reads a boot logo from the external SPI flash memory. The first step consists of flashing a tool in the MCU that will flash the boot logo into this SPI flash memory. This first step is optional but recommended (the bootloader will display garbage on screen for a few second if you don't do it).
|
||||
Using your SWD tool, flash **pinetime-graphics-x.y.z.bin** at offset **0x0000**. Reset the MCU and wait for a few seconds until the logo is completely drawn on the display.
|
||||
|
@ -146,14 +146,14 @@ The new alert characteristic allows sending new notifications to InfiniTime. It
|
||||
For example, here is what a normal notification looks like in Golang (language of `itd`):
|
||||
|
||||
```go
|
||||
// \x00 is the category for simple alert, and there is one new notifcation, hence \x01.
|
||||
// \x00 is the category for simple alert, and there is one new notification, hence \x01.
|
||||
"\x00\x01\x00Test Title\x00Test Body"
|
||||
```
|
||||
|
||||
A call notification looks like so:
|
||||
|
||||
```go
|
||||
// \x03 is the category for calls, and there is one new call notifcation, hence \x01.
|
||||
// \x03 is the category for calls, and there is one new call notification, hence \x01.
|
||||
"\x03\x01\x00Mary"
|
||||
```
|
||||
|
||||
|
@ -3,7 +3,7 @@ Pinetime --> CompanionApp: Start advertising
|
||||
|
||||
group BLE Connection
|
||||
CompanionApp -> Pinetime: Connection request
|
||||
CompanionApp <-> Pinetime: Connection parameters negociation, security procedure,...
|
||||
CompanionApp <-> Pinetime: Connection parameters negotiation, security procedure,...
|
||||
end
|
||||
|
||||
group Service Discovery
|
||||
|
@ -5,7 +5,7 @@ The project is based on 2 main branches:
|
||||
- **master** : this branch is always ready to be deployed. It means that at any time, we should be able to build the branch and release a new version of the application.
|
||||
- **develop** : this branch contains the latest development that will be integrated in the next release once it's considered as stable.
|
||||
|
||||
New features should be implemented in **feature branches** created from **develop**. When the feature is ready, a pull-request is created and it'll be merge into **develop** when it is succesfully reviewed and accepted.
|
||||
New features should be implemented in **feature branches** created from **develop**. When the feature is ready, a pull-request is created and it'll be merge into **develop** when it is successfully reviewed and accepted.
|
||||
|
||||
To release a new version of the application, when develop is considered stable, a **release** branch is created from **develop**. This can be considered as a *release candidate* branch. When everything is OK, this release branch is merged into **master** and the release is generated (a tag is applied to git, the release note is finalized, binaries are built,...) from **master**.
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
# Build
|
||||
## Dependencies
|
||||
To build this project, you'll need:
|
||||
- A cross-compiler : [ARM-GCC (9-2020-q2-update)](https://developer.arm.com/tools-and-software/open-source-software/developer-tools/gnu-toolchain/gnu-rm/downloads/9-2020-q2-update)
|
||||
- A cross-compiler : [ARM-GCC (arm-none-eabi 11.2-2022.02)](https://developer.arm.com/tools-and-software/open-source-software/developer-tools/gnu-toolchain/downloads)
|
||||
- The NRF52 SDK 15.3.0 : [nRF-SDK v15.3.0](https://developer.nordicsemi.com/nRF5_SDK/nRF5_SDK_v15.x.x/nRF5_SDK_15.3.0_59ac345.zip)
|
||||
- The Python 3 modules `cbor`, `intelhex`, `click` and `cryptography` modules for the `mcuboot` tool (see [requirements.txt](../tools/mcuboot/requirements.txt))
|
||||
- To keep the system clean, you can install python modules into a python virtual environment (`venv`)
|
||||
@ -12,6 +12,10 @@ To build this project, you'll need:
|
||||
python -m pip install -r tools/mcuboot/requirements.txt
|
||||
```
|
||||
- A reasonably recent version of CMake (I use 3.16.5)
|
||||
- lv_font_conv, to generate the font .c files
|
||||
- see [lv_font_conv](https://github.com/lvgl/lv_font_conv#install-the-script)
|
||||
- install npm (commonly done via the package manager, ensure node's version is at least 12)
|
||||
- install lv_font_conv: `npm install lv_font_conv`
|
||||
|
||||
## Build steps
|
||||
### Clone the repo
|
||||
@ -27,7 +31,7 @@ CMake configures the project according to variables you specify the command line
|
||||
|
||||
Variable | Description | Example|
|
||||
----------|-------------|--------|
|
||||
**ARM_NONE_EABI_TOOLCHAIN_PATH**|path to the toolchain directory|`-DARM_NONE_EABI_TOOLCHAIN_PATH=/home/jf/nrf52/gcc-arm-none-eabi-9-2020-q2-update/`|
|
||||
**ARM_NONE_EABI_TOOLCHAIN_PATH**|path to the toolchain directory|`-DARM_NONE_EABI_TOOLCHAIN_PATH=/home/jf/nrf52/gcc-arm-11.2-2022.02-x86_64-arm-none-eabi/`|
|
||||
**NRF5_SDK_PATH**|path to the NRF52 SDK|`-DNRF5_SDK_PATH=/home/jf/nrf52/Pinetime/sdk`|
|
||||
**USE_JLINK, USE_GDB_CLIENT and USE_OPENOCD**|Enable *JLink* mode, *GDB Client* (Black Magic Probe) mode or *OpenOCD* mode (set the one you want to use to `1`)|`-DUSE_JLINK=1`
|
||||
**CMAKE_BUILD_TYPE (\*)**| Build type (Release or Debug). Release is applied by default if this variable is not specified.|`-DCMAKE_BUILD_TYPE=Debug`
|
||||
@ -43,7 +47,7 @@ By default, this variable is set to *Release*. It compiles the code with size an
|
||||
The *Debug* mode disables all optimizations, which makes the code easier to debug. However, the binary size will likely be too big to fit in the internal flash memory. If you want to build and debug a *Debug* binary, you'll need to disable some parts of the code. For example, the icons for the **Navigation** app use a lot of memory space. You can comment the content of `m_iconMap` in the [Navigation](https://github.com/InfiniTimeOrg/InfiniTime/blob/develop/src/displayapp/screens/Navigation.h#L148) application to free some memory.
|
||||
|
||||
####(**) Note about **BUILD_DFU**:
|
||||
DFU files are the files you'll need to install your build of InfiniTime using OTA (over-the-air) mecanism. To generate the DFU file, the Python tool [adafruit-nrfutil](https://github.com/adafruit/Adafruit_nRF52_nrfutil) is needed on your system. Check that this tool is properly installed before enabling this option.
|
||||
DFU files are the files you'll need to install your build of InfiniTime using OTA (over-the-air) mechanism. To generate the DFU file, the Python tool [adafruit-nrfutil](https://github.com/adafruit/Adafruit_nRF52_nrfutil) is needed on your system. Check that this tool is properly installed before enabling this option.
|
||||
|
||||
#### CMake command line for JLink
|
||||
```
|
||||
|
@ -1,62 +1,58 @@
|
||||
# Build the project using Docker
|
||||
|
||||
A [Docker image (Dockerfile)](../docker) containing all the build environment is available for X86_64 and AMD64 architectures. These images make the build of the firmware and the generation of the DFU file for OTA quite easy, as well as preventing clashes with any other toolchains or development environments you may have installed.
|
||||
A [Docker image (Dockerfile)](../docker) containing all the build environment is available for X86_64 and AMD64 architectures.
|
||||
These images make the build of the firmware and the generation of the DFU file for OTA quite easy, as well as preventing clashes with any other toolchains or development environments you may have installed.
|
||||
|
||||
Based on Ubuntu 18.04 with the following build dependencies:
|
||||
Based on Ubuntu 22.04 with the following build dependencies:
|
||||
|
||||
* ARM GCC Toolchain
|
||||
* nRF SDK
|
||||
* MCUBoot
|
||||
* adafruit-nrfutil
|
||||
* lv_font_conv
|
||||
|
||||
## Run a container to build the project
|
||||
|
||||
The `infinitime-build` image contains all the dependencies you need. The default `CMD` will compile sources found in `/sources`, so you need only mount your code.
|
||||
The `infinitime-build` image contains all the dependencies you need.
|
||||
The default `CMD` will compile sources found in `/sources`, so you need only mount your code.
|
||||
|
||||
Before continuing, make sure you first build the image as indicated in the [Build the image](#build-the-image) section, or check the [Using the image from Docker Hub](#using-the-image-from-docker-hub) section if you prefer to use a pre-made image.
|
||||
|
||||
This example will build the firmware, generate the MCUBoot image and generate the DFU file. For cloning the repo, see [these instructions](../doc/buildAndProgram.md#clone-the-repo). Outputs will be written to **<project_root>/build/output**:
|
||||
This example will build the firmware, generate the MCUBoot image and generate the DFU file.
|
||||
For cloning the repo, see [these instructions](../doc/buildAndProgram.md#clone-the-repo). Outputs will be written to **<project_root>/build/output**:
|
||||
|
||||
```bash
|
||||
cd <project_root> # e.g. cd ./work/Pinetime
|
||||
docker run --rm -it -v $(pwd):/sources infinitime-build
|
||||
docker run --rm -it -v ${PWD}:/sources --user $(id -u):$(id -g) infinitime-build
|
||||
```
|
||||
|
||||
If you only want to build a single CMake target, you can pass it in as the first parameter to the build script. This means calling the script explicitly as it will override the `CMD`. Here's an example For `pinetime-app`:
|
||||
By default, the container runs as `root`, which is not convenient as all the files generated by the build will also belong to `root`.
|
||||
The parameter `--user` overrides that default behavior.
|
||||
The command above will run as your current user.
|
||||
|
||||
If you only want to build a single CMake target, you can pass it in as the first parameter to the build script.
|
||||
This means calling the script explicitly as it will override the `CMD`.
|
||||
Here's an example for `pinetime-app`:
|
||||
|
||||
```bash
|
||||
docker run --rm -it -v $(pwd):/sources infinitime-build /opt/build.sh pinetime-app
|
||||
```
|
||||
|
||||
The image is built using 1000:1000 for the user id and group id. If this is different to your user or group ids (run `id -u` and `id -g` to find out what your id values are if you are unsure), you will need to override them via the `--user` parameter in order to prevent permission errors with the output files (and the cmake build cache).
|
||||
|
||||
Running with this image is the same as above, you just specify the ids to `docker run`:
|
||||
|
||||
```bash
|
||||
docker run --rm -it -v $(pwd):/sources --user $(id -u):$(id -g) infinitime-build
|
||||
```
|
||||
|
||||
Or you can specify your user id and group id (by number, not by name) directly:
|
||||
|
||||
```bash
|
||||
docker run --rm -it -v $(pwd):/sources --user 1234:1234 infinitime-build
|
||||
docker run --rm -it -v ${PWD}:/sources --user $(id -u):$(id -g) infinitime-build /opt/build.sh pinetime-app
|
||||
```
|
||||
|
||||
## Using the image from Docker Hub
|
||||
|
||||
The image is available via Docker Hub for both the amd64 and arm64v8 architectures at [pfeerick/infinitime-build](https://hub.docker.com/r/pfeerick/infinitime-build).
|
||||
The image is available via Docker Hub for both the amd64 and arm64v8 architectures at [infinitime/infinitime-build](https://hub.docker.com/repository/docker/infinitime/infinitime-build).
|
||||
|
||||
It can be pulled (downloaded) using the following command:
|
||||
You can run it using the following command:
|
||||
|
||||
```bash
|
||||
docker pull pfeerick/infinitime-build
|
||||
docker run --rm -it -v ${PWD}:/sources --user $(id -u):$(id -g) infinitime/infinitime-build
|
||||
```
|
||||
|
||||
The default `latest` tag *should* automatically identify the correct image architecture, but if for some reason Docker does not, you can specify it manually:
|
||||
|
||||
* For AMD64 (x86_64) systems: `docker pull pfeerick/infinitime-build:amd64`
|
||||
* For AMD64 (x86_64) systems: `docker pull --platform linux/amd64 infinitime/infinitime-build`
|
||||
|
||||
* For ARM64v8 (ARM64/aarch64) systems: `docker pull pfeerick/infinitime-build:arm64v8`
|
||||
* For ARM64v8 (ARM64/aarch64) systems: `docker pull --platform linux/arm64 infinitime/infinitime-build`
|
||||
|
||||
## Build the image
|
||||
|
||||
@ -65,11 +61,5 @@ You can build the image yourself if you like!
|
||||
The following commands must be run from the root of the project. This operation will take some time but, when done, a new image named *infinitime-build* is available.
|
||||
|
||||
```bash
|
||||
docker image build -t infinitime-build ./docker
|
||||
```
|
||||
|
||||
The `PUID` and `PGID` build arguments are used to set the user and group ids used in the container, meaning you will not need to specify it later unless they change for some reason. Specifying them is not mandatory, as this can be over-ridden at build time via the `--user` flag, but doing so will make the command you need to run later a bit shorter. In the below examples, they are set to your current user id and group id automatically. You can specify them manually, but they must be specified by number, not by name.
|
||||
|
||||
```bash
|
||||
docker image build -t infinitime-build --build-arg PUID=$(id -u) --build-arg PGID=$(id -g) ./docker
|
||||
```
|
||||
docker build -t infinitime-build ./docker
|
||||
```
|
@ -8,7 +8,7 @@ To support as many setups as possible the VS Code configuration files expect the
|
||||
|
||||
Variable | Description | Example
|
||||
----------|-------------|--------
|
||||
**ARM_NONE_EABI_TOOLCHAIN_PATH**|path to the toolchain directory|`export ARM_NONE_EABI_TOOLCHAIN_PATH=/opt/gcc-arm-none-eabi-9-2020-q2-update`
|
||||
**ARM_NONE_EABI_TOOLCHAIN_PATH**|path to the toolchain directory|`export ARM_NONE_EABI_TOOLCHAIN_PATH=/opt/gcc-arm-11.2-2022.02-x86_64-arm-none-eabi`
|
||||
**NRF5_SDK_PATH**|path to the NRF52 SDK|`export NRF5_SDK_PATH=/opt/nRF5_SDK_15.3.0_59ac345`
|
||||
|
||||
## VS Code Extensions
|
||||
|
@ -18,7 +18,7 @@ You can sync the time using companion apps.
|
||||
|
||||
You can also set the time in the settings without a companion app. (version >1.7.0)
|
||||
|
||||
InfiniTime doesn't handle daylight savings automatically, so make sure to set the correct the time or sync it with a companion app.
|
||||
InfiniTime doesn't handle daylight savings automatically, so make sure to set the correct time or sync it with a companion app.
|
||||
|
||||
### Digital watch face
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
FROM ubuntu:18.04
|
||||
FROM ubuntu:22.04
|
||||
|
||||
ARG DEBIAN_FRONTEND=noninteractive
|
||||
RUN apt-get update -qq \
|
||||
@ -11,21 +11,27 @@ RUN apt-get update -qq \
|
||||
make \
|
||||
python3 \
|
||||
python3-pip \
|
||||
python-is-python3 \
|
||||
tar \
|
||||
unzip \
|
||||
wget \
|
||||
# aarch64 packages
|
||||
wget \
|
||||
curl \
|
||||
# aarch64 packages
|
||||
libffi-dev \
|
||||
libssl-dev \
|
||||
python3-dev \
|
||||
python \
|
||||
git \
|
||||
apt-utils \
|
||||
&& curl -sL https://deb.nodesource.com/setup_18.x | bash - \
|
||||
&& apt-get install -y nodejs \
|
||||
&& rm -rf /var/cache/apt/* /var/lib/apt/lists/*;
|
||||
|
||||
# Git needed for PROJECT_GIT_COMMIT_HASH variable setting
|
||||
|
||||
RUN pip3 install adafruit-nrfutil
|
||||
RUN pip3 install -Iv cryptography==3.3
|
||||
RUN pip3 install cbor
|
||||
RUN npm i lv_font_conv@1.5.2 -g
|
||||
|
||||
# build.sh knows how to compile
|
||||
COPY build.sh /opt/
|
||||
@ -38,10 +44,5 @@ RUN bash -c "source /opt/build.sh; GetNrfSdk;"
|
||||
# McuBoot
|
||||
RUN bash -c "source /opt/build.sh; GetMcuBoot;"
|
||||
|
||||
ARG PUID=1000
|
||||
ARG PGID=1000
|
||||
RUN groupadd --system --gid $PGID infinitime && useradd --system --uid $PUID --gid $PGID infinitime
|
||||
|
||||
USER infinitime:infinitime
|
||||
ENV SOURCES_DIR /sources
|
||||
CMD ["/opt/build.sh"]
|
||||
|
@ -9,21 +9,23 @@ set -e
|
||||
export TOOLS_DIR="${TOOLS_DIR:=/opt}"
|
||||
export SOURCES_DIR="${SOURCES_DIR:=/sources}"
|
||||
export BUILD_DIR="${BUILD_DIR:=$SOURCES_DIR/build}"
|
||||
export OUTPUT_DIR="${OUTPUT_DIR:=$BUILD_DIR/output}"
|
||||
export OUTPUT_DIR="${OUTPUT_DIR:=$SOURCES_DIR/build/output}"
|
||||
|
||||
export BUILD_TYPE=${BUILD_TYPE:=Release}
|
||||
export GCC_ARM_VER=${GCC_ARM_VER:="gcc-arm-none-eabi-9-2020-q2-update"}
|
||||
export GCC_ARM_VER=${GCC_ARM_VER:="11.2-2022.02"}
|
||||
export NRF_SDK_VER=${NRF_SDK_VER:="nRF5_SDK_15.3.0_59ac345"}
|
||||
|
||||
MACHINE="$(uname -m)"
|
||||
[[ "$MACHINE" == "arm64" ]] && MACHINE="aarch64"
|
||||
|
||||
export GCC_ARM_PATH="gcc-arm-$GCC_ARM_VER-$MACHINE-arm-none-eabi"
|
||||
|
||||
main() {
|
||||
local target="$1"
|
||||
|
||||
mkdir -p "$TOOLS_DIR"
|
||||
|
||||
[[ ! -d "$TOOLS_DIR/$GCC_ARM_VER" ]] && GetGcc
|
||||
|
||||
[[ ! -d "$TOOLS_DIR/$GCC_ARM_PATH" ]] && GetGcc
|
||||
[[ ! -d "$TOOLS_DIR/$NRF_SDK_VER" ]] && GetNrfSdk
|
||||
[[ ! -d "$TOOLS_DIR/mcuboot" ]] && GetMcuBoot
|
||||
|
||||
@ -31,15 +33,14 @@ main() {
|
||||
|
||||
CmakeGenerate
|
||||
CmakeBuild $target
|
||||
BUILD_RESULT=$?
|
||||
BUILD_RESULT=$?
|
||||
if [ "$DISABLE_POSTBUILD" != "true" -a "$BUILD_RESULT" == 0 ]; then
|
||||
source "$BUILD_DIR/post_build.sh"
|
||||
fi
|
||||
}
|
||||
|
||||
GetGcc() {
|
||||
GCC_SRC="$GCC_ARM_VER-$MACHINE-linux.tar.bz"
|
||||
wget -q https://developer.arm.com/-/media/Files/downloads/gnu-rm/9-2020q2/$GCC_SRC -O - | tar -xj -C $TOOLS_DIR/
|
||||
wget -q https://developer.arm.com/-/media/Files/downloads/gnu/$GCC_ARM_VER/binrel/$GCC_ARM_PATH.tar.xz -O - | tar -xJ -C $TOOLS_DIR/
|
||||
}
|
||||
|
||||
GetMcuBoot() {
|
||||
@ -54,18 +55,14 @@ GetNrfSdk() {
|
||||
}
|
||||
|
||||
CmakeGenerate() {
|
||||
# We can swap the CD and trailing SOURCES_DIR for -B and -S respectively
|
||||
# once we go to newer CMake (Ubuntu 18.10 gives us CMake 3.10)
|
||||
cd "$BUILD_DIR"
|
||||
|
||||
cmake -G "Unix Makefiles" \
|
||||
-S "$SOURCES_DIR" \
|
||||
-B "$BUILD_DIR" \
|
||||
-DCMAKE_BUILD_TYPE=$BUILD_TYPE \
|
||||
-DUSE_OPENOCD=1 \
|
||||
-DARM_NONE_EABI_TOOLCHAIN_PATH="$TOOLS_DIR/$GCC_ARM_VER" \
|
||||
-DARM_NONE_EABI_TOOLCHAIN_PATH="$TOOLS_DIR/$GCC_ARM_PATH" \
|
||||
-DNRF5_SDK_PATH="$TOOLS_DIR/$NRF_SDK_VER" \
|
||||
-DBUILD_DFU=1 \
|
||||
"$SOURCES_DIR"
|
||||
cmake -L -N .
|
||||
-DBUILD_DFU=1
|
||||
}
|
||||
|
||||
CmakeBuild() {
|
||||
@ -76,4 +73,4 @@ CmakeBuild() {
|
||||
fi
|
||||
}
|
||||
|
||||
[[ $SOURCED == "false" ]] && main "$@" || echo "Sourced!"
|
||||
[[ $SOURCED == "false" ]] && main "$@" || echo "Sourced!"
|
||||
|
@ -15,12 +15,10 @@ cp "$BUILD_DIR/src/pinetime-mcuboot-app-dfu-$PROJECT_VERSION.zip" "$OUTPUT_DIR/p
|
||||
cp "$BUILD_DIR/src/pinetime-mcuboot-recovery-loader-image-$PROJECT_VERSION.bin" "$OUTPUT_DIR/pinetime-mcuboot-recovery-loader-image-$PROJECT_VERSION.bin"
|
||||
cp "$BUILD_DIR/src/pinetime-mcuboot-recovery-loader-dfu-$PROJECT_VERSION.zip" "$OUTPUT_DIR/pinetime-mcuboot-recovery-loader-dfu-$PROJECT_VERSION.zip"
|
||||
|
||||
|
||||
mkdir -p "$OUTPUT_DIR/src"
|
||||
cd "$BUILD_DIR"
|
||||
cp src/*.bin "$OUTPUT_DIR/src"
|
||||
cp src/*.hex "$OUTPUT_DIR/src"
|
||||
cp src/*.out "$OUTPUT_DIR/src"
|
||||
cp src/*.map "$OUTPUT_DIR/src"
|
||||
cp $BUILD_DIR/src/*.bin "$OUTPUT_DIR/src/"
|
||||
cp $BUILD_DIR/src/*.hex "$OUTPUT_DIR/src/"
|
||||
cp $BUILD_DIR/src/*.out "$OUTPUT_DIR/src/"
|
||||
cp $BUILD_DIR/src/*.map "$OUTPUT_DIR/src/"
|
||||
|
||||
ls -RUv1 "$OUTPUT_DIR" | sed 's;^\([^/]\); \1;g'
|
@ -13659,12 +13659,12 @@ POSSIBILITY OF SUCH DAMAGE.\n
|
||||
<usage>read</usage>
|
||||
<enumeratedValue>
|
||||
<name>NotPresent</name>
|
||||
<description>Read: no overrun occured</description>
|
||||
<description>Read: no overrun occurred</description>
|
||||
<value>0</value>
|
||||
</enumeratedValue>
|
||||
<enumeratedValue>
|
||||
<name>Present</name>
|
||||
<description>Read: overrun occured</description>
|
||||
<description>Read: overrun occurred</description>
|
||||
<value>1</value>
|
||||
</enumeratedValue>
|
||||
</enumeratedValues>
|
||||
|
@ -31,6 +31,10 @@ const bool BootloaderVersion::IsValid() {
|
||||
|
||||
void BootloaderVersion::SetVersion(uint32_t v) {
|
||||
BootloaderVersion::version = v;
|
||||
snprintf(BootloaderVersion::versionString, BootloaderVersion::VERSION_STR_LEN, "%ld.%ld.%ld",
|
||||
BootloaderVersion::Major(), BootloaderVersion::Minor(), BootloaderVersion::Patch());
|
||||
snprintf(BootloaderVersion::versionString,
|
||||
BootloaderVersion::VERSION_STR_LEN,
|
||||
"%ld.%ld.%ld",
|
||||
BootloaderVersion::Major(),
|
||||
BootloaderVersion::Minor(),
|
||||
BootloaderVersion::Patch());
|
||||
}
|
||||
|
@ -12,6 +12,7 @@ namespace Pinetime {
|
||||
static const char* VersionString();
|
||||
static const bool IsValid();
|
||||
static void SetVersion(uint32_t v);
|
||||
|
||||
private:
|
||||
static uint32_t version;
|
||||
static constexpr size_t VERSION_STR_LEN = 12;
|
||||
|
@ -42,7 +42,6 @@ set(SDK_SOURCE_FILES
|
||||
"${NRF5_SDK_PATH}/modules/nrfx/drivers/src/nrfx_gpiote.c"
|
||||
"${NRF5_SDK_PATH}/modules/nrfx/soc/nrfx_atomic.c"
|
||||
"${NRF5_SDK_PATH}/modules/nrfx/drivers/src/nrfx_saadc.c"
|
||||
"${NRF5_SDK_PATH}/components/libraries/timer/app_timer.h"
|
||||
|
||||
# FreeRTOS
|
||||
${NRF5_SDK_PATH}/external/freertos/source/croutine.c
|
||||
@ -53,7 +52,6 @@ set(SDK_SOURCE_FILES
|
||||
${NRF5_SDK_PATH}/external/freertos/source/stream_buffer.c
|
||||
${NRF5_SDK_PATH}/external/freertos/source/tasks.c
|
||||
${NRF5_SDK_PATH}/external/freertos/source/timers.c
|
||||
${NRF5_SDK_PATH}/components/libraries/timer/app_timer_freertos.c
|
||||
|
||||
# Libs
|
||||
"${NRF5_SDK_PATH}/components/libraries/atomic/nrf_atomic.c"
|
||||
@ -367,36 +365,8 @@ set(QCBOR_SRC
|
||||
)
|
||||
|
||||
list(APPEND IMAGE_FILES
|
||||
displayapp/icons/battery/os_battery_error.c
|
||||
displayapp/icons/battery/os_battery_100.c
|
||||
displayapp/icons/battery/os_battery_090.c
|
||||
displayapp/icons/battery/os_battery_080.c
|
||||
displayapp/icons/battery/os_battery_070.c
|
||||
displayapp/icons/battery/os_battery_060.c
|
||||
displayapp/icons/battery/os_battery_050.c
|
||||
displayapp/icons/battery/os_battery_040.c
|
||||
displayapp/icons/battery/os_battery_030.c
|
||||
displayapp/icons/battery/os_battery_020.c
|
||||
displayapp/icons/battery/os_battery_010.c
|
||||
displayapp/icons/battery/os_battery_005.c
|
||||
|
||||
displayapp/icons/battery/os_batterycharging_100.c
|
||||
displayapp/icons/battery/os_batterycharging_090.c
|
||||
displayapp/icons/battery/os_batterycharging_080.c
|
||||
displayapp/icons/battery/os_batterycharging_070.c
|
||||
displayapp/icons/battery/os_batterycharging_060.c
|
||||
displayapp/icons/battery/os_batterycharging_050.c
|
||||
displayapp/icons/battery/os_batterycharging_040.c
|
||||
displayapp/icons/battery/os_batterycharging_030.c
|
||||
displayapp/icons/battery/os_batterycharging_020.c
|
||||
displayapp/icons/battery/os_batterycharging_010.c
|
||||
displayapp/icons/battery/os_batterycharging_005.c
|
||||
|
||||
displayapp/icons/bluetooth/os_bt_connected.c
|
||||
displayapp/icons/bluetooth/os_bt_disconnected.c
|
||||
|
||||
displayapp/icons/battery/batteryicon.c
|
||||
)
|
||||
|
||||
list(APPEND SOURCE_FILES
|
||||
BootloaderVersion.cpp
|
||||
logging/NrfLogger.cpp
|
||||
@ -404,14 +374,12 @@ list(APPEND SOURCE_FILES
|
||||
displayapp/screens/Screen.cpp
|
||||
displayapp/screens/Clock.cpp
|
||||
displayapp/screens/Tile.cpp
|
||||
displayapp/screens/Meter.cpp
|
||||
displayapp/screens/InfiniPaint.cpp
|
||||
displayapp/screens/Paddle.cpp
|
||||
displayapp/screens/StopWatch.cpp
|
||||
displayapp/screens/BatteryIcon.cpp
|
||||
displayapp/screens/BleIcon.cpp
|
||||
displayapp/screens/NotificationIcon.cpp
|
||||
displayapp/screens/Brightness.cpp
|
||||
displayapp/screens/SystemInfo.cpp
|
||||
displayapp/screens/Label.cpp
|
||||
displayapp/screens/FirmwareUpdate.cpp
|
||||
@ -435,7 +403,9 @@ list(APPEND SOURCE_FILES
|
||||
displayapp/screens/Error.cpp
|
||||
displayapp/screens/Alarm.cpp
|
||||
displayapp/screens/Styles.cpp
|
||||
displayapp/screens/Agenda.cpp
|
||||
displayapp/Colors.cpp
|
||||
displayapp/widgets/Counter.cpp
|
||||
|
||||
## Settings
|
||||
displayapp/screens/settings/QuickSettings.cpp
|
||||
@ -449,14 +419,14 @@ list(APPEND SOURCE_FILES
|
||||
displayapp/screens/settings/SettingSetTime.cpp
|
||||
displayapp/screens/settings/SettingChimes.cpp
|
||||
displayapp/screens/settings/SettingShakeThreshold.cpp
|
||||
displayapp/screens/settings/SettingAirplaneMode.cpp
|
||||
displayapp/screens/settings/SettingBluetooth.cpp
|
||||
|
||||
## Watch faces
|
||||
displayapp/icons/bg_clock.c
|
||||
displayapp/screens/WatchFaceAnalog.cpp
|
||||
displayapp/screens/WatchFaceDigital.cpp
|
||||
displayapp/screens/WatchFaceTerminal.cpp
|
||||
displayapp/screens/PineTimeStyle.cpp
|
||||
displayapp/screens/WatchFacePineTimeStyle.cpp
|
||||
|
||||
##
|
||||
|
||||
@ -488,7 +458,7 @@ list(APPEND SOURCE_FILES
|
||||
components/ble/MusicService.cpp
|
||||
components/ble/weather/WeatherService.cpp
|
||||
components/ble/NavigationService.cpp
|
||||
displayapp/fonts/lv_font_navi_80.c
|
||||
components/ble/AgendaService.cpp
|
||||
components/ble/BatteryInformationService.cpp
|
||||
components/ble/FSService.cpp
|
||||
components/ble/ImmediateAlertService.cpp
|
||||
@ -507,12 +477,6 @@ list(APPEND SOURCE_FILES
|
||||
FreeRTOS/port_cmsis.c
|
||||
|
||||
displayapp/LittleVgl.cpp
|
||||
displayapp/fonts/jetbrains_mono_extrabold_compressed.c
|
||||
displayapp/fonts/jetbrains_mono_bold_20.c
|
||||
displayapp/fonts/jetbrains_mono_76.c
|
||||
displayapp/fonts/jetbrains_mono_42.c
|
||||
displayapp/fonts/lv_font_sys_48.c
|
||||
displayapp/fonts/open_sans_light.c
|
||||
displayapp/lv_pinetime_theme.c
|
||||
|
||||
systemtask/SystemTask.cpp
|
||||
@ -566,6 +530,7 @@ list(APPEND RECOVERY_SOURCE_FILES
|
||||
components/ble/ImmediateAlertService.cpp
|
||||
components/ble/ServiceDiscovery.cpp
|
||||
components/ble/NavigationService.cpp
|
||||
components/ble/AgendaService.cpp
|
||||
components/ble/HeartRateService.cpp
|
||||
components/ble/MotionService.cpp
|
||||
components/firmwarevalidator/FirmwareValidator.cpp
|
||||
@ -626,14 +591,12 @@ set(INCLUDE_FILES
|
||||
displayapp/screens/Screen.h
|
||||
displayapp/screens/Clock.h
|
||||
displayapp/screens/Tile.h
|
||||
displayapp/screens/Meter.h
|
||||
displayapp/screens/InfiniPaint.h
|
||||
displayapp/screens/StopWatch.h
|
||||
displayapp/screens/Paddle.h
|
||||
displayapp/screens/BatteryIcon.h
|
||||
displayapp/screens/BleIcon.h
|
||||
displayapp/screens/NotificationIcon.h
|
||||
displayapp/screens/Brightness.h
|
||||
displayapp/screens/SystemInfo.h
|
||||
displayapp/screens/ScreenList.h
|
||||
displayapp/screens/Label.h
|
||||
@ -648,6 +611,7 @@ set(INCLUDE_FILES
|
||||
displayapp/screens/Timer.h
|
||||
displayapp/screens/Alarm.h
|
||||
displayapp/Colors.h
|
||||
displayapp/widgets/Counter.h
|
||||
drivers/St7789.h
|
||||
drivers/SpiNorFlash.h
|
||||
drivers/SpiMaster.h
|
||||
@ -826,6 +790,15 @@ if (NOT CMAKE_BUILD_TYPE)
|
||||
set(CMAKE_BUILD_TYPE "Release")
|
||||
endif ()
|
||||
|
||||
add_subdirectory(displayapp/fonts)
|
||||
target_compile_options(infinitime_fonts PUBLIC
|
||||
$<$<AND:$<COMPILE_LANGUAGE:C>,$<CONFIG:DEBUG>>: ${COMMON_FLAGS} -Og -g3>
|
||||
$<$<AND:$<COMPILE_LANGUAGE:C>,$<CONFIG:RELEASE>>: ${COMMON_FLAGS} -Os>
|
||||
$<$<AND:$<COMPILE_LANGUAGE:CXX>,$<CONFIG:DEBUG>>: ${COMMON_FLAGS} -Og -g3 -fno-rtti>
|
||||
$<$<AND:$<COMPILE_LANGUAGE:CXX>,$<CONFIG:RELEASE>>: ${COMMON_FLAGS} -Os -fno-rtti>
|
||||
$<$<COMPILE_LANGUAGE:ASM>: -MP -MD -x assembler-with-cpp>
|
||||
)
|
||||
|
||||
# NRF SDK
|
||||
add_library(nrf-sdk STATIC ${SDK_SOURCE_FILES})
|
||||
target_include_directories(nrf-sdk SYSTEM PUBLIC . ../)
|
||||
@ -899,7 +872,7 @@ set(EXECUTABLE_FILE_NAME ${EXECUTABLE_NAME}-${pinetime_VERSION_MAJOR}.${pinetime
|
||||
set(NRF5_LINKER_SCRIPT "${CMAKE_SOURCE_DIR}/gcc_nrf52.ld")
|
||||
add_executable(${EXECUTABLE_NAME} ${SOURCE_FILES})
|
||||
set_target_properties(${EXECUTABLE_NAME} PROPERTIES OUTPUT_NAME ${EXECUTABLE_FILE_NAME})
|
||||
target_link_libraries(${EXECUTABLE_NAME} nimble nrf-sdk lvgl littlefs QCBOR)
|
||||
target_link_libraries(${EXECUTABLE_NAME} nimble nrf-sdk lvgl littlefs QCBOR infinitime_fonts)
|
||||
target_compile_options(${EXECUTABLE_NAME} PUBLIC
|
||||
$<$<AND:$<COMPILE_LANGUAGE:C>,$<CONFIG:DEBUG>>: ${COMMON_FLAGS} -Wextra -Wformat -Wno-missing-field-initializers -Wno-unused-parameter -Og -g3>
|
||||
$<$<AND:$<COMPILE_LANGUAGE:C>,$<CONFIG:RELEASE>>: ${COMMON_FLAGS} -Wextra -Wformat -Wno-missing-field-initializers -Wno-unused-parameter -Os>
|
||||
@ -920,15 +893,14 @@ add_custom_command(TARGET ${EXECUTABLE_NAME}
|
||||
COMMAND ${CMAKE_OBJCOPY} -O ihex ${EXECUTABLE_FILE_NAME}.out "${EXECUTABLE_FILE_NAME}.hex"
|
||||
COMMENT "post build steps for ${EXECUTABLE_FILE_NAME}")
|
||||
|
||||
|
||||
# Build binary intended to be used by bootloader
|
||||
set(EXECUTABLE_MCUBOOT_NAME "pinetime-mcuboot-app")
|
||||
set(EXECUTABLE_MCUBOOT_FILE_NAME ${EXECUTABLE_MCUBOOT_NAME}-${pinetime_VERSION_MAJOR}.${pinetime_VERSION_MINOR}.${pinetime_VERSION_PATCH})
|
||||
set(IMAGE_MCUBOOT_FILE_NAME ${EXECUTABLE_MCUBOOT_NAME}-image-${pinetime_VERSION_MAJOR}.${pinetime_VERSION_MINOR}.${pinetime_VERSION_PATCH}.bin)
|
||||
set(IMAGE_MCUBOOT_FILE_NAME ${EXECUTABLE_MCUBOOT_NAME}-image-${pinetime_VERSION_MAJOR}.${pinetime_VERSION_MINOR}.${pinetime_VERSION_PATCH}.hex)
|
||||
set(DFU_MCUBOOT_FILE_NAME ${EXECUTABLE_MCUBOOT_NAME}-dfu-${pinetime_VERSION_MAJOR}.${pinetime_VERSION_MINOR}.${pinetime_VERSION_PATCH}.zip)
|
||||
set(NRF5_LINKER_SCRIPT_MCUBOOT "${CMAKE_SOURCE_DIR}/gcc_nrf52-mcuboot.ld")
|
||||
add_executable(${EXECUTABLE_MCUBOOT_NAME} ${SOURCE_FILES})
|
||||
target_link_libraries(${EXECUTABLE_MCUBOOT_NAME} nimble nrf-sdk lvgl littlefs QCBOR)
|
||||
target_link_libraries(${EXECUTABLE_MCUBOOT_NAME} nimble nrf-sdk lvgl littlefs QCBOR infinitime_fonts)
|
||||
set_target_properties(${EXECUTABLE_MCUBOOT_NAME} PROPERTIES OUTPUT_NAME ${EXECUTABLE_MCUBOOT_FILE_NAME})
|
||||
target_compile_options(${EXECUTABLE_MCUBOOT_NAME} PUBLIC
|
||||
$<$<AND:$<COMPILE_LANGUAGE:C>,$<CONFIG:DEBUG>>: ${COMMON_FLAGS} -Og -g3>
|
||||
@ -948,7 +920,7 @@ add_custom_command(TARGET ${EXECUTABLE_MCUBOOT_NAME}
|
||||
COMMAND ${CMAKE_SIZE_UTIL} ${EXECUTABLE_MCUBOOT_FILE_NAME}.out
|
||||
COMMAND ${CMAKE_OBJCOPY} -O binary ${EXECUTABLE_MCUBOOT_FILE_NAME}.out "${EXECUTABLE_MCUBOOT_FILE_NAME}.bin"
|
||||
COMMAND ${CMAKE_OBJCOPY} -O ihex ${EXECUTABLE_MCUBOOT_FILE_NAME}.out "${EXECUTABLE_MCUBOOT_FILE_NAME}.hex"
|
||||
COMMAND ${CMAKE_SOURCE_DIR}/tools/mcuboot/imgtool.py create --align 4 --version 1.0.0 --header-size 32 --slot-size 475136 --pad-header ${EXECUTABLE_MCUBOOT_FILE_NAME}.bin ${IMAGE_MCUBOOT_FILE_NAME}
|
||||
COMMAND ${CMAKE_SOURCE_DIR}/tools/mcuboot/imgtool.py create --align 4 --version 1.0.0 --header-size 32 --slot-size 475136 --pad-header ${EXECUTABLE_MCUBOOT_FILE_NAME}.hex ${IMAGE_MCUBOOT_FILE_NAME}
|
||||
COMMENT "post build steps for ${EXECUTABLE_MCUBOOT_FILE_NAME}"
|
||||
)
|
||||
|
||||
@ -964,7 +936,7 @@ endif()
|
||||
set(EXECUTABLE_RECOVERY_NAME "pinetime-recovery")
|
||||
set(EXECUTABLE_RECOVERY_FILE_NAME ${EXECUTABLE_RECOVERY_NAME}-${pinetime_VERSION_MAJOR}.${pinetime_VERSION_MINOR}.${pinetime_VERSION_PATCH})
|
||||
add_executable(${EXECUTABLE_RECOVERY_NAME} ${RECOVERY_SOURCE_FILES})
|
||||
target_link_libraries(${EXECUTABLE_RECOVERY_NAME} nimble nrf-sdk littlefs QCBOR)
|
||||
target_link_libraries(${EXECUTABLE_RECOVERY_NAME} nimble nrf-sdk littlefs QCBOR infinitime_fonts)
|
||||
set_target_properties(${EXECUTABLE_RECOVERY_NAME} PROPERTIES OUTPUT_NAME ${EXECUTABLE_RECOVERY_FILE_NAME})
|
||||
target_compile_definitions(${EXECUTABLE_RECOVERY_NAME} PUBLIC "PINETIME_IS_RECOVERY")
|
||||
target_compile_options(${EXECUTABLE_RECOVERY_NAME} PUBLIC
|
||||
@ -991,10 +963,10 @@ add_custom_command(TARGET ${EXECUTABLE_RECOVERY_NAME}
|
||||
# InfiniTime recovery firmware (mcuboot)
|
||||
set(EXECUTABLE_RECOVERY_MCUBOOT_NAME "pinetime-mcuboot-recovery")
|
||||
set(EXECUTABLE_RECOVERY_MCUBOOT_FILE_NAME ${EXECUTABLE_RECOVERY_MCUBOOT_NAME}-${pinetime_VERSION_MAJOR}.${pinetime_VERSION_MINOR}.${pinetime_VERSION_PATCH})
|
||||
set(IMAGE_RECOVERY_MCUBOOT_FILE_NAME ${EXECUTABLE_RECOVERY_MCUBOOT_NAME}-image-${pinetime_VERSION_MAJOR}.${pinetime_VERSION_MINOR}.${pinetime_VERSION_PATCH}.bin)
|
||||
set(IMAGE_RECOVERY_MCUBOOT_FILE_NAME ${EXECUTABLE_RECOVERY_MCUBOOT_NAME}-image-${pinetime_VERSION_MAJOR}.${pinetime_VERSION_MINOR}.${pinetime_VERSION_PATCH}.hex)
|
||||
set(DFU_RECOVERY_MCUBOOT_FILE_NAME ${EXECUTABLE_RECOVERY_MCUBOOT_NAME}-dfu-${pinetime_VERSION_MAJOR}.${pinetime_VERSION_MINOR}.${pinetime_VERSION_PATCH}.zip)
|
||||
add_executable(${EXECUTABLE_RECOVERY_MCUBOOT_NAME} ${RECOVERY_SOURCE_FILES})
|
||||
target_link_libraries(${EXECUTABLE_RECOVERY_MCUBOOT_NAME} nimble nrf-sdk littlefs QCBOR)
|
||||
target_link_libraries(${EXECUTABLE_RECOVERY_MCUBOOT_NAME} nimble nrf-sdk littlefs QCBOR infinitime_fonts)
|
||||
set_target_properties(${EXECUTABLE_RECOVERY_MCUBOOT_NAME} PROPERTIES OUTPUT_NAME ${EXECUTABLE_RECOVERY_MCUBOOT_FILE_NAME})
|
||||
target_compile_definitions(${EXECUTABLE_RECOVERY_MCUBOOT_NAME} PUBLIC "PINETIME_IS_RECOVERY")
|
||||
target_compile_options(${EXECUTABLE_RECOVERY_MCUBOOT_NAME} PUBLIC
|
||||
@ -1007,16 +979,17 @@ target_compile_options(${EXECUTABLE_RECOVERY_MCUBOOT_NAME} PUBLIC
|
||||
|
||||
set_target_properties(${EXECUTABLE_RECOVERY_MCUBOOT_NAME} PROPERTIES
|
||||
SUFFIX ".out"
|
||||
LINK_FLAGS "-mthumb -mabi=aapcs -L ${NRF5_SDK_PATH}/modules/nrfx/mdk -T${NRF5_LINKER_SCRIPT} -mcpu=cortex-m4 -mfloat-abi=hard -mfpu=fpv4-sp-d16 -Wl,--gc-sections -Wl,--print-memory-usage --specs=nano.specs -lc -lnosys -lm -Wl,-Map=${EXECUTABLE_GRAPHICS_FILE_NAME}.map"
|
||||
LINK_FLAGS "-mthumb -mabi=aapcs -L ${NRF5_SDK_PATH}/modules/nrfx/mdk -T${NRF5_LINKER_SCRIPT_MCUBOOT} -mcpu=cortex-m4 -mfloat-abi=hard -mfpu=fpv4-sp-d16 -Wl,--gc-sections -Wl,--print-memory-usage --specs=nano.specs -lc -lnosys -lm -Wl,-Map=${EXECUTABLE_GRAPHICS_FILE_NAME}.map"
|
||||
)
|
||||
|
||||
add_custom_command(TARGET ${EXECUTABLE_RECOVERY_MCUBOOT_NAME}
|
||||
POST_BUILD
|
||||
COMMAND ${CMAKE_SIZE_UTIL} ${EXECUTABLE_RECOVERY_MCUBOOT_FILE_NAME}.out
|
||||
COMMAND ${CMAKE_OBJCOPY} -O binary ${EXECUTABLE_RECOVERY_MCUBOOT_FILE_NAME}.out "${EXECUTABLE_RECOVERY_MCUBOOT_FILE_NAME}.bin"
|
||||
COMMAND ${CMAKE_OBJCOPY} -O ihex ${EXECUTABLE_RECOVERY_MCUBOOT_FILE_NAME}.out "${EXECUTABLE_RECOVERYY_MCUBOOT_FILE_NAME}.hex"
|
||||
COMMAND ${CMAKE_SOURCE_DIR}/tools/mcuboot/imgtool.py create --align 4 --version 1.0.0 --header-size 32 --slot-size 475136 --pad-header ${EXECUTABLE_RECOVERY_MCUBOOT_FILE_NAME}.bin ${IMAGE_RECOVERY_MCUBOOT_FILE_NAME}
|
||||
COMMAND python3 ${CMAKE_SOURCE_DIR}/tools/bin2c.py ${IMAGE_RECOVERY_MCUBOOT_FILE_NAME} recoveryImage > recoveryImage.h
|
||||
COMMAND ${CMAKE_OBJCOPY} -O ihex ${EXECUTABLE_RECOVERY_MCUBOOT_FILE_NAME}.out "${EXECUTABLE_RECOVERY_MCUBOOT_FILE_NAME}.hex"
|
||||
COMMAND ${CMAKE_SOURCE_DIR}/tools/mcuboot/imgtool.py create --align 4 --version 1.0.0 --header-size 32 --slot-size 475136 --pad-header ${EXECUTABLE_RECOVERY_MCUBOOT_FILE_NAME}.hex ${IMAGE_RECOVERY_MCUBOOT_FILE_NAME}
|
||||
COMMAND ${CMAKE_OBJCOPY} -I ihex -O binary ${IMAGE_RECOVERY_MCUBOOT_FILE_NAME} "${IMAGE_RECOVERY_MCUBOOT_FILE_NAME}.bin"
|
||||
COMMAND python3 ${CMAKE_SOURCE_DIR}/tools/bin2c.py ${IMAGE_RECOVERY_MCUBOOT_FILE_NAME}.bin recoveryImage > recoveryImage.h
|
||||
COMMENT "post build steps for ${EXECUTABLE_RECOVERY_MCUBOOT_FILE_NAME}"
|
||||
)
|
||||
|
||||
@ -1032,7 +1005,7 @@ endif()
|
||||
set(EXECUTABLE_RECOVERYLOADER_NAME "pinetime-recovery-loader")
|
||||
set(EXECUTABLE_RECOVERYLOADER_FILE_NAME ${EXECUTABLE_RECOVERYLOADER_NAME}-${pinetime_VERSION_MAJOR}.${pinetime_VERSION_MINOR}.${pinetime_VERSION_PATCH})
|
||||
add_executable(${EXECUTABLE_RECOVERYLOADER_NAME} ${RECOVERYLOADER_SOURCE_FILES})
|
||||
target_link_libraries(${EXECUTABLE_RECOVERYLOADER_NAME} nrf-sdk QCBOR)
|
||||
target_link_libraries(${EXECUTABLE_RECOVERYLOADER_NAME} nrf-sdk QCBOR infinitime_fonts)
|
||||
set_target_properties(${EXECUTABLE_RECOVERYLOADER_NAME} PROPERTIES OUTPUT_NAME ${EXECUTABLE_RECOVERYLOADER_FILE_NAME})
|
||||
target_compile_options(${EXECUTABLE_RECOVERYLOADER_NAME} PUBLIC
|
||||
$<$<AND:$<COMPILE_LANGUAGE:C>,$<CONFIG:DEBUG>>: ${COMMON_FLAGS} -Og -g3>
|
||||
@ -1062,10 +1035,10 @@ add_custom_command(TARGET ${EXECUTABLE_RECOVERYLOADER_NAME}
|
||||
# Build binary that writes the recovery image (MCUBoot version)
|
||||
set(EXECUTABLE_MCUBOOT_RECOVERYLOADER_NAME "pinetime-mcuboot-recovery-loader")
|
||||
set(EXECUTABLE_MCUBOOT_RECOVERYLOADER_FILE_NAME ${EXECUTABLE_MCUBOOT_RECOVERYLOADER_NAME}-${pinetime_VERSION_MAJOR}.${pinetime_VERSION_MINOR}.${pinetime_VERSION_PATCH})
|
||||
set(IMAGE_MCUBOOT_RECOVERYLOADER_FILE_NAME ${EXECUTABLE_MCUBOOT_RECOVERYLOADER_NAME}-image-${pinetime_VERSION_MAJOR}.${pinetime_VERSION_MINOR}.${pinetime_VERSION_PATCH}.bin)
|
||||
set(IMAGE_MCUBOOT_RECOVERYLOADER_FILE_NAME ${EXECUTABLE_MCUBOOT_RECOVERYLOADER_NAME}-image-${pinetime_VERSION_MAJOR}.${pinetime_VERSION_MINOR}.${pinetime_VERSION_PATCH}.hex)
|
||||
set(DFU_MCUBOOT_RECOVERYLOADER_FILE_NAME ${EXECUTABLE_MCUBOOT_RECOVERYLOADER_NAME}-dfu-${pinetime_VERSION_MAJOR}.${pinetime_VERSION_MINOR}.${pinetime_VERSION_PATCH}.zip)
|
||||
add_executable(${EXECUTABLE_MCUBOOT_RECOVERYLOADER_NAME} ${RECOVERYLOADER_SOURCE_FILES})
|
||||
target_link_libraries(${EXECUTABLE_MCUBOOT_RECOVERYLOADER_NAME} nrf-sdk QCBOR)
|
||||
target_link_libraries(${EXECUTABLE_MCUBOOT_RECOVERYLOADER_NAME} nrf-sdk QCBOR infinitime_fonts)
|
||||
set_target_properties(${EXECUTABLE_MCUBOOT_RECOVERYLOADER_NAME} PROPERTIES OUTPUT_NAME ${EXECUTABLE_MCUBOOT_RECOVERYLOADER_FILE_NAME})
|
||||
target_compile_options(${EXECUTABLE_MCUBOOT_RECOVERYLOADER_NAME} PUBLIC
|
||||
$<$<AND:$<COMPILE_LANGUAGE:C>,$<CONFIG:DEBUG>>: ${COMMON_FLAGS} -Og -g3>
|
||||
@ -1089,8 +1062,9 @@ add_custom_command(TARGET ${EXECUTABLE_MCUBOOT_RECOVERYLOADER_NAME}
|
||||
COMMAND ${CMAKE_SIZE_UTIL} ${EXECUTABLE_MCUBOOT_RECOVERYLOADER_FILE_NAME}.out
|
||||
COMMAND ${CMAKE_OBJCOPY} -O binary ${EXECUTABLE_MCUBOOT_RECOVERYLOADER_FILE_NAME}.out "${EXECUTABLE_MCUBOOT_RECOVERYLOADER_FILE_NAME}.bin"
|
||||
COMMAND ${CMAKE_OBJCOPY} -O ihex ${EXECUTABLE_MCUBOOT_RECOVERYLOADER_FILE_NAME}.out "${EXECUTABLE_MCUBOOT_RECOVERYLOADER_FILE_NAME}.hex"
|
||||
COMMAND ${CMAKE_SOURCE_DIR}/tools/mcuboot/imgtool.py create --align 4 --version 1.0.0 --header-size 32 --slot-size 475136 --pad-header ${EXECUTABLE_MCUBOOT_RECOVERYLOADER_FILE_NAME}.bin ${IMAGE_MCUBOOT_RECOVERYLOADER_FILE_NAME}
|
||||
COMMAND python3 ${CMAKE_SOURCE_DIR}/tools/bin2c.py ${IMAGE_MCUBOOT_RECOVERYLOADER_FILE_NAME} recoveryLoaderImage > recoveryLoaderImage.h
|
||||
COMMAND ${CMAKE_SOURCE_DIR}/tools/mcuboot/imgtool.py create --align 4 --version 1.0.0 --header-size 32 --slot-size 475136 --pad-header ${EXECUTABLE_MCUBOOT_RECOVERYLOADER_FILE_NAME}.hex ${IMAGE_MCUBOOT_RECOVERYLOADER_FILE_NAME}
|
||||
COMMAND ${CMAKE_OBJCOPY} -I ihex -O binary ${IMAGE_MCUBOOT_RECOVERYLOADER_FILE_NAME} "${IMAGE_MCUBOOT_RECOVERYLOADER_FILE_NAME}.bin"
|
||||
COMMAND python3 ${CMAKE_SOURCE_DIR}/tools/bin2c.py ${IMAGE_MCUBOOT_RECOVERYLOADER_FILE_NAME}.bin recoveryLoaderImage > recoveryLoaderImage.h
|
||||
COMMENT "post build steps for ${EXECUTABLE_MCUBOOT_RECOVERYLOADER_FILE_NAME}"
|
||||
)
|
||||
|
||||
|
@ -17,7 +17,6 @@
|
||||
*/
|
||||
#include "components/alarm/AlarmController.h"
|
||||
#include "systemtask/SystemTask.h"
|
||||
#include "app_timer.h"
|
||||
#include "task.h"
|
||||
#include <chrono>
|
||||
|
||||
@ -27,20 +26,16 @@ using namespace std::chrono_literals;
|
||||
AlarmController::AlarmController(Controllers::DateTime& dateTimeController) : dateTimeController {dateTimeController} {
|
||||
}
|
||||
|
||||
APP_TIMER_DEF(alarmAppTimer);
|
||||
|
||||
namespace {
|
||||
void SetOffAlarm(void* p_context) {
|
||||
auto* controller = static_cast<Pinetime::Controllers::AlarmController*>(p_context);
|
||||
if (controller != nullptr) {
|
||||
controller->SetOffAlarmNow();
|
||||
}
|
||||
void SetOffAlarm(TimerHandle_t xTimer) {
|
||||
auto controller = static_cast<Pinetime::Controllers::AlarmController*>(pvTimerGetTimerID(xTimer));
|
||||
controller->SetOffAlarmNow();
|
||||
}
|
||||
}
|
||||
|
||||
void AlarmController::Init(System::SystemTask* systemTask) {
|
||||
app_timer_create(&alarmAppTimer, APP_TIMER_MODE_SINGLE_SHOT, SetOffAlarm);
|
||||
this->systemTask = systemTask;
|
||||
alarmTimer = xTimerCreate("Alarm", 1, pdFALSE, this, SetOffAlarm);
|
||||
}
|
||||
|
||||
void AlarmController::SetAlarmTime(uint8_t alarmHr, uint8_t alarmMin) {
|
||||
@ -49,12 +44,12 @@ void AlarmController::SetAlarmTime(uint8_t alarmHr, uint8_t alarmMin) {
|
||||
}
|
||||
|
||||
void AlarmController::ScheduleAlarm() {
|
||||
// Determine the next time the alarm needs to go off and set the app_timer
|
||||
app_timer_stop(alarmAppTimer);
|
||||
// Determine the next time the alarm needs to go off and set the timer
|
||||
xTimerStop(alarmTimer, 0);
|
||||
|
||||
auto now = dateTimeController.CurrentDateTime();
|
||||
alarmTime = now;
|
||||
time_t ttAlarmTime = std::chrono::system_clock::to_time_t(alarmTime);
|
||||
time_t ttAlarmTime = std::chrono::system_clock::to_time_t(std::chrono::time_point_cast<std::chrono::system_clock::duration>(alarmTime));
|
||||
tm* tmAlarmTime = std::localtime(&ttAlarmTime);
|
||||
|
||||
// If the time being set has already passed today,the alarm should be set for tomorrow
|
||||
@ -80,8 +75,9 @@ void AlarmController::ScheduleAlarm() {
|
||||
|
||||
// now can convert back to a time_point
|
||||
alarmTime = std::chrono::system_clock::from_time_t(std::mktime(tmAlarmTime));
|
||||
auto mSecToAlarm = std::chrono::duration_cast<std::chrono::milliseconds>(alarmTime - now).count();
|
||||
app_timer_start(alarmAppTimer, APP_TIMER_TICKS(mSecToAlarm), this);
|
||||
auto secondsToAlarm = std::chrono::duration_cast<std::chrono::seconds>(alarmTime - now).count();
|
||||
xTimerChangePeriod(alarmTimer, secondsToAlarm * configTICK_RATE_HZ, 0);
|
||||
xTimerStart(alarmTimer, 0);
|
||||
|
||||
state = AlarmState::Set;
|
||||
}
|
||||
@ -91,7 +87,7 @@ uint32_t AlarmController::SecondsToAlarm() {
|
||||
}
|
||||
|
||||
void AlarmController::DisableAlarm() {
|
||||
app_timer_stop(alarmAppTimer);
|
||||
xTimerStop(alarmTimer, 0);
|
||||
state = AlarmState::Not_Set;
|
||||
}
|
||||
|
||||
@ -101,14 +97,12 @@ void AlarmController::SetOffAlarmNow() {
|
||||
}
|
||||
|
||||
void AlarmController::StopAlerting() {
|
||||
systemTask->PushMessage(System::Messages::StopRinging);
|
||||
|
||||
// Alarm state is off unless this is a recurring alarm
|
||||
if (recurrence == RecurType::None) {
|
||||
state = AlarmState::Not_Set;
|
||||
} else {
|
||||
state = AlarmState::Set;
|
||||
// set next instance
|
||||
ScheduleAlarm();
|
||||
}
|
||||
systemTask->PushMessage(System::Messages::StopRinging);
|
||||
}
|
||||
|
@ -17,6 +17,8 @@
|
||||
*/
|
||||
#pragma once
|
||||
|
||||
#include <FreeRTOS.h>
|
||||
#include <timers.h>
|
||||
#include <cstdint>
|
||||
#include "components/datetime/DateTimeController.h"
|
||||
|
||||
@ -57,6 +59,7 @@ namespace Pinetime {
|
||||
private:
|
||||
Controllers::DateTime& dateTimeController;
|
||||
System::SystemTask* systemTask = nullptr;
|
||||
TimerHandle_t alarmTimer;
|
||||
uint8_t hours = 7;
|
||||
uint8_t minutes = 0;
|
||||
std::chrono::time_point<std::chrono::system_clock, std::chrono::nanoseconds> alarmTime;
|
||||
|
109
src/components/ble/AgendaService.cpp
Normal file
@ -0,0 +1,109 @@
|
||||
/* Copyright (C) 2021 Adam Pigg
|
||||
|
||||
This file is part of InfiniTime.
|
||||
|
||||
InfiniTime is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published
|
||||
by the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
InfiniTime is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#include "components/ble/AgendaService.h"
|
||||
|
||||
#include "systemtask/SystemTask.h"
|
||||
|
||||
namespace {
|
||||
// 3fdaYYXX-e246-472e-b7e0-d2b0f3d9c17a
|
||||
constexpr ble_uuid128_t CharUuid(uint8_t x, uint8_t y) {
|
||||
return ble_uuid128_t {.u = {.type = BLE_UUID_TYPE_128},
|
||||
.value = {0x7a, 0xc1, 0xd9, 0xf3, 0xb0, 0xd2, 0xe0, 0xb7, 0x2e, 0x47, 0x46, 0xe2, x, y, 0xda, 0x3f}};
|
||||
}
|
||||
|
||||
// 00010000-78fc-48fe-8e23-433b3a1942d0
|
||||
constexpr ble_uuid128_t BaseUuid() {
|
||||
return CharUuid(0x00, 0x00);
|
||||
}
|
||||
|
||||
constexpr ble_uuid128_t agendaUuid {BaseUuid()};
|
||||
|
||||
constexpr ble_uuid128_t agendaItemCharUuid {CharUuid(0x01, 0x00)};
|
||||
/*constexpr ble_uuid128_t navNarrativeCharUuid {CharUuid(0x02, 0x00)};
|
||||
constexpr ble_uuid128_t navManDistCharUuid {CharUuid(0x03, 0x00)};
|
||||
constexpr ble_uuid128_t navProgressCharUuid {CharUuid(0x04, 0x00)};*/
|
||||
|
||||
int AgendaCallback(uint16_t conn_handle, uint16_t attr_handle, struct ble_gatt_access_ctxt* ctxt, void* arg) {
|
||||
auto agendaService = static_cast<Pinetime::Controllers::AgendaService*>(arg);
|
||||
return agendaService->OnCommand(conn_handle, attr_handle, ctxt);
|
||||
}
|
||||
} // namespace
|
||||
|
||||
Pinetime::Controllers::AgendaService::AgendaService(Pinetime::System::SystemTask& system) : m_system(system) {
|
||||
characteristicDefinition[0] = {.uuid = &agendaItemCharUuid.u,
|
||||
.access_cb = AgendaCallback,
|
||||
.arg = this,
|
||||
.flags = BLE_GATT_CHR_F_WRITE | BLE_GATT_CHR_F_READ};
|
||||
|
||||
characteristicDefinition[1] = {0};
|
||||
|
||||
serviceDefinition[0] = {.type = BLE_GATT_SVC_TYPE_PRIMARY, .uuid = &agendaUuid.u, .characteristics = characteristicDefinition};
|
||||
serviceDefinition[1] = {0};
|
||||
}
|
||||
|
||||
void Pinetime::Controllers::AgendaService::Init() {
|
||||
int res = 0;
|
||||
res = ble_gatts_count_cfg(serviceDefinition);
|
||||
ASSERT(res == 0);
|
||||
|
||||
res = ble_gatts_add_svcs(serviceDefinition);
|
||||
ASSERT(res == 0);
|
||||
|
||||
m_agenda_times[0] = 1655327841;
|
||||
m_agenda_pieces[0] = "C++ Fumbling";
|
||||
}
|
||||
|
||||
int Pinetime::Controllers::AgendaService::OnCommand(uint16_t conn_handle, uint16_t attr_handle, struct ble_gatt_access_ctxt* ctxt) {
|
||||
|
||||
if (ctxt->op == BLE_GATT_ACCESS_OP_WRITE_CHR) {
|
||||
size_t notifSize = OS_MBUF_PKTLEN(ctxt->om);
|
||||
uint8_t data[notifSize + 1];
|
||||
data[notifSize] = '\0';
|
||||
os_mbuf_copydata(ctxt->om, 0, notifSize, data);
|
||||
if (ble_uuid_cmp(ctxt->chr->uuid, &agendaItemCharUuid.u) == 0) {
|
||||
if (notifSize >= 5) {
|
||||
uint8_t itemIndex = (uint8_t) data[0];
|
||||
uint32_t itemTime = ((uint32_t) data[1]) << 24 | ((uint32_t) data[2]) << 16 | ((uint32_t) data[3]) << 8 | ((uint32_t) data[4]);
|
||||
char* sAgendaItem = (char*) &data[5];
|
||||
if (itemIndex < AGENDA_CAPACITY) { // don't allow a buffer overflow
|
||||
m_agenda_times[itemIndex] = itemTime;
|
||||
// implicit std::string copy/conversion here:
|
||||
m_agenda_pieces[itemIndex] = sAgendaItem;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
uint32_t Pinetime::Controllers::AgendaService::getAgendaTime(uint8_t index) {
|
||||
if (index < AGENDA_CAPACITY) {
|
||||
return m_agenda_times[index];
|
||||
} else {
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
std::string Pinetime::Controllers::AgendaService::getAgendaPiece(uint8_t index) {
|
||||
if (index < AGENDA_CAPACITY) {
|
||||
return m_agenda_pieces[index];
|
||||
} else {
|
||||
return 0;
|
||||
}
|
||||
}
|
59
src/components/ble/AgendaService.h
Normal file
@ -0,0 +1,59 @@
|
||||
/* Copyright (C) 2021 Adam Pigg
|
||||
|
||||
This file is part of InfiniTime.
|
||||
|
||||
InfiniTime is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published
|
||||
by the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
InfiniTime is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*/
|
||||
#pragma once
|
||||
|
||||
#include <cstdint>
|
||||
#include <string>
|
||||
#define min // workaround: nimble's min/max macros conflict with libstdc++
|
||||
#define max
|
||||
#include <host/ble_gap.h>
|
||||
#include <host/ble_uuid.h>
|
||||
#undef max
|
||||
#undef min
|
||||
|
||||
namespace Pinetime {
|
||||
namespace System {
|
||||
class SystemTask;
|
||||
}
|
||||
namespace Controllers {
|
||||
|
||||
class AgendaService {
|
||||
public:
|
||||
static const uint8_t AGENDA_CAPACITY = 35;
|
||||
|
||||
explicit AgendaService(Pinetime::System::SystemTask& system);
|
||||
|
||||
void Init();
|
||||
|
||||
int OnCommand(uint16_t conn_handle, uint16_t attr_handle, struct ble_gatt_access_ctxt* ctxt);
|
||||
|
||||
uint32_t getAgendaTime(uint8_t index);
|
||||
|
||||
std::string getAgendaPiece(uint8_t index);
|
||||
|
||||
private:
|
||||
struct ble_gatt_chr_def characteristicDefinition[2];
|
||||
struct ble_gatt_svc_def serviceDefinition[2];
|
||||
|
||||
uint32_t m_agenda_times[AGENDA_CAPACITY];
|
||||
std::string m_agenda_pieces[AGENDA_CAPACITY];
|
||||
|
||||
Pinetime::System::SystemTask& m_system;
|
||||
};
|
||||
}
|
||||
}
|
@ -26,8 +26,11 @@ namespace {
|
||||
return client->OnCharacteristicsDiscoveryEvent(conn_handle, error, chr);
|
||||
}
|
||||
|
||||
int OnAlertNotificationDescriptorDiscoveryEventCallback(
|
||||
uint16_t conn_handle, const struct ble_gatt_error* error, uint16_t chr_val_handle, const struct ble_gatt_dsc* dsc, void* arg) {
|
||||
int OnAlertNotificationDescriptorDiscoveryEventCallback(uint16_t conn_handle,
|
||||
const struct ble_gatt_error* error,
|
||||
uint16_t chr_val_handle,
|
||||
const struct ble_gatt_dsc* dsc,
|
||||
void* arg) {
|
||||
auto client = static_cast<AlertNotificationClient*>(arg);
|
||||
return client->OnDescriptorDiscoveryEventCallback(conn_handle, error, chr_val_handle, dsc);
|
||||
}
|
||||
|
@ -18,6 +18,7 @@ namespace Pinetime {
|
||||
|
||||
int OnBatteryServiceRequested(uint16_t connectionHandle, uint16_t attributeHandle, ble_gatt_access_ctxt* context);
|
||||
void NotifyBatteryLevel(uint16_t connectionHandle, uint8_t level);
|
||||
|
||||
private:
|
||||
Controllers::Battery& batteryController;
|
||||
static constexpr uint16_t batteryInformationServiceId {0x180F};
|
||||
|
@ -85,10 +85,21 @@ int CurrentTimeClient::OnCurrentTimeReadResult(uint16_t conn_handle, const ble_g
|
||||
// TODO check that attribute->handle equals the handle discovered in OnCharacteristicDiscoveryEvent
|
||||
CtsData result;
|
||||
os_mbuf_copydata(attribute->om, 0, sizeof(CtsData), &result);
|
||||
NRF_LOG_INFO(
|
||||
"Received data: %d-%d-%d %d:%d:%d", result.year, result.month, result.dayofmonth, result.hour, result.minute, result.second);
|
||||
dateTimeController.SetTime(
|
||||
result.year, result.month, result.dayofmonth, 0, result.hour, result.minute, result.second, nrf_rtc_counter_get(portNRF_RTC_REG));
|
||||
NRF_LOG_INFO("Received data: %d-%d-%d %d:%d:%d",
|
||||
result.year,
|
||||
result.month,
|
||||
result.dayofmonth,
|
||||
result.hour,
|
||||
result.minute,
|
||||
result.second);
|
||||
dateTimeController.SetTime(result.year,
|
||||
result.month,
|
||||
result.dayofmonth,
|
||||
0,
|
||||
result.hour,
|
||||
result.minute,
|
||||
result.second,
|
||||
nrf_rtc_counter_get(portNRF_RTC_REG));
|
||||
} else {
|
||||
NRF_LOG_INFO("Error retrieving current time: %d", error->status);
|
||||
}
|
||||
|
@ -29,11 +29,22 @@ int CurrentTimeService::OnTimeAccessed(uint16_t conn_handle, uint16_t attr_handl
|
||||
CtsData result;
|
||||
os_mbuf_copydata(ctxt->om, 0, sizeof(CtsData), &result);
|
||||
|
||||
NRF_LOG_INFO(
|
||||
"Received data: %d-%d-%d %d:%d:%d", result.year, result.month, result.dayofmonth, result.hour, result.minute, result.second);
|
||||
NRF_LOG_INFO("Received data: %d-%d-%d %d:%d:%d",
|
||||
result.year,
|
||||
result.month,
|
||||
result.dayofmonth,
|
||||
result.hour,
|
||||
result.minute,
|
||||
result.second);
|
||||
|
||||
m_dateTimeController.SetTime(
|
||||
result.year, result.month, result.dayofmonth, 0, result.hour, result.minute, result.second, nrf_rtc_counter_get(portNRF_RTC_REG));
|
||||
m_dateTimeController.SetTime(result.year,
|
||||
result.month,
|
||||
result.dayofmonth,
|
||||
0,
|
||||
result.hour,
|
||||
result.minute,
|
||||
result.second,
|
||||
nrf_rtc_counter_get(portNRF_RTC_REG));
|
||||
|
||||
} else if (ctxt->op == BLE_GATT_ACCESS_OP_READ_CHR) {
|
||||
CtsData currentDateTime;
|
||||
|
@ -119,8 +119,10 @@ int DfuService::WritePacketHandler(uint16_t connectionHandle, os_mbuf* om) {
|
||||
bootloaderSize = om->om_data[4] + (om->om_data[5] << 8) + (om->om_data[6] << 16) + (om->om_data[7] << 24);
|
||||
applicationSize = om->om_data[8] + (om->om_data[9] << 8) + (om->om_data[10] << 16) + (om->om_data[11] << 24);
|
||||
bleController.FirmwareUpdateTotalBytes(applicationSize);
|
||||
NRF_LOG_INFO(
|
||||
"[DFU] -> Start data received : SD size : %d, BT size : %d, app size : %d", softdeviceSize, bootloaderSize, applicationSize);
|
||||
NRF_LOG_INFO("[DFU] -> Start data received : SD size : %d, BT size : %d, app size : %d",
|
||||
softdeviceSize,
|
||||
bootloaderSize,
|
||||
applicationSize);
|
||||
|
||||
// wait until SystemTask has finished waking up all devices
|
||||
while (systemTask.IsSleeping()) {
|
||||
@ -165,10 +167,10 @@ int DfuService::WritePacketHandler(uint16_t connectionHandle, os_mbuf* om) {
|
||||
|
||||
if ((nbPacketReceived % nbPacketsToNotify) == 0 && bytesReceived != applicationSize) {
|
||||
uint8_t data[5] {static_cast<uint8_t>(Opcodes::PacketReceiptNotification),
|
||||
(uint8_t)(bytesReceived & 0x000000FFu),
|
||||
(uint8_t)(bytesReceived >> 8u),
|
||||
(uint8_t)(bytesReceived >> 16u),
|
||||
(uint8_t)(bytesReceived >> 24u)};
|
||||
static_cast<uint8_t>(bytesReceived & 0x000000FFu),
|
||||
static_cast<uint8_t>(bytesReceived >> 8u),
|
||||
static_cast<uint8_t>(bytesReceived >> 16u),
|
||||
static_cast<uint8_t>(bytesReceived >> 24u)};
|
||||
NRF_LOG_INFO("[DFU] -> Send packet notification: %d bytes received", bytesReceived);
|
||||
notificationManager.Send(connectionHandle, controlPointCharacteristicHandle, data, 5);
|
||||
}
|
||||
@ -244,7 +246,7 @@ int DfuService::ControlPointHandler(uint16_t connectionHandle, os_mbuf* om) {
|
||||
NRF_LOG_INFO("[DFU] -> Receive firmware image requested, but we are not in Start Init");
|
||||
return 0;
|
||||
}
|
||||
// TODO the chunk size is dependant of the implementation of the host application...
|
||||
// TODO the chunk size is dependent of the implementation of the host application...
|
||||
dfuImage.Init(20, applicationSize, expectedCrc);
|
||||
NRF_LOG_INFO("[DFU] -> Starting receive firmware");
|
||||
state = States::Data;
|
||||
@ -423,9 +425,9 @@ uint16_t DfuService::DfuImage::ComputeCrc(uint8_t const* p_data, uint32_t size,
|
||||
uint16_t crc = (p_crc == NULL) ? 0xFFFF : *p_crc;
|
||||
|
||||
for (uint32_t i = 0; i < size; i++) {
|
||||
crc = (uint8_t)(crc >> 8) | (crc << 8);
|
||||
crc = static_cast<uint8_t>(crc >> 8) | (crc << 8);
|
||||
crc ^= p_data[i];
|
||||
crc ^= (uint8_t)(crc & 0xFF) >> 4;
|
||||
crc ^= static_cast<uint8_t>(crc & 0xFF) >> 4;
|
||||
crc ^= (crc << 8) << 4;
|
||||
crc ^= ((crc & 0xFF) << 4) << 1;
|
||||
}
|
||||
|
@ -81,7 +81,7 @@ int FSService::FSCommandHandler(uint16_t connectionHandle, os_mbuf* om) {
|
||||
return -1;
|
||||
}
|
||||
memcpy(filepath, header->pathstr, plen);
|
||||
filepath[plen] = 0; // Copy and null teminate string
|
||||
filepath[plen] = 0; // Copy and null terminate string
|
||||
ReadResponse resp;
|
||||
os_mbuf* om;
|
||||
resp.command = commands::READ_DATA;
|
||||
@ -148,7 +148,7 @@ int FSService::FSCommandHandler(uint16_t connectionHandle, os_mbuf* om) {
|
||||
return -1; // TODO make this actually return a BLE notif
|
||||
}
|
||||
memcpy(filepath, header->pathstr, plen);
|
||||
filepath[plen] = 0; // Copy and null teminate string
|
||||
filepath[plen] = 0; // Copy and null terminate string
|
||||
fileSize = header->totalSize;
|
||||
WriteResponse resp;
|
||||
resp.command = commands::WRITE_PACING;
|
||||
@ -193,7 +193,7 @@ int FSService::FSCommandHandler(uint16_t connectionHandle, os_mbuf* om) {
|
||||
uint16_t plen = header->pathlen;
|
||||
char path[plen + 1] = {0};
|
||||
memcpy(path, header->pathstr, plen);
|
||||
path[plen] = 0; // Copy and null teminate string
|
||||
path[plen] = 0; // Copy and null terminate string
|
||||
DelResponse resp {};
|
||||
resp.command = commands::DELETE_STATUS;
|
||||
int res = fs.FileDelete(path);
|
||||
@ -208,7 +208,7 @@ int FSService::FSCommandHandler(uint16_t connectionHandle, os_mbuf* om) {
|
||||
uint16_t plen = header->pathlen;
|
||||
char path[plen + 1] = {0};
|
||||
memcpy(path, header->pathstr, plen);
|
||||
path[plen] = 0; // Copy and null teminate string
|
||||
path[plen] = 0; // Copy and null terminate string
|
||||
MKDirResponse resp {};
|
||||
resp.command = commands::MKDIR_STATUS;
|
||||
resp.modification_time = 0;
|
||||
@ -223,7 +223,7 @@ int FSService::FSCommandHandler(uint16_t connectionHandle, os_mbuf* om) {
|
||||
ListDirHeader* header = (ListDirHeader*) om->om_data;
|
||||
uint16_t plen = header->pathlen;
|
||||
char path[plen + 1] = {0};
|
||||
path[plen] = 0; // Copy and null teminate string
|
||||
path[plen] = 0; // Copy and null terminate string
|
||||
memcpy(path, header->pathstr, plen);
|
||||
|
||||
ListDirResponse resp {};
|
||||
@ -290,7 +290,7 @@ int FSService::FSCommandHandler(uint16_t connectionHandle, os_mbuf* om) {
|
||||
header->pathstr[plen] = 0;
|
||||
char path[header->NewPathLength + 1] = {0};
|
||||
memcpy(path, &header->pathstr[plen + 1], header->NewPathLength);
|
||||
path[header->NewPathLength] = 0; // Copy and null teminate string
|
||||
path[header->NewPathLength] = 0; // Copy and null terminate string
|
||||
MoveResponse resp {};
|
||||
resp.command = commands::MOVE_STATUS;
|
||||
int8_t res = (int8_t) fs.Rename(header->pathstr, path);
|
||||
|
@ -57,7 +57,8 @@ int HeartRateService::OnHeartRateRequested(uint16_t connectionHandle, uint16_t a
|
||||
}
|
||||
|
||||
void HeartRateService::OnNewHeartRateValue(uint8_t heartRateValue) {
|
||||
if(!heartRateMeasurementNotificationEnable) return;
|
||||
if (!heartRateMeasurementNotificationEnable)
|
||||
return;
|
||||
|
||||
uint8_t buffer[2] = {0, heartRateController.HeartRate()}; // [0] = flags, [1] = hr value
|
||||
auto* om = ble_hs_mbuf_from_flat(buffer, 2);
|
||||
@ -72,11 +73,11 @@ void HeartRateService::OnNewHeartRateValue(uint8_t heartRateValue) {
|
||||
}
|
||||
|
||||
void HeartRateService::SubscribeNotification(uint16_t connectionHandle, uint16_t attributeHandle) {
|
||||
if(attributeHandle == heartRateMeasurementHandle)
|
||||
if (attributeHandle == heartRateMeasurementHandle)
|
||||
heartRateMeasurementNotificationEnable = true;
|
||||
}
|
||||
|
||||
void HeartRateService::UnsubscribeNotification(uint16_t connectionHandle, uint16_t attributeHandle) {
|
||||
if(attributeHandle == heartRateMeasurementHandle)
|
||||
if (attributeHandle == heartRateMeasurementHandle)
|
||||
heartRateMeasurementNotificationEnable = false;
|
||||
}
|
@ -8,10 +8,8 @@ using namespace Pinetime::Controllers;
|
||||
namespace {
|
||||
// 0003yyxx-78fc-48fe-8e23-433b3a1942d0
|
||||
constexpr ble_uuid128_t CharUuid(uint8_t x, uint8_t y) {
|
||||
return ble_uuid128_t{
|
||||
.u = {.type = BLE_UUID_TYPE_128},
|
||||
.value = { 0xd0, 0x42, 0x19, 0x3a, 0x3b, 0x43, 0x23, 0x8e, 0xfe, 0x48, 0xfc, 0x78, x, y, 0x03, 0x00 }
|
||||
};
|
||||
return ble_uuid128_t {.u = {.type = BLE_UUID_TYPE_128},
|
||||
.value = {0xd0, 0x42, 0x19, 0x3a, 0x3b, 0x43, 0x23, 0x8e, 0xfe, 0x48, 0xfc, 0x78, x, y, 0x03, 0x00}};
|
||||
}
|
||||
|
||||
// 00030000-78fc-48fe-8e23-433b3a1942d0
|
||||
@ -45,11 +43,7 @@ MotionService::MotionService(Pinetime::System::SystemTask& system, Controllers::
|
||||
.val_handle = &motionValuesHandle},
|
||||
{0}},
|
||||
serviceDefinition {
|
||||
{
|
||||
.type = BLE_GATT_SVC_TYPE_PRIMARY,
|
||||
.uuid = &motionServiceUuid.u,
|
||||
.characteristics = characteristicDefinition
|
||||
},
|
||||
{.type = BLE_GATT_SVC_TYPE_PRIMARY, .uuid = &motionServiceUuid.u, .characteristics = characteristicDefinition},
|
||||
{0},
|
||||
} {
|
||||
// TODO refactor to prevent this loop dependency (service depends on controller and controller depends on service)
|
||||
@ -72,8 +66,8 @@ int MotionService::OnStepCountRequested(uint16_t connectionHandle, uint16_t attr
|
||||
|
||||
int res = os_mbuf_append(context->om, &buffer, 4);
|
||||
return (res == 0) ? 0 : BLE_ATT_ERR_INSUFFICIENT_RES;
|
||||
} else if(attributeHandle == motionValuesHandle) {
|
||||
int16_t buffer[3] = { motionController.X(), motionController.Y(), motionController.Z() };
|
||||
} else if (attributeHandle == motionValuesHandle) {
|
||||
int16_t buffer[3] = {motionController.X(), motionController.Y(), motionController.Z()};
|
||||
|
||||
int res = os_mbuf_append(context->om, buffer, 3 * sizeof(int16_t));
|
||||
return (res == 0) ? 0 : BLE_ATT_ERR_INSUFFICIENT_RES;
|
||||
@ -82,7 +76,8 @@ int MotionService::OnStepCountRequested(uint16_t connectionHandle, uint16_t attr
|
||||
}
|
||||
|
||||
void MotionService::OnNewStepCountValue(uint32_t stepCount) {
|
||||
if(!stepCountNoficationEnabled) return;
|
||||
if (!stepCountNoficationEnabled)
|
||||
return;
|
||||
|
||||
uint32_t buffer = stepCount;
|
||||
auto* om = ble_hs_mbuf_from_flat(&buffer, 4);
|
||||
@ -96,9 +91,10 @@ void MotionService::OnNewStepCountValue(uint32_t stepCount) {
|
||||
ble_gattc_notify_custom(connectionHandle, stepCountHandle, om);
|
||||
}
|
||||
void MotionService::OnNewMotionValues(int16_t x, int16_t y, int16_t z) {
|
||||
if(!motionValuesNoficationEnabled) return;
|
||||
if (!motionValuesNoficationEnabled)
|
||||
return;
|
||||
|
||||
int16_t buffer[3] = { motionController.X(), motionController.Y(), motionController.Z() };
|
||||
int16_t buffer[3] = {motionController.X(), motionController.Y(), motionController.Z()};
|
||||
auto* om = ble_hs_mbuf_from_flat(buffer, 3 * sizeof(int16_t));
|
||||
|
||||
uint16_t connectionHandle = system.nimble().connHandle();
|
||||
@ -111,15 +107,15 @@ void MotionService::OnNewMotionValues(int16_t x, int16_t y, int16_t z) {
|
||||
}
|
||||
|
||||
void MotionService::SubscribeNotification(uint16_t connectionHandle, uint16_t attributeHandle) {
|
||||
if(attributeHandle == stepCountHandle)
|
||||
if (attributeHandle == stepCountHandle)
|
||||
stepCountNoficationEnabled = true;
|
||||
else if(attributeHandle == motionValuesHandle)
|
||||
else if (attributeHandle == motionValuesHandle)
|
||||
motionValuesNoficationEnabled = true;
|
||||
}
|
||||
|
||||
void MotionService::UnsubscribeNotification(uint16_t connectionHandle, uint16_t attributeHandle) {
|
||||
if(attributeHandle == stepCountHandle)
|
||||
if (attributeHandle == stepCountHandle)
|
||||
stepCountNoficationEnabled = false;
|
||||
else if(attributeHandle == motionValuesHandle)
|
||||
else if (attributeHandle == motionValuesHandle)
|
||||
motionValuesNoficationEnabled = false;
|
||||
}
|
||||
|
@ -22,10 +22,8 @@
|
||||
namespace {
|
||||
// 0000yyxx-78fc-48fe-8e23-433b3a1942d0
|
||||
constexpr ble_uuid128_t CharUuid(uint8_t x, uint8_t y) {
|
||||
return ble_uuid128_t{
|
||||
.u = {.type = BLE_UUID_TYPE_128},
|
||||
.value = { 0xd0, 0x42, 0x19, 0x3a, 0x3b, 0x43, 0x23, 0x8e, 0xfe, 0x48, 0xfc, 0x78, x, y, 0x00, 0x00 }
|
||||
};
|
||||
return ble_uuid128_t {.u = {.type = BLE_UUID_TYPE_128},
|
||||
.value = {0xd0, 0x42, 0x19, 0x3a, 0x3b, 0x43, 0x23, 0x8e, 0xfe, 0x48, 0xfc, 0x78, x, y, 0x00, 0x00}};
|
||||
}
|
||||
|
||||
// 00000000-78fc-48fe-8e23-433b3a1942d0
|
||||
@ -111,8 +109,7 @@ Pinetime::Controllers::MusicService::MusicService(Pinetime::System::SystemTask&
|
||||
.flags = BLE_GATT_CHR_F_WRITE | BLE_GATT_CHR_F_READ};
|
||||
characteristicDefinition[13] = {0};
|
||||
|
||||
serviceDefinition[0] = {
|
||||
.type = BLE_GATT_SVC_TYPE_PRIMARY, .uuid = &msUuid.u, .characteristics = characteristicDefinition};
|
||||
serviceDefinition[0] = {.type = BLE_GATT_SVC_TYPE_PRIMARY, .uuid = &msUuid.u, .characteristics = characteristicDefinition};
|
||||
serviceDefinition[1] = {0};
|
||||
}
|
||||
|
||||
@ -137,9 +134,9 @@ int Pinetime::Controllers::MusicService::OnCommand(uint16_t conn_handle, uint16_
|
||||
os_mbuf_copydata(ctxt->om, 0, bufferSize, data);
|
||||
|
||||
if (notifSize > bufferSize) {
|
||||
data[bufferSize-1] = '.';
|
||||
data[bufferSize-2] = '.';
|
||||
data[bufferSize-3] = '.';
|
||||
data[bufferSize - 1] = '.';
|
||||
data[bufferSize - 2] = '.';
|
||||
data[bufferSize - 3] = '.';
|
||||
}
|
||||
data[bufferSize] = '\0';
|
||||
|
||||
@ -152,12 +149,21 @@ int Pinetime::Controllers::MusicService::OnCommand(uint16_t conn_handle, uint16_
|
||||
albumName = s;
|
||||
} else if (ble_uuid_cmp(ctxt->chr->uuid, &msStatusCharUuid.u) == 0) {
|
||||
playing = s[0];
|
||||
// These variables need to be updated, because the progress may not be updated immediately,
|
||||
// leading to getProgress() returning an incorrect position.
|
||||
if (playing) {
|
||||
trackProgressUpdateTime = xTaskGetTickCount();
|
||||
} else {
|
||||
trackProgress +=
|
||||
static_cast<int>((static_cast<float>(xTaskGetTickCount() - trackProgressUpdateTime) / 1024.0f) * getPlaybackSpeed());
|
||||
}
|
||||
} else if (ble_uuid_cmp(ctxt->chr->uuid, &msRepeatCharUuid.u) == 0) {
|
||||
repeat = s[0];
|
||||
} else if (ble_uuid_cmp(ctxt->chr->uuid, &msShuffleCharUuid.u) == 0) {
|
||||
shuffle = s[0];
|
||||
} else if (ble_uuid_cmp(ctxt->chr->uuid, &msPositionCharUuid.u) == 0) {
|
||||
trackProgress = (s[0] << 24) | (s[1] << 16) | (s[2] << 8) | s[3];
|
||||
trackProgressUpdateTime = xTaskGetTickCount();
|
||||
} else if (ble_uuid_cmp(ctxt->chr->uuid, &msTotalLengthCharUuid.u) == 0) {
|
||||
trackLength = (s[0] << 24) | (s[1] << 16) | (s[2] << 8) | s[3];
|
||||
} else if (ble_uuid_cmp(ctxt->chr->uuid, &msTrackNumberCharUuid.u) == 0) {
|
||||
@ -192,6 +198,10 @@ float Pinetime::Controllers::MusicService::getPlaybackSpeed() const {
|
||||
}
|
||||
|
||||
int Pinetime::Controllers::MusicService::getProgress() const {
|
||||
if (isPlaying()) {
|
||||
return trackProgress +
|
||||
static_cast<int>((static_cast<float>(xTaskGetTickCount() - trackProgressUpdateTime) / 1024.0f) * getPlaybackSpeed());
|
||||
}
|
||||
return trackProgress;
|
||||
}
|
||||
|
||||
|
@ -81,6 +81,7 @@ namespace Pinetime {
|
||||
int trackLength {0};
|
||||
int trackNumber {};
|
||||
int tracksTotal {};
|
||||
TickType_t trackProgressUpdateTime {0};
|
||||
|
||||
float playbackSpeed {1.0f};
|
||||
|
||||
|
@ -46,15 +46,23 @@ namespace {
|
||||
} // namespace
|
||||
|
||||
Pinetime::Controllers::NavigationService::NavigationService(Pinetime::System::SystemTask& system) : m_system(system) {
|
||||
characteristicDefinition[0] = {
|
||||
.uuid = &navFlagCharUuid.u, .access_cb = NAVCallback, .arg = this, .flags = BLE_GATT_CHR_F_WRITE | BLE_GATT_CHR_F_READ};
|
||||
characteristicDefinition[0] = {.uuid = &navFlagCharUuid.u,
|
||||
.access_cb = NAVCallback,
|
||||
.arg = this,
|
||||
.flags = BLE_GATT_CHR_F_WRITE | BLE_GATT_CHR_F_READ};
|
||||
|
||||
characteristicDefinition[1] = {
|
||||
.uuid = &navNarrativeCharUuid.u, .access_cb = NAVCallback, .arg = this, .flags = BLE_GATT_CHR_F_WRITE | BLE_GATT_CHR_F_READ};
|
||||
characteristicDefinition[2] = {
|
||||
.uuid = &navManDistCharUuid.u, .access_cb = NAVCallback, .arg = this, .flags = BLE_GATT_CHR_F_WRITE | BLE_GATT_CHR_F_READ};
|
||||
characteristicDefinition[3] = {
|
||||
.uuid = &navProgressCharUuid.u, .access_cb = NAVCallback, .arg = this, .flags = BLE_GATT_CHR_F_WRITE | BLE_GATT_CHR_F_READ};
|
||||
characteristicDefinition[1] = {.uuid = &navNarrativeCharUuid.u,
|
||||
.access_cb = NAVCallback,
|
||||
.arg = this,
|
||||
.flags = BLE_GATT_CHR_F_WRITE | BLE_GATT_CHR_F_READ};
|
||||
characteristicDefinition[2] = {.uuid = &navManDistCharUuid.u,
|
||||
.access_cb = NAVCallback,
|
||||
.arg = this,
|
||||
.flags = BLE_GATT_CHR_F_WRITE | BLE_GATT_CHR_F_READ};
|
||||
characteristicDefinition[3] = {.uuid = &navProgressCharUuid.u,
|
||||
.access_cb = NAVCallback,
|
||||
.arg = this,
|
||||
.flags = BLE_GATT_CHR_F_WRITE | BLE_GATT_CHR_F_READ};
|
||||
|
||||
characteristicDefinition[4] = {0};
|
||||
|
||||
|
@ -35,7 +35,6 @@ NimbleController::NimbleController(Pinetime::System::SystemTask& systemTask,
|
||||
: systemTask {systemTask},
|
||||
bleController {bleController},
|
||||
dateTimeController {dateTimeController},
|
||||
notificationManager {notificationManager},
|
||||
spiNorFlash {spiNorFlash},
|
||||
fs {fs},
|
||||
dfuService {systemTask, bleController, spiNorFlash},
|
||||
@ -52,6 +51,7 @@ NimbleController::NimbleController(Pinetime::System::SystemTask& systemTask,
|
||||
heartRateService {systemTask, heartRateController},
|
||||
motionService {systemTask, motionController},
|
||||
fsService {systemTask, fs},
|
||||
agendaService {systemTask},
|
||||
serviceDiscovery({¤tTimeClient, &alertNotificationClient}) {
|
||||
}
|
||||
|
||||
@ -94,6 +94,7 @@ void NimbleController::Init() {
|
||||
musicService.Init();
|
||||
weatherService.Init();
|
||||
navService.Init();
|
||||
agendaService.Init();
|
||||
anService.Init();
|
||||
dfuService.Init();
|
||||
batteryInformationService.Init();
|
||||
@ -224,7 +225,7 @@ int NimbleController::OnGAPEvent(ble_gap_event* event) {
|
||||
currentTimeClient.Reset();
|
||||
alertNotificationClient.Reset();
|
||||
connectionHandle = BLE_HS_CONN_HANDLE_NONE;
|
||||
if(bleController.IsConnected()) {
|
||||
if (bleController.IsConnected()) {
|
||||
bleController.Disconnect();
|
||||
fastAdvCount = 0;
|
||||
StartAdvertising();
|
||||
|
@ -21,6 +21,7 @@
|
||||
#include "components/ble/NavigationService.h"
|
||||
#include "components/ble/ServiceDiscovery.h"
|
||||
#include "components/ble/MotionService.h"
|
||||
#include "components/ble/AgendaService.h"
|
||||
#include "components/ble/weather/WeatherService.h"
|
||||
#include "components/fs/FS.h"
|
||||
|
||||
@ -61,6 +62,9 @@ namespace Pinetime {
|
||||
Pinetime::Controllers::NavigationService& navigation() {
|
||||
return navService;
|
||||
};
|
||||
Pinetime::Controllers::AgendaService& agenda() {
|
||||
return agendaService;
|
||||
};
|
||||
Pinetime::Controllers::AlertNotificationService& alertService() {
|
||||
return anService;
|
||||
};
|
||||
@ -86,7 +90,6 @@ namespace Pinetime {
|
||||
Pinetime::System::SystemTask& systemTask;
|
||||
Ble& bleController;
|
||||
DateTime& dateTimeController;
|
||||
NotificationManager& notificationManager;
|
||||
Pinetime::Drivers::SpiNorFlash& spiNorFlash;
|
||||
FS& fs;
|
||||
DfuService dfuService;
|
||||
@ -104,6 +107,7 @@ namespace Pinetime {
|
||||
HeartRateService heartRateService;
|
||||
MotionService motionService;
|
||||
FSService fsService;
|
||||
AgendaService agendaService;
|
||||
ServiceDiscovery serviceDiscovery;
|
||||
|
||||
uint8_t addrType;
|
||||
|
@ -127,7 +127,8 @@ namespace Pinetime {
|
||||
{.uuid = &weatherControlCharUuid.u, .access_cb = WeatherCallback, .arg = this, .flags = BLE_GATT_CHR_F_WRITE | BLE_GATT_CHR_F_READ},
|
||||
{nullptr}};
|
||||
const struct ble_gatt_svc_def serviceDefinition[2] = {
|
||||
{.type = BLE_GATT_SVC_TYPE_PRIMARY, .uuid = &weatherUuid.u, .characteristics = characteristicDefinition}, {0}};
|
||||
{.type = BLE_GATT_SVC_TYPE_PRIMARY, .uuid = &weatherUuid.u, .characteristics = characteristicDefinition},
|
||||
{0}};
|
||||
|
||||
uint16_t eventHandle {};
|
||||
|
||||
|
@ -19,8 +19,14 @@ void DateTime::SetCurrentTime(std::chrono::time_point<std::chrono::system_clock,
|
||||
UpdateTime(previousSystickCounter); // Update internal state without updating the time
|
||||
}
|
||||
|
||||
void DateTime::SetTime(
|
||||
uint16_t year, uint8_t month, uint8_t day, uint8_t dayOfWeek, uint8_t hour, uint8_t minute, uint8_t second, uint32_t systickCounter) {
|
||||
void DateTime::SetTime(uint16_t year,
|
||||
uint8_t month,
|
||||
uint8_t day,
|
||||
uint8_t dayOfWeek,
|
||||
uint8_t hour,
|
||||
uint8_t minute,
|
||||
uint8_t second,
|
||||
uint32_t systickCounter) {
|
||||
std::tm tm = {
|
||||
/* .tm_sec = */ second,
|
||||
/* .tm_min = */ minute,
|
||||
@ -129,16 +135,16 @@ std::string DateTime::FormattedTime() {
|
||||
// Return time as a string in 12- or 24-hour format
|
||||
char buff[9];
|
||||
if (settingsController.GetClockType() == ClockType::H12) {
|
||||
uint8_t hour12;
|
||||
const char* amPmStr;
|
||||
if (hour < 12) {
|
||||
hour12 = (hour == 0) ? 12 : hour;
|
||||
amPmStr = "AM";
|
||||
} else {
|
||||
hour12 = (hour == 12) ? 12 : hour - 12;
|
||||
amPmStr = "PM";
|
||||
}
|
||||
sprintf(buff, "%i:%02i %s", hour12, minute, amPmStr);
|
||||
uint8_t hour12;
|
||||
const char* amPmStr;
|
||||
if (hour < 12) {
|
||||
hour12 = (hour == 0) ? 12 : hour;
|
||||
amPmStr = "AM";
|
||||
} else {
|
||||
hour12 = (hour == 12) ? 12 : hour - 12;
|
||||
amPmStr = "PM";
|
||||
}
|
||||
sprintf(buff, "%i:%02i %s", hour12, minute, amPmStr);
|
||||
} else {
|
||||
sprintf(buff, "%02i:%02i", hour, minute);
|
||||
}
|
||||
|
@ -95,8 +95,8 @@ int FS::DirRewind(lfs_dir_t* dir) {
|
||||
int FS::DirCreate(const char* path) {
|
||||
return lfs_mkdir(&lfs, path);
|
||||
}
|
||||
int FS::Rename(const char* oldPath, const char* newPath){
|
||||
return lfs_rename(&lfs,oldPath,newPath);
|
||||
int FS::Rename(const char* oldPath, const char* newPath) {
|
||||
return lfs_rename(&lfs, oldPath, newPath);
|
||||
}
|
||||
int FS::Stat(const char* path, lfs_info* info) {
|
||||
return lfs_stat(&lfs, path, info);
|
||||
|
@ -26,7 +26,7 @@ namespace Pinetime {
|
||||
int DirRead(lfs_dir_t* dir, lfs_info* info);
|
||||
int DirRewind(lfs_dir_t* dir);
|
||||
int DirCreate(const char* path);
|
||||
|
||||
|
||||
lfs_ssize_t GetFSSize();
|
||||
int Rename(const char* oldPath, const char* newPath);
|
||||
int Stat(const char* path, lfs_info* info);
|
||||
|
@ -1,43 +1,39 @@
|
||||
#include "components/motor/MotorController.h"
|
||||
#include <hal/nrf_gpio.h>
|
||||
#include "systemtask/SystemTask.h"
|
||||
#include "app_timer.h"
|
||||
#include "drivers/PinMap.h"
|
||||
|
||||
APP_TIMER_DEF(shortVibTimer);
|
||||
APP_TIMER_DEF(longVibTimer);
|
||||
|
||||
using namespace Pinetime::Controllers;
|
||||
|
||||
void MotorController::Init() {
|
||||
nrf_gpio_cfg_output(PinMap::Motor);
|
||||
nrf_gpio_pin_set(PinMap::Motor);
|
||||
app_timer_init();
|
||||
|
||||
app_timer_create(&shortVibTimer, APP_TIMER_MODE_SINGLE_SHOT, StopMotor);
|
||||
app_timer_create(&longVibTimer, APP_TIMER_MODE_REPEATED, Ring);
|
||||
shortVib = xTimerCreate("shortVib", 1, pdFALSE, nullptr, StopMotor);
|
||||
longVib = xTimerCreate("longVib", pdMS_TO_TICKS(1000), pdTRUE, this, Ring);
|
||||
}
|
||||
|
||||
void MotorController::Ring(void* p_context) {
|
||||
auto* motorController = static_cast<MotorController*>(p_context);
|
||||
void MotorController::Ring(TimerHandle_t xTimer) {
|
||||
auto* motorController = static_cast<MotorController*>(pvTimerGetTimerID(xTimer));
|
||||
motorController->RunForDuration(50);
|
||||
}
|
||||
|
||||
void MotorController::RunForDuration(uint8_t motorDuration) {
|
||||
nrf_gpio_pin_clear(PinMap::Motor);
|
||||
app_timer_start(shortVibTimer, APP_TIMER_TICKS(motorDuration), nullptr);
|
||||
if (xTimerChangePeriod(shortVib, pdMS_TO_TICKS(motorDuration), 0) == pdPASS && xTimerStart(shortVib, 0) == pdPASS) {
|
||||
nrf_gpio_pin_clear(PinMap::Motor);
|
||||
}
|
||||
}
|
||||
|
||||
void MotorController::StartRinging() {
|
||||
Ring(this);
|
||||
app_timer_start(longVibTimer, APP_TIMER_TICKS(1000), this);
|
||||
RunForDuration(50);
|
||||
xTimerStart(longVib, 0);
|
||||
}
|
||||
|
||||
void MotorController::StopRinging() {
|
||||
app_timer_stop(longVibTimer);
|
||||
xTimerStop(longVib, 0);
|
||||
nrf_gpio_pin_set(PinMap::Motor);
|
||||
}
|
||||
|
||||
void MotorController::StopMotor(void* p_context) {
|
||||
void MotorController::StopMotor(TimerHandle_t xTimer) {
|
||||
nrf_gpio_pin_set(PinMap::Motor);
|
||||
}
|
||||
|
@ -1,5 +1,7 @@
|
||||
#pragma once
|
||||
|
||||
#include <FreeRTOS.h>
|
||||
#include <timers.h>
|
||||
#include <cstdint>
|
||||
|
||||
namespace Pinetime {
|
||||
@ -15,8 +17,10 @@ namespace Pinetime {
|
||||
void StopRinging();
|
||||
|
||||
private:
|
||||
static void Ring(void* p_context);
|
||||
static void StopMotor(void* p_context);
|
||||
static void Ring(TimerHandle_t xTimer);
|
||||
static void StopMotor(TimerHandle_t xTimer);
|
||||
TimerHandle_t shortVib;
|
||||
TimerHandle_t longVib;
|
||||
};
|
||||
}
|
||||
}
|
||||
|
@ -26,12 +26,12 @@ void Settings::LoadSettingsFromFile() {
|
||||
SettingsData bufferSettings;
|
||||
lfs_file_t settingsFile;
|
||||
|
||||
if ( fs.FileOpen(&settingsFile, "/settings.dat", LFS_O_RDONLY) != LFS_ERR_OK) {
|
||||
if (fs.FileOpen(&settingsFile, "/settings.dat", LFS_O_RDONLY) != LFS_ERR_OK) {
|
||||
return;
|
||||
}
|
||||
fs.FileRead(&settingsFile, reinterpret_cast<uint8_t*>(&bufferSettings), sizeof(settings));
|
||||
fs.FileClose(&settingsFile);
|
||||
if ( bufferSettings.version == settingsVersion ) {
|
||||
if (bufferSettings.version == settingsVersion) {
|
||||
settings = bufferSettings;
|
||||
}
|
||||
}
|
||||
@ -39,7 +39,7 @@ void Settings::LoadSettingsFromFile() {
|
||||
void Settings::SaveSettingsToFile() {
|
||||
lfs_file_t settingsFile;
|
||||
|
||||
if ( fs.FileOpen(&settingsFile, "/settings.dat", LFS_O_WRONLY | LFS_O_CREAT) != LFS_ERR_OK) {
|
||||
if (fs.FileOpen(&settingsFile, "/settings.dat", LFS_O_WRONLY | LFS_O_CREAT) != LFS_ERR_OK) {
|
||||
return;
|
||||
}
|
||||
fs.FileWrite(&settingsFile, reinterpret_cast<uint8_t*>(&settings), sizeof(settings));
|
||||
|
@ -140,15 +140,14 @@ namespace Pinetime {
|
||||
return settings.screenTimeOut;
|
||||
};
|
||||
|
||||
void SetShakeThreshold(uint16_t thresh){
|
||||
if(settings.shakeWakeThreshold != thresh){
|
||||
settings.shakeWakeThreshold = thresh;
|
||||
settingsChanged = true;
|
||||
void SetShakeThreshold(uint16_t thresh) {
|
||||
if (settings.shakeWakeThreshold != thresh) {
|
||||
settings.shakeWakeThreshold = thresh;
|
||||
settingsChanged = true;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
int16_t GetShakeThreshold() const{
|
||||
int16_t GetShakeThreshold() const {
|
||||
return settings.shakeWakeThreshold;
|
||||
}
|
||||
|
||||
@ -195,20 +194,20 @@ namespace Pinetime {
|
||||
if (goal != settings.stepsGoal) {
|
||||
settingsChanged = true;
|
||||
}
|
||||
settings.stepsGoal = goal;
|
||||
settings.stepsGoal = goal;
|
||||
};
|
||||
|
||||
|
||||
uint32_t GetStepsGoal() const {
|
||||
return settings.stepsGoal;
|
||||
};
|
||||
|
||||
void SetBleRadioEnabled(bool enabled) {
|
||||
bleRadioEnabled = enabled;
|
||||
};
|
||||
void SetBleRadioEnabled(bool enabled) {
|
||||
bleRadioEnabled = enabled;
|
||||
};
|
||||
|
||||
bool GetBleRadioEnabled() const {
|
||||
return bleRadioEnabled;
|
||||
};
|
||||
bool GetBleRadioEnabled() const {
|
||||
return bleRadioEnabled;
|
||||
};
|
||||
|
||||
private:
|
||||
Pinetime::Controllers::FS& fs;
|
||||
@ -237,7 +236,7 @@ namespace Pinetime {
|
||||
|
||||
uint8_t appMenu = 0;
|
||||
uint8_t settingsMenu = 0;
|
||||
/* airplaneMode is intentionally not saved with the other watch settings and initialized
|
||||
/* ble state is intentionally not saved with the other watch settings and initialized
|
||||
* to off (false) on every boot because we always want ble to be enabled on startup
|
||||
*/
|
||||
bool bleRadioEnabled = true;
|
||||
|
@ -1,69 +1,39 @@
|
||||
//
|
||||
// Created by florian on 16.05.21.
|
||||
//
|
||||
|
||||
#include "components/timer/TimerController.h"
|
||||
#include "systemtask/SystemTask.h"
|
||||
#include "app_timer.h"
|
||||
#include "task.h"
|
||||
|
||||
using namespace Pinetime::Controllers;
|
||||
|
||||
|
||||
APP_TIMER_DEF(timerAppTimer);
|
||||
|
||||
namespace {
|
||||
void TimerEnd(void* p_context) {
|
||||
auto* controller = static_cast<Pinetime::Controllers::TimerController*> (p_context);
|
||||
if(controller != nullptr)
|
||||
controller->OnTimerEnd();
|
||||
}
|
||||
void TimerCallback(TimerHandle_t xTimer) {
|
||||
auto* controller = static_cast<TimerController*>(pvTimerGetTimerID(xTimer));
|
||||
controller->OnTimerEnd();
|
||||
}
|
||||
|
||||
|
||||
void TimerController::Init() {
|
||||
app_timer_create(&timerAppTimer, APP_TIMER_MODE_SINGLE_SHOT, TimerEnd);
|
||||
void TimerController::Init(Pinetime::System::SystemTask* systemTask) {
|
||||
this->systemTask = systemTask;
|
||||
timer = xTimerCreate("Timer", 1, pdFALSE, this, TimerCallback);
|
||||
}
|
||||
|
||||
void TimerController::StartTimer(uint32_t duration) {
|
||||
app_timer_stop(timerAppTimer);
|
||||
auto currentTicks = xTaskGetTickCount();
|
||||
app_timer_start(timerAppTimer, APP_TIMER_TICKS(duration), this);
|
||||
endTicks = currentTicks + APP_TIMER_TICKS(duration);
|
||||
timerRunning = true;
|
||||
xTimerChangePeriod(timer, pdMS_TO_TICKS(duration), 0);
|
||||
xTimerStart(timer, 0);
|
||||
}
|
||||
|
||||
uint32_t TimerController::GetTimeRemaining() {
|
||||
if (!timerRunning) {
|
||||
return 0;
|
||||
if (IsRunning()) {
|
||||
TickType_t remainingTime = xTimerGetExpiryTime(timer) - xTaskGetTickCount();
|
||||
return (remainingTime * 1000 / configTICK_RATE_HZ);
|
||||
}
|
||||
auto currentTicks = xTaskGetTickCount();
|
||||
|
||||
TickType_t deltaTicks = 0;
|
||||
if (currentTicks > endTicks) {
|
||||
deltaTicks = 0xffffffff - currentTicks;
|
||||
deltaTicks += (endTicks + 1);
|
||||
} else {
|
||||
deltaTicks = endTicks - currentTicks;
|
||||
}
|
||||
|
||||
return (static_cast<TickType_t>(deltaTicks) / static_cast<TickType_t>(configTICK_RATE_HZ)) * 1000;
|
||||
return 0;
|
||||
}
|
||||
|
||||
void TimerController::StopTimer() {
|
||||
app_timer_stop(timerAppTimer);
|
||||
timerRunning = false;
|
||||
xTimerStop(timer, 0);
|
||||
}
|
||||
|
||||
bool TimerController::IsRunning() {
|
||||
return timerRunning;
|
||||
}
|
||||
void TimerController::OnTimerEnd() {
|
||||
timerRunning = false;
|
||||
if(systemTask != nullptr)
|
||||
systemTask->PushMessage(System::Messages::OnTimerDone);
|
||||
return (xTimerIsTimerActive(timer) == pdTRUE);
|
||||
}
|
||||
|
||||
void TimerController::Register(Pinetime::System::SystemTask* systemTask) {
|
||||
this->systemTask = systemTask;
|
||||
void TimerController::OnTimerEnd() {
|
||||
systemTask->PushMessage(System::Messages::OnTimerDone);
|
||||
}
|
||||
|
@ -1,37 +1,33 @@
|
||||
#pragma once
|
||||
|
||||
#include <cstdint>
|
||||
#include "app_timer.h"
|
||||
#include "portmacro_cmsis.h"
|
||||
#include <FreeRTOS.h>
|
||||
#include <timers.h>
|
||||
|
||||
namespace Pinetime {
|
||||
namespace System {
|
||||
class SystemTask;
|
||||
}
|
||||
namespace Controllers {
|
||||
|
||||
|
||||
class TimerController {
|
||||
public:
|
||||
TimerController() = default;
|
||||
|
||||
void Init();
|
||||
|
||||
|
||||
void Init(System::SystemTask* systemTask);
|
||||
|
||||
void StartTimer(uint32_t duration);
|
||||
|
||||
|
||||
void StopTimer();
|
||||
|
||||
|
||||
uint32_t GetTimeRemaining();
|
||||
|
||||
|
||||
bool IsRunning();
|
||||
|
||||
void OnTimerEnd();
|
||||
|
||||
void Register(System::SystemTask* systemTask);
|
||||
|
||||
private:
|
||||
System::SystemTask* systemTask = nullptr;
|
||||
TickType_t endTicks;
|
||||
bool timerRunning = false;
|
||||
TimerHandle_t timer;
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -38,8 +38,10 @@ namespace Pinetime {
|
||||
SettingSetTime,
|
||||
SettingChimes,
|
||||
SettingShakeThreshold,
|
||||
SettingAirplaneMode,
|
||||
Error
|
||||
SettingBluetooth,
|
||||
Error,
|
||||
// oli: custom
|
||||
Agenda
|
||||
};
|
||||
}
|
||||
}
|
||||
|
@ -5,23 +5,41 @@ using namespace Pinetime::Controllers;
|
||||
|
||||
lv_color_t Pinetime::Applications::Convert(Pinetime::Controllers::Settings::Colors color) {
|
||||
switch (color) {
|
||||
case Pinetime::Controllers::Settings::Colors::White: return LV_COLOR_WHITE;
|
||||
case Pinetime::Controllers::Settings::Colors::Silver: return LV_COLOR_SILVER;
|
||||
case Pinetime::Controllers::Settings::Colors::Gray: return LV_COLOR_GRAY;
|
||||
case Pinetime::Controllers::Settings::Colors::Black: return LV_COLOR_BLACK;
|
||||
case Pinetime::Controllers::Settings::Colors::Red: return LV_COLOR_RED;
|
||||
case Pinetime::Controllers::Settings::Colors::Maroon: return LV_COLOR_MAROON;
|
||||
case Pinetime::Controllers::Settings::Colors::Yellow: return LV_COLOR_YELLOW;
|
||||
case Pinetime::Controllers::Settings::Colors::Olive: return LV_COLOR_OLIVE;
|
||||
case Pinetime::Controllers::Settings::Colors::Lime: return LV_COLOR_LIME;
|
||||
case Pinetime::Controllers::Settings::Colors::Green: return LV_COLOR_GREEN;
|
||||
case Pinetime::Controllers::Settings::Colors::Cyan: return LV_COLOR_CYAN;
|
||||
case Pinetime::Controllers::Settings::Colors::Teal: return LV_COLOR_TEAL;
|
||||
case Pinetime::Controllers::Settings::Colors::Blue: return LV_COLOR_BLUE;
|
||||
case Pinetime::Controllers::Settings::Colors::Navy: return LV_COLOR_NAVY;
|
||||
case Pinetime::Controllers::Settings::Colors::Magenta: return LV_COLOR_MAGENTA;
|
||||
case Pinetime::Controllers::Settings::Colors::Purple: return LV_COLOR_PURPLE;
|
||||
case Pinetime::Controllers::Settings::Colors::Orange: return LV_COLOR_ORANGE;
|
||||
default: return LV_COLOR_WHITE;
|
||||
case Pinetime::Controllers::Settings::Colors::White:
|
||||
return LV_COLOR_WHITE;
|
||||
case Pinetime::Controllers::Settings::Colors::Silver:
|
||||
return LV_COLOR_SILVER;
|
||||
case Pinetime::Controllers::Settings::Colors::Gray:
|
||||
return LV_COLOR_GRAY;
|
||||
case Pinetime::Controllers::Settings::Colors::Black:
|
||||
return LV_COLOR_BLACK;
|
||||
case Pinetime::Controllers::Settings::Colors::Red:
|
||||
return LV_COLOR_RED;
|
||||
case Pinetime::Controllers::Settings::Colors::Maroon:
|
||||
return LV_COLOR_MAKE(0xb0, 0x0, 0x0);
|
||||
case Pinetime::Controllers::Settings::Colors::Yellow:
|
||||
return LV_COLOR_YELLOW;
|
||||
case Pinetime::Controllers::Settings::Colors::Olive:
|
||||
return LV_COLOR_MAKE(0xb0, 0xb0, 0x0);
|
||||
case Pinetime::Controllers::Settings::Colors::Lime:
|
||||
return LV_COLOR_LIME;
|
||||
case Pinetime::Controllers::Settings::Colors::Green:
|
||||
return LV_COLOR_MAKE(0x0, 0xb0, 0x0);
|
||||
case Pinetime::Controllers::Settings::Colors::Cyan:
|
||||
return LV_COLOR_CYAN;
|
||||
case Pinetime::Controllers::Settings::Colors::Teal:
|
||||
return LV_COLOR_MAKE(0x0, 0xb0, 0xb0);
|
||||
case Pinetime::Controllers::Settings::Colors::Blue:
|
||||
return LV_COLOR_BLUE;
|
||||
case Pinetime::Controllers::Settings::Colors::Navy:
|
||||
return LV_COLOR_MAKE(0x0, 0x0, 0xb0);
|
||||
case Pinetime::Controllers::Settings::Colors::Magenta:
|
||||
return LV_COLOR_MAGENTA;
|
||||
case Pinetime::Controllers::Settings::Colors::Purple:
|
||||
return LV_COLOR_MAKE(0xb0, 0x0, 0xb0);
|
||||
case Pinetime::Controllers::Settings::Colors::Orange:
|
||||
return LV_COLOR_ORANGE;
|
||||
default:
|
||||
return LV_COLOR_WHITE;
|
||||
}
|
||||
}
|
||||
|
@ -11,14 +11,12 @@
|
||||
#include "components/motion/MotionController.h"
|
||||
#include "components/motor/MotorController.h"
|
||||
#include "displayapp/screens/ApplicationList.h"
|
||||
#include "displayapp/screens/Brightness.h"
|
||||
#include "displayapp/screens/Clock.h"
|
||||
#include "displayapp/screens/FirmwareUpdate.h"
|
||||
#include "displayapp/screens/FirmwareValidation.h"
|
||||
#include "displayapp/screens/InfiniPaint.h"
|
||||
#include "displayapp/screens/Paddle.h"
|
||||
#include "displayapp/screens/StopWatch.h"
|
||||
#include "displayapp/screens/Meter.h"
|
||||
#include "displayapp/screens/Metronome.h"
|
||||
#include "displayapp/screens/Music.h"
|
||||
#include "displayapp/screens/Navigation.h"
|
||||
@ -32,6 +30,8 @@
|
||||
#include "displayapp/screens/PassKey.h"
|
||||
#include "displayapp/screens/Error.h"
|
||||
|
||||
#include "displayapp/screens/Agenda.h"
|
||||
|
||||
#include "drivers/Cst816s.h"
|
||||
#include "drivers/St7789.h"
|
||||
#include "drivers/Watchdog.h"
|
||||
@ -49,7 +49,7 @@
|
||||
#include "displayapp/screens/settings/SettingSetTime.h"
|
||||
#include "displayapp/screens/settings/SettingChimes.h"
|
||||
#include "displayapp/screens/settings/SettingShakeThreshold.h"
|
||||
#include "displayapp/screens/settings/SettingAirplaneMode.h"
|
||||
#include "displayapp/screens/settings/SettingBluetooth.h"
|
||||
|
||||
#include "libs/lv_conf.h"
|
||||
|
||||
@ -60,28 +60,6 @@ namespace {
|
||||
static inline bool in_isr(void) {
|
||||
return (SCB->ICSR & SCB_ICSR_VECTACTIVE_Msk) != 0;
|
||||
}
|
||||
|
||||
TouchEvents ConvertGesture(Pinetime::Drivers::Cst816S::Gestures gesture) {
|
||||
switch (gesture) {
|
||||
case Pinetime::Drivers::Cst816S::Gestures::SingleTap:
|
||||
return TouchEvents::Tap;
|
||||
case Pinetime::Drivers::Cst816S::Gestures::LongPress:
|
||||
return TouchEvents::LongTap;
|
||||
case Pinetime::Drivers::Cst816S::Gestures::DoubleTap:
|
||||
return TouchEvents::DoubleTap;
|
||||
case Pinetime::Drivers::Cst816S::Gestures::SlideRight:
|
||||
return TouchEvents::SwipeRight;
|
||||
case Pinetime::Drivers::Cst816S::Gestures::SlideLeft:
|
||||
return TouchEvents::SwipeLeft;
|
||||
case Pinetime::Drivers::Cst816S::Gestures::SlideDown:
|
||||
return TouchEvents::SwipeDown;
|
||||
case Pinetime::Drivers::Cst816S::Gestures::SlideUp:
|
||||
return TouchEvents::SwipeUp;
|
||||
case Pinetime::Drivers::Cst816S::Gestures::None:
|
||||
default:
|
||||
return TouchEvents::None;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
DisplayApp::DisplayApp(Drivers::St7789& lcd,
|
||||
@ -185,12 +163,10 @@ void DisplayApp::Refresh() {
|
||||
brightnessController.Lower();
|
||||
vTaskDelay(100);
|
||||
}
|
||||
lcd.DisplayOff();
|
||||
PushMessageToSystemTask(Pinetime::System::Messages::OnDisplayTaskSleeping);
|
||||
state = States::Idle;
|
||||
break;
|
||||
case Messages::GoToRunning:
|
||||
lcd.DisplayOn();
|
||||
brightnessController.Restore();
|
||||
state = States::Running;
|
||||
break;
|
||||
@ -207,7 +183,7 @@ void DisplayApp::Refresh() {
|
||||
case Messages::TimerDone:
|
||||
if (currentApp == Apps::Timer) {
|
||||
auto* timer = static_cast<Screens::Timer*>(currentScreen.get());
|
||||
timer->setDone();
|
||||
timer->SetDone();
|
||||
} else {
|
||||
LoadApp(Apps::Timer, DisplayApp::FullRefreshDirections::Down);
|
||||
}
|
||||
@ -227,7 +203,7 @@ void DisplayApp::Refresh() {
|
||||
if (state != States::Running) {
|
||||
break;
|
||||
}
|
||||
auto gesture = ConvertGesture(touchHandler.GestureGet());
|
||||
auto gesture = touchHandler.GestureGet();
|
||||
if (gesture == TouchEvents::None) {
|
||||
break;
|
||||
}
|
||||
@ -306,14 +282,14 @@ void DisplayApp::Refresh() {
|
||||
}
|
||||
}
|
||||
|
||||
if (touchHandler.IsTouching()) {
|
||||
currentScreen->OnTouchEvent(touchHandler.GetX(), touchHandler.GetY());
|
||||
}
|
||||
|
||||
if (nextApp != Apps::None) {
|
||||
LoadApp(nextApp, nextDirection);
|
||||
nextApp = Apps::None;
|
||||
}
|
||||
|
||||
if (touchHandler.IsTouching()) {
|
||||
currentScreen->OnTouchEvent(touchHandler.GetX(), touchHandler.GetY());
|
||||
}
|
||||
}
|
||||
|
||||
void DisplayApp::StartApp(Apps app, DisplayApp::FullRefreshDirections direction) {
|
||||
@ -349,7 +325,8 @@ void DisplayApp::LoadApp(Apps app, DisplayApp::FullRefreshDirections direction)
|
||||
notificationManager,
|
||||
settingsController,
|
||||
heartRateController,
|
||||
motionController);
|
||||
motionController,
|
||||
systemTask->nimble().agenda());
|
||||
break;
|
||||
|
||||
case Apps::Error:
|
||||
@ -372,13 +349,21 @@ void DisplayApp::LoadApp(Apps app, DisplayApp::FullRefreshDirections direction)
|
||||
break;
|
||||
|
||||
case Apps::Notifications:
|
||||
currentScreen = std::make_unique<Screens::Notifications>(
|
||||
this, notificationManager, systemTask->nimble().alertService(), motorController, *systemTask, Screens::Notifications::Modes::Normal);
|
||||
currentScreen = std::make_unique<Screens::Notifications>(this,
|
||||
notificationManager,
|
||||
systemTask->nimble().alertService(),
|
||||
motorController,
|
||||
*systemTask,
|
||||
Screens::Notifications::Modes::Normal);
|
||||
ReturnApp(Apps::Clock, FullRefreshDirections::Up, TouchEvents::SwipeUp);
|
||||
break;
|
||||
case Apps::NotificationsPreview:
|
||||
currentScreen = std::make_unique<Screens::Notifications>(
|
||||
this, notificationManager, systemTask->nimble().alertService(), motorController, *systemTask, Screens::Notifications::Modes::Preview);
|
||||
currentScreen = std::make_unique<Screens::Notifications>(this,
|
||||
notificationManager,
|
||||
systemTask->nimble().alertService(),
|
||||
motorController,
|
||||
*systemTask,
|
||||
Screens::Notifications::Modes::Preview);
|
||||
ReturnApp(Apps::Clock, FullRefreshDirections::Up, TouchEvents::SwipeUp);
|
||||
break;
|
||||
case Apps::Timer:
|
||||
@ -390,8 +375,12 @@ void DisplayApp::LoadApp(Apps app, DisplayApp::FullRefreshDirections direction)
|
||||
|
||||
// Settings
|
||||
case Apps::QuickSettings:
|
||||
currentScreen = std::make_unique<Screens::QuickSettings>(
|
||||
this, batteryController, dateTimeController, brightnessController, motorController, settingsController);
|
||||
currentScreen = std::make_unique<Screens::QuickSettings>(this,
|
||||
batteryController,
|
||||
dateTimeController,
|
||||
brightnessController,
|
||||
motorController,
|
||||
settingsController);
|
||||
ReturnApp(Apps::Clock, FullRefreshDirections::LeftAnim, TouchEvents::SwipeLeft);
|
||||
break;
|
||||
case Apps::Settings:
|
||||
@ -434,8 +423,8 @@ void DisplayApp::LoadApp(Apps app, DisplayApp::FullRefreshDirections direction)
|
||||
currentScreen = std::make_unique<Screens::SettingShakeThreshold>(this, settingsController, motionController, *systemTask);
|
||||
ReturnApp(Apps::Settings, FullRefreshDirections::Down, TouchEvents::SwipeDown);
|
||||
break;
|
||||
case Apps::SettingAirplaneMode:
|
||||
currentScreen = std::make_unique<Screens::SettingAirplaneMode>(this, settingsController);
|
||||
case Apps::SettingBluetooth:
|
||||
currentScreen = std::make_unique<Screens::SettingBluetooth>(this, settingsController);
|
||||
ReturnApp(Apps::Settings, FullRefreshDirections::Down, TouchEvents::SwipeDown);
|
||||
break;
|
||||
case Apps::BatteryInfo:
|
||||
@ -443,8 +432,14 @@ void DisplayApp::LoadApp(Apps app, DisplayApp::FullRefreshDirections direction)
|
||||
ReturnApp(Apps::Settings, FullRefreshDirections::Down, TouchEvents::SwipeDown);
|
||||
break;
|
||||
case Apps::SysInfo:
|
||||
currentScreen = std::make_unique<Screens::SystemInfo>(
|
||||
this, dateTimeController, batteryController, brightnessController, bleController, watchdog, motionController, touchPanel);
|
||||
currentScreen = std::make_unique<Screens::SystemInfo>(this,
|
||||
dateTimeController,
|
||||
batteryController,
|
||||
brightnessController,
|
||||
bleController,
|
||||
watchdog,
|
||||
motionController,
|
||||
touchPanel);
|
||||
ReturnApp(Apps::Settings, FullRefreshDirections::Down, TouchEvents::SwipeDown);
|
||||
break;
|
||||
case Apps::FlashLight:
|
||||
@ -482,6 +477,10 @@ void DisplayApp::LoadApp(Apps app, DisplayApp::FullRefreshDirections direction)
|
||||
case Apps::Steps:
|
||||
currentScreen = std::make_unique<Screens::Steps>(this, motionController, settingsController);
|
||||
break;
|
||||
|
||||
case Apps::Agenda:
|
||||
currentScreen = std::make_unique<Screens::Agenda>(this, systemTask->nimble().agenda(), dateTimeController);
|
||||
break;
|
||||
}
|
||||
currentApp = app;
|
||||
}
|
||||
@ -519,6 +518,9 @@ void DisplayApp::SetFullRefresh(DisplayApp::FullRefreshDirections direction) {
|
||||
case DisplayApp::FullRefreshDirections::RightAnim:
|
||||
lvgl.SetFullRefresh(Components::LittleVgl::FullRefreshDirections::RightAnim);
|
||||
break;
|
||||
// case DisplayApp::FullRefreshDirections::None:
|
||||
// lvgl.SetFullRefresh(Components::LittleVgl::FullRefreshDirections::None);
|
||||
// break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
@ -88,7 +88,7 @@ namespace Pinetime {
|
||||
Pinetime::Controllers::MotionController& motionController;
|
||||
Pinetime::Controllers::TimerController& timerController;
|
||||
Pinetime::Controllers::AlarmController& alarmController;
|
||||
Pinetime::Controllers::BrightnessController &brightnessController;
|
||||
Pinetime::Controllers::BrightnessController& brightnessController;
|
||||
Pinetime::Controllers::TouchHandler& touchHandler;
|
||||
|
||||
Pinetime::Controllers::FirmwareValidator validator;
|
||||
|
@ -26,7 +26,6 @@ DisplayApp::DisplayApp(Drivers::St7789& lcd,
|
||||
Pinetime::Controllers::BrightnessController& brightnessController,
|
||||
Pinetime::Controllers::TouchHandler& touchHandler)
|
||||
: lcd {lcd}, bleController {bleController} {
|
||||
|
||||
}
|
||||
|
||||
void DisplayApp::Start() {
|
||||
@ -121,5 +120,4 @@ void DisplayApp::PushMessage(Display::Messages msg) {
|
||||
}
|
||||
|
||||
void DisplayApp::Register(Pinetime::System::SystemTask* systemTask) {
|
||||
|
||||
}
|
||||
|
@ -61,7 +61,9 @@ namespace Pinetime {
|
||||
Pinetime::Controllers::BrightnessController& brightnessController,
|
||||
Pinetime::Controllers::TouchHandler& touchHandler);
|
||||
void Start();
|
||||
void Start(Pinetime::System::BootErrors){ Start(); };
|
||||
void Start(Pinetime::System::BootErrors) {
|
||||
Start();
|
||||
};
|
||||
void PushMessage(Pinetime::Applications::Display::Messages msg);
|
||||
void Register(Pinetime::System::SystemTask* systemTask);
|
||||
|
||||
|
@ -20,7 +20,6 @@ namespace Pinetime {
|
||||
LittleVgl& operator=(LittleVgl&&) = delete;
|
||||
|
||||
void Init() {
|
||||
|
||||
}
|
||||
|
||||
void FlushDisplay(const lv_area_t* area, lv_color_t* color_p) {
|
||||
@ -33,7 +32,6 @@ namespace Pinetime {
|
||||
void SetNewTapEvent(uint16_t x, uint16_t y) {
|
||||
}
|
||||
void SetNewTouchPoint(uint16_t x, uint16_t y, bool contact) {
|
||||
|
||||
}
|
||||
};
|
||||
}
|
||||
|
@ -16,14 +16,22 @@ static void disp_flush(lv_disp_drv_t* disp_drv, const lv_area_t* area, lv_color_
|
||||
lvgl->FlushDisplay(area, color_p);
|
||||
}
|
||||
|
||||
static void rounder(lv_disp_drv_t* disp_drv, lv_area_t* area) {
|
||||
auto* lvgl = static_cast<LittleVgl*>(disp_drv->user_data);
|
||||
if (lvgl->GetFullRefresh()) {
|
||||
area->x1 = 0;
|
||||
area->x2 = LV_HOR_RES - 1;
|
||||
area->y1 = 0;
|
||||
area->y2 = LV_VER_RES - 1;
|
||||
}
|
||||
}
|
||||
|
||||
bool touchpad_read(lv_indev_drv_t* indev_drv, lv_indev_data_t* data) {
|
||||
auto* lvgl = static_cast<LittleVgl*>(indev_drv->user_data);
|
||||
return lvgl->GetTouchPadInfo(data);
|
||||
}
|
||||
|
||||
LittleVgl::LittleVgl(Pinetime::Drivers::St7789& lcd, Pinetime::Drivers::Cst816S& touchPanel)
|
||||
: lcd {lcd}, touchPanel {touchPanel}, previousClick {0, 0} {
|
||||
|
||||
LittleVgl::LittleVgl(Pinetime::Drivers::St7789& lcd, Pinetime::Drivers::Cst816S& touchPanel) : lcd {lcd}, touchPanel {touchPanel} {
|
||||
}
|
||||
|
||||
void LittleVgl::Init() {
|
||||
@ -48,6 +56,7 @@ void LittleVgl::InitDisplay() {
|
||||
/*Set a display buffer*/
|
||||
disp_drv.buffer = &disp_buf_2;
|
||||
disp_drv.user_data = this;
|
||||
disp_drv.rounder_cb = rounder;
|
||||
|
||||
/*Finally register the driver*/
|
||||
lv_disp_drv_register(&disp_drv);
|
||||
@ -78,14 +87,15 @@ void LittleVgl::SetFullRefresh(FullRefreshDirections direction) {
|
||||
lv_disp_set_direction(lv_disp_get_default(), 4);
|
||||
}
|
||||
}
|
||||
fullRefresh = true;
|
||||
}
|
||||
|
||||
void LittleVgl::FlushDisplay(const lv_area_t* area, lv_color_t* color_p) {
|
||||
uint16_t y1, y2, width, height = 0;
|
||||
|
||||
ulTaskNotifyTake(pdTRUE, 200);
|
||||
// NOtification is still needed (even if there is a mutex on SPI) because of the DataCommand pin
|
||||
// which cannot be set/clear during a transfert.
|
||||
// Notification is still needed (even if there is a mutex on SPI) because of the DataCommand pin
|
||||
// which cannot be set/clear during a transfer.
|
||||
|
||||
if ((scrollDirection == LittleVgl::FullRefreshDirections::Down) && (area->y2 == visibleNbLines - 1)) {
|
||||
writeOffset = ((writeOffset + totalNbLines) - visibleNbLines) % totalNbLines;
|
||||
@ -185,8 +195,13 @@ bool LittleVgl::GetTouchPadInfo(lv_indev_data_t* ptr) {
|
||||
|
||||
void LittleVgl::InitTheme() {
|
||||
|
||||
lv_theme_t* th = lv_pinetime_theme_init(
|
||||
LV_COLOR_WHITE, LV_COLOR_SILVER, 0, &jetbrains_mono_bold_20, &jetbrains_mono_bold_20, &jetbrains_mono_bold_20, &jetbrains_mono_bold_20);
|
||||
lv_theme_t* th = lv_pinetime_theme_init(LV_COLOR_WHITE,
|
||||
LV_COLOR_SILVER,
|
||||
0,
|
||||
&jetbrains_mono_bold_20,
|
||||
&jetbrains_mono_bold_20,
|
||||
&jetbrains_mono_bold_20,
|
||||
&jetbrains_mono_bold_20);
|
||||
|
||||
lv_theme_set_act(th);
|
||||
}
|
||||
|
@ -26,6 +26,14 @@ namespace Pinetime {
|
||||
void SetFullRefresh(FullRefreshDirections direction);
|
||||
void SetNewTouchPoint(uint16_t x, uint16_t y, bool contact);
|
||||
|
||||
bool GetFullRefresh() {
|
||||
bool returnValue = fullRefresh;
|
||||
if (fullRefresh) {
|
||||
fullRefresh = false;
|
||||
}
|
||||
return returnValue;
|
||||
}
|
||||
|
||||
private:
|
||||
void InitDisplay();
|
||||
void InitTouchpad();
|
||||
@ -39,9 +47,8 @@ namespace Pinetime {
|
||||
lv_color_t buf2_2[LV_HOR_RES_MAX * 4];
|
||||
|
||||
lv_disp_drv_t disp_drv;
|
||||
lv_point_t previousClick;
|
||||
|
||||
bool firstTouch = true;
|
||||
bool fullRefresh = false;
|
||||
static constexpr uint8_t nbWriteLines = 4;
|
||||
static constexpr uint16_t totalNbLines = 320;
|
||||
static constexpr uint16_t visibleNbLines = 240;
|
||||
|
35
src/displayapp/fonts/CMakeLists.txt
Normal file
@ -0,0 +1,35 @@
|
||||
set(FONTS jetbrains_mono_42 jetbrains_mono_76 jetbrains_mono_bold_20
|
||||
jetbrains_mono_extrabold_compressed lv_font_navi_80 lv_font_sys_48
|
||||
open_sans_light)
|
||||
find_program(LV_FONT_CONV "lv_font_conv" NO_CACHE REQUIRED
|
||||
HINTS "${CMAKE_SOURCE_DIR}/node_modules/.bin")
|
||||
message(STATUS "Using ${LV_FONT_CONV} to generate font files")
|
||||
configure_file(${CMAKE_CURRENT_LIST_DIR}/jetbrains_mono_bold_20.c_zero.patch
|
||||
${CMAKE_CURRENT_BINARY_DIR}/jetbrains_mono_bold_20.c_zero.patch COPYONLY)
|
||||
if(CMAKE_VERSION VERSION_GREATER_EQUAL 3.12)
|
||||
# FindPython3 module introduces with CMake 3.12
|
||||
# https://cmake.org/cmake/help/latest/module/FindPython3.html
|
||||
find_package(Python3 REQUIRED)
|
||||
else()
|
||||
set(Python3_EXECUTABLE "python")
|
||||
endif()
|
||||
|
||||
# create static library building fonts
|
||||
add_library(infinitime_fonts STATIC)
|
||||
# add include directory to lvgl headers needed to compile the font files on its own
|
||||
target_include_directories(infinitime_fonts PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/../../libs")
|
||||
foreach(FONT ${FONTS})
|
||||
add_custom_command(
|
||||
OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/${FONT}.c
|
||||
COMMAND "${Python3_EXECUTABLE}" ${CMAKE_CURRENT_SOURCE_DIR}/generate.py
|
||||
--lv-font-conv "${LV_FONT_CONV}"
|
||||
--font ${FONT} ${CMAKE_CURRENT_SOURCE_DIR}/fonts.json
|
||||
DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/fonts.json
|
||||
WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
|
||||
)
|
||||
add_custom_target(infinitime_fonts_${FONT}
|
||||
DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/${FONT}.c
|
||||
)
|
||||
target_sources(infinitime_fonts PRIVATE "${CMAKE_CURRENT_BINARY_DIR}/${FONT}.c")
|
||||
add_dependencies(infinitime_fonts infinitime_fonts_${FONT})
|
||||
endforeach()
|
BIN
src/displayapp/fonts/FontAwesome5-Solid+Brands+Regular.woff
Normal file
BIN
src/displayapp/fonts/JetBrainsMono-Light.ttf
Normal file
@ -4,17 +4,10 @@
|
||||
* [Awesome font from LVGL](https://lvgl.io/assets/others/FontAwesome5-Solid+Brands+Regular.woff)
|
||||
* [Open Sans Light from Google](https://fonts.google.com/specimen/Open+Sans)
|
||||
|
||||
## Generate the fonts:
|
||||
|
||||
* Open the [LVGL font converter](https://lvgl.io/tools/fontconverter)
|
||||
* Enter the settings for the font that you wish to convert
|
||||
* Click on Convert, download the file and place it in `src/DisplayApp/Fonts`
|
||||
|
||||
### How to add new symbols:
|
||||
|
||||
* Browse [this cheatsheet](https://fontawesome.com/cheatsheet/free/solid) and pick symbols
|
||||
* For each symbol, add its hex code (0xf641 for the 'Ad' icon, for example) to the *Range* list (Remember to keep this
|
||||
readme updated with newest range list)
|
||||
* For each symbol, add its hex code (0xf641 for the 'Ad' icon, for example) to the *Range* list (or the symbol list when its simple enough) in the `fonts.json` file
|
||||
* Convert this hex value into a UTF-8 code
|
||||
using [this site](http://www.ltg.ed.ac.uk/~richard/utf-8.cgi?input=f185&mode=hex)
|
||||
* Define the new symbols in `src/displayapp/screens/Symbols.h`:
|
||||
@ -23,77 +16,17 @@
|
||||
static constexpr const char* newSymbol = "\xEF\x86\x85";
|
||||
```
|
||||
|
||||
### Small font
|
||||
### the config file format:
|
||||
|
||||
* Name: jetbrains_mono_bold_20
|
||||
* Size: 20
|
||||
* Bpp: 1 bit-per-pixel
|
||||
* Do not enable font compression or horizontal subpixel rendering
|
||||
* Load the file `JetBrainsMono-Bold.tff` (use the file in this repo to ensure the version matches) and specify the following range: `0x20-0x7e, 0x410-0x44f`
|
||||
* Add a 2nd font, load the file `FontAwesome5-Solid+Brands+Regular.woff` and specify the following
|
||||
range: `0xf293, 0xf294, 0xf244, 0xf240, 0xf242, 0xf243, 0xf241, 0xf54b, 0xf21e, 0xf1e6, 0xf54b, 0xf017, 0xf129, 0xf03a, 0xf185, 0xf560, 0xf001, 0xf3fd, 0xf069, 0xf1fc, 0xf45d, 0xf59f, 0xf5a0, 0xf029, 0xf027, 0xf028, 0xf6a9, 0xf04b, 0xf04c, 0xf048, 0xf051, 0xf095, 0xf3dd, 0xf04d, 0xf2f2, 0xf024, 0xf252, 0xf569, 0xf201, 0xf06e, 0xf015, 0xf072`
|
||||
* Fix an error in the font conversion.
|
||||
|
||||
Replace the following:
|
||||
|
||||
/* U+0030 "0" */
|
||||
0x3f, 0x1f, 0xef, 0x3f, 0x87, 0xe1, 0xf8, 0x7f,
|
||||
0xdf, 0xf7, 0xe1, 0xf8, 0x7e, 0x1f, 0xcf, 0x7f,
|
||||
0x8f, 0xc0,
|
||||
|
||||
with
|
||||
|
||||
/* U+0030 "0" */
|
||||
0x3f, 0x1f, 0xef, 0x3f, 0x87, 0xe1, 0xf8, 0x7e,
|
||||
0xdf, 0xb7, 0xe1, 0xf8, 0x7e, 0x1f, 0xcf, 0x7f,
|
||||
0x8f, 0xc0,
|
||||
|
||||
(there are two changes: 7f -> 7e and f7 -> b7)
|
||||
|
||||
### Medium font
|
||||
|
||||
* Name: jetbrains_mono_42
|
||||
* Size: 42
|
||||
* Bpp: 1 bit-per-pixel
|
||||
* Do not enable font compression or horizontal subpixel rendering
|
||||
* Load the file `JetBrainsMono-Regular.tff` (use the file in this repo to ensure the version matches) and specify the following range: `0x25, 0x30-0x3a`
|
||||
|
||||
### Large font
|
||||
|
||||
* Name: jetbrains_mono_76
|
||||
* Size: 76
|
||||
* Bpp: 1 bit-per-pixel
|
||||
* Do not enable font compression or horizontal subpixel rendering
|
||||
* Load the file `JetBrainsMono-Regular.tff` (use the file in this repo to ensure the version matches) and specify the following range: `0x25, 0x2D, 0x2F, 0x30-0x3a`
|
||||
|
||||
### Digital watchface font
|
||||
|
||||
* Name: jetbrains_mono_extrabold_compressed
|
||||
* Size: 80
|
||||
* Bpp: 1 bit-per-pixel
|
||||
* Do not enable font compression or horizontal subpixel rendering
|
||||
* Load the file `JetBrainsMono-ExtraBold.tff` (use the file in this repo to ensure the version matches) and specify the following range: `0x30-0x3a`
|
||||
|
||||
### PineTimeStyle font
|
||||
|
||||
* Name: open_sans_light
|
||||
* Size: 150
|
||||
* Bpp: 1 bit-per-pixel
|
||||
* Do not enable font compression or horizontal subpixel rendering
|
||||
* Load the file `open_sans_light.tff` (use the file in this repo to ensure the version matches) and specify the following symbols: `0123456789`
|
||||
|
||||
### Symbols font (Used in QuickSettings for example)
|
||||
|
||||
* Name: lv_font_sys_48
|
||||
* Size: 48
|
||||
* Bpp: 1 bit-per-pixel
|
||||
* Do not enable font compression or horizontal subpixel rendering
|
||||
* Load the file `icons_sys_48.tff` and specify the following range: `0xe902, 0xe904-0xe907, 0xe90b-0xe90c`
|
||||
inside `fonts`, there is a dictionary of fonts,
|
||||
and for each font there is:
|
||||
* sources - list of file,range(,symbols) wanted (as a dictionary of those)
|
||||
* bpp - bits per pixel.
|
||||
* size - size.
|
||||
* patches - list of extra "patches" to run: a path to a .patch file. (may be relative)
|
||||
* compress - optional. default disabled. add `"compress": true` to enable
|
||||
|
||||
### Navigation font
|
||||
|
||||
`navigtion.ttf` is created with the web app [icomoon](https://icomoon.io/app) by importing the svg files from `src/displayapp/icons/navigation/unique` and generating the font. `lv_font_navi_80.json` is a project file for the site, which you can import to add or remove icons.
|
||||
|
||||
This font must be generated with the `lv_font_conv` tool, which has additional options not available in the online converter.
|
||||
|
||||
`lv_font_conv --font navigation.ttf -r '0xe900-0xe929' --size 80 --format lvgl --bpp 2 -o lv_font_navi_80.c`
|
||||
|
78
src/displayapp/fonts/fonts.json
Normal file
@ -0,0 +1,78 @@
|
||||
{
|
||||
"jetbrains_mono_bold_20": {
|
||||
"sources": [
|
||||
{
|
||||
"file": "JetBrainsMono-Bold.ttf",
|
||||
"range": "0x20-0x7e, 0x410-0x44f"
|
||||
},
|
||||
{
|
||||
"file": "FontAwesome5-Solid+Brands+Regular.woff",
|
||||
"range": "0xf294, 0xf242, 0xf54b, 0xf21e, 0xf1e6, 0xf017, 0xf129, 0xf03a, 0xf185, 0xf560, 0xf001, 0xf3fd, 0xf1fc, 0xf45d, 0xf59f, 0xf5a0, 0xf027, 0xf028, 0xf6a9, 0xf04b, 0xf04c, 0xf048, 0xf051, 0xf095, 0xf3dd, 0xf04d, 0xf2f2, 0xf024, 0xf252, 0xf569, 0xf201, 0xf06e, 0xf015"
|
||||
}
|
||||
],
|
||||
"bpp": 1,
|
||||
"size": 20,
|
||||
"patches": ["jetbrains_mono_bold_20.c_zero.patch"]
|
||||
},
|
||||
"jetbrains_mono_42": {
|
||||
"sources": [
|
||||
{
|
||||
"file": "JetBrainsMono-Regular.ttf",
|
||||
"range": "0x25, 0x2b, 0x2d, 0x30-0x3a"
|
||||
}
|
||||
],
|
||||
"bpp": 1,
|
||||
"size": 42
|
||||
},
|
||||
"jetbrains_mono_76": {
|
||||
"sources": [
|
||||
{
|
||||
"file": "JetBrainsMono-Light.ttf",
|
||||
"range": "0x25, 0x2D, 0x2F, 0x30-0x3a"
|
||||
}
|
||||
],
|
||||
"bpp": 1,
|
||||
"size": 76
|
||||
},
|
||||
"jetbrains_mono_extrabold_compressed": {
|
||||
"sources": [
|
||||
{
|
||||
"file": "JetBrainsMono-ExtraBold.ttf",
|
||||
"range": "0x30-0x3a"
|
||||
}
|
||||
],
|
||||
"bpp": 1,
|
||||
"size": 80
|
||||
},
|
||||
"open_sans_light": {
|
||||
"sources": [
|
||||
{
|
||||
"file": "open_sans_light.ttf",
|
||||
"symbols": "0123456789"
|
||||
}
|
||||
],
|
||||
"bpp": 1,
|
||||
"size": 150
|
||||
},
|
||||
"lv_font_sys_48": {
|
||||
"sources": [
|
||||
{
|
||||
"file": "icons_sys_48.ttf",
|
||||
"range": "0xe902, 0xe904-0xe907, 0xe90b-0xe90c"
|
||||
}
|
||||
],
|
||||
"bpp": 1,
|
||||
"size": 48
|
||||
},
|
||||
"lv_font_navi_80": {
|
||||
"sources": [
|
||||
{
|
||||
"file": "navigation.ttf",
|
||||
"range": "0xe900-0xe929"
|
||||
}
|
||||
],
|
||||
"bpp": 2,
|
||||
"size": 80,
|
||||
"compress": true
|
||||
}
|
||||
}
|
75
src/displayapp/fonts/generate.py
Executable file
@ -0,0 +1,75 @@
|
||||
#!/usr/bin/env python
|
||||
|
||||
import io
|
||||
import sys
|
||||
import json
|
||||
import shutil
|
||||
import typing
|
||||
import os.path
|
||||
import argparse
|
||||
import subprocess
|
||||
|
||||
class Source(object):
|
||||
def __init__(self, d):
|
||||
self.file = d['file']
|
||||
if not os.path.exists(self.file):
|
||||
self.file = os.path.join(os.path.dirname(sys.argv[0]), self.file)
|
||||
self.range = d.get('range')
|
||||
self.symbols = d.get('symbols')
|
||||
|
||||
|
||||
def gen_lvconv_line(lv_font_conv: str, dest: str, size: int, bpp: int, sources: typing.List[Source], compress:bool=False):
|
||||
args = [lv_font_conv, '--size', str(size), '--output', dest, '--bpp', str(bpp), '--format', 'lvgl']
|
||||
if not compress:
|
||||
args.append('--no-compress')
|
||||
for source in sources:
|
||||
args.extend(['--font', source.file])
|
||||
if source.range:
|
||||
args.extend(['--range', source.range])
|
||||
if source.symbols:
|
||||
args.extend(['--symbols', source.symbols])
|
||||
|
||||
return args
|
||||
|
||||
def main():
|
||||
ap = argparse.ArgumentParser(description='auto generate LVGL font files from fonts')
|
||||
ap.add_argument('config', type=str, help='config file to use')
|
||||
ap.add_argument('-f', '--font', type=str, action='append', help='Choose specific fonts to generate (default: all)', default=[])
|
||||
ap.add_argument('--lv-font-conv', type=str, help='Path to "lv_font_conf" executable', default="lv_font_conv")
|
||||
args = ap.parse_args()
|
||||
|
||||
if not shutil.which(args.lv_font_conv):
|
||||
sys.exit(f"Missing lv_font_conv. Make sure it's findable (in PATH) or specify it manually")
|
||||
if not os.path.exists(args.config):
|
||||
sys.exit(f'Error: the config file {args.config} does not exist.')
|
||||
if not os.access(args.config, os.R_OK):
|
||||
sys.exit(f'Error: the config file {args.config} is not accessible (permissions?).')
|
||||
with open(args.config, 'r') as fd:
|
||||
data = json.load(fd)
|
||||
|
||||
fonts_to_run = set(data.keys())
|
||||
|
||||
if args.font:
|
||||
enabled_fonts = set()
|
||||
for font in args.font:
|
||||
enabled_fonts.add(font[:-2] if font.endswith('.c') else font)
|
||||
d = enabled_fonts.difference(fonts_to_run)
|
||||
if d:
|
||||
print(f'Warning: requested font{"s" if len(d)>1 else ""} missing: {" ".join(d)}')
|
||||
fonts_to_run = fonts_to_run.intersection(enabled_fonts)
|
||||
|
||||
for name in fonts_to_run:
|
||||
font = data[name]
|
||||
sources = font.pop('sources')
|
||||
patches = font.pop('patches') if 'patches' in font else []
|
||||
font['sources'] = [Source(thing) for thing in sources]
|
||||
line = gen_lvconv_line(args.lv_font_conv, f'{name}.c', **font)
|
||||
subprocess.check_call(line)
|
||||
if patches:
|
||||
for patch in patches:
|
||||
subprocess.check_call(['/usr/bin/patch', name+'.c', patch])
|
||||
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
main()
|
@ -1,258 +0,0 @@
|
||||
/*******************************************************************************
|
||||
* Size: 42 px
|
||||
* Bpp: 1
|
||||
* Opts:
|
||||
******************************************************************************/
|
||||
|
||||
#ifdef LV_LVGL_H_INCLUDE_SIMPLE
|
||||
#include "lvgl.h"
|
||||
#else
|
||||
#include "lvgl/lvgl.h"
|
||||
#endif
|
||||
|
||||
#ifndef JETBRAINS_MONO_42
|
||||
#define JETBRAINS_MONO_42 1
|
||||
#endif
|
||||
|
||||
#if JETBRAINS_MONO_42
|
||||
|
||||
/*-----------------
|
||||
* BITMAPS
|
||||
*----------------*/
|
||||
|
||||
/*Store the image of the glyphs*/
|
||||
static LV_ATTRIBUTE_LARGE_CONST const uint8_t glyph_bitmap[] = {
|
||||
/* U+0025 "%" */
|
||||
0x1f, 0x80, 0x7, 0x3f, 0xc0, 0xe, 0x7f, 0xe0,
|
||||
0x1c, 0xf0, 0xf0, 0x1c, 0xe0, 0x70, 0x38, 0xe0,
|
||||
0x70, 0x70, 0xe0, 0x70, 0x70, 0xe0, 0x70, 0xe0,
|
||||
0xe0, 0x71, 0xc0, 0xe0, 0x71, 0xc0, 0xf0, 0xf3,
|
||||
0x80, 0x7f, 0xe7, 0x0, 0x3f, 0xc7, 0x0, 0x1f,
|
||||
0x8e, 0x0, 0x0, 0x1c, 0x0, 0x0, 0x3c, 0x0,
|
||||
0x0, 0x38, 0x0, 0x0, 0x71, 0xf8, 0x0, 0xe3,
|
||||
0xfc, 0x0, 0xe7, 0xfe, 0x1, 0xcf, 0xf, 0x3,
|
||||
0x8e, 0x7, 0x3, 0x8e, 0x7, 0x7, 0xe, 0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0xf,
|
||||
0x80, 0xff, 0xf0, 0x3, 0xfc, 0x0, 0x7f, 0xe0,
|
||||
0xf, 0xff, 0x3, 0xe0, 0x7c, 0x3c, 0x3, 0xc7,
|
||||
0x80, 0x1e, 0xf0, 0x0, 0xff, 0x0, 0xf, 0xf0,
|
||||
0x0, 0xff, 0x0, 0xf, 0xf0, 0x0, 0xff, 0x80,
|
||||
0x1f, 0x7c, 0x3, 0xe7, 0xe0, 0x7e, 0x3f, 0xff,
|
||||
0xc0, 0xff, 0xf0, 0x3, 0xfc, 0x0,
|
||||
|
||||
/* U+0039 "9" */
|
||||
0x3, 0xf8, 0x0, 0xff, 0xf0, 0x1f, 0xff, 0x83,
|
||||
0xe0, 0xfc, 0x7c, 0x3, 0xe7, 0x80, 0x1e, 0xf8,
|
||||
0x1, 0xff, 0x0, 0xf, 0xf0, 0x0, 0xff, 0x0,
|
||||
0xf, 0xf0, 0x0, 0xff, 0x0, 0xf, 0xf8, 0x1,
|
||||
0xf7, 0x80, 0x1e, 0x7c, 0x3, 0xe3, 0xe0, 0x7e,
|
||||
0x3f, 0xff, 0xc1, 0xff, 0xfc, 0x7, 0xe7, 0x80,
|
||||
0x0, 0xf8, 0x0, 0xf, 0x0, 0x1, 0xe0, 0x0,
|
||||
0x1e, 0x0, 0x3, 0xc0, 0x0, 0x3c, 0x0, 0x7,
|
||||
0x80, 0x0, 0xf8, 0x0, 0xf, 0x0, 0x1, 0xe0,
|
||||
0x0, 0x1e, 0x0, 0x3, 0xc0, 0x0,
|
||||
|
||||
/* U+003A ":" */
|
||||
0x7d, 0xff, 0xff, 0xff, 0xef, 0x80, 0x0, 0x0,
|
||||
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1,
|
||||
0xf7, 0xff, 0xff, 0xff, 0xbe
|
||||
};
|
||||
|
||||
|
||||
/*---------------------
|
||||
* GLYPH DESCRIPTION
|
||||
*--------------------*/
|
||||
|
||||
static const lv_font_fmt_txt_glyph_dsc_t glyph_dsc[] = {
|
||||
{.bitmap_index = 0, .adv_w = 0, .box_w = 0, .box_h = 0, .ofs_x = 0, .ofs_y = 0} /* id = 0 reserved */,
|
||||
{.bitmap_index = 0, .adv_w = 403, .box_w = 24, .box_h = 31, .ofs_x = 1, .ofs_y = 0},
|
||||
{.bitmap_index = 93, .adv_w = 403, .box_w = 19, .box_h = 31, .ofs_x = 3, .ofs_y = 0},
|
||||
{.bitmap_index = 167, .adv_w = 403, .box_w = 19, .box_h = 31, .ofs_x = 4, .ofs_y = 0},
|
||||
{.bitmap_index = 241, .adv_w = 403, .box_w = 19, .box_h = 31, .ofs_x = 3, .ofs_y = 0},
|
||||
{.bitmap_index = 315, .adv_w = 403, .box_w = 19, .box_h = 31, .ofs_x = 3, .ofs_y = 0},
|
||||
{.bitmap_index = 389, .adv_w = 403, .box_w = 18, .box_h = 31, .ofs_x = 3, .ofs_y = 0},
|
||||
{.bitmap_index = 459, .adv_w = 403, .box_w = 18, .box_h = 31, .ofs_x = 3, .ofs_y = 0},
|
||||
{.bitmap_index = 529, .adv_w = 403, .box_w = 20, .box_h = 31, .ofs_x = 3, .ofs_y = 0},
|
||||
{.bitmap_index = 607, .adv_w = 403, .box_w = 20, .box_h = 31, .ofs_x = 3, .ofs_y = 0},
|
||||
{.bitmap_index = 685, .adv_w = 403, .box_w = 20, .box_h = 31, .ofs_x = 3, .ofs_y = 0},
|
||||
{.bitmap_index = 763, .adv_w = 403, .box_w = 20, .box_h = 31, .ofs_x = 3, .ofs_y = 0},
|
||||
{.bitmap_index = 841, .adv_w = 403, .box_w = 7, .box_h = 24, .ofs_x = 9, .ofs_y = 0}
|
||||
};
|
||||
|
||||
/*---------------------
|
||||
* CHARACTER MAPPING
|
||||
*--------------------*/
|
||||
|
||||
|
||||
|
||||
/*Collect the unicode lists and glyph_id offsets*/
|
||||
static const lv_font_fmt_txt_cmap_t cmaps[] =
|
||||
{
|
||||
{
|
||||
.range_start = 37, .range_length = 1, .glyph_id_start = 1,
|
||||
.unicode_list = NULL, .glyph_id_ofs_list = NULL, .list_length = 0, .type = LV_FONT_FMT_TXT_CMAP_FORMAT0_TINY
|
||||
},
|
||||
{
|
||||
.range_start = 48, .range_length = 11, .glyph_id_start = 2,
|
||||
.unicode_list = NULL, .glyph_id_ofs_list = NULL, .list_length = 0, .type = LV_FONT_FMT_TXT_CMAP_FORMAT0_TINY
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
|
||||
/*--------------------
|
||||
* ALL CUSTOM DATA
|
||||
*--------------------*/
|
||||
|
||||
#if LV_VERSION_CHECK(8, 0, 0)
|
||||
/*Store all the custom data of the font*/
|
||||
static lv_font_fmt_txt_glyph_cache_t cache;
|
||||
static const lv_font_fmt_txt_dsc_t font_dsc = {
|
||||
#else
|
||||
static lv_font_fmt_txt_dsc_t font_dsc = {
|
||||
#endif
|
||||
.glyph_bitmap = glyph_bitmap,
|
||||
.glyph_dsc = glyph_dsc,
|
||||
.cmaps = cmaps,
|
||||
.kern_dsc = NULL,
|
||||
.kern_scale = 0,
|
||||
.cmap_num = 2,
|
||||
.bpp = 1,
|
||||
.kern_classes = 0,
|
||||
.bitmap_format = 0,
|
||||
#if LV_VERSION_CHECK(8, 0, 0)
|
||||
.cache = &cache
|
||||
#endif
|
||||
};
|
||||
|
||||
|
||||
/*-----------------
|
||||
* PUBLIC FONT
|
||||
*----------------*/
|
||||
|
||||
/*Initialize a public general font descriptor*/
|
||||
#if LV_VERSION_CHECK(8, 0, 0)
|
||||
const lv_font_t jetbrains_mono_42 = {
|
||||
#else
|
||||
lv_font_t jetbrains_mono_42 = {
|
||||
#endif
|
||||
.get_glyph_dsc = lv_font_get_glyph_dsc_fmt_txt, /*Function pointer to get glyph's data*/
|
||||
.get_glyph_bitmap = lv_font_get_bitmap_fmt_txt, /*Function pointer to get glyph's bitmap*/
|
||||
.line_height = 31, /*The maximum line height required by the font*/
|
||||
.base_line = 0, /*Baseline measured from the bottom of the line*/
|
||||
#if !(LVGL_VERSION_MAJOR == 6 && LVGL_VERSION_MINOR == 0)
|
||||
.subpx = LV_FONT_SUBPX_NONE,
|
||||
#endif
|
||||
#if LV_VERSION_CHECK(7, 4, 0) || LVGL_VERSION_MAJOR >= 8
|
||||
.underline_position = -7,
|
||||
.underline_thickness = 2,
|
||||
#endif
|
||||
.dsc = &font_dsc /*The custom font data. Will be accessed by `get_glyph_bitmap/dsc` */
|
||||
};
|
||||
|
||||
|
||||
|
||||
#endif /*#if JETBRAINS_MONO_42*/
|
||||
|
@ -1,554 +0,0 @@
|
||||
/*******************************************************************************
|
||||
* Size: 76 px
|
||||
* Bpp: 1
|
||||
* Opts:
|
||||
******************************************************************************/
|
||||
|
||||
#ifdef LV_LVGL_H_INCLUDE_SIMPLE
|
||||
#include "lvgl.h"
|
||||
#else
|
||||
#include "lvgl/lvgl.h"
|
||||
#endif
|
||||
|
||||
#ifndef JETBRAINS_MONO_76
|
||||
#define JETBRAINS_MONO_76 1
|
||||
#endif
|
||||
|
||||
#if JETBRAINS_MONO_76
|
||||
|
||||
/*-----------------
|
||||
* BITMAPS
|
||||
*----------------*/
|
||||
|
||||
/*Store the image of the glyphs*/
|
||||
static LV_ATTRIBUTE_LARGE_CONST const uint8_t glyph_bitmap[] = {
|
||||
/* U+0025 "%" */
|
||||
0x1, 0xfc, 0x0, 0x0, 0x7, 0xe1, 0xff, 0xf0,
|
||||
0x0, 0x1, 0xf8, 0x7f, 0xff, 0x0, 0x0, 0x3f,
|
||||
0x1f, 0xff, 0xf0, 0x0, 0xf, 0xc7, 0xff, 0xff,
|
||||
0x0, 0x3, 0xf0, 0xfe, 0xf, 0xe0, 0x0, 0x7e,
|
||||
0x3f, 0x80, 0xfc, 0x0, 0x1f, 0x87, 0xe0, 0xf,
|
||||
0xc0, 0x7, 0xe0, 0xfc, 0x1, 0xf8, 0x0, 0xfc,
|
||||
0x1f, 0x80, 0x3f, 0x0, 0x3f, 0x3, 0xf0, 0x7,
|
||||
0xe0, 0xf, 0xc0, 0x7e, 0x0, 0xfc, 0x1,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x0,
|
||||
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
||||
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
||||
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
||||
0x0, 0x0, 0x0, 0x0, 0x2, 0x0, 0xff, 0x1f,
|
||||
0xfc, 0xff, 0xef, 0xff, 0xff, 0xff, 0xff, 0xff,
|
||||
0xff, 0x7f, 0xf3, 0xff, 0x8f, 0xf8, 0x4, 0x0
|
||||
};
|
||||
|
||||
|
||||
/*---------------------
|
||||
* GLYPH DESCRIPTION
|
||||
*--------------------*/
|
||||
|
||||
static const lv_font_fmt_txt_glyph_dsc_t glyph_dsc[] = {
|
||||
{.bitmap_index = 0, .adv_w = 0, .box_w = 0, .box_h = 0, .ofs_x = 0, .ofs_y = 0} /* id = 0 reserved */,
|
||||
{.bitmap_index = 0, .adv_w = 730, .box_w = 43, .box_h = 57, .ofs_x = 1, .ofs_y = -1},
|
||||
{.bitmap_index = 307, .adv_w = 730, .box_w = 24, .box_h = 6, .ofs_x = 11, .ofs_y = 22},
|
||||
{.bitmap_index = 325, .adv_w = 730, .box_w = 34, .box_h = 72, .ofs_x = 6, .ofs_y = -8},
|
||||
{.bitmap_index = 631, .adv_w = 730, .box_w = 34, .box_h = 58, .ofs_x = 6, .ofs_y = -1},
|
||||
{.bitmap_index = 878, .adv_w = 730, .box_w = 34, .box_h = 56, .ofs_x = 7, .ofs_y = 0},
|
||||
{.bitmap_index = 1116, .adv_w = 730, .box_w = 34, .box_h = 57, .ofs_x = 6, .ofs_y = 0},
|
||||
{.bitmap_index = 1359, .adv_w = 730, .box_w = 34, .box_h = 57, .ofs_x = 5, .ofs_y = -1},
|
||||
{.bitmap_index = 1602, .adv_w = 730, .box_w = 32, .box_h = 56, .ofs_x = 5, .ofs_y = 0},
|
||||
{.bitmap_index = 1826, .adv_w = 730, .box_w = 32, .box_h = 57, .ofs_x = 7, .ofs_y = -1},
|
||||
{.bitmap_index = 2054, .adv_w = 730, .box_w = 36, .box_h = 58, .ofs_x = 5, .ofs_y = -1},
|
||||
{.bitmap_index = 2315, .adv_w = 730, .box_w = 36, .box_h = 56, .ofs_x = 6, .ofs_y = 0},
|
||||
{.bitmap_index = 2567, .adv_w = 730, .box_w = 36, .box_h = 58, .ofs_x = 5, .ofs_y = -1},
|
||||
{.bitmap_index = 2828, .adv_w = 730, .box_w = 36, .box_h = 57, .ofs_x = 5, .ofs_y = 0},
|
||||
{.bitmap_index = 3085, .adv_w = 730, .box_w = 13, .box_h = 44, .ofs_x = 16, .ofs_y = -1}
|
||||
};
|
||||
|
||||
/*---------------------
|
||||
* CHARACTER MAPPING
|
||||
*--------------------*/
|
||||
|
||||
static const uint16_t unicode_list_0[] = {
|
||||
0x0, 0x8
|
||||
};
|
||||
|
||||
/*Collect the unicode lists and glyph_id offsets*/
|
||||
static const lv_font_fmt_txt_cmap_t cmaps[] =
|
||||
{
|
||||
{
|
||||
.range_start = 37, .range_length = 9, .glyph_id_start = 1,
|
||||
.unicode_list = unicode_list_0, .glyph_id_ofs_list = NULL, .list_length = 2, .type = LV_FONT_FMT_TXT_CMAP_SPARSE_TINY
|
||||
},
|
||||
{
|
||||
.range_start = 47, .range_length = 12, .glyph_id_start = 3,
|
||||
.unicode_list = NULL, .glyph_id_ofs_list = NULL, .list_length = 0, .type = LV_FONT_FMT_TXT_CMAP_FORMAT0_TINY
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
|
||||
/*--------------------
|
||||
* ALL CUSTOM DATA
|
||||
*--------------------*/
|
||||
|
||||
#if LV_VERSION_CHECK(8, 0, 0)
|
||||
/*Store all the custom data of the font*/
|
||||
static lv_font_fmt_txt_glyph_cache_t cache;
|
||||
static const lv_font_fmt_txt_dsc_t font_dsc = {
|
||||
#else
|
||||
static lv_font_fmt_txt_dsc_t font_dsc = {
|
||||
#endif
|
||||
.glyph_bitmap = glyph_bitmap,
|
||||
.glyph_dsc = glyph_dsc,
|
||||
.cmaps = cmaps,
|
||||
.kern_dsc = NULL,
|
||||
.kern_scale = 0,
|
||||
.cmap_num = 2,
|
||||
.bpp = 1,
|
||||
.kern_classes = 0,
|
||||
.bitmap_format = 0,
|
||||
#if LV_VERSION_CHECK(8, 0, 0)
|
||||
.cache = &cache
|
||||
#endif
|
||||
};
|
||||
|
||||
|
||||
/*-----------------
|
||||
* PUBLIC FONT
|
||||
*----------------*/
|
||||
|
||||
/*Initialize a public general font descriptor*/
|
||||
#if LV_VERSION_CHECK(8, 0, 0)
|
||||
const lv_font_t jetbrains_mono_76 = {
|
||||
#else
|
||||
lv_font_t jetbrains_mono_76 = {
|
||||
#endif
|
||||
.get_glyph_dsc = lv_font_get_glyph_dsc_fmt_txt, /*Function pointer to get glyph's data*/
|
||||
.get_glyph_bitmap = lv_font_get_bitmap_fmt_txt, /*Function pointer to get glyph's bitmap*/
|
||||
.line_height = 72, /*The maximum line height required by the font*/
|
||||
.base_line = 8, /*Baseline measured from the bottom of the line*/
|
||||
#if !(LVGL_VERSION_MAJOR == 6 && LVGL_VERSION_MINOR == 0)
|
||||
.subpx = LV_FONT_SUBPX_NONE,
|
||||
#endif
|
||||
#if LV_VERSION_CHECK(7, 4, 0) || LVGL_VERSION_MAJOR >= 8
|
||||
.underline_position = -12,
|
||||
.underline_thickness = 4,
|
||||
#endif
|
||||
.dsc = &font_dsc /*The custom font data. Will be accessed by `get_glyph_bitmap/dsc` */
|
||||
};
|
||||
|
||||
|
||||
|
||||
#endif /*#if JETBRAINS_MONO_76*/
|
||||
|
6
src/displayapp/fonts/jetbrains_mono_bold_20.c_zero.patch
Normal file
@ -0,0 +1,6 @@
|
||||
91,92c91,92
|
||||
< 0x3f, 0x1f, 0xef, 0x3f, 0x87, 0xe1, 0xf8, 0x7f,
|
||||
< 0xdf, 0xf7, 0xe1, 0xf8, 0x7e, 0x1f, 0xcf, 0x7f,
|
||||
---
|
||||
> 0x3f, 0x1f, 0xef, 0x3f, 0x87, 0xe1, 0xf8, 0x7e,
|
||||
> 0xdf, 0xb7, 0xe1, 0xf8, 0x7e, 0x1f, 0xcf, 0x7f,
|
@ -1,523 +0,0 @@
|
||||
/*******************************************************************************
|
||||
* Size: 80 px
|
||||
* Bpp: 1
|
||||
* Opts:
|
||||
******************************************************************************/
|
||||
|
||||
#ifdef LV_LVGL_H_INCLUDE_SIMPLE
|
||||
#include "lvgl.h"
|
||||
#else
|
||||
#include "lvgl/lvgl.h"
|
||||
#endif
|
||||
|
||||
#ifndef JETBRAINS_MONO_EXTRABOLD_COMPRESSED
|
||||
#define JETBRAINS_MONO_EXTRABOLD_COMPRESSED 1
|
||||
#endif
|
||||
|
||||
#if JETBRAINS_MONO_EXTRABOLD_COMPRESSED
|
||||
|
||||
/*-----------------
|
||||
* BITMAPS
|
||||
*----------------*/
|
||||
|
||||
/*Store the image of the glyphs*/
|
||||
static LV_ATTRIBUTE_LARGE_CONST const uint8_t glyph_bitmap[] = {
|
||||
/* U+0030 "0" */
|
||||
0x0, 0x3, 0xff, 0x80, 0x0, 0x0, 0x3f, 0xff,
|
||||
0xe0, 0x0, 0x1, 0xff, 0xff, 0xf0, 0x0, 0xf,
|
||||
0xff, 0xff, 0xf8, 0x0, 0x3f, 0xff, 0xff, 0xf8,
|
||||
0x0, 0xff, 0xff, 0xff, 0xf8, 0x3, 0xff, 0xff,
|
||||
0xff, 0xf8, 0xf, 0xff, 0xff, 0xff, 0xf8, 0x3f,
|
||||
0xff, 0xff, 0xff, 0xf8, 0x7f, 0xff, 0xff, 0xff,
|
||||
0xf1, 0xff, 0xfc, 0x7, 0xff, 0xf3, 0xff, 0xe0,
|
||||
0x3, 0xff, 0xe7, 0xff, 0x80, 0x3, 0xff, 0xdf,
|
||||
0xfe, 0x0, 0x3, 0xff, 0xff, 0xfc, 0x0, 0x3,
|
||||
0xff, 0xff, 0xf0, 0x0, 0x7, 0xff, 0xff, 0xe0,
|
||||
0x0, 0xf, 0xff, 0xff, 0xc0, 0x0, 0x1f, 0xff,
|
||||
0xff, 0x80, 0x0, 0x3f, 0xff, 0xff, 0x0, 0x0,
|
||||
0x7f, 0xff, 0xfe, 0x0, 0x0, 0xff, 0xff, 0xfc,
|
||||
0x0, 0x1, 0xff, 0xff, 0xf8, 0x0, 0x3, 0xff,
|
||||
0xff, 0xf0, 0x0, 0x7, 0xff, 0xff, 0xe0, 0x7c,
|
||||
0xf, 0xff, 0xff, 0xc1, 0xfe, 0x1f, 0xff, 0xff,
|
||||
0x87, 0xfc, 0x3f, 0xff, 0xff, 0x1f, 0xfc, 0x7f,
|
||||
0xff, 0xfe, 0x3f, 0xf8, 0xff, 0xff, 0xfc, 0x7f,
|
||||
0xf1, 0xff, 0xff, 0xf8, 0xff, 0xe3, 0xff, 0xff,
|
||||
0xf1, 0xff, 0xc7, 0xff, 0xff, 0xe1, 0xff, 0xf,
|
||||
0xff, 0xff, 0xc1, 0xfc, 0x1f, 0xff, 0xff, 0x81,
|
||||
0xf0, 0x3f, 0xff, 0xff, 0x0, 0x0, 0x7f, 0xff,
|
||||
0xfe, 0x0, 0x0, 0xff, 0xff, 0xfc, 0x0, 0x1,
|
||||
0xff, 0xff, 0xf8, 0x0, 0x3, 0xff, 0xff, 0xf0,
|
||||
0x0, 0x7, 0xff, 0xff, 0xe0, 0x0, 0xf, 0xff,
|
||||
0xff, 0xc0, 0x0, 0x1f, 0xff, 0xff, 0x80, 0x0,
|
||||
0x3f, 0xff, 0xff, 0x0, 0x0, 0x7f, 0xff, 0xfe,
|
||||
0x0, 0x0, 0xff, 0xff, 0xfe, 0x0, 0x1, 0xff,
|
||||
0xff, 0xfc, 0x0, 0x7, 0xff, 0xbf, 0xfc, 0x0,
|
||||
0x1f, 0xfe, 0x7f, 0xfc, 0x0, 0x7f, 0xfc, 0xff,
|
||||
0xfe, 0x3, 0xff, 0xf8, 0xff, 0xff, 0xff, 0xff,
|
||||
0xe1, 0xff, 0xff, 0xff, 0xff, 0xc1, 0xff, 0xff,
|
||||
0xff, 0xff, 0x1, 0xff, 0xff, 0xff, 0xfc, 0x1,
|
||||
0xff, 0xff, 0xff, 0xf0, 0x1, 0xff, 0xff, 0xff,
|
||||
0xc0, 0x1, 0xff, 0xff, 0xff, 0x0, 0x0, 0xff,
|
||||
0xff, 0xf8, 0x0, 0x0, 0x7f, 0xff, 0xc0, 0x0,
|
||||
0x0, 0x1f, 0xfc, 0x0, 0x0,
|
||||
|
||||
/* U+0031 "1" */
|
||||
0x0, 0x3, 0xff, 0xe0, 0x0, 0x0, 0x3f, 0xff,
|
||||
0x80, 0x0, 0x1, 0xff, 0xfe, 0x0, 0x0, 0x1f,
|
||||
0xff, 0xf8, 0x0, 0x0, 0xff, 0xff, 0xe0, 0x0,
|
||||
0x7, 0xff, 0xff, 0x80, 0x0, 0x7f, 0xff, 0xfe,
|
||||
0x0, 0x3, 0xff, 0xff, 0xf8, 0x0, 0x3f, 0xff,
|
||||
0xff, 0xe0, 0x1, 0xff, 0xff, 0xff, 0x80, 0xf,
|
||||
0xff, 0xff, 0xfe, 0x0, 0x3f, 0xff, 0xff, 0xf8,
|
||||
0x0, 0xff, 0xfd, 0xff, 0xe0, 0x3, 0xff, 0xc7,
|
||||
0xff, 0x80, 0xf, 0xfe, 0x1f, 0xfe, 0x0, 0x3f,
|
||||
0xe0, 0x7f, 0xf8, 0x0, 0xff, 0x1, 0xff, 0xe0,
|
||||
0x3, 0xf8, 0x7, 0xff, 0x80, 0xf, 0x80, 0x1f,
|
||||
0xfe, 0x0, 0x3c, 0x0, 0x7f, 0xf8, 0x0, 0xe0,
|
||||
0x1, 0xff, 0xe0, 0x2, 0x0, 0x7, 0xff, 0x80,
|
||||
0x0, 0x0, 0x1f, 0xfe, 0x0, 0x0, 0x0, 0x7f,
|
||||
0xf8, 0x0, 0x0, 0x1, 0xff, 0xe0, 0x0, 0x0,
|
||||
0x7, 0xff, 0x80, 0x0, 0x0, 0x1f, 0xfe, 0x0,
|
||||
0x0, 0x0, 0x7f, 0xf8, 0x0, 0x0, 0x1, 0xff,
|
||||
0xe0, 0x0, 0x0, 0x7, 0xff, 0x80, 0x0, 0x0,
|
||||
0x1f, 0xfe, 0x0, 0x0, 0x0, 0x7f, 0xf8, 0x0,
|
||||
0x0, 0x1, 0xff, 0xe0, 0x0, 0x0, 0x7, 0xff,
|
||||
0x80, 0x0, 0x0, 0x1f, 0xfe, 0x0, 0x0, 0x0,
|
||||
0x7f, 0xf8, 0x0, 0x0, 0x1, 0xff, 0xe0, 0x0,
|
||||
0x0, 0x7, 0xff, 0x80, 0x0, 0x0, 0x1f, 0xfe,
|
||||
0x0, 0x0, 0x0, 0x7f, 0xf8, 0x0, 0x0, 0x1,
|
||||
0xff, 0xe0, 0x0, 0x0, 0x7, 0xff, 0x80, 0x0,
|
||||
0x0, 0x1f, 0xfe, 0x0, 0x0, 0x0, 0x7f, 0xf8,
|
||||
0x0, 0x0, 0x1, 0xff, 0xe0, 0x0, 0x0, 0x7,
|
||||
0xff, 0x80, 0x0, 0x0, 0x1f, 0xfe, 0x0, 0x0,
|
||||
0x0, 0x7f, 0xf8, 0x0, 0xff, 0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
|
||||
0xc0,
|
||||
|
||||
/* U+0032 "2" */
|
||||
0x0, 0x1, 0xff, 0x80, 0x0, 0x0, 0x3f, 0xff,
|
||||
0xe0, 0x0, 0x1, 0xff, 0xff, 0xf8, 0x0, 0xf,
|
||||
0xff, 0xff, 0xf8, 0x0, 0x3f, 0xff, 0xff, 0xf8,
|
||||
0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 0x0,
|
||||
0x0, 0xff, 0xff, 0x0, 0x0, 0x3, 0xff, 0xf8,
|
||||
0x0, 0x0, 0xf, 0xff, 0xe0, 0x0, 0x0, 0x3f,
|
||||
0xff, 0x80, 0x0, 0x0, 0xff, 0xfe, 0x0, 0x0,
|
||||
0x3, 0xff, 0xf8, 0x0, 0x0, 0xf, 0xff, 0xe0,
|
||||
0x0, 0x0, 0x3f, 0xff, 0x80, 0x0, 0x0, 0xff,
|
||||
0xff, 0xff, 0xff, 0xfd, 0xff, 0xff, 0xff, 0xff,
|
||||
0xfb, 0xff, 0xff, 0xff, 0xff, 0xf7, 0xff, 0xff,
|
||||
0xff, 0xff, 0xef, 0xff, 0xff, 0xff, 0xff, 0xdf,
|
||||
0xff, 0xff, 0xff, 0xff, 0xbf, 0xff, 0xff, 0xff,
|
||||
0xff, 0x7f, 0xff, 0xff, 0xff, 0xfe, 0xff, 0xff,
|
||||
0xff, 0xff, 0xfd, 0xff, 0xff, 0xff, 0xff, 0xfb,
|
||||
0xff, 0xff, 0xff, 0xff, 0xf0,
|
||||
|
||||
/* U+0033 "3" */
|
||||
0x1f, 0xff, 0xff, 0xff, 0xf8, 0x3f, 0xff, 0xff,
|
||||
0xff, 0xf0, 0x7f, 0xff, 0xff, 0xff, 0xe0, 0xff,
|
||||
0xff, 0xff, 0xff, 0xc1, 0xff, 0xff, 0xff, 0xff,
|
||||
0x83, 0xff, 0xff, 0xff, 0xff, 0x7, 0xff, 0xff,
|
||||
0xff, 0xfe, 0xf, 0xff, 0xff, 0xff, 0xfc, 0x1f,
|
||||
0xff, 0xff, 0xff, 0xf8, 0x3f, 0xff, 0xff, 0xff,
|
||||
0xf0, 0x0, 0x0, 0x3, 0xff, 0xc0, 0x0, 0x0,
|
||||
0xf, 0xff, 0x0, 0x0, 0x0, 0x3f, 0xfc, 0x0,
|
||||
0x0, 0x0, 0xff, 0xf0, 0x0, 0x0, 0x3, 0xff,
|
||||
0xc0, 0x0, 0x0, 0x1f, 0xff, 0x0, 0x0, 0x0,
|
||||
0x7f, 0xf8, 0x0, 0x0, 0x1, 0xff, 0xe0, 0x0,
|
||||
0x0, 0x7, 0xff, 0x80, 0x0, 0x0, 0x1f, 0xfe,
|
||||
0x0, 0x0, 0x0, 0x7f, 0xf8, 0x0, 0x0, 0x1,
|
||||
0xff, 0xf8, 0x0, 0x0, 0x3, 0xff, 0xfe, 0x0,
|
||||
0x0, 0x7, 0xff, 0xff, 0x0, 0x0, 0xf, 0xff,
|
||||
0xff, 0x80, 0x0, 0x1f, 0xff, 0xff, 0x80, 0x0,
|
||||
0x3f, 0xff, 0xff, 0x80, 0x0, 0x7f, 0xff, 0xff,
|
||||
0x80, 0x0, 0xff, 0xff, 0xff, 0x80, 0x1, 0xff,
|
||||
0xff, 0xff, 0x0, 0x3, 0xff, 0xff, 0xff, 0x0,
|
||||
0x0, 0x0, 0xff, 0xfe, 0x0, 0x0, 0x0, 0x7f,
|
||||
0xfc, 0x0, 0x0, 0x0, 0x7f, 0xfc, 0x0, 0x0,
|
||||
0x0, 0xff, 0xf8, 0x0, 0x0, 0x0, 0xff, 0xf0,
|
||||
0x0, 0x0, 0x1, 0xff, 0xe0, 0x0, 0x0, 0x3,
|
||||
0xff, 0xc0, 0x0, 0x0, 0x7, 0xff, 0x80, 0x0,
|
||||
0x0, 0xf, 0xff, 0x0, 0x0, 0x0, 0x1f, 0xfe,
|
||||
0x0, 0x0, 0x0, 0x3f, 0xff, 0xff, 0xc0, 0x0,
|
||||
0x7f, 0xff, 0xff, 0x80, 0x0, 0xff, 0xff, 0xff,
|
||||
0x0, 0x1, 0xff, 0xff, 0xff, 0x0, 0x7, 0xff,
|
||||
0xff, 0xfe, 0x0, 0xf, 0xff, 0xbf, 0xfe, 0x0,
|
||||
0x3f, 0xfe, 0x7f, 0xff, 0x1, 0xff, 0xfc, 0xff,
|
||||
0xff, 0xff, 0xff, 0xf8, 0xff, 0xff, 0xff, 0xff,
|
||||
0xe0, 0xff, 0xff, 0xff, 0xff,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||||
0x3f, 0xfd, 0xff, 0xf8, 0x0, 0xff, 0xf7, 0xff,
|
||||
0xc0, 0x3, 0xff, 0xff, 0xfe, 0x0, 0xf, 0xff,
|
||||
0xff, 0xf8, 0x0, 0x3f, 0xff, 0xff, 0xc0, 0x0,
|
||||
0xff, 0xff, 0xfe, 0x0, 0x3, 0xff, 0xff, 0xf8,
|
||||
0x0, 0xf, 0xff, 0xff, 0xe0, 0x0, 0x3f, 0xff,
|
||||
0xff, 0x80, 0x0, 0xff, 0xff, 0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff, 0xff, 0x0, 0x0, 0x0, 0x3f,
|
||||
0xfc, 0x0, 0x0, 0x0, 0xff, 0xf0, 0x0, 0x0,
|
||||
0x3, 0xff, 0xc0, 0x0, 0x0, 0xf, 0xff, 0x0,
|
||||
0x0, 0x0, 0x3f, 0xfc, 0x0, 0x0, 0x0, 0xff,
|
||||
0xf0, 0x0, 0x0, 0x3, 0xff, 0xc0, 0x0, 0x0,
|
||||
0xf, 0xff, 0x0, 0x0, 0x0, 0x3f, 0xfc, 0x0,
|
||||
0x0, 0x0, 0xff, 0xf0, 0x0, 0x0, 0x3, 0xff,
|
||||
0xc0,
|
||||
|
||||
/* U+0035 "5" */
|
||||
0x7f, 0xff, 0xff, 0xff, 0xf1, 0xff, 0xff, 0xff,
|
||||
0xff, 0xc7, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xff,
|
||||
0xff, 0xff, 0xfc, 0x7f, 0xff, 0xff, 0xff, 0xf1,
|
||||
0xff, 0xff, 0xff, 0xff, 0xc7, 0xff, 0xff, 0xff,
|
||||
0xff, 0x1f, 0xff, 0xff, 0xff, 0xfc, 0x7f, 0xff,
|
||||
0xff, 0xff, 0xf1, 0xff, 0xff, 0xff, 0xff, 0xc7,
|
||||
0xff, 0xff, 0xff, 0xff, 0x1f, 0xfe, 0x0, 0x0,
|
||||
0x0, 0x7f, 0xf8, 0x0, 0x0, 0x1, 0xff, 0xe0,
|
||||
0x0, 0x0, 0x7, 0xff, 0x80, 0x0, 0x0, 0x1f,
|
||||
0xfe, 0x0, 0x0, 0x0, 0x7f, 0xf8, 0x0, 0x0,
|
||||
0x1, 0xff, 0xe0, 0x0, 0x0, 0x7, 0xff, 0x80,
|
||||
0x0, 0x0, 0x1f, 0xfe, 0x0, 0x0, 0x0, 0x7f,
|
||||
0xf8, 0x1f, 0xf0, 0x1, 0xff, 0xe1, 0xff, 0xf0,
|
||||
0x7, 0xff, 0x9f, 0xff, 0xf0, 0x1f, 0xfe, 0xff,
|
||||
0xff, 0xe0, 0x7f, 0xfb, 0xff, 0xff, 0xc1, 0xff,
|
||||
0xff, 0xff, 0xff, 0x87, 0xff, 0xff, 0xff, 0xff,
|
||||
0x1f, 0xff, 0xff, 0xff, 0xfc, 0x7f, 0xff, 0xff,
|
||||
0xff, 0xf9, 0xff, 0xff, 0xff, 0xff, 0xe7, 0xff,
|
||||
0xf0, 0x3f, 0xff, 0x9f, 0xff, 0x0, 0x3f, 0xfe,
|
||||
0x7f, 0xf8, 0x0, 0x7f, 0xfc, 0x0, 0x0, 0x1,
|
||||
0xff, 0xf0, 0x0, 0x0, 0x3, 0xff, 0xc0, 0x0,
|
||||
0x0, 0xf, 0xff, 0x0, 0x0, 0x0, 0x3f, 0xfc,
|
||||
0x0, 0x0, 0x0, 0xff, 0xf0, 0x0, 0x0, 0x3,
|
||||
0xff, 0xc0, 0x0, 0x0, 0xf, 0xff, 0x0, 0x0,
|
||||
0x0, 0x3f, 0xfc, 0x0, 0x0, 0x0, 0xff, 0xf0,
|
||||
0x0, 0x0, 0x3, 0xff, 0xc0, 0x0, 0x0, 0xf,
|
||||
0xff, 0xff, 0xf0, 0x0, 0x3f, 0xff, 0xff, 0xc0,
|
||||
0x0, 0xff, 0xff, 0xff, 0x0, 0x7, 0xff, 0xff,
|
||||
0xfe, 0x0, 0x1f, 0xfe, 0xff, 0xfc, 0x0, 0xff,
|
||||
0xf9, 0xff, 0xfc, 0xf, 0xff, 0xe7, 0xff, 0xff,
|
||||
0xff, 0xff, 0xf, 0xff, 0xff, 0xff, 0xfc, 0x3f,
|
||||
0xff, 0xff, 0xff, 0xe0, 0x7f, 0xff, 0xff, 0xff,
|
||||
0x80, 0xff, 0xff, 0xff, 0xfc, 0x1, 0xff, 0xff,
|
||||
0xff, 0xe0, 0x3, 0xff, 0xff, 0xfe, 0x0, 0x3,
|
||||
0xff, 0xff, 0xf0, 0x0, 0x3, 0xff, 0xff, 0x0,
|
||||
0x0, 0x1, 0xff, 0xc0, 0x0,
|
||||
|
||||
/* U+0036 "6" */
|
||||
0x0, 0x0, 0x3f, 0xfe, 0x0, 0x0, 0x0, 0x1f,
|
||||
0xff, 0x0, 0x0, 0x0, 0x1f, 0xff, 0x0, 0x0,
|
||||
0x0, 0xf, 0xff, 0x80, 0x0, 0x0, 0xf, 0xff,
|
||||
0x80, 0x0, 0x0, 0x7, 0xff, 0x80, 0x0, 0x0,
|
||||
0x7, 0xff, 0xc0, 0x0, 0x0, 0x7, 0xff, 0xc0,
|
||||
0x0, 0x0, 0x3, 0xff, 0xe0, 0x0, 0x0, 0x3,
|
||||
0xff, 0xe0, 0x0, 0x0, 0x1, 0xff, 0xf0, 0x0,
|
||||
0x0, 0x1, 0xff, 0xf0, 0x0, 0x0, 0x0, 0xff,
|
||||
0xf0, 0x0, 0x0, 0x0, 0xff, 0xf8, 0x0, 0x0,
|
||||
0x0, 0xff, 0xf8, 0x0, 0x0, 0x0, 0x7f, 0xfc,
|
||||
0x0, 0x0, 0x0, 0x7f, 0xfc, 0x0, 0x0, 0x0,
|
||||
0x3f, 0xfc, 0x0, 0x0, 0x0, 0x3f, 0xfe, 0x0,
|
||||
0x0, 0x0, 0x3f, 0xfe, 0x0, 0x0, 0x0, 0x1f,
|
||||
0xff, 0x0, 0x0, 0x0, 0x1f, 0xff, 0x0, 0x0,
|
||||
0x0, 0xf, 0xff, 0x80, 0x0, 0x0, 0xf, 0xff,
|
||||
0x87, 0xf8, 0x0, 0x7, 0xff, 0x8f, 0xff, 0x0,
|
||||
0x7, 0xff, 0xcf, 0xff, 0xe0, 0x3, 0xff, 0xdf,
|
||||
0xff, 0xf8, 0x3, 0xff, 0xef, 0xff, 0xfe, 0x1,
|
||||
0xff, 0xff, 0xff, 0xff, 0x81, 0xff, 0xff, 0xff,
|
||||
0xff, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xf8, 0x7f,
|
||||
0xff, 0xff, 0xff, 0xfc, 0x7f, 0xff, 0x81, 0xff,
|
||||
0xff, 0x3f, 0xff, 0x0, 0x3f, 0xff, 0x9f, 0xff,
|
||||
0x0, 0x7, 0xff, 0xdf, 0xff, 0x80, 0x3, 0xff,
|
||||
0xef, 0xff, 0x80, 0x0, 0xff, 0xff, 0xff, 0xc0,
|
||||
0x0, 0x7f, 0xff, 0xff, 0xc0, 0x0, 0x1f, 0xff,
|
||||
0xff, 0xe0, 0x0, 0xf, 0xff, 0xff, 0xf0, 0x0,
|
||||
0x7, 0xff, 0xff, 0xf8, 0x0, 0x3, 0xff, 0xff,
|
||||
0xfc, 0x0, 0x1, 0xff, 0xff, 0xfe, 0x0, 0x0,
|
||||
0xff, 0xff, 0xff, 0x80, 0x0, 0xff, 0xfb, 0xff,
|
||||
0xc0, 0x0, 0x7f, 0xfd, 0xff, 0xf0, 0x0, 0x7f,
|
||||
0xfc, 0xff, 0xf8, 0x0, 0x3f, 0xfe, 0x3f, 0xfe,
|
||||
0x0, 0x3f, 0xff, 0x1f, 0xff, 0xc0, 0x7f, 0xff,
|
||||
0x7, 0xff, 0xff, 0xff, 0xff, 0x83, 0xff, 0xff,
|
||||
0xff, 0xff, 0x80, 0xff, 0xff, 0xff, 0xff, 0x80,
|
||||
0x3f, 0xff, 0xff, 0xff, 0xc0, 0xf, 0xff, 0xff,
|
||||
0xff, 0xc0, 0x3, 0xff, 0xff, 0xff, 0x80, 0x0,
|
||||
0xff, 0xff, 0xff, 0x80, 0x0, 0x1f, 0xff, 0xff,
|
||||
0x0, 0x0, 0x3, 0xff, 0xfe, 0x0, 0x0, 0x0,
|
||||
0x3f, 0xf8, 0x0, 0x0,
|
||||
|
||||
/* U+0037 "7" */
|
||||
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff, 0xff, 0xfc, 0x0, 0x3, 0xff,
|
||||
0xff, 0xfe, 0x0, 0x1, 0xff, 0xef, 0xff, 0x0,
|
||||
0x1, 0xff, 0xf7, 0xff, 0x80, 0x0, 0xff, 0xf3,
|
||||
0xff, 0xc0, 0x0, 0xff, 0xf9, 0xff, 0xe0, 0x0,
|
||||
0x7f, 0xfc, 0xff, 0xf0, 0x0, 0x7f, 0xfc, 0x7f,
|
||||
0xf8, 0x0, 0x3f, 0xfe, 0x3f, 0xfc, 0x0, 0x3f,
|
||||
0xfe, 0x1f, 0xfe, 0x0, 0x1f, 0xff, 0x0, 0x0,
|
||||
0x0, 0x1f, 0xff, 0x0, 0x0, 0x0, 0xf, 0xff,
|
||||
0x80, 0x0, 0x0, 0x7, 0xff, 0x80, 0x0, 0x0,
|
||||
0x7, 0xff, 0x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0,
|
||||
|
||||
/* U+0038 "8" */
|
||||
0x0, 0x1, 0xff, 0x80, 0x0, 0x0, 0xf, 0xff,
|
||||
0xfc, 0x0, 0x0, 0x1f, 0xff, 0xff, 0x80, 0x0,
|
||||
0x1f, 0xff, 0xff, 0xf0, 0x0, 0x3f, 0xff, 0xff,
|
||||
0xfc, 0x0, 0x3f, 0xff, 0xff, 0xff, 0x0, 0x3f,
|
||||
0xff, 0xff, 0xff, 0xc0, 0x3f, 0xff, 0xff, 0xff,
|
||||
0xf0, 0x1f, 0xff, 0xff, 0xff, 0xf8, 0x1f, 0xff,
|
||||
0xff, 0xff, 0xfe, 0xf, 0xff, 0xe0, 0x7f, 0xff,
|
||||
0x7, 0xff, 0xc0, 0xf, 0xff, 0x87, 0xff, 0xc0,
|
||||
0x3, 0xff, 0xe3, 0xff, 0xe0, 0x1, 0xff, 0xf1,
|
||||
0xff, 0xe0, 0x0, 0x7f, 0xf8, 0xff, 0xf0, 0x0,
|
||||
0x3f, 0xfc, 0x7f, 0xf8, 0x0, 0x1f, 0xfe, 0x3f,
|
||||
0xfc, 0x0, 0xf, 0xff, 0x1f, 0xfe, 0x0, 0x7,
|
||||
0xff, 0x8f, 0xff, 0x80, 0x7, 0xff, 0xc3, 0xff,
|
||||
0xc0, 0x3, 0xff, 0xc1, 0xff, 0xf0, 0x3, 0xff,
|
||||
0xe0, 0x7f, 0xfc, 0x3, 0xff, 0xe0, 0x3f, 0xff,
|
||||
0x3, 0xff, 0xf0, 0xf, 0xff, 0xe7, 0xff, 0xf0,
|
||||
0x3, 0xff, 0xff, 0xff, 0xf0, 0x0, 0xff, 0xff,
|
||||
0xff, 0xf0, 0x0, 0x1f, 0xff, 0xff, 0xf0, 0x0,
|
||||
0x7, 0xff, 0xff, 0xf0, 0x0, 0x1, 0xff, 0xff,
|
||||
0xf0, 0x0, 0x3, 0xff, 0xff, 0xfc, 0x0, 0x3,
|
||||
0xff, 0xff, 0xff, 0x80, 0x3, 0xff, 0xff, 0xff,
|
||||
0xe0, 0x3, 0xff, 0xff, 0xff, 0xf8, 0x3, 0xff,
|
||||
0xf0, 0xff, 0xfe, 0x3, 0xff, 0xf0, 0x1f, 0xff,
|
||||
0x83, 0xff, 0xe0, 0x7, 0xff, 0xe3, 0xff, 0xe0,
|
||||
0x1, 0xff, 0xf1, 0xff, 0xe0, 0x0, 0x7f, 0xfc,
|
||||
0xff, 0xf0, 0x0, 0x1f, 0xfe, 0xff, 0xf0, 0x0,
|
||||
0x7, 0xff, 0xff, 0xf8, 0x0, 0x3, 0xff, 0xff,
|
||||
0xfc, 0x0, 0x1, 0xff, 0xff, 0xfe, 0x0, 0x0,
|
||||
0xff, 0xff, 0xff, 0x0, 0x0, 0x7f, 0xff, 0xff,
|
||||
0xc0, 0x0, 0x7f, 0xff, 0xff, 0xe0, 0x0, 0x3f,
|
||||
0xff, 0xff, 0xf8, 0x0, 0x3f, 0xff, 0x7f, 0xfe,
|
||||
0x0, 0x3f, 0xff, 0x3f, 0xff, 0xc0, 0x7f, 0xff,
|
||||
0x9f, 0xff, 0xff, 0xff, 0xff, 0xc7, 0xff, 0xff,
|
||||
0xff, 0xff, 0xc1, 0xff, 0xff, 0xff, 0xff, 0xc0,
|
||||
0x7f, 0xff, 0xff, 0xff, 0xe0, 0x3f, 0xff, 0xff,
|
||||
0xff, 0xe0, 0x7, 0xff, 0xff, 0xff, 0xe0, 0x1,
|
||||
0xff, 0xff, 0xff, 0xc0, 0x0, 0x3f, 0xff, 0xff,
|
||||
0x80, 0x0, 0x7, 0xff, 0xff, 0x0, 0x0, 0x0,
|
||||
0x3f, 0xf8, 0x0, 0x0,
|
||||
|
||||
/* U+0039 "9" */
|
||||
0x0, 0x1, 0xff, 0x80, 0x0, 0x0, 0x7, 0xff,
|
||||
0xfc, 0x0, 0x0, 0xf, 0xff, 0xff, 0x80, 0x0,
|
||||
0x1f, 0xff, 0xff, 0xf0, 0x0, 0x1f, 0xff, 0xff,
|
||||
0xfc, 0x0, 0x1f, 0xff, 0xff, 0xff, 0x0, 0x1f,
|
||||
0xff, 0xff, 0xff, 0xc0, 0x1f, 0xff, 0xff, 0xff,
|
||||
0xf0, 0x1f, 0xff, 0xff, 0xff, 0xfc, 0x1f, 0xff,
|
||||
0xff, 0xff, 0xfe, 0xf, 0xff, 0xf0, 0x7f, 0xff,
|
||||
0x8f, 0xff, 0xe0, 0xf, 0xff, 0xc7, 0xff, 0xc0,
|
||||
0x1, 0xff, 0xf3, 0xff, 0xe0, 0x0, 0xff, 0xfb,
|
||||
0xff, 0xe0, 0x0, 0x3f, 0xfd, 0xff, 0xf0, 0x0,
|
||||
0x1f, 0xff, 0xff, 0xf0, 0x0, 0x7, 0xff, 0xff,
|
||||
0xf8, 0x0, 0x3, 0xff, 0xff, 0xfc, 0x0, 0x1,
|
||||
0xff, 0xff, 0xfe, 0x0, 0x0, 0xff, 0xff, 0xff,
|
||||
0x0, 0x0, 0x7f, 0xff, 0xff, 0x80, 0x0, 0x3f,
|
||||
0xff, 0xff, 0xe0, 0x0, 0x3f, 0xff, 0xff, 0xf0,
|
||||
0x0, 0x1f, 0xff, 0x7f, 0xfc, 0x0, 0x1f, 0xff,
|
||||
0x3f, 0xfe, 0x0, 0xf, 0xff, 0x9f, 0xff, 0xc0,
|
||||
0x1f, 0xff, 0xc7, 0xff, 0xf8, 0x3f, 0xff, 0xe3,
|
||||
0xff, 0xff, 0xff, 0xff, 0xe0, 0xff, 0xff, 0xff,
|
||||
0xff, 0xf0, 0x7f, 0xff, 0xff, 0xff, 0xf8, 0x1f,
|
||||
0xff, 0xff, 0xff, 0xf8, 0x7, 0xff, 0xff, 0xbf,
|
||||
0xfc, 0x1, 0xff, 0xff, 0xbf, 0xfc, 0x0, 0x7f,
|
||||
0xff, 0xbf, 0xfe, 0x0, 0xf, 0xff, 0x1f, 0xfe,
|
||||
0x0, 0x1, 0xfe, 0x1f, 0xff, 0x0, 0x0, 0x0,
|
||||
0xf, 0xff, 0x0, 0x0, 0x0, 0xf, 0xff, 0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0, 0x0,
|
||||
0x7, 0xe0, 0x1f, 0xf8, 0x3f, 0xfc, 0x7f, 0xfe,
|
||||
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0x3f, 0xfc,
|
||||
0x1f, 0xf8, 0x7, 0xe0
|
||||
};
|
||||
|
||||
|
||||
/*---------------------
|
||||
* GLYPH DESCRIPTION
|
||||
*--------------------*/
|
||||
|
||||
static const lv_font_fmt_txt_glyph_dsc_t glyph_dsc[] = {
|
||||
{.bitmap_index = 0, .adv_w = 0, .box_w = 0, .box_h = 0, .ofs_x = 0, .ofs_y = 0} /* id = 0 reserved */,
|
||||
{.bitmap_index = 0, .adv_w = 768, .box_w = 39, .box_h = 60, .ofs_x = 5, .ofs_y = -1},
|
||||
{.bitmap_index = 293, .adv_w = 768, .box_w = 38, .box_h = 59, .ofs_x = 6, .ofs_y = 0},
|
||||
{.bitmap_index = 574, .adv_w = 768, .box_w = 39, .box_h = 60, .ofs_x = 4, .ofs_y = 0},
|
||||
{.bitmap_index = 867, .adv_w = 768, .box_w = 39, .box_h = 59, .ofs_x = 4, .ofs_y = -1},
|
||||
{.bitmap_index = 1155, .adv_w = 768, .box_w = 38, .box_h = 59, .ofs_x = 4, .ofs_y = 0},
|
||||
{.bitmap_index = 1436, .adv_w = 768, .box_w = 38, .box_h = 60, .ofs_x = 5, .ofs_y = -1},
|
||||
{.bitmap_index = 1721, .adv_w = 768, .box_w = 41, .box_h = 60, .ofs_x = 4, .ofs_y = -1},
|
||||
{.bitmap_index = 2029, .adv_w = 768, .box_w = 41, .box_h = 58, .ofs_x = 4, .ofs_y = 0},
|
||||
{.bitmap_index = 2327, .adv_w = 768, .box_w = 41, .box_h = 60, .ofs_x = 4, .ofs_y = -1},
|
||||
{.bitmap_index = 2635, .adv_w = 768, .box_w = 41, .box_h = 60, .ofs_x = 4, .ofs_y = -1},
|
||||
{.bitmap_index = 2943, .adv_w = 768, .box_w = 16, .box_h = 46, .ofs_x = 16, .ofs_y = -1}
|
||||
};
|
||||
|
||||
/*---------------------
|
||||
* CHARACTER MAPPING
|
||||
*--------------------*/
|
||||
|
||||
|
||||
|
||||
/*Collect the unicode lists and glyph_id offsets*/
|
||||
static const lv_font_fmt_txt_cmap_t cmaps[] =
|
||||
{
|
||||
{
|
||||
.range_start = 48, .range_length = 11, .glyph_id_start = 1,
|
||||
.unicode_list = NULL, .glyph_id_ofs_list = NULL, .list_length = 0, .type = LV_FONT_FMT_TXT_CMAP_FORMAT0_TINY
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
|
||||
/*--------------------
|
||||
* ALL CUSTOM DATA
|
||||
*--------------------*/
|
||||
|
||||
#if LV_VERSION_CHECK(8, 0, 0)
|
||||
/*Store all the custom data of the font*/
|
||||
static lv_font_fmt_txt_glyph_cache_t cache;
|
||||
static const lv_font_fmt_txt_dsc_t font_dsc = {
|
||||
#else
|
||||
static lv_font_fmt_txt_dsc_t font_dsc = {
|
||||
#endif
|
||||
.glyph_bitmap = glyph_bitmap,
|
||||
.glyph_dsc = glyph_dsc,
|
||||
.cmaps = cmaps,
|
||||
.kern_dsc = NULL,
|
||||
.kern_scale = 0,
|
||||
.cmap_num = 1,
|
||||
.bpp = 1,
|
||||
.kern_classes = 0,
|
||||
.bitmap_format = 0,
|
||||
#if LV_VERSION_CHECK(8, 0, 0)
|
||||
.cache = &cache
|
||||
#endif
|
||||
};
|
||||
|
||||
|
||||
/*-----------------
|
||||
* PUBLIC FONT
|
||||
*----------------*/
|
||||
|
||||
/*Initialize a public general font descriptor*/
|
||||
#if LV_VERSION_CHECK(8, 0, 0)
|
||||
const lv_font_t jetbrains_mono_extrabold_compressed = {
|
||||
#else
|
||||
lv_font_t jetbrains_mono_extrabold_compressed = {
|
||||
#endif
|
||||
.get_glyph_dsc = lv_font_get_glyph_dsc_fmt_txt, /*Function pointer to get glyph's data*/
|
||||
.get_glyph_bitmap = lv_font_get_bitmap_fmt_txt, /*Function pointer to get glyph's bitmap*/
|
||||
.line_height = 61, /*The maximum line height required by the font*/
|
||||
.base_line = 1, /*Baseline measured from the bottom of the line*/
|
||||
#if !(LVGL_VERSION_MAJOR == 6 && LVGL_VERSION_MINOR == 0)
|
||||
.subpx = LV_FONT_SUBPX_NONE,
|
||||
#endif
|
||||
#if LV_VERSION_CHECK(7, 4, 0) || LVGL_VERSION_MAJOR >= 8
|
||||
.underline_position = -12,
|
||||
.underline_thickness = 4,
|
||||
#endif
|
||||
.dsc = &font_dsc /*The custom font data. Will be accessed by `get_glyph_bitmap/dsc` */
|
||||
};
|
||||
|
||||
|
||||
|
||||
#endif /*#if JETBRAINS_MONO_EXTRABOLD_COMPRESSED*/
|
||||
|
@ -1,324 +0,0 @@
|
||||
/*******************************************************************************
|
||||
* Size: 48 px
|
||||
* Bpp: 1
|
||||
* Opts:
|
||||
******************************************************************************/
|
||||
|
||||
#ifdef LV_LVGL_H_INCLUDE_SIMPLE
|
||||
#include "lvgl.h"
|
||||
#else
|
||||
#include "lvgl/lvgl.h"
|
||||
#endif
|
||||
|
||||
#ifndef LV_FONT_SYS_48
|
||||
#define LV_FONT_SYS_48 1
|
||||
#endif
|
||||
|
||||
#if LV_FONT_SYS_48
|
||||
|
||||
/*-----------------
|
||||
* BITMAPS
|
||||
*----------------*/
|
||||
|
||||
/*Store the image of the glyphs*/
|
||||
static LV_ATTRIBUTE_LARGE_CONST const uint8_t glyph_bitmap[] = {
|
||||
/* U+E902 "" */
|
||||
0x0, 0x1, 0xff, 0x80, 0x0, 0x0, 0x1, 0xff,
|
||||
0x80, 0x0, 0x0, 0x1, 0xff, 0x80, 0x0, 0x0,
|
||||
0x1, 0xff, 0x80, 0x0, 0x0, 0x1, 0xff, 0x80,
|
||||
0x0, 0x0, 0x3, 0xff, 0xc0, 0x0, 0x6, 0x7,
|
||||
0xff, 0xe0, 0x60, 0xf, 0x8f, 0xff, 0xf1, 0xf0,
|
||||
0xf, 0xff, 0xff, 0xff, 0x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||||
0x1f, 0xf0, 0xff, 0xff, 0xff, 0xf, 0xf0, 0xff,
|
||||
0xff, 0xff, 0xf, 0xf0, 0xff, 0xff, 0xff, 0xf,
|
||||
0x0, 0xff, 0xff, 0xff, 0x0, 0x0, 0xff, 0xff,
|
||||
0xff, 0x0, 0x0, 0xff, 0xff, 0xff, 0x0, 0x0,
|
||||
0xff, 0xff, 0xff, 0x0, 0x0, 0xff, 0xff, 0xff,
|
||||
0x0, 0x0, 0xff, 0xff, 0xff, 0x0, 0x0, 0xff,
|
||||
0xff, 0xff, 0x0, 0x0, 0xff, 0xff, 0xff, 0x0,
|
||||
0x0, 0xff, 0xff, 0xff, 0x0, 0x0, 0xff, 0xff,
|
||||
0xff, 0x0, 0x0, 0xff, 0xff, 0xff, 0x0, 0x1,
|
||||
0xff, 0xff, 0xff, 0x80, 0x3, 0xff, 0xff, 0xff,
|
||||
0xc0, 0x7, 0xff, 0xff, 0xff, 0xe0, 0xf, 0xff,
|
||||
0xff, 0xff, 0xf0, 0xf, 0xff, 0xff, 0xff, 0xf0,
|
||||
0xf, 0xff, 0xff, 0xff, 0xf0, 0x0, 0x0, 0x0,
|
||||
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
||||
0x0, 0xff, 0x0, 0x0, 0x0, 0x0, 0xff, 0x0,
|
||||
0x0, 0x0, 0x0, 0x7e, 0x0, 0x0, 0x0, 0x0,
|
||||
0x3c, 0x0, 0x0
|
||||
};
|
||||
|
||||
|
||||
/*---------------------
|
||||
* GLYPH DESCRIPTION
|
||||
*--------------------*/
|
||||
|
||||
static const lv_font_fmt_txt_glyph_dsc_t glyph_dsc[] = {
|
||||
{.bitmap_index = 0, .adv_w = 0, .box_w = 0, .box_h = 0, .ofs_x = 0, .ofs_y = 0} /* id = 0 reserved */,
|
||||
{.bitmap_index = 0, .adv_w = 768, .box_w = 40, .box_h = 40, .ofs_x = 4, .ofs_y = 0},
|
||||
{.bitmap_index = 200, .adv_w = 768, .box_w = 46, .box_h = 46, .ofs_x = 1, .ofs_y = -3},
|
||||
{.bitmap_index = 465, .adv_w = 768, .box_w = 46, .box_h = 46, .ofs_x = 1, .ofs_y = -3},
|
||||
{.bitmap_index = 730, .adv_w = 768, .box_w = 46, .box_h = 46, .ofs_x = 1, .ofs_y = -3},
|
||||
{.bitmap_index = 995, .adv_w = 768, .box_w = 34, .box_h = 40, .ofs_x = 7, .ofs_y = 0},
|
||||
{.bitmap_index = 1165, .adv_w = 768, .box_w = 34, .box_h = 39, .ofs_x = 8, .ofs_y = 0},
|
||||
{.bitmap_index = 1331, .adv_w = 768, .box_w = 40, .box_h = 39, .ofs_x = 4, .ofs_y = 0}
|
||||
};
|
||||
|
||||
/*---------------------
|
||||
* CHARACTER MAPPING
|
||||
*--------------------*/
|
||||
|
||||
static const uint8_t glyph_id_ofs_list_0[] = {
|
||||
0, 0, 1, 2, 3, 4, 0, 0,
|
||||
0, 5, 6
|
||||
};
|
||||
|
||||
/*Collect the unicode lists and glyph_id offsets*/
|
||||
static const lv_font_fmt_txt_cmap_t cmaps[] =
|
||||
{
|
||||
{
|
||||
.range_start = 59650, .range_length = 11, .glyph_id_start = 1,
|
||||
.unicode_list = NULL, .glyph_id_ofs_list = glyph_id_ofs_list_0, .list_length = 11, .type = LV_FONT_FMT_TXT_CMAP_FORMAT0_FULL
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
|
||||
/*--------------------
|
||||
* ALL CUSTOM DATA
|
||||
*--------------------*/
|
||||
|
||||
#if LV_VERSION_CHECK(8, 0, 0)
|
||||
/*Store all the custom data of the font*/
|
||||
static lv_font_fmt_txt_glyph_cache_t cache;
|
||||
static const lv_font_fmt_txt_dsc_t font_dsc = {
|
||||
#else
|
||||
static lv_font_fmt_txt_dsc_t font_dsc = {
|
||||
#endif
|
||||
.glyph_bitmap = glyph_bitmap,
|
||||
.glyph_dsc = glyph_dsc,
|
||||
.cmaps = cmaps,
|
||||
.kern_dsc = NULL,
|
||||
.kern_scale = 0,
|
||||
.cmap_num = 1,
|
||||
.bpp = 1,
|
||||
.kern_classes = 0,
|
||||
.bitmap_format = 0,
|
||||
#if LV_VERSION_CHECK(8, 0, 0)
|
||||
.cache = &cache
|
||||
#endif
|
||||
};
|
||||
|
||||
|
||||
/*-----------------
|
||||
* PUBLIC FONT
|
||||
*----------------*/
|
||||
|
||||
/*Initialize a public general font descriptor*/
|
||||
#if LV_VERSION_CHECK(8, 0, 0)
|
||||
const lv_font_t lv_font_sys_48 = {
|
||||
#else
|
||||
lv_font_t lv_font_sys_48 = {
|
||||
#endif
|
||||
.get_glyph_dsc = lv_font_get_glyph_dsc_fmt_txt, /*Function pointer to get glyph's data*/
|
||||
.get_glyph_bitmap = lv_font_get_bitmap_fmt_txt, /*Function pointer to get glyph's bitmap*/
|
||||
.line_height = 46, /*The maximum line height required by the font*/
|
||||
.base_line = 3, /*Baseline measured from the bottom of the line*/
|
||||
#if !(LVGL_VERSION_MAJOR == 6 && LVGL_VERSION_MINOR == 0)
|
||||
.subpx = LV_FONT_SUBPX_NONE,
|
||||
#endif
|
||||
#if LV_VERSION_CHECK(7, 4, 0) || LVGL_VERSION_MAJOR >= 8
|
||||
.underline_position = 0,
|
||||
.underline_thickness = 0,
|
||||
#endif
|
||||
.dsc = &font_dsc /*The custom font data. Will be accessed by `get_glyph_bitmap/dsc` */
|
||||
};
|
||||
|
||||
|
||||
|
||||
#endif /*#if LV_FONT_SYS_48*/
|
||||
|
BIN
src/displayapp/icons/battery/battery.png
Normal file
After Width: | Height: | Size: 193 B |
52
src/displayapp/icons/battery/batteryicon.c
Normal file
@ -0,0 +1,52 @@
|
||||
#if defined(LV_LVGL_H_INCLUDE_SIMPLE)
|
||||
#include "lvgl.h"
|
||||
#else
|
||||
#include "lvgl/lvgl.h"
|
||||
#endif
|
||||
|
||||
|
||||
#ifndef LV_ATTRIBUTE_MEM_ALIGN
|
||||
#define LV_ATTRIBUTE_MEM_ALIGN
|
||||
#endif
|
||||
|
||||
#ifndef LV_ATTRIBUTE_IMG_BATTERYICON
|
||||
#define LV_ATTRIBUTE_IMG_BATTERYICON
|
||||
#endif
|
||||
|
||||
const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_LARGE_CONST LV_ATTRIBUTE_IMG_BATTERYICON uint8_t batteryicon_map[] = {
|
||||
0xff, 0xff, 0xff, 0xff, /*Color of index 0*/
|
||||
0x6a, 0xfc, 0x6c, 0xff, /*Color of index 1*/
|
||||
|
||||
0xe0, 0x70,
|
||||
0xe0, 0x70,
|
||||
0x00, 0x00,
|
||||
0x00, 0x00,
|
||||
0x3f, 0xc0,
|
||||
0x3f, 0xc0,
|
||||
0x3f, 0xc0,
|
||||
0x3f, 0xc0,
|
||||
0x3f, 0xc0,
|
||||
0x3f, 0xc0,
|
||||
0x3f, 0xc0,
|
||||
0x3f, 0xc0,
|
||||
0x3f, 0xc0,
|
||||
0x3f, 0xc0,
|
||||
0x3f, 0xc0,
|
||||
0x3f, 0xc0,
|
||||
0x3f, 0xc0,
|
||||
0x3f, 0xc0,
|
||||
0x00, 0x00,
|
||||
0x00, 0x00,
|
||||
};
|
||||
|
||||
const lv_img_dsc_t batteryicon = {
|
||||
{
|
||||
LV_IMG_CF_INDEXED_1BIT,
|
||||
0,
|
||||
0,
|
||||
12,
|
||||
20,
|
||||
},
|
||||
48,
|
||||
batteryicon_map,
|
||||
};
|
@ -1,56 +0,0 @@
|
||||
#include "lvgl/lvgl.h"
|
||||
|
||||
#ifndef LV_ATTRIBUTE_MEM_ALIGN
|
||||
#define LV_ATTRIBUTE_MEM_ALIGN
|
||||
#endif
|
||||
|
||||
#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERY_005
|
||||
#define LV_ATTRIBUTE_IMG_CK_OS_BATTERY_005
|
||||
#endif
|
||||
|
||||
const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERY_005 uint8_t ck_os_battery_005_map[] = {
|
||||
0x04, 0x02, 0xcc, 0xff, /*Color of index 0*/
|
||||
0x6c, 0xfe, 0x6c, 0xff, /*Color of index 1*/
|
||||
|
||||
0xfc, 0x00, 0x3f,
|
||||
0xf8, 0x00, 0x1f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0x00, 0xff, 0x00,
|
||||
0x00, 0xff, 0x00,
|
||||
0x00, 0xff, 0x00,
|
||||
0x00, 0xff, 0x00,
|
||||
0x0f, 0xff, 0xf0,
|
||||
0x0f, 0xff, 0xf0,
|
||||
0x0f, 0xff, 0xf0,
|
||||
0x0f, 0xff, 0xf0,
|
||||
0x0f, 0xff, 0xf0,
|
||||
0x0f, 0xff, 0xf0,
|
||||
0x0f, 0xff, 0xf0,
|
||||
0x0f, 0xff, 0xf0,
|
||||
0x0f, 0xff, 0xf0,
|
||||
0x0f, 0xff, 0xf0,
|
||||
0x0f, 0xff, 0xf0,
|
||||
0x0f, 0xff, 0xf0,
|
||||
0x0f, 0xff, 0xf0,
|
||||
0x0f, 0xff, 0xf0,
|
||||
0x0f, 0xff, 0xf0,
|
||||
0x0f, 0xff, 0xf0,
|
||||
0x0f, 0xff, 0xf0,
|
||||
0x0f, 0xff, 0xf0,
|
||||
0x0f, 0xff, 0xf0,
|
||||
0x0f, 0xff, 0xf0,
|
||||
0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00,
|
||||
};
|
||||
|
||||
const lv_img_dsc_t ck_os_battery_005 = {
|
||||
.header.always_zero = 0,
|
||||
.header.w = 24,
|
||||
.header.h = 32,
|
||||
.data_size = 104,
|
||||
.header.cf = LV_IMG_CF_INDEXED_1BIT,
|
||||
.data = ck_os_battery_005_map,
|
||||
};
|
Before Width: | Height: | Size: 1.5 KiB |
@ -1,58 +0,0 @@
|
||||
#include "lvgl/lvgl.h"
|
||||
|
||||
#ifndef LV_ATTRIBUTE_MEM_ALIGN
|
||||
#define LV_ATTRIBUTE_MEM_ALIGN
|
||||
#endif
|
||||
|
||||
#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERY_010
|
||||
#define LV_ATTRIBUTE_IMG_CK_OS_BATTERY_010
|
||||
#endif
|
||||
|
||||
const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERY_010 uint8_t ck_os_battery_010_map[] = {
|
||||
0x04, 0x02, 0xcc, 0xff, /*Color of index 0*/
|
||||
0x6c, 0xfe, 0x6c, 0xff, /*Color of index 1*/
|
||||
0x04, 0x7a, 0xf4, 0xff, /*Color of index 2*/
|
||||
0xe4, 0xe6, 0xe4, 0xff, /*Color of index 3*/
|
||||
|
||||
0x55, 0x5f, 0xff, 0xff, 0xf5, 0x55, 0x55,
|
||||
0x55, 0x7f, 0xff, 0xff, 0xfd, 0x55, 0x55,
|
||||
0x55, 0xff, 0xff, 0xff, 0xff, 0x55, 0x55,
|
||||
0x55, 0xff, 0xff, 0xff, 0xff, 0x55, 0x55,
|
||||
0xff, 0xff, 0x55, 0x55, 0xff, 0xff, 0x55,
|
||||
0xff, 0xff, 0x55, 0x55, 0xff, 0xff, 0x55,
|
||||
0xff, 0xff, 0x55, 0x55, 0xff, 0xff, 0x55,
|
||||
0xff, 0xff, 0x55, 0x55, 0xff, 0xff, 0x55,
|
||||
0xff, 0x55, 0x55, 0x55, 0x55, 0xff, 0x55,
|
||||
0xff, 0x55, 0x55, 0x55, 0x55, 0xff, 0x55,
|
||||
0xff, 0x55, 0x55, 0x55, 0x55, 0xff, 0x55,
|
||||
0xff, 0x55, 0x55, 0x55, 0x55, 0xff, 0x55,
|
||||
0xff, 0x55, 0x55, 0x55, 0x55, 0xff, 0x55,
|
||||
0xff, 0x55, 0x55, 0x55, 0x55, 0xff, 0x55,
|
||||
0xff, 0x55, 0x55, 0x55, 0x55, 0x55, 0x55,
|
||||
0xff, 0x55, 0x55, 0x55, 0x55, 0x55, 0x55,
|
||||
0xff, 0x55, 0x55, 0x6a, 0xaa, 0xaa, 0xa9,
|
||||
0xff, 0x55, 0x55, 0xaa, 0xaa, 0xaa, 0xaa,
|
||||
0xff, 0x55, 0x55, 0xaa, 0xa5, 0x5a, 0xaa,
|
||||
0xff, 0x55, 0x55, 0xaa, 0xa5, 0x5a, 0xaa,
|
||||
0xff, 0x55, 0x55, 0xaa, 0xa5, 0x5a, 0xaa,
|
||||
0xff, 0x55, 0x55, 0xaa, 0xa5, 0x5a, 0xaa,
|
||||
0xff, 0x55, 0x55, 0xaa, 0xa5, 0x5a, 0xaa,
|
||||
0xff, 0x55, 0x55, 0xaa, 0xa5, 0x5a, 0xaa,
|
||||
0xff, 0x50, 0x05, 0xaa, 0xaa, 0xaa, 0xaa,
|
||||
0xff, 0x50, 0x05, 0xaa, 0xaa, 0xaa, 0xaa,
|
||||
0xff, 0x55, 0x55, 0xaa, 0xa5, 0x5a, 0xaa,
|
||||
0xff, 0x55, 0x55, 0xaa, 0xa5, 0x5a, 0xaa,
|
||||
0xff, 0xff, 0xf5, 0xaa, 0xa5, 0x5a, 0xaa,
|
||||
0xff, 0xff, 0xf5, 0xaa, 0xa5, 0x5a, 0xaa,
|
||||
0xff, 0xff, 0xf5, 0xaa, 0xaa, 0xaa, 0xaa,
|
||||
0xff, 0xff, 0xf5, 0x6a, 0xaa, 0xaa, 0xa9,
|
||||
};
|
||||
|
||||
const lv_img_dsc_t ck_os_battery_010 = {
|
||||
.header.always_zero = 0,
|
||||
.header.w = 28,
|
||||
.header.h = 32,
|
||||
.data_size = 240,
|
||||
.header.cf = LV_IMG_CF_INDEXED_2BIT,
|
||||
.data = ck_os_battery_010_map,
|
||||
};
|
Before Width: | Height: | Size: 1.8 KiB |
@ -1,58 +0,0 @@
|
||||
#include "lvgl/lvgl.h"
|
||||
|
||||
#ifndef LV_ATTRIBUTE_MEM_ALIGN
|
||||
#define LV_ATTRIBUTE_MEM_ALIGN
|
||||
#endif
|
||||
|
||||
#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERY_020
|
||||
#define LV_ATTRIBUTE_IMG_CK_OS_BATTERY_020
|
||||
#endif
|
||||
|
||||
const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERY_020 uint8_t ck_os_battery_020_map[] = {
|
||||
0x04, 0x02, 0xcc, 0xff, /*Color of index 0*/
|
||||
0x6c, 0xfe, 0x6c, 0xff, /*Color of index 1*/
|
||||
0xe4, 0xe6, 0xe4, 0xff, /*Color of index 2*/
|
||||
0xff, 0xff, 0xff, 0xff, /*Color of index 3*/
|
||||
|
||||
0x55, 0x5a, 0xaa, 0xaa, 0xa5, 0x55,
|
||||
0x55, 0x6a, 0xaa, 0xaa, 0xa9, 0x55,
|
||||
0x55, 0xaa, 0xaa, 0xaa, 0xaa, 0x55,
|
||||
0x55, 0xaa, 0xaa, 0xaa, 0xaa, 0x55,
|
||||
0xaa, 0xaa, 0x55, 0x55, 0xaa, 0xaa,
|
||||
0xaa, 0xaa, 0x55, 0x55, 0xaa, 0xaa,
|
||||
0xaa, 0xaa, 0x55, 0x55, 0xaa, 0xaa,
|
||||
0xaa, 0xaa, 0x55, 0x55, 0xaa, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x50, 0x00, 0x00, 0x05, 0xaa,
|
||||
0xaa, 0x50, 0x00, 0x00, 0x05, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0xaa, 0xaa, 0xaa, 0xaa, 0xaa,
|
||||
0xaa, 0xaa, 0xaa, 0xaa, 0xaa, 0xaa,
|
||||
0xaa, 0xaa, 0xaa, 0xaa, 0xaa, 0xaa,
|
||||
0xaa, 0xaa, 0xaa, 0xaa, 0xaa, 0xaa,
|
||||
};
|
||||
|
||||
const lv_img_dsc_t ck_os_battery_020 = {
|
||||
.header.always_zero = 0,
|
||||
.header.w = 24,
|
||||
.header.h = 32,
|
||||
.data_size = 208,
|
||||
.header.cf = LV_IMG_CF_INDEXED_2BIT,
|
||||
.data = ck_os_battery_020_map,
|
||||
};
|
Before Width: | Height: | Size: 1.5 KiB |
@ -1,58 +0,0 @@
|
||||
#include "lvgl/lvgl.h"
|
||||
|
||||
#ifndef LV_ATTRIBUTE_MEM_ALIGN
|
||||
#define LV_ATTRIBUTE_MEM_ALIGN
|
||||
#endif
|
||||
|
||||
#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERY_030
|
||||
#define LV_ATTRIBUTE_IMG_CK_OS_BATTERY_030
|
||||
#endif
|
||||
|
||||
const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERY_030 uint8_t ck_os_battery_030_map[] = {
|
||||
0x04, 0x7a, 0xf4, 0xff, /*Color of index 0*/
|
||||
0x6c, 0xfe, 0x6c, 0xff, /*Color of index 1*/
|
||||
0xe4, 0xe6, 0xe4, 0xff, /*Color of index 2*/
|
||||
0xff, 0xff, 0xff, 0xff, /*Color of index 3*/
|
||||
|
||||
0x55, 0x5a, 0xaa, 0xaa, 0xa5, 0x55,
|
||||
0x55, 0x6a, 0xaa, 0xaa, 0xa9, 0x55,
|
||||
0x55, 0xaa, 0xaa, 0xaa, 0xaa, 0x55,
|
||||
0x55, 0xaa, 0xaa, 0xaa, 0xaa, 0x55,
|
||||
0xaa, 0xaa, 0x55, 0x55, 0xaa, 0xaa,
|
||||
0xaa, 0xaa, 0x55, 0x55, 0xaa, 0xaa,
|
||||
0xaa, 0xaa, 0x55, 0x55, 0xaa, 0xaa,
|
||||
0xaa, 0xaa, 0x55, 0x55, 0xaa, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x50, 0x00, 0x00, 0x05, 0xaa,
|
||||
0xaa, 0x50, 0x00, 0x00, 0x05, 0xaa,
|
||||
0xaa, 0x50, 0x00, 0x00, 0x05, 0xaa,
|
||||
0xaa, 0x50, 0x00, 0x00, 0x05, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa,
|
||||
0xaa, 0xaa, 0xaa, 0xaa, 0xaa, 0xaa,
|
||||
0xaa, 0xaa, 0xaa, 0xaa, 0xaa, 0xaa,
|
||||
0xaa, 0xaa, 0xaa, 0xaa, 0xaa, 0xaa,
|
||||
0xaa, 0xaa, 0xaa, 0xaa, 0xaa, 0xaa,
|
||||
};
|
||||
|
||||
const lv_img_dsc_t ck_os_battery_030 = {
|
||||
.header.always_zero = 0,
|
||||
.header.w = 24,
|
||||
.header.h = 32,
|
||||
.data_size = 208,
|
||||
.header.cf = LV_IMG_CF_INDEXED_2BIT,
|
||||
.data = ck_os_battery_030_map,
|
||||
};
|
Before Width: | Height: | Size: 1.5 KiB |
@ -1,56 +0,0 @@
|
||||
#include "lvgl/lvgl.h"
|
||||
|
||||
#ifndef LV_ATTRIBUTE_MEM_ALIGN
|
||||
#define LV_ATTRIBUTE_MEM_ALIGN
|
||||
#endif
|
||||
|
||||
#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERY_040
|
||||
#define LV_ATTRIBUTE_IMG_CK_OS_BATTERY_040
|
||||
#endif
|
||||
|
||||
const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERY_040 uint8_t ck_os_battery_040_map[] = {
|
||||
0x6c, 0xfe, 0x6c, 0xff, /*Color of index 0*/
|
||||
0xe4, 0xe6, 0xe4, 0xff, /*Color of index 1*/
|
||||
|
||||
0x03, 0xff, 0xc0,
|
||||
0x07, 0xff, 0xe0,
|
||||
0x0f, 0xff, 0xf0,
|
||||
0x0f, 0xff, 0xf0,
|
||||
0xff, 0x00, 0xff,
|
||||
0xff, 0x00, 0xff,
|
||||
0xff, 0x00, 0xff,
|
||||
0xff, 0x00, 0xff,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff,
|
||||
};
|
||||
|
||||
const lv_img_dsc_t ck_os_battery_040 = {
|
||||
.header.always_zero = 0,
|
||||
.header.w = 24,
|
||||
.header.h = 32,
|
||||
.data_size = 104,
|
||||
.header.cf = LV_IMG_CF_INDEXED_1BIT,
|
||||
.data = ck_os_battery_040_map,
|
||||
};
|
Before Width: | Height: | Size: 1.5 KiB |
@ -1,56 +0,0 @@
|
||||
#include "lvgl/lvgl.h"
|
||||
|
||||
#ifndef LV_ATTRIBUTE_MEM_ALIGN
|
||||
#define LV_ATTRIBUTE_MEM_ALIGN
|
||||
#endif
|
||||
|
||||
#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERY_050
|
||||
#define LV_ATTRIBUTE_IMG_CK_OS_BATTERY_050
|
||||
#endif
|
||||
|
||||
const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERY_050 uint8_t ck_os_battery_050_map[] = {
|
||||
0x6c, 0xfe, 0x6c, 0xff, /*Color of index 0*/
|
||||
0xe4, 0xe6, 0xe4, 0xff, /*Color of index 1*/
|
||||
|
||||
0x03, 0xff, 0xc0,
|
||||
0x07, 0xff, 0xe0,
|
||||
0x0f, 0xff, 0xf0,
|
||||
0x0f, 0xff, 0xf0,
|
||||
0xff, 0x00, 0xff,
|
||||
0xff, 0x00, 0xff,
|
||||
0xff, 0x00, 0xff,
|
||||
0xff, 0x00, 0xff,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff,
|
||||
};
|
||||
|
||||
const lv_img_dsc_t ck_os_battery_050 = {
|
||||
.header.always_zero = 0,
|
||||
.header.w = 24,
|
||||
.header.h = 32,
|
||||
.data_size = 104,
|
||||
.header.cf = LV_IMG_CF_INDEXED_1BIT,
|
||||
.data = ck_os_battery_050_map,
|
||||
};
|
Before Width: | Height: | Size: 1.5 KiB |
@ -1,56 +0,0 @@
|
||||
#include "lvgl/lvgl.h"
|
||||
|
||||
#ifndef LV_ATTRIBUTE_MEM_ALIGN
|
||||
#define LV_ATTRIBUTE_MEM_ALIGN
|
||||
#endif
|
||||
|
||||
#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERY_060
|
||||
#define LV_ATTRIBUTE_IMG_CK_OS_BATTERY_060
|
||||
#endif
|
||||
|
||||
const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERY_060 uint8_t ck_os_battery_060_map[] = {
|
||||
0x6c, 0xfe, 0x6c, 0xff, /*Color of index 0*/
|
||||
0xe4, 0xe6, 0xe4, 0xff, /*Color of index 1*/
|
||||
|
||||
0x03, 0xff, 0xc0,
|
||||
0x07, 0xff, 0xe0,
|
||||
0x0f, 0xff, 0xf0,
|
||||
0x0f, 0xff, 0xf0,
|
||||
0xff, 0x00, 0xff,
|
||||
0xff, 0x00, 0xff,
|
||||
0xff, 0x00, 0xff,
|
||||
0xff, 0x00, 0xff,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff,
|
||||
};
|
||||
|
||||
const lv_img_dsc_t ck_os_battery_060 = {
|
||||
.header.always_zero = 0,
|
||||
.header.w = 24,
|
||||
.header.h = 32,
|
||||
.data_size = 104,
|
||||
.header.cf = LV_IMG_CF_INDEXED_1BIT,
|
||||
.data = ck_os_battery_060_map,
|
||||
};
|
Before Width: | Height: | Size: 1.5 KiB |
@ -1,56 +0,0 @@
|
||||
#include "lvgl/lvgl.h"
|
||||
|
||||
#ifndef LV_ATTRIBUTE_MEM_ALIGN
|
||||
#define LV_ATTRIBUTE_MEM_ALIGN
|
||||
#endif
|
||||
|
||||
#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERY_070
|
||||
#define LV_ATTRIBUTE_IMG_CK_OS_BATTERY_070
|
||||
#endif
|
||||
|
||||
const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERY_070 uint8_t ck_os_battery_070_map[] = {
|
||||
0x6c, 0xfe, 0x6c, 0xff, /*Color of index 0*/
|
||||
0xe4, 0xe6, 0xe4, 0xff, /*Color of index 1*/
|
||||
|
||||
0x03, 0xff, 0xc0,
|
||||
0x07, 0xff, 0xe0,
|
||||
0x0f, 0xff, 0xf0,
|
||||
0x0f, 0xff, 0xf0,
|
||||
0xff, 0x00, 0xff,
|
||||
0xff, 0x00, 0xff,
|
||||
0xff, 0x00, 0xff,
|
||||
0xff, 0x00, 0xff,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff,
|
||||
};
|
||||
|
||||
const lv_img_dsc_t ck_os_battery_070 = {
|
||||
.header.always_zero = 0,
|
||||
.header.w = 24,
|
||||
.header.h = 32,
|
||||
.data_size = 104,
|
||||
.header.cf = LV_IMG_CF_INDEXED_1BIT,
|
||||
.data = ck_os_battery_070_map,
|
||||
};
|
Before Width: | Height: | Size: 1.5 KiB |
@ -1,56 +0,0 @@
|
||||
#include "lvgl/lvgl.h"
|
||||
|
||||
#ifndef LV_ATTRIBUTE_MEM_ALIGN
|
||||
#define LV_ATTRIBUTE_MEM_ALIGN
|
||||
#endif
|
||||
|
||||
#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERY_080
|
||||
#define LV_ATTRIBUTE_IMG_CK_OS_BATTERY_080
|
||||
#endif
|
||||
|
||||
const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERY_080 uint8_t ck_os_battery_080_map[] = {
|
||||
0x6c, 0xfe, 0x6c, 0xff, /*Color of index 0*/
|
||||
0xe4, 0xe6, 0xe4, 0xff, /*Color of index 1*/
|
||||
|
||||
0x03, 0xff, 0xc0,
|
||||
0x07, 0xff, 0xe0,
|
||||
0x0f, 0xff, 0xf0,
|
||||
0x0f, 0xff, 0xf0,
|
||||
0xff, 0x00, 0xff,
|
||||
0xff, 0x00, 0xff,
|
||||
0xff, 0x00, 0xff,
|
||||
0xff, 0x00, 0xff,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf3, 0xff, 0xcf,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xf0, 0x00, 0x0f,
|
||||
0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff,
|
||||
};
|
||||
|
||||
const lv_img_dsc_t ck_os_battery_080 = {
|
||||
.header.always_zero = 0,
|
||||
.header.w = 24,
|
||||
.header.h = 32,
|
||||
.data_size = 104,
|
||||
.header.cf = LV_IMG_CF_INDEXED_1BIT,
|
||||
.data = ck_os_battery_080_map,
|
||||
};
|
Before Width: | Height: | Size: 1.5 KiB |