To use a series wound DC motor as a generator you need to energise the field winding with DC. This willrequire as a minimum access to the connection between the two windings. #you can then control the output voltage from the armature by varying the current through the field winding.
See:https:
//www.electricaleasy.com/2022/09/construction-and-working-of-dc-generator.html
for a description of how this type of machine works. You may be able to make it self exciting, Google “Flashing the field” (not in the field that may bring up different results:-) )
EDIT: If you have two STATOR windings ignore the one producing a weak field. It is likely a compensating winding. This may be needed once you have basic working if it is a large generator. It is connected in series with the armature winding to reduce sparking at the brushes.
Robert.