Magnetic rotary encoder


Published on

  • Be the first to comment

  • Be the first to like this

No Downloads
Total views
On SlideShare
From Embeds
Number of Embeds
Embeds 0
No embeds

No notes for slide

Magnetic rotary encoder

  1. 1. Magnetic Rotary Encoder The magnetic rotatary encoders have the potention to offer a incomparable control loop. Due the elotromagnetic properties, and the capability to independantly mount the sensor above the magnet. A sesnor such as this can be incorperated into various places on the robot for multipul purposes. The ÜberBots incorperated two magnetic rotary encoders in order to have realtime control and feedback on the robots steering. These magnetic sensors chips are on a frame independent to the drive shaft. Therefore, the sensors can be easily monitored, managed, and any other hardware failure would not compromise the magnetic encoders readings. In addition, a magnet was mounted on the extruding drive shaft, paired with each chip and offset, apromimently 5mm above the drive shaft, these sensors provide feedback on the gearbox that is responsible for rotating each pairing of wheels. While designing and prototyping this system of drive, we learned many valuable lessons about voltage based sensors. After first implemenation of the sensors we discovers discovered that there was a distinct point of rotation where the voltage jumped from 5 to 0. This point is where the rotary encoder crossed the poles on the magnet. As show in the graph below, at an almost unpredicable point, where the magnetic poles on the magnet are crossed, the voltage reading will instantly jump from 5 to 0.Analogue SensorVoltage Reading Degree of Rotation
  2. 2. This rapid jump from 5 to 0, in a unpredictable location was a serveredisadvatage and greatly limited the functionality of the system. Instanceswhere the control loop was attempting to reach a voltage of 2 from the currentvoltage of 2.5 would rotate 180 degrees and then jump to another line. Thedrastic jump, greatly reduces the lineararity of the readings. As a result, thecontrol loop may lose track of the system because of rapidly changing non-linear feed back readings.This vital problem was solved by a software based normalizer. This normalizerwas intended to manipulate the encoder readings in order to acquire linearfeedback readings. To successfully complete this task, we needed to find thecrossoverpoints on the rotary encoder. In order to calulate the angle at whichthe voltage crossed over, the sensor was manually moved in order to find theproper orientation of north and south on the magnet. Then, to determinewhere the cross over point was, the angle of rotation was calculated bymuliplying the voltage by 72 or the rangle of rotation divided by the range ofvoltage readings. Once calculated a unique algarithm was implemented tolinearize the graph. This is shown in the graph below. Normalized Relationship Beteen Angle of Rotation and Voltage Reading 6 4 Voltage 2 Voltage 0 0 72 144 216 288 360 Degrees Of Rotation After further development and tuning, the encoders were independently normalized and rotated in order to implement a hardware limit on the system. The result can be seen to the right. The shifted voltage readings are now the same on all encoders. Also, because of the location of the CIM motor on the gearbox the cross over point is now located at an unreachable degree. At this point the CIM will contact the chassis preventing any more rotation in that direction. This facilitates modular and easily repaired code. Hardware Limit Hardware Limit