> They are called resolvers which are rotary transformers which output a sine and cosine signal. You input an AC sine wave and compare the phase offsets of the outputs to determine the rotor angle.
Right. Syncro resolvers are the classic way to do it. Modern versions use a permanent magnet and two Hall-effect sensors.