In the course of a system design which uses a magnetic sensor for current sensing, it is important to know the magnitude of the magnetic field generated around a current-carrying trace. In this case, the designer will need to simulate the magnetic field with the help of an appropriate simulation tool.
The correct implementation of contactless current sensing draws on detailed information about the way the magnetic flux vector forms around the current-conducting material. The direction and magnitude of the flux vectors – which follow the super-positioning rule – are highly dependent on the shape of the current-carrying conductor.
The general formula for calculating the magnitude of a magnetic field, and the right-hand rule for determining the direction of the magnetic vector, assume the current is carried through a very long and narrow, one-dimensional wire. This simple assumption is often good enough for engineering work. But if more accurate data are needed, then a more complex computation based on 2D or 3D simulation is required.
To explain the method, this Design Note presents a 2D simulation of the magnetic field around a current-carrying trace on a PCB. A knowledge of magnetic field simulation will help the designer to better understand the approach to differential current sensing, which may be implemented with sensors from Crocus Technology such as the CTSR215V-IS4, CTSR218V-IS4 or CTSR222V-IS4.
Use of a simulation tool
The main goal of this simulation is to solve for the field vectors of the induced magnetic field around a flat, narrow and thin current-carrying trace. For this purpose, the QuickFields 6.0 Student Edition software was used: it can provide a 2D analysis of induced magnetic fields. The user sets values for various parameters based on the environment to be simulated, and then calculates the direction and magnitude of the magnetic field.
The magnitude of a magnetic flux, B, generated by the current, I, in a straight and long wire at a distance, r, from the wire is expressed by Ampere’s equation:
In this equation, μ0 is the permeability of the medium. The direction of the field B’s vector is given by the familiar right-hand rule.
The Crocus application note, AN103: General Current Sensing, explains the principle of contactless current sensing with a Crocus IC. The aim is to locate a magnetic sensor at a very short distance from a current-carrying trace on the PCB.
The case described in this application note uses the PCB itself as the insulator between the sensor and the current-carrying trace. In this case, the magnetic sensor is mounted on top of the PCB with the current-carrying trace located exactly under the sensor but on the other side of the PCB. The dimensions applied in this simulation are shown in Table 1.
|Relative permeability of air||1.00000037|
|Relative permeability of PCB||1|
|Relative permeability of chip||1|
|Relative permeability of copper||0.999994|
The permeability of the different materials is shown in Table 2.
The final step is to define the simulation environment. The physical setup has a current-carrying trace on the bottom side of the PCB located exactly under the sensor package located on the top side of the PCB. This set-up is shown in Figure 1. The current in this simulation comes out of the page, and has a magnitude of 10A DC.
The second example involves two sensors and two traces as shown in Figure 2.
The distance between the two current-carrying traces in Figure 2 is 14mm from centre to centre; the current is coming out of the page for the current trace on the left, and is going into the page for the current trace on the right. In both cases, the current is 10A DC.
The results of the simulation
The simulation result for the first example is shown in Figure 3. The thin blue line indicates the profile of the PCB with the sensor on the top and the trace on the bottom. If we consider that the sensing die is located approximately in the middle of the package, then we can see that the flux vector in the active sensing area of the chip is horizontal and, in this case, pointing to the left. Another important insight is that lines showing where the magnetic field has the same magnitude follow the shape of the trace – that is, they are not concentric circles.
The result of the second simulation is shown in Figure 4. It shows that the direction of the magnetic vector is determined by the current flow, since the magnetic field on the left is in the opposite direction to the magnetic field on the right. And again, the contours showing where the magnetic field has the same magnitude follow the shape of the trace on the PCB.
One can also see that the magnetic flux density in the area between the two traces is very low (less than 0.3фB) when the two traces are placed far from each other. This simulation shows that the two traces will have a negligible effect on each other as long as there is enough distance between them.
The interesting question then is: how does the magnetic field emanating from a trace on the PCB compare to the field emanating from a linear conductor carrying the same current? To answer this question, the ratio of the magnitude of the magnetic field for a trace to the magnitude of the field for a linear circular conductor, as a function of distance, is shown in Figure 5.
As one would expect, the magnetic field in both cases decreases with distance. But the magnetic field in the case of the trace is much lower when the sensor is very close to the conductor. The difference in the magnitude of the magnetic fields of the current-carrying trace and the linear conductor is negligible at a distance of around 2mm and more.
Simulation results show that, in the case of a conducting trace, the shape of the magnetic field follows the shape of the trace. Also, a wider trace generates a weaker magnetic field close to the surface of the trace.
This is a design challenge that needs to be taken into account when designing a PCB for a current-sensing application. Clearly, the wider the trace the lower the current density, thus the weaker the magnetic field. At a certain distance, typically several millimetres, from the surface of the trace carrying the current, however, the magnitude of the magnetic field can be estimated rather accurately by using Ampere’s equation for a linear conductor.