mirror of
https://github.com/MaSzyna-EU07/maszyna.git
synced 2026-11-27 21:45:16 +01:00
* fix(ai): read the motor parameters of ESMVelocity() within the table
TController::ESMVelocity() indexed MotorParam with the field shunting
step of the next master controller position. For a position with a
step of its own that index is RList[].ScndAct, the sixth column of the
RList rows of the .fiz, which readRList() takes as it is. A step of 11
or more read past the 11 entries of MotorParam.
The pole flux is now read through motor_param(), which keeps the index
inside the table, as MomentumF() in the same loop and Momentum() already
do. Nothing changes for a .fiz with valid steps.
The unit tests show the loader keeping an out-of-range ScndAct and
motor_param() clamping it; ESMVelocity() itself is in Driver.cpp, which
the unit tests don't build.
* test(scenarios): a Traxx, with a brake handle with a time chamber, starting up
None of the cases had a driver's brake handle with a time chamber
(MHZ_K5P, MHZ_6P, M394, Knorr, St113, FVel6, FVE408), for which the AI
getting the vehicle ready has a rule of its own for releasing the train
brake (5775493b2). Three cases run a Traxx (E186, MHZ_6P) on td.scn: the
timetable run from a trainset ready to depart, the same from a cold
start, and the locomotive standing ready to depart with nobody in it
until a driver is put in. In each the driver puts the handle to running
and leaves.
* test: read the EP09 definition into a json with '=', not braces
GCC takes nlohmann::ordered_json in braces for an initializer list and
makes an array holding the parsed object, so at("RList") threw on the
Linux build (type_error 304); MSVC kept the object.
21 lines
997 B
JSON
21 lines
997 B
JSON
{
|
|
"description": "As traxx_td_timetable, from a cold start: the trainset stands with velocity 0, so the locomotive starts braked, its brake handle (MHZ_6P, with a time chamber) in the holding position and the brake pipe below running pressure. The driver gets the order to run as a train, starts the locomotive, puts the handle to running, charges the brake pipe and leaves on time.",
|
|
"base_scenery": "td.scn",
|
|
"time": "10:34",
|
|
"fragment": "td_cold_timetable.scn",
|
|
"vars": {
|
|
"consist": "node -1 0 {{vehicle}} dynamic pkp/e186_v2 146_226-6 p160dc 0 headdriver 0 0 enddynamic"
|
|
},
|
|
"track_events": {
|
|
"tdo_n1734": "event0 autotest_wake"
|
|
},
|
|
"duration": 300,
|
|
"timeout": 600,
|
|
"checks": [
|
|
{ "type": "starts", "min_speed": 20, "within": 150 },
|
|
{ "type": "max_speed", "limit": 90, "tolerance": 3 },
|
|
{ "type": "brakes", "min_pressure": 0.5 },
|
|
{ "type": "stops", "moving_speed": 20, "stop_speed": 1.0, "hold": 0, "min_distance": 1380, "max_distance": 1420 }
|
|
]
|
|
}
|