A method of regulating a current of a coil of a contactor, comprising: obtaining a first sample value of the current of the coil at a first moment, the first sample value being associated with a duty cycle of a PWM signal applied to a control end of a switch, and the switch being coupled in series with the coil; obtaining a second sample value of the current of the coil at a second moment; determining a difference value between the first and the second sample values; and updating the duty cycle of the PWM signal based on the difference value to regulate the current of the coil; the method further comprising: by means of an enable module coupled to a PWM generator; determining a duty cycle of the PWM generator based on the updated duty cycle and an enable signal of the enable module; by means of an analog comparator comprised by the enable module; receiving an actual current value of the coil and a preset target current value and output the enable signal based on the actual current value and the target current value; by means of a digital-to-analog converter coupled to the analog comparator: receiving a digital target current value; converting the digital target current value into an analog target current value; and transmitting the analog target current value to the analog comparator; and characterized in that, by means of a direct memory accessor coupled to the digital-to-analog converter: transmitting the digital target current value to the digital-to-analog converter. obtaining a first sample value of the current of the coil at a first moment, the first sample value being associated with a duty cycle of a PWM signal applied to a control end of a switch, and the switch being coupled in series with the coil; obtaining a second sample value of the current of the coil at a second moment; determining a difference value between the first and the second sample values; and updating the duty cycle of the PWM signal based on the difference value to regulate the current of the coil; the method further comprising: by means of an enable module coupled to a PWM generator; determining a duty cycle of the PWM generator based on the updated duty cycle and an enable signal of the enable module; by means of an analog comparator comprised by the enable module; receiving an actual current value of the coil and a preset target current value and output the enable signal based on the actual current value and the target current value; by means of a digital-to-analog converter coupled to the analog comparator: receiving a digital target current value; converting the digital target current value into an analog target current value; and transmitting the analog target current value to the analog comparator; and characterized in that, by means of a direct memory accessor coupled to the digital-to-analog converter: transmitting the digital target current value to the digital-to-analog converter. by means of an enable module coupled to a PWM generator; determining a duty cycle of the PWM generator based on the updated duty cycle and an enable signal of the enable module; by means of an analog comparator comprised by the enable module; receiving an actual current value of the coil and a preset target current value and output the enable signal based on the actual current value and the target current value; by means of a digital-to-analog converter coupled to the analog comparator: receiving a digital target current value; converting the digital target current value into an analog target current value; and transmitting the analog target current value to the analog comparator; and receiving a digital target current value; converting the digital target current value into an analog target current value; and transmitting the analog target current value to the analog comparator; and characterized in that, by means of a direct memory accessor coupled to the digital-to-analog converter: transmitting the digital target current value to the digital-to-analog converter. transmitting the digital target current value to the digital-to-analog converter.