Skip to content

Commit e4afff8

Browse files
Merge pull request #75 from ctrmint/agent/prepare-v4.3.0
Prepare v4.3.0 release
2 parents 9976d1c + b18ed3f commit e4afff8

5 files changed

Lines changed: 69 additions & 8 deletions

File tree

‎README.md‎

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,19 @@
1-
# Track Session Timer - v4.2.0
1+
# Track Session Timer - v4.3.0
22
Trackday or race session timer.
33

44
# Change log
5-
## Unreleased
5+
## Version 4.3
6+
### v4.3.0 [current]
67
* Added an interactive post-track review with a high-visibility page for actual duration, overrun, completion reason, total maximum G, and each directional acceleration/braking/left/right peak.
78
* Added left/right review navigation and prevented cool-down from starting until every result page has been reached and the final page is advanced.
89
* Kept summary data in bounded RAM only; no session history is written to flash in this increment.
910
* Retained captured peaks as explicitly partial data if the IMU fails during a session, while normal timing continues.
11+
* Added a live maximum-G value above the running track-session countdown.
1012
* Added a persistent Auto-Dim setting that reduces the Ready screen to 25% brightness after 10 seconds without motion and restores the saved brightness immediately when motion resumes or Ready is left.
1113
* Kept Auto-Dim disabled by default and preserved normal brightness if motion sensing is disabled or unavailable.
1214
* Moved the Ready-screen dim level into `params.json` as the validated `AUTO_DIM_PERCENT` system setting, defaulting to 25%.
13-
* Expanded hardware-independent regression coverage to 185 tests.
15+
* Added a hardware Bill of Materials identifying the cased Waveshare RP2040-Touch-LCD-1.28-B reference variant.
16+
* Expanded hardware-independent regression coverage to 186 tests.
1417

1518
## Version 4.2
1619
### v4.2.0
@@ -207,7 +210,7 @@ When upgrading an existing device, omit that command so all of its saved user se
207210

208211
### 4. Verify first boot
209212

210-
The display should show the Caterham v4.2.0 splash, the hardware-information splash, and then the green **Ready** screen. The serial console should report the loaded user parameters, `Success:Detected CST816T.`, and the touchscreen revision without a traceback.
213+
The display should show the Caterham v4.3.0 splash, the hardware-information splash with **Firmware v4.3.0**, and then the green **Ready** screen. The serial console should report the loaded user parameters, `Success:Detected CST816T.`, and the touchscreen revision without a traceback.
211214

212215
If first boot fails:
213216

@@ -226,7 +229,7 @@ The QMI8658 IMU is optional unless a non-zero Launch Mode sensitivity, G Mode, A
226229

227230
## Configuration files
228231

229-
Version 4.2.0 uses two separate configuration scopes:
232+
Version 4.3.0 uses two separate configuration scopes:
230233

231234
* `params.json` contains system-owned choices and display behavior: `DURATION_VALUES`, `LAUNCH_SENSE_VALUES`, `VERSION`, `DISPLAY_DELAY_REST`, `DISPLAY_DELAY_REST_COLOUR`, `STARTUP_SPLASH_DURATION_SEC`, `HARDWARE_SPLASH_DURATION_SEC`, `MODE_MENU_HOLD_SEC`, and `AUTO_DIM_PERCENT` (an integer from 1 to 100, default 25).
232235
* `user.json` contains the current user selections: `RACE_LENGTH` (track-session minutes), `REST_LENGTH` (pit-rest minutes), `SENSITIVITY` (launch threshold; `0` disables Launch Mode), `OPERATING_MODE` (`timer` or `g`), `BRIGHTNESS_PERCENT`, `DISPLAY_ROTATION_DEG` (`auto` or the fixed clockwise device mounting angle `0`, `90`, `180`, or `270`), and `AUTO_DIM_ENABLED` (`true` or `false`).

‎User Guide.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# User Guide - v4.2.0
1+
# User Guide - v4.3.0
22

33
## General / Sessions Use
44
The following describes general operation of both the ``Track Session`` and ``Rest in Pits Session`` timer.

‎params.json‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"DURATION_VALUES": [1, 5, 10, 15, 20, 25, 30, 40, 50, 60],
33
"DISPLAY_DELAY_REST": 5,
44
"LAUNCH_SENSE_VALUES": [0, 0.5, 1, 1.25, 1.5, 1.75, 2, 2.5, 3.5, 4],
5-
"VERSION": "4.2.0",
5+
"VERSION": "4.3.0",
66
"DISPLAY_DELAY_REST_COLOUR": "blue",
77
"STARTUP_SPLASH_DURATION_SEC": 2,
88
"HARDWARE_SPLASH_DURATION_SEC": 2,

‎settings.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
"DURATION_VALUES": [1, 5, 10, 15, 20, 25, 30, 40, 50, 60],
1313
"DISPLAY_DELAY_REST": 5,
1414
"LAUNCH_SENSE_VALUES": [0, 0.5, 1, 1.25, 1.5, 1.75, 2, 2.5, 3.5, 4],
15-
"VERSION": "4.2.0",
15+
"VERSION": "4.3.0",
1616
"DISPLAY_DELAY_REST_COLOUR": "blue",
1717
"STARTUP_SPLASH_DURATION_SEC": 2,
1818
"HARDWARE_SPLASH_DURATION_SEC": 2,

‎tests/test_release_version.py‎

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
import json
2+
import unittest
3+
from pathlib import Path
4+
5+
from hardware_splash import run_startup_screens
6+
from settings import DEFAULT_SYSTEM_PARAMS
7+
8+
9+
RELEASE_VERSION = "4.3.0"
10+
REPOSITORY_ROOT = Path(__file__).resolve().parents[1]
11+
12+
13+
class FakeTouch:
14+
def __init__(self):
15+
self.boot_version = None
16+
self.hardware_lines = None
17+
18+
def BootScreen(self, _lcd, version_number):
19+
self.boot_version = version_number
20+
21+
def ControlScreen(self, _lcd, text_array, back_colour):
22+
self.hardware_lines = text_array
23+
self.hardware_background = back_colour
24+
25+
26+
class ReleaseVersionTests(unittest.TestCase):
27+
def test_build_defaults_docs_and_both_startup_screens_report_release(self):
28+
with (REPOSITORY_ROOT / "params.json").open(encoding="utf-8") as source:
29+
params = json.load(source)
30+
readme = (REPOSITORY_ROOT / "README.md").read_text(encoding="utf-8")
31+
user_guide = (REPOSITORY_ROOT / "User Guide.md").read_text(
32+
encoding="utf-8"
33+
)
34+
35+
self.assertEqual(RELEASE_VERSION, params["VERSION"])
36+
self.assertEqual(RELEASE_VERSION, DEFAULT_SYSTEM_PARAMS["VERSION"])
37+
self.assertTrue(readme.startswith("# Track Session Timer - v" + RELEASE_VERSION))
38+
self.assertTrue(user_guide.startswith("# User Guide - v" + RELEASE_VERSION))
39+
40+
touch = FakeTouch()
41+
run_startup_screens(
42+
touch,
43+
object(),
44+
firmware_version=params["VERSION"],
45+
startup_duration_sec=0,
46+
hardware_duration_sec=0,
47+
wait=lambda _lcd, _duration: None,
48+
)
49+
50+
self.assertEqual(RELEASE_VERSION, touch.boot_version)
51+
self.assertIn(
52+
"Firmware v" + RELEASE_VERSION,
53+
[line[0] for line in touch.hardware_lines],
54+
)
55+
56+
57+
if __name__ == "__main__":
58+
unittest.main()

0 commit comments

Comments
 (0)