Load engines from TOML and improve scenario audio and carb tuning

Migrate 32 engine definitions into validated startup-loaded TOML files and separate configuration and snapshots from scenario assembly. Add camera-based stereo propagation from shared pipe geometry, preserve exhaust character, tune carburetor mixtures and idle, use ignition cuts for carb engines, and support returning to the scenario menu.

Validation: full Windows build and all 14 CTest checks passed.
This commit is contained in:
max
2026-10-24 03:24:35 +02:00
parent 5607dcf2b5
commit bf8621ad39
82 changed files with 24084 additions and 648 deletions

68
engines/fivehundred.toml Normal file
View File

@@ -0,0 +1,68 @@
# Engine definition. Dimensional keys state their units.
schema_version = 1
id = "fivehundred"
name = "500 cc / big single"
category = "Two-stroke / 500 cc"
description = "Concept single / transported carb fuel"
order = 16
cycle = "two_stroke"
[two_stroke]
initial_rpm = 3000.0
starter_torque_nm = 8.0
maximum_load_torque_nm = 10.0
crankshaft_inertia_kg_m2 = 0.04002316
bore_mm = 86.0
carburetor_diameter_mm = 41.0
crankcase_clearance_cc = 600.3475
exhaust = "racing"
exhaust_cell_length_mm = 15.0
exhaust_duration_deg = 190.0
exhaust_width_mm = 57.15746
friction_bar = 0.4
friction_bar_per_mps = 0.09
friction_bar_per_mps2 = 0.0009
idle_minimum_advance_deg = -10.0
idle_slide_opening = 0.045
idle_spark_gain = 0.05
jet_scale = 1.0
main_jet_scale = 1.7504
minimum_burn_s = 0.001270166
needle_jet_scale = 1.06
needle_low_scale = 3.04
needle_mid_scale = 0.8
needle_off_idle_scale = 12.0
needle_quarter_scale = 1.4
needle_tip_scale = 5.0
needle_transition_scale = 9.0
needle_upper_scale = 0.76
pilot_jet_scale = 0.75
pilot_tip_scale = 1.0
pilot_transition_scale = 1.0
rod_mm = 174.6478
stroke_mm = 86.0
transfer_duration_deg = 130.0
transfer_width_mm = 79.38537
trapped_compression = 8.2
chamber_sections_mm = [[254.0332, 57.15746, 57.15746], [285.7873, 57.15746, 95.26245], [301.6644, 95.26245, 166.7093], [206.402, 166.7093, 166.7093], [333.4185, 166.7093, 34.92956], [381.0498, 34.92956, 34.92956]]
[ecu]
idle_control = "fixed"
idle_rpm = 3000.0
idle_max_opening = 0.3
throttle_time_constant_s = 0.0002
throttle_rate = 5000.0
rev_limit_enabled = false
rev_limit_fuel_cut_enabled = false
overrun_cut_rpm = 5000.0
overrun_resume_rpm = 3500.0
overrun_fuel_cut_enabled = false
overrun_ignition_cut_enabled = true
ignition_map = [[0, 10], [3000, 18], [6000, 24], [9000, 18], [11000, 12], [13000, 6], [15000, 2], [18000, 0]]
[vehicle]
primary_reduction = 3.368421
final_drive_ratio = 3.769231
mass_kg = 170
wheel_radius_mm = 331.3
gear_ratios = [2.384615, 1.933333, 1.588235, 1.352941, 1.176471, 1.055556]