Performance analysis of a digital compass for the heading estimation in nautical application Ivo Boniolo†, Sergio M. Savaresi†, Maria Prandini† Giuseppe Borghi*, Bruno Garavelli*, Sergio Bittanti† † Dipartimento di Elettronica e Informazione, Politecnico di Milano, Piazza Leonardo da Vinci, 32, 20133 Milano, ITALY {boniolo, savaresi, prandini, bittanti}@elet.polimi.it * TEK4VALUE, Via A. Lamarmora 2, 20038 Seregno, ITALY {gborghi, bgaravelli}@tek4value.com Abstract: This paper deals with the calibration of a magnetic digital compass for measuring the heading angle of a vessel. The main source of error in the heading measurement is the distortion caused by the presence of ferrous materials nearby the instrument that produces a local magnetic field interfering with the earth magnetic field. This distortion generally changes as the vessel moves around and, for this reason, it is generally difficult to compensate. Tuning the calibration algorithm based on data collected dynamically rather than at a fix location, as it is the standard practice, allows to account for this time- varying characteristics, while avoiding at the same time to discontinue the vessel operation. The accuracy achieved by different calibration algorithms tuned on data collected on a car ferry performing a round trip in the Venetian lagoon is analysed. In particular, a calibration algorithm combining the elliptical model of the magnetic distortion with a neural network is proposed. Keywords: magnetic bearings, calibration, radial basis function network. 1. INTRODUCTION AND MOTIVATION Compasses are traditionally used in maritime transport to determine the direction of navigation. The earliest compass consisted of a magnetized pointer providing measurements of the direction of navigation by getting aligned with the earth magnetic field. Currently, the more commonly used compasses are digital, due to their small size, low cost and power requirement, and the fact that they can be easily integrated into more complex multi-sensor systems [8, 10]. This paper studies the performance of a class of digital compasses that are built with three strapdown magnetic field sensors positioned along orthogonal measurement axes, typically rotated of 180° around the roll axis of the body coordinate system of the vessel, as represented in Figure 1. The magnetic field measurements obtained through these three orthogonal magnetoresistive sensors are used to determine the direction on the horizontal plane pointing towards the geographic north (true bearing). To this purpose, tilt sensors are used to compensate the roll and pitch rotation of the vehicle and guarantee that the magnetic field is measured on a horizontal plane [4]. The so-obtained magnetic field measurement vector identifies a direction (compass bearing) that generally differs from the true bearing because of various sources of errors, among which the A/D converter resolution, the magnetic sensor errors, temperature effects, and the compass tilt errors, as pointed out in [1]. The main source of error is the so-called magnetic declination, which requires an appropriate calibration of the compass [6, 7, 2]. The magnetic declination error consists of two components named magnetic variation and magnetic deviation according to the nautical terminology. The magnetic variation is the difference between the direction towards the magnetic North (magnetic bearing) and the true bearing towards the geographic North. The geographic North is situated at the North Pole, while the magnetic North position changes every year and is currently in the Bathurst Island, at a distance of 2200 km from the North Pole. The error introduced by the magnetic variation can be easily compensated since it is a known function of the position on the globe of the compass. The magnetic deviation error causes the compass bearing to differ from the magnetic bearing, and is due to the presence                Fig. 1. Reference and measurement coordinate frames. Proceedings of the 15th IFAC Symposium on System Identification Saint-Malo, France, July 6-8, 2009 978-3-902661-47-0/09/$20.00 © 2009 IFAC 1399 10.3182/20090706-3-FR-2004.0229