Two wires could be field and armature, with common return via the casing / chassis earth, as per a normal automotive dynamo working with its control box containing regulator and cutout.
Any engine-driven or axle-driven dynamo that charges batteries needs a cutout (relay), to stop the dynamo motoring from the battery. A standard automotive setup has a voltage coil (across the dynamo output) and a current coil (in series with the contact, between the dynamo output and battery / load). The dynamo is isolated from the battery until the output voltage reaches the 'cut-in' voltage, set slightly higher than the normal system voltage, at which point the voltage coil on the cutout closes the contact. Current then flows towards the battery / load, through the current coil which adds its MMF to the voltage coil MMF, creating positive feedback and hysteresis to hold the relay closed. If the speed reduces and the generated voltage falls below the battery OCV, the armature current reverses and the machine begins to motor. The current coil MMF now opposes the voltage coil MMF and the flux in the relay falls suddenly, opening the contacts and isolating the dynamo again.
An automotive control box will typically have one (voltage only) or two (voltage and current) regulators, with contacts that interrupt a bypass around a resistance in the field circuit when the voltage / current exceeds a threshold. There's no positive feedback so they oscillate around the set point, adjusting the field duty cycle to suit the conditions. Rolling-stock regulators were often complex beasts with servo-motor driven multi-step resistances and various arrangements to optimise the charging conditions to the battery and load status and minimise voltage variation at the lights while making best use of the available generation. The configuration depended on whether single or dual battery working was used. There's some stuff online about Stone's, Tonum etc. systems if you search.