Add Python TrainSim with loop track map and physics.
FastAPI server, replaceable JSON config, tests, Dockerfile. Pairs with ATO via spec/interface.md contract. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
parent
45c95836ef
commit
9c5ef3a5cd
18 changed files with 414 additions and 18 deletions
8
config/sim.default.json
Normal file
8
config/sim.default.json
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
{
|
||||
"track_length_m": 1000.0,
|
||||
"tick_hz": 20.0,
|
||||
"traction_gain": 0.15,
|
||||
"brake_gain": 0.25,
|
||||
"drag": 0.02,
|
||||
"max_speed_mps": 25.0
|
||||
}
|
||||
14
config/track.default.json
Normal file
14
config/track.default.json
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
{
|
||||
"nodes": [
|
||||
{"id": "A", "x": 200, "y": 100},
|
||||
{"id": "B", "x": 400, "y": 200},
|
||||
{"id": "C", "x": 200, "y": 300},
|
||||
{"id": "D", "x": 0, "y": 200}
|
||||
],
|
||||
"edges": [
|
||||
{"from": "A", "to": "B", "length_m": 250},
|
||||
{"from": "B", "to": "C", "length_m": 250},
|
||||
{"from": "C", "to": "D", "length_m": 250},
|
||||
{"from": "D", "to": "A", "length_m": 250}
|
||||
]
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue