I'm not %100 on the theory but I can observe.

generator basics:

1. take a small dc PM motor, chuck it up to a variable speed drill, and connect a voltmeter (they are fairly high impedance). The voltage output WILL be proportional to speed/rpm.

2. add a resistor to the motor terminals, now you have current and a bit more load on the drill (torque input). the current is the voltage output at that rpm divided by both the load resistance and the internal resistance of the motor windings/etc. the voltage output drops a little because the motor windings and resistor act like a voltage divider.

3. put a lower value resistor on there, get more current, more torque on the drill, more voltage drop in the motor for a given rpm.

therefore: rpm~volts out (no load), torque in = current out (you have to actually apply a load to change the current at a given rpm).

same sort of thing happens when it is motoring. current = torque, volts ~ rpm. Power is a function of volts*amps or torque*rpm. Due to winding resistance/friction/etc electrical power != mechanical power. electrical power is less in a generator, and more in a motor.

4. replace the resistor with a battery(watch the polarity, should spin same direction as drill). It too has some resistance.

5. if you spin it with the drill so the no load motor voltage is the same as the battery voltage, no current will flow. The back emf from the motor is the same as the battery. If you spin it slower, the battery will discharge. if you spin it faster it will charge. the current is a function of the voltage difference and the total circuit resistance.

Apologies if that is all obvious. Anyway on to the "theory".

you are right that if you simply open the circuit mechanically, while current is flowing, you will get a voltage spike, it is a big inductor after all. DC motor controllers have a diode in parallel with the motor, and when the pwm cycle is off, the current continues to flow in the motor. But even without the extra diode, the mosfet/igbt also has a diode, so the voltage spike would go right up to pack voltage and then you get some current, but that is less efficient. And 3 phase controllers are silly with diodes. So not a problem.

I don't know exactly how to analyze a motor by looking at it, but the voltage output (or needed for input) is a function of the rpm, the number of turns, the resistance, the amount of flux the wires are traversing. turns and length are interchangeable (how much wire is passing through the magnetic field in the right orientation). you can think of the turns as being like putting batteries in series, kinda.

once you know the voltage, the current is the total voltage difference divided by the total resistance, i.e. superimposed.

Anyway thats my guess, you can probably google generator theory or something.

motors ARE generators.