HMR3100
Advanced Information SENSOR PRODUCTS
Solid State Electronics Center • www.magneticsensors.com • (800) 323-8295 • Page 6
Calibration Mode
When the host processor pulses the RTS pin, and sends the RXD pin to a low logic level, the HMR3100 is in
calibration mode. At a moderate rate (2 to 5 seconds per rotation), rotate the HMR3100/host assembly two complete
circles to allow the HMR3100 to take measurements for compass calibration. At the completion of the rotations,
return the RXD to a high logic level. The HMR3100 will return to sleep status until another mode has been initiated.
Upon initiation of the calibration mode, the microcontroller shall output a STA (53 54 41 hex) indicating a start of
calibration and then RDY (52 44 59 hex) at the completion of the rotations and the RXD line returning high. Figure 3
shows the calibration mode timing diagram.
Data Description
The HMR-3100 host processor uses a three byte reply as the RTS line is brought low. The data is formatted in
hexadecimal (hex) fashion with the first byte being either 80(hex) or 81(hex). If that first byte LSbit is flagged high (81
hex), it means magnetic distortion maybe present and a calibration should be performed. The remaining two bytes
are the heading (in degrees) in MSB to LSB format. There is some data interpretation needed to derive the heading.
For example, an 80 02 85 (hex) Byte pattern correlates to 322.5 degrees.
This is done by taking the MSB hex value, converting it to decimal representation (e.g. 02 decimal) and multiplying it
by 256. Then the LSB is decimalized (e.g. 85(hex) to 133(decimal)) and added to the 512(decimal) MSB. The total
(512+133=645) is then divided by two to arrive at a 322.5 degree heading. This data format permits the 0.5°
resolution.
Figure 3
Calibration Mode Timing Diagram