A generator controller for controlling a permanent magnet generator where
each phase of the generator is connectable to a DC link via electrically
controllable switches, the controller characterised by a data processor
adapted to receive a measurement of generator current output and a demand
current, and to form a current error between the demanded value and the
measured generator current; derive a target voltage as a function of the
current error; and form control signals for the electrically controllable
switches as a function of the target voltage.