18
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-12-01 04:47:06 +01:00
Commit Graph

3 Commits

Author SHA1 Message Date
Hirek 95e7b55495 refactor(physics): the revolutions of the engine and the steps of the master controller in the drives
Two more switches on EngineType go into the classes of the drives:

- TractionDrive::UpdateEngineRevolutions(): the diesel-electric engine
  follows the revolutions it aims for, the diesel engine with a mechanical
  transmission gives its ratio and its moment, the others turn with the
  wheels (UpdateEngineRevolutions() before)
- TractionDrive::IncreaseMainController(), DecreaseMainController(): a notch
  of the master controller as the kind of the engine takes it: the series
  motors through their own steps, the diesel engine running to the end at
  a fast step, the draisine by a push, the others one position at a time
  (IncMainCtrlByEngine(), DecMainCtrlByEngine() before)

NoDrive splits in two: NoEngineDrive for a vehicle without an engine (its
controller steps, for the vehicles it controls) and UnmodelledDrive for the
steam engine and Main, which did nothing in these steps and still don't.

No change in behaviour: 1144/1144 tests, golden traces exact against staging
62f7a29b.
2026-11-28 16:02:59 +01:00
Hirek ff739d2328 refactor(physics): the induction motor drive is a component of its own
The fields of the drive of asynchronous motors fed by inverters move from
TMoverParameters into InductionMotor inductionMotor
(physics/components/inductionmotor.h):

  eimc[26]                    config (std::array, indexed by eimc_* as before)
  eimv[21]                    state (std::array, indexed by eimv_*)
  eimv_pr                     forceShare
  InverterFrequency           inverterFrequency
  InvertersNo, InvertersRatio inverterCount, inverterRatio
  Inverters                   inverters (of Inverter, inverter before)
  InverterControlCouplerFlag  inverterControlCouplings
  EIM_Pmax_Table              maxPowerTable
  EIMCLogForce                logForce

The integrated controller (eimic, EIMCtrlType), which the diesel-electric
vehicles use too, and the ED/EP blending (MED_*) stay where they are.

No change in behaviour: 1144/1144 tests, golden traces exact against staging
62f7a29b.
2026-11-28 15:43:22 +01:00
Hirek d4bd3fc5ca refactor(physics): physics/mover/ becomes physics/components/
The files of the parts of a vehicle (pneumatics, electrics, traction, doors,
drives...) are in physics/components/, not under the old name of the mover;
the file of the vehicle as a body, its forces and its movement, is body.cpp
(was mover.cpp). The includes, CMakeLists.txt and AGENTS.md name the new
paths.

Renames only. 1144/1144 tests, golden traces exact against staging 62f7a29b.
2026-11-28 00:28:34 +01:00