SPRADA5 April   2024 TMS320F28P550SJ , TMS320F28P559SJ-Q1

 

  1.   1
  2.   Abstract
  3.   Trademarks
  4. 1Introduction
    1. 1.1 Supplementary Information
    2. 1.2 Features
    3. 1.3 Block Diagram
    4. 1.4 Operation Modes
  5. 2Use Cases
    1. 2.1 Buffer Mode for High-Impedance Source
    2. 2.2 Battery Voltage and Current Monitoring
    3. 2.3 Low-Side Shunt Current Monitoring
    4. 2.4 Three-Phase Low-Side Current Sensing
    5. 2.5 Bidirectional Current Sensing
    6. 2.6 Non-Inverting Amplifier for Low-Voltage Sensors
    7. 2.7 Non-Inverting Amplifier for Bipolar Signals
    8. 2.8 Standalone Mode for Various Applications
  6. 3Summary
  7. 4References

Low-Side Shunt Current Monitoring

Accurately and quickly detecting load current through a low-side shunt resistor is crucial for various applications such as over-current protection, faster feedback control loops, and battery and power supply monitoring. In low-side current sensing, the sensing resistor is positioned between the load and the ground. The sensing resistor has a low value to prevent obstructing the current flow, resulting in a correspondingly small voltage drop. However, to facilitate upstream conversion by an analog-to-digital converter (ADC), the small voltage across the shunt resistor usually needs to be amplified from tens or hundreds of millivolts to tenths of a volt or even volts. This amplification allows the ADC to measure and process the current information accurately. The PGA module can perform this task.

In Figure 2-6, a scheme of the low-side current sensing in a high-frequency MOSFET leg using a PGA module is depicted. Even though Type-1 PGA supports the low-side current sensing, using Type-2 PGA helps save a pin to use for other functions, such as ADC pin and digital inputs and outputs (AGPIO).

To optimize the current-sensing signal chain, it is crucial to appropriately select the shunt-resistor value and amplifier gain based on the current range and full-scale input range of the ADC. Choosing the right shunt resistor values involves finding the right balance between measurement accuracy and power dissipation across the shunt resistor. If a large-value shunt resistor is used, the resistor can develop a larger differential voltage as current flows through the resistor, resulting in smaller measurement errors due to the fixed amplifier offset voltage. However, a larger signal also creates a larger power dissipation across the shunt resistor, which can pose a challenge to the power dissipation requirement.

Additionally, using smaller shunt resistor values results in a smaller voltage drop across the shunt resistor, which reduces the power dissipation requirements. However, this can also lead to increased measurement errors, as the amplifier's fixed offset errors become a more significant percentage of the signal.

If you want to implement low-pass filtering in your circuit to remove any high-frequency noise, you can combine an external capacitor with the internal filter resistors RFILT. To implement this, you must connect an external capacitor to the output pin of the PGA module. This combination of the external capacitor and internal filter resistors can create a low-pass filter that allows low-frequency signals to pass through while attenuating high-frequency signals.

The same principle applies to selecting amplifier gain, which must be chosen in such a way as to maximize measurement accuracy while minimizing noise.

GUID-20230425-SS0I-CLZC-PQBQ-JKWX014GJTK7-low.svg Figure 2-6 Shunt Current Measurement Using a PGA Module

In the circuit shown in Figure 2-6, the amplifier gain is set by the ratio of Rib divided by Ria. If the divider resisters R1=Rib and R2=Ria, then the amplified voltage can be calculated by Equation 5.

Equation 3. V P G A _ O U T = R i b R i a ( R s h u n t I l o a d )

The filter cutoff frequency is estimated using Equation 4.

Equation 4. f c u t o f f = 1 2 π R F I L T C F I L T E R

If you want to adjust the gain value using the internal gain resistors Ria and Rib, as well as select an appropriate filter resistor RFILT, you can add the following custom code snippet.

//
// Gain
//
#define PGA_GAINVALUE PGA_GAIN_4
//
// Filter Resistor
//
#define PGA_FILTERVALUE PGA_LOW_PASS_FILTER_RESISTOR_50_OHM

//
// P-MUX selection
//
#define PGA_PMUXINPUT PGA_PMUX_POS 

//
// N-MUX selection
//
#define PGA_NMUXINPUT PGA_NMUX_RTAP

//
// M-MUX selection
//
#define PGA_MMUXINPUT PGA_MMUX_NON_INVERTING_GAIN_VSSA

In the code snippet, PGA_GAINVALUE represents the desired gain value for the PGA module, and PGA_FILTERVALUE represents the desired value for the filter resistor RFILT. Please make sure to consult the documentation or reference manual for your specific device to find the available RFILT and gain values, and then replace PGA_GAINVALUE and PGA_FILTERVALUE with the actual values you want to use in your circuit.