Weird servo mechanism
Looks like a gray code rotary encoder. There is a nice tutorial here of a two output version. Good to wrap your head around.
You've got four outputs, so it's a four bit gray encoder. There are some truth tables of those outputs here and shown below.
But, now that you know what you're looking for you'll find a plethora of information. It'll make your head spin...