Skip to content

Commit cc489d2

Browse files
authored
Merge branch 'main' into music_redesign_2
2 parents d613c1c + 6c119eb commit cc489d2

15 files changed

Lines changed: 117 additions & 44 deletions

.vscode/c_cpp_properties.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"env": {
33
// TODO: This is a duplication of the configuration set in /docker/build.sh!
44
"TOOLS_DIR": "/opt",
5-
"GCC_ARM_PATH": "gcc-arm-none-eabi-10.3-2021.10"
5+
"GCC_ARM_PATH": "arm-gnu-toolchain-15.3.rel1-x86_64-arm-none-eabi"
66
},
77
"configurations": [
88
{

.vscode/launch.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@
5353
"continue"
5454
],
5555
// Only use armToolchainPath if your arm-none-eabi-gdb is not in your path (some GCC packages does not contain arm-none-eabi-gdb)
56-
"armToolchainPath": "${workspaceRoot}/../gcc-arm-none-eabi-10.3-2021.10/bin",
56+
"armToolchainPath": "${workspaceRoot}/../arm-gnu-toolchain-15.3.rel1-x86_64-arm-none-eabi/bin",
5757
"svdFile": "${workspaceRoot}/nrf52.svd",
5858
"configFiles": [
5959
"interface/stlink.cfg",
@@ -68,7 +68,7 @@
6868
"request": "launch",
6969
"servertype": "external",
7070
// FIXME: This is hardcoded. I have no idea how to use the values set in build.sh here
71-
"gdbPath": "/opt/gcc-arm-none-eabi-10.3-2021.10/bin/arm-none-eabi-gdb",
71+
"gdbPath": "/opt/arm-gnu-toolchain-15.3.rel1-x86_64-arm-none-eabi/bin/arm-none-eabi-gdb",
7272
// Connect to an already running OpenOCD instance
7373
"gdbTarget": "host.docker.internal:3333",
7474
"svdFile": "${workspaceRoot}/nrf52.svd",

AI_USAGE.md

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
<!--
2+
SPDX-FileCopyrightText: 2025 Gusted, jeanbaptisteC, gedankenstuecke, mark9064
3+
4+
SPDX-License-Identifier: CC-BY-4.0
5+
-->
6+
7+
# AI usage in the InfiniTime project
8+
9+
This document describes if and how _artificial intelligence_ can be used in the InfiniTime project by contributors, including agreements for how to use it in a transparent and responsible way. This agreement is applicable to all projects hosted under the [InfiniTime organisation](https://github.com/InfiniTimeOrg).
10+
11+
All contributors are expected to be aware of this agreement and to apply it in their contributions. Contributions that do not honor these agreements will not be accepted and admins will close corresponding pull requests and issues.
12+
13+
## Definitions & Motivations
14+
15+
> [!NOTE]
16+
>This does not necessarily reflect the official or commonly used definitions.
17+
18+
Software and services that heavily rely on large language model technology to generate their outcomes are referred to as Artificial Intelligence (AI). Examples of products that fit this definition: GitHub Copilot, ChatGPT, Claude Sonnet, DeepSeek, Llama and Gemini.
19+
20+
There's a distinction between general and narrow AI, all the aforementioned examples fall under general AI as they were not trained to execute a specific well-defined task. Narrow AI is trained to be used for specific well-defined tasks where the problem space is known in advance.
21+
22+
Vibe coding is the practice where AI creates a code change (feature, bug fix, tests, refactor) with a human that describes what needs to be implemented.
23+
24+
AI agents are AIs that are configured to perform interactions or make changes with little to no human supervision.
25+
26+
"AI agents" and "vibe coding" typically result in the "authors" of code not having expertise in the changes they aim to contribute, thus not able to answer questions about which trade-offs were made and why. If authors were only minimally involved in how code was generated, they can't be accountable for AI's output, which is harmful to the long-term sustainability of open source projects like InfiniTime.
27+
28+
## Agreement
29+
30+
1. If content was made with the help of AI, you must convey that this is the case. This includes content that you authored but was motivated by a suggestion of AI.
31+
2. If at any point you used AI's work in your contribution you must make an effort to verify that you can submit this under the license of the repository.
32+
3. The accountability of using AI in a contribution lies with the person that makes that contribution.
33+
4. All communication, that includes: **commit messages**, **pull request messages**, **documentation**, **code comments** and **issues** (and comments on issues/pull requests), that is intended to be read by people to understand your thoughts and work must not have been generated with AI. We exclude machine translation and tooling that helps with grammar and spelling check.
34+
5. Using general AI for review is forbidden. Changes have to be approved by a human reviewer.
35+
6. It is not allowed to use AI in an autonomous-looking way to contribute in InfiniTime (i.e. solely using 'agent mode' or 'vibe coding'). To ensure the long-term maintainability and sustainability of the project, we require authors to have read **and** understand the code they submit themselves.
36+
7. Commit messages must not contain advertisements for AI services/agents. This includes Co-authored-by lines and similar statements within the message text.
37+
38+
## License
39+
40+
This agreement is a near verbatim copy of [the _AI Agreement_ that the _CoMaps_ project has passed in March 2026](https://codeberg.org/comaps/Governance/pulls/136) which is [licensed under a Creative Commons CC BY 4.0 license](https://creativecommons.org/licenses/by/4.0/legalcode).
41+
42+
That agreement was in turn adapted from the _Forgejo_ project. The InfiniTime project extends its thanks to many upstream contributors to this policy, and also releases this version under the same CC BY 4.0 license with the hope that any further adopters of this policy would consider doing the same.

CONTRIBUTING.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
# How to contribute?
22

3+
> [!WARNING]
4+
>All contributions must adhere to the [AI policy](AI_USAGE.md)
5+
36
Here are things you can do to help.
47

58
- [Report bugs or issues](https://github.com/InfiniTimeOrg/InfiniTime/issues/new/choose)

doc/buildAndProgram.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
To build this project, you'll need:
66

7-
- A cross-compiler : [ARM-GCC (10.3-2021.10)](https://developer.arm.com/downloads/-/gnu-rm)
7+
- A cross-compiler : [ARM-GCC 15.3-Rel1 (arm-none-eabi)](https://gitlab.arm.com/tooling/gnu-toolchains-for-arm/-/tree/releases/15.3.rel1)
88
- The NRF52 SDK 15.3.0 : [nRF-SDK v15.3.0](https://nsscprodmedia.blob.core.windows.net/prod/software-and-other-downloads/sdks/nrf5/binaries/nrf5sdk153059ac345.zip)
99
- The Python 3 modules `cbor`, `intelhex`, `click` and `cryptography` modules for the `mcuboot` tool (see [requirements.txt](../tools/mcuboot/requirements.txt))
1010
- To keep the system clean, you can install python modules into a python virtual environment (`venv`)
@@ -38,7 +38,7 @@ CMake configures the project according to variables you specify the command line
3838
3939
Variable | Description | Example|
4040
----------|-------------|--------|
41-
**ARM_NONE_EABI_TOOLCHAIN_PATH**|path to the toolchain directory|`-DARM_NONE_EABI_TOOLCHAIN_PATH=/home/jf/nrf52/gcc-arm-none-eabi-10.3-2021.10/`|
41+
**ARM_NONE_EABI_TOOLCHAIN_PATH**|path to the toolchain directory|`-DARM_NONE_EABI_TOOLCHAIN_PATH=/home/jf/nrf52/arm-gnu-toolchain-15.3.rel1-x86_64-arm-none-eabi/`|
4242
**NRF5_SDK_PATH**|path to the NRF52 SDK|`-DNRF5_SDK_PATH=/home/jf/nrf52/Pinetime/sdk`|
4343
**CMAKE_BUILD_TYPE (\*)**| Build type (Release or Debug). Release is applied by default if this variable is not specified.|`-DCMAKE_BUILD_TYPE=Debug`
4444
**BUILD_DFU (\*\*)**|Build DFU files while building (needs [adafruit-nrfutil](https://github.com/adafruit/Adafruit_nRF52_nrfutil)).|`-DBUILD_DFU=1`

doc/buildWithVScode.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ To support as many setups as possible the VS Code configuration files expect the
88

99
Variable | Description | Example
1010
----------|-------------|--------
11-
**ARM_NONE_EABI_TOOLCHAIN_PATH**|path to the toolchain directory|`export ARM_NONE_EABI_TOOLCHAIN_PATH=/opt/gcc-arm-none-eabi-10.3-2021.10`
11+
**ARM_NONE_EABI_TOOLCHAIN_PATH**|path to the toolchain directory|`export ARM_NONE_EABI_TOOLCHAIN_PATH=/opt/arm-gnu-toolchain-15.3.rel1-x86_64-arm-none-eabi`
1212
**NRF5_SDK_PATH**|path to the NRF52 SDK|`export NRF5_SDK_PATH=/opt/nRF5_SDK_15.3.0_59ac345`
1313

1414
## VS Code Extensions

docker/build.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ export NPM_DIR="$BUILD_DIR/npm"
1616
export npm_config_cache="${NPM_DIR}"
1717

1818
export BUILD_TYPE=${BUILD_TYPE:=Release}
19-
export GCC_ARM_VER=${GCC_ARM_VER:="10.3-2021.10"}
19+
export GCC_ARM_VER=${GCC_ARM_VER:="15.3.rel1"}
2020
export NRF_SDK_VER=${NRF_SDK_VER:="nRF5_SDK_15.3.0_59ac345"}
2121
# convert to lower case and remove _ and . character
2222
# the download URL uses the SLUG, but the extracted folder is named like the original value
@@ -26,7 +26,7 @@ export NRF_SDK_VER_SLUG=${NRF_SDK_VER_SLUG//[_.]/}
2626
MACHINE="$(uname -m)"
2727
[ "$MACHINE" = "arm64" ] && MACHINE="aarch64"
2828

29-
export GCC_ARM_PATH="gcc-arm-none-eabi-$GCC_ARM_VER"
29+
export GCC_ARM_PATH="arm-gnu-toolchain-$GCC_ARM_VER-$MACHINE-arm-none-eabi"
3030

3131
main() {
3232
local target="$1"
@@ -50,7 +50,7 @@ main() {
5050
}
5151

5252
GetGcc() {
53-
wget -q https://developer.arm.com/-/media/Files/downloads/gnu-rm/$GCC_ARM_VER/$GCC_ARM_PATH-$MACHINE-linux.tar.bz2 -O - | tar -xj -C $TOOLS_DIR/
53+
wget -q https://gitlab.arm.com/api/v4/projects/tooling%2Fgnu-toolchains-for-arm/packages/generic/gnu-toolchain/$GCC_ARM_VER/$GCC_ARM_PATH.tar.xz -O - | tar -xJ -C $TOOLS_DIR/
5454
if [ ! -d "$TOOLS_DIR/$GCC_ARM_PATH" ]; then
5555
echo "missing GCC path: $TOOLS_DIR/$GCC_ARM_PATH"
5656
return 1

src/CMakeLists.txt

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -930,7 +930,7 @@ target_compile_options(${EXECUTABLE_NAME} PUBLIC
930930

931931
set_target_properties(${EXECUTABLE_NAME} PROPERTIES
932932
SUFFIX ".out"
933-
LINK_FLAGS "-mthumb -mabi=aapcs -L ${NRF5_SDK_PATH}/modules/nrfx/mdk -T${NRF5_LINKER_SCRIPT} --specs=nosys.specs -mcpu=cortex-m4 -mfloat-abi=hard -mfpu=fpv4-sp-d16 -Wl,--gc-sections -Wl,--print-memory-usage --specs=nano.specs -Wl,-Map=${EXECUTABLE_FILE_NAME}.map"
933+
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 -Wl,-Map=${EXECUTABLE_FILE_NAME}.map"
934934
)
935935

936936
add_custom_command(TARGET ${EXECUTABLE_NAME}
@@ -965,7 +965,7 @@ target_compile_options(${EXECUTABLE_MCUBOOT_NAME} PUBLIC
965965

966966
set_target_properties(${EXECUTABLE_MCUBOOT_NAME} PROPERTIES
967967
SUFFIX ".out"
968-
LINK_FLAGS "-mthumb -mabi=aapcs -L ${NRF5_SDK_PATH}/modules/nrfx/mdk -T${NRF5_LINKER_SCRIPT_MCUBOOT} --specs=nosys.specs -mcpu=cortex-m4 -mfloat-abi=hard -mfpu=fpv4-sp-d16 -Wl,--gc-sections -Wl,--print-memory-usage --specs=nano.specs -Wl,-Map=${EXECUTABLE_MCUBOOT_FILE_NAME}.map"
968+
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 -Wl,-Map=${EXECUTABLE_MCUBOOT_FILE_NAME}.map"
969969
)
970970

971971
add_custom_command(TARGET ${EXECUTABLE_MCUBOOT_NAME}
@@ -1008,7 +1008,7 @@ target_compile_options(${EXECUTABLE_RECOVERY_NAME} PUBLIC
10081008

10091009
set_target_properties(${EXECUTABLE_RECOVERY_NAME} PROPERTIES
10101010
SUFFIX ".out"
1011-
LINK_FLAGS "-mthumb -mabi=aapcs -L ${NRF5_SDK_PATH}/modules/nrfx/mdk -T${NRF5_LINKER_SCRIPT} --specs=nosys.specs -mcpu=cortex-m4 -mfloat-abi=hard -mfpu=fpv4-sp-d16 -Wl,--gc-sections -Wl,--print-memory-usage --specs=nano.specs -Wl,-Map=${EXECUTABLE_RECOVERY_FILE_NAME}.map"
1011+
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 -Wl,-Map=${EXECUTABLE_RECOVERY_FILE_NAME}.map"
10121012
)
10131013

10141014
add_custom_command(TARGET ${EXECUTABLE_RECOVERY_NAME}
@@ -1040,7 +1040,7 @@ target_compile_options(${EXECUTABLE_RECOVERY_MCUBOOT_NAME} PUBLIC
10401040

10411041
set_target_properties(${EXECUTABLE_RECOVERY_MCUBOOT_NAME} PROPERTIES
10421042
SUFFIX ".out"
1043-
LINK_FLAGS "-mthumb -mabi=aapcs -L ${NRF5_SDK_PATH}/modules/nrfx/mdk -T${NRF5_LINKER_SCRIPT_MCUBOOT} --specs=nosys.specs -mcpu=cortex-m4 -mfloat-abi=hard -mfpu=fpv4-sp-d16 -Wl,--gc-sections -Wl,--print-memory-usage --specs=nano.specs -Wl,-Map=${EXECUTABLE_GRAPHICS_FILE_NAME}.map"
1043+
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 -Wl,-Map=${EXECUTABLE_GRAPHICS_FILE_NAME}.map"
10441044
)
10451045

10461046
add_custom_command(TARGET ${EXECUTABLE_RECOVERY_MCUBOOT_NAME}
@@ -1083,7 +1083,7 @@ add_dependencies(${EXECUTABLE_RECOVERYLOADER_NAME} ${EXECUTABLE_RECOVERY_MCUBOOT
10831083

10841084
set_target_properties(${EXECUTABLE_RECOVERYLOADER_NAME} PROPERTIES
10851085
SUFFIX ".out"
1086-
LINK_FLAGS "-mthumb -mabi=aapcs -L ${NRF5_SDK_PATH}/modules/nrfx/mdk -T${NRF5_LINKER_SCRIPT} --specs=nosys.specs -mcpu=cortex-m4 -mfloat-abi=hard -mfpu=fpv4-sp-d16 -Wl,--gc-sections -Wl,--print-memory-usage --specs=nano.specs -Wl,-Map=${EXECUTABLE_RECOVERYLOADER_FILE_NAME}.map"
1086+
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 -Wl,-Map=${EXECUTABLE_RECOVERYLOADER_FILE_NAME}.map"
10871087
)
10881088

10891089
add_custom_command(TARGET ${EXECUTABLE_RECOVERYLOADER_NAME}
@@ -1118,7 +1118,7 @@ add_dependencies(${EXECUTABLE_MCUBOOT_RECOVERYLOADER_NAME} ${EXECUTABLE_RECOVERY
11181118

11191119
set_target_properties(${EXECUTABLE_MCUBOOT_RECOVERYLOADER_NAME} PROPERTIES
11201120
SUFFIX ".out"
1121-
LINK_FLAGS "-mthumb -mabi=aapcs -std=gnu++98 -std=c99 -L ${NRF5_SDK_PATH}/modules/nrfx/mdk -T${NRF5_LINKER_SCRIPT_MCUBOOT} --specs=nosys.specs -mcpu=cortex-m4 -mfloat-abi=hard -mfpu=fpv4-sp-d16 -Wl,--gc-sections -Wl,--print-memory-usage --specs=nano.specs -Wl,-Map=${EXECUTABLE_MCUBOOT_RECOVERYLOADER_FILE_NAME}.map"
1121+
LINK_FLAGS "-mthumb -mabi=aapcs -std=gnu++98 -std=c99 -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 -Wl,-Map=${EXECUTABLE_MCUBOOT_RECOVERYLOADER_FILE_NAME}.map"
11221122
)
11231123

11241124
add_custom_command(TARGET ${EXECUTABLE_MCUBOOT_RECOVERYLOADER_NAME}

src/displayapp/fonts/CMakeLists.txt

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,6 @@ set(FONTS jetbrains_mono_42 jetbrains_mono_76 jetbrains_mono_bold_20
44
find_program(LV_FONT_CONV "lv_font_conv" NO_CACHE REQUIRED
55
HINTS "${CMAKE_SOURCE_DIR}/node_modules/.bin")
66
message(STATUS "Using ${LV_FONT_CONV} to generate font files")
7-
configure_file(${CMAKE_CURRENT_LIST_DIR}/jetbrains_mono_bold_20.c_zero.patch
8-
${CMAKE_CURRENT_BINARY_DIR}/jetbrains_mono_bold_20.c_zero.patch COPYONLY)
9-
configure_file(${CMAKE_CURRENT_LIST_DIR}/jetbrains_mono_bold_20.c_M.patch
10-
${CMAKE_CURRENT_BINARY_DIR}/jetbrains_mono_bold_20.c_M.patch COPYONLY)
117
if(CMAKE_VERSION VERSION_GREATER_EQUAL 3.12)
128
# FindPython3 module introduces with CMake 3.12
139
# https://cmake.org/cmake/help/latest/module/FindPython3.html

src/displayapp/fonts/fonts.json

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,8 @@
1010
"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, 0xf06e, 0xf015, 0xf00c, 0xf0f3, 0xf522, 0xf743, 0xf1ec, 0xf55a, 0xf3ed"
1111
}
1212
],
13-
"bpp": 1,
14-
"size": 20,
15-
"patches": ["jetbrains_mono_bold_20.c_zero.patch", "jetbrains_mono_bold_20.c_M.patch"]
13+
"bpp": 2,
14+
"size": 20
1615
},
1716
"jetbrains_mono_42": {
1817
"sources": [
@@ -21,7 +20,7 @@
2120
"range": "0x25, 0x2b, 0x2d, 0x2e, 0x30-0x3a, 0x43, 0x46, 0x4b-0x4d, 0x66, 0x69, 0x6b, 0x6d, 0x74, 0xb0"
2221
}
2322
],
24-
"bpp": 1,
23+
"bpp": 2,
2524
"size": 42
2625
},
2726
"jetbrains_mono_76": {
@@ -71,7 +70,7 @@
7170
"range": "0xf185, 0xf186, 0xf6c3, 0xf6c4, 0xf73c, 0xf743, 0xf740, 0xf75f, 0xf0c2, 0xf05e, 0xf73b, 0xf0e7, 0xf2dc"
7271
}
7372
],
74-
"bpp": 1,
73+
"bpp": 2,
7574
"size": 25
7675
}
7776
}

0 commit comments

Comments
 (0)