TIDUF60 December 2023
The current through the motor is sampled by microcontroller as part of the motor control algorithm during every one PWM cycle. TMS320F2800137 daughter board supports 1-3 shunt current sensing, MSPM0G1507 daughterboard supports 1-2 shunt current sensing. To measure bidirectional currents of the motor phase, that is, positive and negative currents, the circuits below require a reference voltage of 1.65 V. This offset reference voltage is created by a voltage follower as shown in Figure 2-29.
Figure 2-30 shows how the motor current is represented as a voltage signal, with filtering, amplification, and offset to the center of the ADC input range for TMS320F2800137 daughterboard. This circuit is used for each phase of the 3-phase PMSM of compressor and fan. The transfer function of this circuit is given by Equation 52.
where
The calculated resistance values lead to the sensing circuit shown in Figure 2-36, Gi is given by Equation 53.
The maximum peak-to-peak current measurable by the microcontroller is given by Equation 54.
This has the peak-to-peak value of ±7.99 A. The following code snippet shows how this is defined for compressor motor in user_mtr1.h file:
//! \brief Defines the maximum current at the AD converter
#define USER_M1_ADC_FULL_SCALE_CURRENT_A (15.97f)
Correct polarity of the current feedback is also important so that the microcontroller has an accurate current measurement. In this hardware board configuration, the negative pin of the shunt resistor, which is connected to ground, is also connected to the inverting pin of the operational amplifier. The highlighted sign is required to be configured to have the correct polarity for the current feedback in software as shown in the following code snippet in user.mtr1.h:
// define the sign of current feedback based on hardware board
#define USER_M1_SIGN_CURRENT_SF (1.0f)
On the MSPM0 daughterboard, two shunt current sensing are implemented with the two high-end internal amplifiers to save system cost. The amplifier gain is also 4.132, and the cutoff frequency is 70 kHz. Figure 2-31 shows the two-shunt current sensing circuit for the MSPM0G1507 daughterboard.