Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 6 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -101,16 +101,18 @@ Every file is formatted as follows:
# carId (String) - The carId property as it appears in SimHub
# carClass (String) - The car's 3-5 letter class shorthand
# ledNumber (Int) - The car's in game number of telemetry LED's
# redlineBlinkInterval (Int) - The Speed at which the redline blinks in ms
# redlineBlinkInterval (Int|Array) - The speed at which the redline blinks in ms. If an array, it matches the redline stages.
# ledColor An array of the led color
# redline(:Value) (String) - A color name or HEX value for the red line
# redline1(:Value) (String) - (Optional) Stage 1 color name or HEX value for the red line
# redlineN(:Value) (String) - (Optional) Stage N color name or HEX value for the red line
# led1color(:Value) (String) - A color name or HEX value for LED 1
# led2color(:Value) (String) - A color name or HEX value for LED 2
# led3color(:Value) (String) - A color name or HEX value for LED 3
# ledNcolor(:Value) (String) - A color name or HEX value for LED N
# ledRpm An array of all the RPM data per gear
# gear(:Key) (String) - The gear number
# redline(:Value) (Int) - The RPM red line value per gear
# redline1(:Value) (Int) - (Optional) Stage 1 RPM red line value per gear
# redlineN(:Value) (Int) - (Optional) Stage N RPM red line value per gear
# led1rpm(:Value) (Int) - The RPM value for LED 1
# led2rpm(:Value) (Int) - The RPM value for LED 2
# led3rpm(:Value) (Int) - The RPM value for LED 3
Expand Down Expand Up @@ -149,7 +151,7 @@ pre-commit install
### 3. Test & Finish
You're all set as far as tooling is concerned. Every time you make a commit, the `pre-commit` script will make sure the files are properly formatted and are prettified.

It's usually a good idea to run the hooks against all of the files when adding new hooks (usually pre-commit will only run on the changed files during git hooks). Running `pre-commit run --all-files` will have a pass at everythig, and if all is well, you should see somthing like the below.
It's usually a good idea to run the hooks against all of the files when adding new hooks (usually pre-commit will only run on the changed files during git hooks). Running `pre-commit run --all-files` will have a pass at everything, and if all is well, you should see something like the below.

```
$ pre-commit run --all-files
Expand Down
20 changes: 10 additions & 10 deletions data/iracing/ferrari296gt3.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,18 +3,18 @@
"carId": "ferrari296gt3",
"carClass": "GT3",
"ledNumber": 6,
"redlineBlinkInterval": 250,
"ledColor": ["#FFFF0000","#FF00FF00","#FF00FF00","#FFFFFF00","#FFFFFF00","#FFFF0000","#FFFF0000"],
"redlineBlinkInterval": [0, 250],
"ledColor": ["#FFFF0000","#FFFF0000","#FF00FF00","#FF00FF00","#FFFFFF00","#FFFFFF00","#FFFF0000","#FFFF0000"],
"ledRpm": [
{
"R": [7500,4500,5000,5500,6000,6500,7000],
"N": [7500,4500,5000,5500,6000,6500,7000],
"1": [7360,6760,6860,6960,7060,7160,7260],
"2": [7440,6840,6940,7040,7144,7240,7340],
"3": [7420,6820,6920,7020,7120,7220,7320],
"4": [7360,6760,6860,6960,7060,7160,7260],
"5": [7350,6750,6850,6950,7050,7150,7250],
"6": [7900,6700,6900,7100,7300,7500,7700]
"R": [7300,7500,4500,5000,5500,6000,6500,7000],
"N": [7300,7500,4500,5000,5500,6000,6500,7000],
"1": [7200,7360,6760,6860,6960,7060,7160,7260],
"2": [7300,7440,6840,6940,7040,7144,7240,7340],
"3": [7250,7420,6820,6920,7020,7120,7220,7320],
"4": [7200,7360,6760,6860,6960,7060,7160,7260],
"5": [7150,7350,6750,6850,6950,7050,7150,7250],
"6": [7700,7900,6700,6900,7100,7300,7500,7700]
}
]
}
22 changes: 11 additions & 11 deletions data/lmu/gt3-awa-racing-2025.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,19 @@
"carClass": "GT3",
"ledNumber": 8,
"redlineBlinkInterval": 0,
"ledColor": ["#FFFF0000","#FF00FF00","#FF00FF00","#FF00FF00","#FF00FF00","#FF00FF00","#FF00FF00","#FFFFFF00","#FFFFFF00"],
"ledColor": ["#FFFF0000","#FF0000FF","#FF00FF00","#FF00FF00","#FF00FF00","#FF00FF00","#FF00FF00","#FF00FF00","#FFFFFF00","#FFFFFF00"],
"ledRpm": [
{
"R": [7520,6619,6732,6845,6958,7069,7181,7293,7408],
"N": [7520,6619,6732,6845,6958,7069,7181,7293,7408],
"1": [7520,6619,6732,6845,6958,7069,7181,7293,7408],
"2": [7520,6619,6732,6845,6958,7069,7181,7293,7408],
"3": [7520,6619,6732,6845,6958,7069,7181,7293,7408],
"4": [7520,6619,6732,6845,6958,7069,7181,7293,7408],
"5": [7520,6619,6732,6845,6958,7069,7181,7293,7408],
"6": [7520,6619,6732,6845,6958,7069,7181,7293,7408],
"7": [7520,6619,6732,6845,6958,7069,7181,7293,7408],
"8": [7520,6619,6732,6845,6958,7069,7181,7293,7408]
"R": [7520,7730,6619,6732,6845,6958,7069,7181,7293,7408],
"N": [7520,7730,6619,6732,6845,6958,7069,7181,7293,7408],
"1": [7520,7730,6619,6732,6845,6958,7069,7181,7293,7408],
"2": [7520,7730,6619,6732,6845,6958,7069,7181,7293,7408],
"3": [7520,7730,6619,6732,6845,6958,7069,7181,7293,7408],
"4": [7520,7730,6619,6732,6845,6958,7069,7181,7293,7408],
"5": [7520,7730,6619,6732,6845,6958,7069,7181,7293,7408],
"6": [7520,7730,6619,6732,6845,6958,7069,7181,7293,7408],
"7": [7520,7730,6619,6732,6845,6958,7069,7181,7293,7408],
"8": [7520,7730,6619,6732,6845,6958,7069,7181,7293,7408]
}
]
}
22 changes: 11 additions & 11 deletions data/lmu/gt3-tf-sport-2025.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,19 @@
"carClass": "GT3",
"ledNumber": 8,
"redlineBlinkInterval": 0,
"ledColor": ["#FFFF0000","#FF00FF00","#FF00FF00","#FF00FF00","#FF00FF00","#FF00FF00","#FF00FF00","#FFFFFF00","#FFFFFF00"],
"ledColor": ["#FFFF0000","#FF0000FF","#FF00FF00","#FF00FF00","#FF00FF00","#FF00FF00","#FF00FF00","#FF00FF00","#FFFFFF00","#FFFFFF00"],
"ledRpm": [
{
"R": [7520,6619,6732,6845,6958,7069,7181,7293,7408],
"N": [7520,6619,6732,6845,6958,7069,7181,7293,7408],
"1": [7520,6619,6732,6845,6958,7069,7181,7293,7408],
"2": [7520,6619,6732,6845,6958,7069,7181,7293,7408],
"3": [7520,6619,6732,6845,6958,7069,7181,7293,7408],
"4": [7520,6619,6732,6845,6958,7069,7181,7293,7408],
"5": [7520,6619,6732,6845,6958,7069,7181,7293,7408],
"6": [7520,6619,6732,6845,6958,7069,7181,7293,7408],
"7": [7520,6619,6732,6845,6958,7069,7181,7293,7408],
"8": [7520,6619,6732,6845,6958,7069,7181,7293,7408]
"R": [7520,7730,6619,6732,6845,6958,7069,7181,7293,7408],
"N": [7520,7730,6619,6732,6845,6958,7069,7181,7293,7408],
"1": [7520,7730,6619,6732,6845,6958,7069,7181,7293,7408],
"2": [7520,7730,6619,6732,6845,6958,7069,7181,7293,7408],
"3": [7520,7730,6619,6732,6845,6958,7069,7181,7293,7408],
"4": [7520,7730,6619,6732,6845,6958,7069,7181,7293,7408],
"5": [7520,7730,6619,6732,6845,6958,7069,7181,7293,7408],
"6": [7520,7730,6619,6732,6845,6958,7069,7181,7293,7408],
"7": [7520,7730,6619,6732,6845,6958,7069,7181,7293,7408],
"8": [7520,7730,6619,6732,6845,6958,7069,7181,7293,7408]
}
]
}
22 changes: 11 additions & 11 deletions data/lmu/gt3-z06gt3r-custom-team-2025.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,19 @@
"carClass": "GT3",
"ledNumber": 8,
"redlineBlinkInterval": 0,
"ledColor": ["#FFFF0000","#FF00FF00","#FF00FF00","#FF00FF00","#FF00FF00","#FF00FF00","#FF00FF00","#FFFFFF00","#FFFFFF00"],
"ledColor": ["#FFFF0000","#FF0000FF","#FF00FF00","#FF00FF00","#FF00FF00","#FF00FF00","#FF00FF00","#FF00FF00","#FFFFFF00","#FFFFFF00"],
"ledRpm": [
{
"R": [7520,6619,6732,6845,6958,7069,7181,7293,7408],
"N": [7520,6619,6732,6845,6958,7069,7181,7293,7408],
"1": [7520,6619,6732,6845,6958,7069,7181,7293,7408],
"2": [7520,6619,6732,6845,6958,7069,7181,7293,7408],
"3": [7520,6619,6732,6845,6958,7069,7181,7293,7408],
"4": [7520,6619,6732,6845,6958,7069,7181,7293,7408],
"5": [7520,6619,6732,6845,6958,7069,7181,7293,7408],
"6": [7520,6619,6732,6845,6958,7069,7181,7293,7408],
"7": [7520,6619,6732,6845,6958,7069,7181,7293,7408],
"8": [7520,6619,6732,6845,6958,7069,7181,7293,7408]
"R": [7520,7730,6619,6732,6845,6958,7069,7181,7293,7408],
"N": [7520,7730,6619,6732,6845,6958,7069,7181,7293,7408],
"1": [7520,7730,6619,6732,6845,6958,7069,7181,7293,7408],
"2": [7520,7730,6619,6732,6845,6958,7069,7181,7293,7408],
"3": [7520,7730,6619,6732,6845,6958,7069,7181,7293,7408],
"4": [7520,7730,6619,6732,6845,6958,7069,7181,7293,7408],
"5": [7520,7730,6619,6732,6845,6958,7069,7181,7293,7408],
"6": [7520,7730,6619,6732,6845,6958,7069,7181,7293,7408],
"7": [7520,7730,6619,6732,6845,6958,7069,7181,7293,7408],
"8": [7520,7730,6619,6732,6845,6958,7069,7181,7293,7408]
}
]
}
36 changes: 36 additions & 0 deletions docs/N_redline.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# Pull Request: Proposal — Multi-Stage Redline Support & LMU GT3 Car Profiles

## Description
Some Le Mans Ultimate GT3 cars (like the 2025 Z06) feature RPM LED clusters with multi-stage redline behavior, where all LEDs change color in sequence (e.g.Red → Blue) as RPM climbs past specific thresholds. The current format doesn't have a clear way to represent this. This PR proposes a small, (hopefully) backward-compatible extension to the file format spec alongside three new car profiles that rely on this structure.

Open to feedback on the approach — happy to adjust based on your preferences.

### Changes

1. **Proposed update to `README.md` — File Format Specification:**
- Added optional `redline1`–`redlineN` entries to the `ledColor` and `ledRpm` documentation, prepended before the existing `led1`–`ledN` entries.
- Consumers can detect the extra array length (`ledColor.length > ledNumber`) and use the offset to drive sequential redline stages. Existing files with no redline stages are unaffected.
- Open to alternative structural approaches if a different convention would be preferred.

2. **Proposed update to `README.md` — Per-Stage Blinking:**
- Modified `redlineBlinkInterval` to support both `Int` and `Array` types.
- For multi-stage cases, an array maps 1:1 with stages (e.g., `[0, 250]` for static then blinking).
- Downstream consumers (Python/JS) can handle this union type dynamically, while strictly typed languages (C#/Rust) would use standard JSON sum-type patterns.
- This ensures backward compatibility for single-stage cars while enabling high-fidelity behavior for complex GT3 dashes.

3. **Updated `ferrari296gt3.json` (iRacing) as an example:**
- Ferrari 296 GT3 profile with 6 LEDs and 2 redline stages.
- Stage 1 (Static Red): `0` ms blink.
- Stage 2 (Blinking Red): `250` ms blink.

## Considerations
- **Union Type Handling**: Adopting `Int | Array<Int>` is safe for modern JSON consumers. Python/JS tools used for SimHub profile generation handle this with simple type checks.
- **Backward Compatibility**: Single-stage profiles continue to use a single integer, preventing any breaking changes for existing repositories.
- **Telemetry Fidelity**: This change allows for exact matching of real-world LED behaviors like "solid color change -> final warning blink" sequences.

> **Note:** I included these Z06 GT3R and Ferrari 296 updates as examples. LMU v1.3 updates may change some car ID logic, but this format extension remains robust regardless of car identification methods.

## Testing
- All JSON files pass `pre-commit run --all-files` (check json + pretty format).
- Array lengths are consistent: `ledColor` has 10 entries, each gear RPM array has 10 entries, matching `ledNumber (8) + redline stages (2)`.
- Format aligns with the proposed README specification for `redline1`–`redlineN` handling.