Calibration of a Digital Magnetic Compass

Why do we need to calibrate a digital magnetic compass?

A digital magnetic compass is an indispensable part of any ship or vessel sailing in the sea. A digital magnetic compass consists of a magnetometer which relies on earth’s magnetic field to indicate the direction. The output of the magnetic compass is susceptible to change if any stray magnetic field or ferrous materials are present in the vicinity. Output of any magnetometer will be a combination of earth’s magnetic field and any other magnetic fields present around. Before a digital magnetic compass is put to the actual use, it is very important to calibrate it so as to compensate for the factors which affect its output from the correct value.

Before we discuss the process of calibration of a magnetic compass, we would have a look at different types of sources of errors which can affect the compass output.

Hard iron sources of error

Hard iron sources of error are the objects that produce magnetic field and either add or subtract to the earth’s magnetic field. Hard iron sources of error include wires carrying electric current which result in changes in earth’s magnetic field, permanent magnets etc. A speaker which produces magnetic field is also a hard iron source of error.

Soft iron sources of error

Unlike hard iron sources of error, soft iron sources of error do not produce any magnetic field of their own. They distort the magnetic field and hence, cause an error. It is commonly observed, that certain metals like iron and nickel stretch or distort the magnetic field which deviates the output of the digital magnetic compass.

Effects of presence of distortions

When hard and soft iron sources of error are not present, the graph of the compass output will be in form of a perfect circle with the centre at (0, 0). The radius of this circle will indicate the magnitude of the magnetic field. The graph below shows the output of a digital magnetic compass when sources of errors are absent.

When any hard iron source of error is present, it shifts the centre of the circle depending upon the location and magnitude of the stray magnetic field. Hence, if a hard iron source of error is present, the output graph of a magnetic compass will look as follows:

A soft iron source of error will not shift the centre, but will affect the circularity of the output as seen in the graph below:

Calibration of a digital magnetic compass and swinging of the ship

The above part of this article makes the importance of calibrating the digital magnetic compass quite clear. What could be the correct procedure of calibrating a compass being used on a vessel? The process, called as swinging of the ship involves the ship making a 360 Deg. round in the water with compass installed on board.

The digital magnetic compass can be calibrated in three modes, automatic, semi-automatic and manual.

    1. Automatic calibration of digital magnetic compass

This involves taking a 360 Deg. round in the water with the compass fixed on the ship. When the round is completed, if the compass is calibrated correctly, it notifies the user about the successful completion of calibration. If automatic calibration fails, user should go for the semi-automatic calibration.

    1. Semi-automatic calibration

Automatic calibration fails if the compass fails to record the output at particular points. In semi-automatic calibration, the ship or vessel takes three rounds in the water. This ensures that any data points, if missed in a round, are captured in the subsequent rounds.

    1. Manual Calibration

In rare and poor conditions, the semi-automatic calibration could also fail. Users are required to go for a manual calibration during such conditions. In manual calibrations, the output of the compass is manually recorded, correction factors calculated, and then fed in to the compass.


Calibration of digital magnetic compass is an essential and critical step before actually using the compass. Many times, it has been observed that users tend to skip this step which is a highly unsafe practice. The compass should be re-calibrated if the soft or hard iron sources of error in the vicinity change.

In case you have any queries about digital magnetic compass and its calibration, please write to us at