scieee AI-readable full text Open interactive document viewer

Contactless Fault Detection of a DC Motor Direction of Rotation Using Its Stray Magnetic Field

Matějásko, Michal; Brablc, Martin; Appel, Martin; Grepl, Robert

Abstract

In large-scale manufacturing and assembly applications, especially when trying to automate most steps, implementing quality control as early in the process as possible is the key to prevent expenses later. We deal mainly with the production of DC motor powered fuel pumps, which are commonly used in the automotive industry. The goal of this paper is to present a newly developed technique for non-invasive fault detection of a DC motor’s direction of rotation using a stray magnetic field out of the motor chassis. The results presented in this paper show that it is possible to detect faults even on low-power motors while the algorithm is kept as simple as possible to allow for large-scale deployment on a production line. It also gives new insight into the behavior of the stray magnetic field of electric motors, which may benefit other applications and future research.

Full text

machines Article Contactless Fault Detection of a DC Motor Direction of Rotation Using Its Stray Magnetic Field Michal Matˇejásko, Martin Brablc * , Martin Appel and Robert Grepl   Citation: Matˇejásko, M.; Brablc, M.; Appel, M.; Grepl, R. Contactless Fault Detection of a DC Motor Direction of Rotation Using Its Stray Magnetic Field. Machines 2021,9, 281. https:// doi.org/10.3390/machines9110281 Academic Editor: Dan Zhang Received: 22 September 2021 Accepted: 5 November 2021 Published: 10 November 2021 Publisher’s Note: MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations. Copyright: © 2021 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https:// creativecommons.org/licenses/by/ 4.0/). Faculty of Mechanical Engineering, Brno University of Technology, Technická2, 61600 Brno, Czech Republic; [email protected] (M.M.); [email protected] (M.A.); [email protected].cz (R.G.) *Correspondence: [email protected] Abstract: In large-scale manufacturing and assembly applications, especially when trying to automate most steps, implementing quality control as early in the process as possible is the key to prevent expenses later. We deal mainly with the production of DC motor powered fuel pumps, which are commonly used in the automotive industry. The goal of this paper is to present a newly developed technique for non-invasive fault detection of a DC motor’s direction of rotation using a stray magnetic field out of the motor chassis. The results presented in this paper show that it is possible to detect faults even on low-power motors while the algorithm is kept as simple as possible to allow for large-scale deployment on a production line. It also gives new insight into the behavior of the stray magnetic field of electric motors, which may benefit other applications and future research. Keywords: fault detection; fault diagnosis; non-invasive; DC motor; direction of rotation; stray magnetic field; magnetic flux density; automation; fuel pump; automotive; manufacturing; quality control 1. Introduction The diagnosis of electrical motors out of their stray (escaping the chassis) magnetic field was up until recently focused mainly on large, high-power motors. The main reasons were the high field strength and the size of the motors. Therefore, a simple sensing coil with easily modifiable sensitivity could be used. With smaller motors, however, the magnetic field is physically changing at a smaller scale, which makes the measurement sensitive to the background, noise, size, and exact positioning of the sensing element and requires much more precise measurement techniques. This applies to the whole dynamics of the motor and makes all measurements, control, and parameter analysis harder [ 1 , 2 ]. It follows that these kinds of external diagnosis methods would be beneficial over classical invasive approaches for diagnosis and fault detection, which require disassembly or dedicated internal sensors. Due to the miniaturization advances in sensors and microelectronics, the diagnostic of small electrical motors comes into the scientific and engineering focus as it became technologically feasible. With the progress in further automation of manufacturing processes comes the need to invent new diagnostic methods that will be easily applicable on a production line in an automated way. During the last decade, the main research focus was put on three-phase motors, which can be seen from the research conducted in the field of fault diagnostics [ 3 – 5 ]. Given the sinusoidal character of the magnetic fields, the most dominant method used is the analysis of the magnetic field in the frequency domain. Less attention is paid to small inductive motors [ 6 ] or electrically commutated Permanent Magnet Synchronous Motors (PMSM) [ 7 ]. However, we were unable to find any relevant publication in the fault diagnostics out of the stray magnetic field for direct current (DC) brushed motors. It appears that little to no attention is paid to this topic, though there is a need in the industry for further advances. Among the most examined phenomena are short-circuits in a defective winding [ 4 , 8 , 9 ] or the influence of load changes [ 10 , 11 ]. Recent experiments with the use of the stray field for BLDC motor commutation under varying load torque can be found in [12,13]. Machines 2021,9, 281. https://doi.org/10.3390/machines9110281 https://www.mdpi.com/journal/machines Machines 2021,9, 281 2 of 13 One of the problems at hand is the detection of the rotation direction of small DC motors. These types of motors are cheap to manufacture and find their use in a wide variety of products. Though cheap, there are products in which the replacement of a faulty motor can lead to excessive expenses. One such example can be a fuel pump used in combustion engine cars. Once built into a fuel tank and installed in a car coming out of the production line, finding a faulty piece comes with high costs. Yet, incorrect direction rotation caused by swapped wiring is a common manufacturing fault. There exists an industrial sensor capable of detecting the rotation direction of a brushed DC motor based on the measurement of changes of the stray magnetic field escaping from the gaps between stator magnets. However, the results from the sensor are highly dependent on the exact position of the sensor, which might not lead to a reliable solution to the problem. Existing diagnosis methods, which utilize the stray magnetic field of a motor, can be divided into two basic subgroups of model-based and data-driven methods [ 3 , 7 ]. The model-based methods work based on a dynamic model of the system, which predicts its behavior and compares the predictions with measured data. The data-driven methods, on the contrary, compare the measurements with previously measured data, which are known to represent specific correct or faulty states of the diagnosed system. While both approaches have their advantages and disadvantages, this paper deals primarily with the data-driven approaches. The goal of this work is to develop and experimentally verify a novel method of the DC motor rotation direction detection using an affordable magnetic flux density sensor, while automating the process of the magnetic field analysis and at the same time locating a suitable position for the sensor during the measurement of a given motor. To the best of our knowledge, no similar experimental work has been conducted in the field of the detection of the rotation direction out of the stray magnetic field. From the research in scientific publications, it seems that the problem of analysis of small direct current motors out of their stray magnetic field receives little attention from researchers. Existing Sensor for Detection of the Rotation Direction Only a few sensors for the detection of rotation direction out of the stray magnetic field of a brushed electric motor exist, mainly produced by German company Process Control Electronic GmbH [14]. One of the sensors can be seen in Figure 1. The rotation direction sensors can be used with three-phase AC or brushed DC motors. For the purpose of this article, only the latter variant will be considered further. The measurement is very simple, as the sensor compares the values of magnetic flux density before and while supplying the motor, effectively comparing the average values of the static field with the average value of the rotating field. The sensor must be placed within a given proximity to the gap between stator magnets and with a given orientation (there are more construction variants for different sensor orientations) [15]. There is a magnetic field escaping the motor’s body from the gap between the stator magnets. In this area, the stray magnetic flux density is the strongest. However, the magnetic field lines diverge on both sides along with the motor housing, to subsequently close in the gap between the stator magnets on the other side of the motor (see section Experimental Results for more details). Machines 2021,9, 281 3 of 13 Machines 2021, 9, x FOR PEER REVIEW 3 of 13 Figure 1. Commercially available sensor DRH 090 (Reprinted with permission from ref. [15]. 2021 PCE Process Control Electronic GmbH). There is a magnetic field escaping the motor’s body from the gap between the stator magnets. In this area, the stray magnetic flux density is the strongest. However, the magnetic field lines diverge on both sides along with the motor housing, to subsequently close in the gap between the stator magnets on the other side of the motor (see section Experimental Results for more details). 2. Detecting the Rotation Direction of a Brushed DC Motor Based on our experience from previous experiments, we proposed a novel, non-in- vasive method that can detect the rotation direction of a DC motor shaft based on the measurement of its stray magnetic field, which would be simple enough to be easily implemented in industrial applications. As the method is data-based, it requires a reference measurement of the correct state of the motor. All required measurements can be done using a 3-axis magnetic flux density sensor with suitable range and sampling. In the following text, by “taking a measurement” we mean: • Placing the sensor in a suitable location (explained further in the following sections) within near proximity of the motor chassis. • Applying voltage to the motor and letting the angular velocity of the rotor stabilize. • Measuring the level of magnetic flux density. As it is expected to oscillate around a certain value due to the motor construction, it is preferable to take the average value from a high frequency sampling over a longer period to filter out these oscillations, noise, and the effects of coil commutation. • All measurements are taken with the same voltage level applied to the motor either with positive or negative polarity. The voltage level needs to be chosen such that the motor is spinning as fast as possible, while not posing a risk of causing damage to the motor in either direction. 2.1. Reference Image Before the application of the diagnostic technique in a large-scale manufacturing process, we need to acquire the reference image of the magnetic flux difference vector 𝒃 according to Equation (1). Figure 1. Commercially available sensor DRH 090 (Reprinted with permission from ref. [ 15 ]. 2021 PCE Process Control Electronic GmbH). 2. Detecting the Rotation Direction of a Brushed DC Motor Based on our experience from previous experiments, we proposed a novel, noninvasive method that can detect the rotation direction of a DC motor shaft based on the measurement of its stray magnetic field, which would be simple enough to be easily implemented in industrial applications. As the method is data-based, it requires a reference measurement of the correct state of the motor. All required measurements can be done using a 3-axis magnetic flux density sensor with suitable range and sampling. In the following text, by “taking a measurement” we mean: • Placing the sensor in a suitable location (explained further in the following sections) within near proximity of the motor chassis. •Applying voltage to the motor and letting the angular velocity of the rotor stabilize. • Measuring the level of magnetic flux density. As it is expected to oscillate around a certain value due to the motor construction, it is preferable to take the average value from a high frequency sampling over a longer period to filter out these oscillations, noise, and the effects of coil commutation. • All measurements are taken with the same voltage level applied to the motor either with positive or negative polarity. The voltage level needs to be chosen such that the motor is spinning as fast as possible, while not posing a risk of causing damage to the motor in either direction. 2.1. Reference Image Before the application of the diagnostic technique in a large-scale manufacturing process, we need to acquire the reference image of the magnetic flux difference vector bre f according to Equation (1). bre f =pre f −nre f , (1) where pre f (T) is the magnetic flux density measured with positive voltage applied to the motor and with the shaft rotating in the correct direction, and nre f (T) is the magnetic flux density with negative voltage applied to the motor and with the shaft rotating in the incorrect direction, meaning the pre f and nre f represent the OK and NOK states of the motor, respectively. Machines 2021,9, 281 4 of 13 2.2. Application Later, when the method is applied to test a newly manufactured motor for correct direction of rotation, again take the p and n measurements for the testing. Calculate the difference vector b according to Equation (2), this time not knowing whether the motor is wired correctly and therefore is spinning in the correct direction or not. b=p−n, (2) To diagnose if the motor is in the OK or the NOK state, we use the cosine of the angle between the reference vector bre f and the measured b , computed according to Equation (3). cos(ϕ)=bre f ·b kbre f kkbk(3) If we choose a threshold value K (we suggest K=√2/ 2, corresponding to 45 ◦ ), three outcomes are possible: •cos(ϕ)>K⇒motor is OK. •cos(ϕ)<−K⇒motor is NOK. • −K<cos(ϕ)<K⇒ the result cannot be determined, and the process should be repeated. The magnetic flux density measured outside the motor chassis consists mainly of two parts: the static magnetic field induced by the stator magnets and the background, and the magnetic field induced by the rotor coils. The static part does not change with the rotation direction, but the rotor-induced part does. In theory, since we are subtracting the vectors for both rotation directions (eliminating the static field), the difference vector b should point in the same direction as the reference vector bre f if the motor is OK and directly in the opposite direction if the motor is NOK, which makes this approach less sensitive to noise and other corrupting factors. Advantages of the proposed method are: •Very simple in principle and execution. • The influence of background magnetic induction is negated, assuming it is static during the measurement. •The result and measurement values have a clear physical dimension. •Robust evaluation of the result. Disadvantages of the proposed method can be: •The requirement of knowing the reference vector bre f for the result evaluation. •Sensitive to unstable magnetic background. •Proper measurement location needs to be determined. 2.3. Optimal Measurement Location The proposed method of detection of the rotation direction strongly depends on the exact location chosen for the taking of the measurements. As it relies on the reference vector bre f , the only criteria suitable to choose the correct location is its length kbre f k . To acquire some insights on how to choose the measurement location for a specific motor and to put the method to a test, we developed custom measuring equipment and measured the stray magnetic field surrounding a fuel pump DC motor, which is covered in the following sections. 3. Experimental Setup To conduct the experiment, we used a Universal Robots UR10e [ 16 ] collaborative robot. It is a 6 DOF manipulator for a wide range of automated applications, with an option of TCP/IP interface, that can be used to control the robotic arm. It enabled the fast Machines 2021,9, 281 5 of 13 development of a measurement station suiting the needs of a three-dimensional magnetic field measurement around an electric motor. To take the measurements of the stray magnetic flux density in a cylindrical envelope surrounding the measured motor simple for the robotic arm, a plastic holder for sensors was prototyped and 3D printed (see Figure 2). This also kept the electromagnetic noise emerging from the motors of the robot to a minimum. The experimental setup consisted of: •UR10e 6-DOF robotic arm, •small PCB with 4 Hall-effect sensors in 2 ×2 matrix, •dsPIC MCU, and •host PC. Machines 2021, 9, x FOR PEER REVIEW 5 of 13 and to put the method to a test, we developed custom measuring equipment and measured the stray magnetic field surrounding a fuel pump DC motor, which is covered in the following sections. 3. Experimental Setup To conduct the experiment, we used a Universal Robots UR10e [16] collaborative robot. It is a 6 DOF manipulator for a wide range of automated applications, with an option of TCP/IP interface, that can be used to control the robotic arm. It enabled the fast development of a measurement station suiting the needs of a three-dimensional magnetic field measurement around an electric motor. To take the measurements of the stray magnetic flux density in a cylindrical envelope surrounding the measured motor simple for the robotic arm, a plastic holder for sensors was prototyped and 3D printed (see Figure 2). This also kept the electromagnetic noise emerging from the motors of the robot to a minimum. The experimental setup consisted of: • UR10e 6-DOF robotic arm, • small PCB with 4 Hall-effect sensors in 2 × 2 matrix, • dsPIC MCU, and • host PC. Figure 2. UR10e robotic arm during the experimental measurement with a small DC brushed motor. 3.1. Sensors Three-axis Hall-effect sensor MLX90393 [17,18], which has a schematic depicted in Figure 3, was chosen as the sensing element, mainly for its high sensitivity and compactness. It is an integrated circuit sensor with a high dynamic range (5–50 mT), configurable sampling frequency (from 259 µs to 66.6 ms conversion time for a single axis), and high sensitivity (0.161 µT/LSB for x, y-axis, and 0.294 µT/LSB for z axis) that allows for measurements with a wide range of motor sizes. Internally, the sensor senses the Hall-effect voltage on 3 elements, each effective in one axis. The signals are amplified and digitalized with internal ADC and stored in internal 16-bit registers. The sensor also comes with many customizable settings, such as onboard filtering, different acquisition triggering modes, adjustable sampling rate, or single Figure 2. UR10e robotic arm during the experimental measurement with a small DC brushed motor. 3.1. Sensors Three-axis Hall-effect sensor MLX90393 [ 17 , 18 ], which has a schematic depicted in Figure 3 , was chosen as the sensing element, mainly for its high sensitivity and compactness. It is an integrated circuit sensor with a high dynamic range (5–50 mT), configurable sampling frequency (from 259 µ s to 66.6 ms conversion time for a single axis), and high sensitivity (0.161 µ T/LSB for x,y-axis, and 0.294 µ T/LSB for zaxis) that allows for measurements with a wide range of motor sizes. Internally, the sensor senses the Hall-effect voltage on 3 elements, each effective in one axis. The signals are amplified and digitalized with internal ADC and stored in internal 16-bit registers. The sensor also comes with many customizable settings, such as on-board filtering, different acquisition triggering modes, adjustable sampling rate, or single measurement mode. Thanks to these features, it can be fine-tuned to best serve the intended application. Machines 2021,9, 281 6 of 13 Machines 2021, 9, x FOR PEER REVIEW 6 of 13 measurement mode. Thanks to these features, it can be fine-tuned to best serve the intended application. Figure 3. General block diagram of MLX90393 integrated circuit sensor. For the purposes of our application, we used the I2C interface, which comes with the additional benefit of having multiple sensors on the same bus, thanks to the possibility of changing the device’s address by defining the logical level of A0 and A1 pins. The sensitivity of the sensor was set to maximum (0.161 µT/LSB for x, y-axis, and 0.294 µT/LSB for z axis) with the output data rate set to 493 Hz, which translates to 1.84 ms conversion time for all 3 magnetic flux density axes. As the setting of the used sensor is not trivial, please refer to the datasheet [18] for specific timing, sensitivity, and sampling options available. 3.2. Software The measurements were controlled by a custom-made MATLAB script with the use of MATLAB Toolbox for UR Manipulators developed at the United States Naval Academy [19]. The toolbox consists of MATLAB functions for controlling the robot and of a local server service written in Python, that provides a communication interface between MATLAB and the UR10e through a TCP/IP connection. Measurement Procedure For each measurement, the MATLAB script generates a new set of cylindrical coordinates αRZ (the center of the coordinate system is placed in the motor axis of rotation), and a corresponding set of joint coordinates for the robotic arm. The measurement was conducted in the following ranges: • α < 0°; 360° > with 1° step, • R < 60 mm; 80 mm > with 5 mm step, • Z < 0 mm; 120 mm > with 5 mm step. After running the control script and thus starting the measurement process, the coordinates for the next measurement point are sent to the manipulator and when the position is reached, a command to take a single measurement is sent to the sensors. The measured values are read-out by the MCU and sent via UART-USB to the host PC. The control script reads the data and stores them in the workspace. This sequence is repeated for the complete measurement procedure, i.e., for all the measurement points. In each measurement point, data from four sensors in all three axes were acquired at the same time (see the experimental setup schematic in Figure 4). In the results section below, the data presented are a mean value from all four sensors in every given measurement point. Figure 3. General block diagram of MLX90393 integrated circuit sensor. For the purposes of our application, we used the I2C interface, which comes with the additional benefit of having multiple sensors on the same bus, thanks to the possibility of changing the device’s address by defining the logical level of A0 and A1 pins. The sensitivity of the sensor was set to maximum (0.161 µ T/LSB for x,y-axis, and 0.294 µ T/LSB for zaxis) with the output data rate set to 493 Hz, which translates to 1.84 ms conversion time for all 3 magnetic flux density axes. As the setting of the used sensor is not trivial, please refer to the datasheet [ 18 ] for specific timing, sensitivity, and sampling options available. 3.2. Software The measurements were controlled by a custom-made MATLAB script with the use of MATLAB Toolbox for UR Manipulators developed at the United States Naval Academy [ 19 ]. The toolbox consists of MATLAB functions for controlling the robot and of a local server service written in Python, that provides a communication interface between MATLAB and the UR10e through a TCP/IP connection. Measurement Procedure For each measurement, the MATLAB script generates a new set of cylindrical coordinates α RZ (the center of the coordinate system is placed in the motor axis of rotation), and a corresponding set of joint coordinates for the robotic arm. The measurement was conducted in the following ranges: •α< 0◦; 360◦> with 1◦step, •R < 60 mm; 80 mm > with 5 mm step, •Z < 0 mm; 120 mm > with 5 mm step. After running the control script and thus starting the measurement process, the coordinates for the next measurement point are sent to the manipulator and when the position is reached, a command to take a single measurement is sent to the sensors. The measured values are read-out by the MCU and sent via UART-USB to the host PC. The control script reads the data and stores them in the workspace. This sequence is repeated for the complete measurement procedure, i.e., for all the measurement points. In each measurement point, data from four sensors in all three axes were acquired at the same time (see the experimental setup schematic in Figure 4). In the results section below, the data presented are a mean value from all four sensors in every given measurement point. Machines 2021,9, 281 7 of 13 Machines 2021, 9, x FOR PEER REVIEW 7 of 13 Figure 4. Experimental setup schematic. 4. Results 4.1. Experimental Results The series of measurements were conducted with a 2-pole, DC brushed motor with permanent stator magnets. The motor type that was measured, shown in Figure 5, is commonly used in fuel pumps in the automotive industry. The dimensions of the motor are d = 38 mm, l = 87 mm, with a rated nominal supply of 12 V. For the experiment, supply voltage of +/− 5 V was applied, leading to 1420 RPM of the motor. Figure 5. Measured motor in a printed plastic holder. At first, we looked at the magnetic flux density escaping the measured motor chassis (low pass filtered with the sensor used), while the motor was running at a constant speed, in both directions. The correct rotation direction is marked as OK and the opposite direction as NOK. For visual simplification, the measured data are presented in 3 horizontal planes (z-axis) and from 3 radiuses (60, 65, 70 mm). The MATLAB function quiver3 was used to produce vectors with automatic scaling turned on. Therefore, the size of the vectors represents their relative amplitude in each given plot, not the absolute measured values. The goal of the following figures is to understand the field orientation, not its magnitude in the measured points. Figure 4. Experimental setup schematic. 4. Results 4.1. Experimental Results The series of measurements were conducted with a 2-pole, DC brushed motor with permanent stator magnets. The motor type that was measured, shown in Figure 5, is commonly used in fuel pumps in the automotive industry. The dimensions of the motor are d= 38 mm, l= 87 mm, with a rated nominal supply of 12 V. For the experiment, supply voltage of +/−5 V was applied, leading to 1420 RPM of the motor. Machines 2021, 9, x FOR PEER REVIEW 7 of 13 Figure 4. Experimental setup schematic. 4. Results 4.1. Experimental Results The series of measurements were conducted with a 2-pole, DC brushed motor with permanent stator magnets. The motor type that was measured, shown in Figure 5, is commonly used in fuel pumps in the automotive industry. The dimensions of the motor are d = 38 mm, l = 87 mm, with a rated nominal supply of 12 V. For the experiment, supply voltage of +/− 5 V was applied, leading to 1420 RPM of the motor. Figure 5. Measured motor in a printed plastic holder. At first, we looked at the magnetic flux density escaping the measured motor chassis (low pass filtered with the sensor used), while the motor was running at a constant speed, in both directions. The correct rotation direction is marked as OK and the opposite direction as NOK. For visual simplification, the measured data are presented in 3 horizontal planes (z-axis) and from 3 radiuses (60, 65, 70 mm). The MATLAB function quiver3 was used to produce vectors with automatic scaling turned on. Therefore, the size of the vectors represents their relative amplitude in each given plot, not the absolute measured values. The goal of the following figures is to understand the field orientation, not its magnitude in the measured points. Figure 5. Measured motor in a printed plastic holder. At first, we looked at the magnetic flux density escaping the measured motor chassis (low pass filtered with the sensor used), while the motor was running at a constant speed, in both directions. The correct rotation direction is marked as OK and the opposite direction as NOK. For visual simplification, the measured data are presented in 3 horizontal planes (z-axis) and from 3 radiuses (60, 65, 70 mm). The MATLAB function quiver3 was used to produce vectors with automatic scaling turned on. Therefore, the size of the vectors represents their relative amplitude in each given plot, not the absolute measured values. The goal of the following figures is to understand the field orientation, not its magnitude in the measured points. Machines 2021,9, 281 8 of 13 As can be observed from the above Figure 6, both magnetic fields appear to be strongly similar in their orientations. Looking into the measurement data points, it appears that the amplitudes of the vectors for OK and NOK rotation directions magnetic fields are also similar. However, a shift between the measured fields can be noticed. Machines 2021, 9, x FOR PEER REVIEW 8 of 13 As can be observed from the above Figure 6, both magnetic fields appear to be strongly similar in their orientations. Looking into the measurement data points, it appears that the amplitudes of the vectors for OK and NOK rotation directions magnetic fields are also similar. However, a shift between the measured fields can be noticed. Figure 6. Stray magnetic field orientation in 3 horizontal planes, for the OK (blue) and NOK (red) rotation directions, for R = 60 mm. By calculating and visualizing the vector field of the reference vector 𝒃(α,R,Z), the information about the rotation direction is revealed in Figures 7 and 8. Figure 7. Stray magnetic field orientation in 3 horizontal planes, for the difference vector (𝒃) between both rotation directions. Figure 6. Stray magnetic field orientation in 3 horizontal planes, for the OK (blue) and NOK (red) rotation directions, for R = 60 mm. By calculating and visualizing the vector field of the reference vector bre f (α, R, Z) , the information about the rotation direction is revealed in Figures 7and 8. Machines 2021, 9, x FOR PEER REVIEW 8 of 13 As can be observed from the above Figure 6, both magnetic fields appear to be strongly similar in their orientations. Looking into the measurement data points, it appears that the amplitudes of the vectors for OK and NOK rotation directions magnetic fields are also similar. However, a shift between the measured fields can be noticed. Figure 6. Stray magnetic field orientation in 3 horizontal planes, for the OK (blue) and NOK (red) rotation directions, for R = 60 mm. By calculating and visualizing the vector field of the reference vector 𝒃(α,R,Z), the information about the rotation direction is revealed in Figures 7 and 8. Figure 7. Stray magnetic field orientation in 3 horizontal planes, for the difference vector (𝒃) between both rotation directions. Figure 7. Stray magnetic field orientation in 3 horizontal planes, for the difference vector ( bre f ) between both rotation directions. 4.2. Choosing Optimal Measurement Point As was stated earlier, the suitability of the measurement locations for the algorithm application can be determined from the size of reference vector bre f . Figure 9visualizes the scalar field kbre f (α, Z, R)k at constant radius R= 60 mm . The field clearly reveals one Machines 2021,9, 281 9 of 13 location, corresponding with one of the gaps between stator magnets, which is much more suitable for direction detection. Machines 2021, 9, x FOR PEER REVIEW 9 of 13 Figure 8. Differential vector field in 3D perspective for R = 60 mm. 4.2. Choosing Optimal Measurement Point As was stated earlier, the suitability of the measurement locations for the algorithm application can be determined from the size of reference vector 𝒃. Figure 9 visualizes the scalar field 𝒃(α,Z,R) at constant radius R = 60 mm. The field clearly reveals one location, corresponding with one of the gaps between stator magnets, which is much more suitable for direction detection. Figure 9. Scalar field of the differential vector size 𝒃(α,Z,R) size in the motor surroundings. R = 60 mm. Figure 8. Differential vector field in 3D perspective for R = 60 mm. Machines 2021, 9, x FOR PEER REVIEW 9 of 13 Figure 8. Differential vector field in 3D perspective for R = 60 mm. 4.2. Choosing Optimal Measurement Point As was stated earlier, the suitability of the measurement locations for the algorithm application can be determined from the size of reference vector 𝒃. Figure 9 visualizes the scalar field 𝒃(α,Z,R) at constant radius R = 60 mm. The field clearly reveals one location, corresponding with one of the gaps between stator magnets, which is much more suitable for direction detection. Figure 9. Scalar field of the differential vector size 𝒃(α,Z,R) size in the motor surroundings. R = 60 mm. Figure 9. Scalar field of the differential vector size kbre f (α, Z, R)k size in the motor surroundings. R = 60 mm. 4.3. Application of the Proposed Method in the Chosen Area We obtained a reference differential vector field bre f (α, Z, R) and discovered the most suitable area for a measurement from the noise tolerance and result reliability points of view. From Figure 9, it is apparent that this area can be found at around Alpha = 360 ◦ and z= 0.05 m. Another motor of the same type was set for a measurement with the goal of determining in which direction the motor rotates. To demonstrate the robustness of the method, a motor that is built into a plastic fuel module was chosen—see Figure 10.