The invention provides a temperature sensor applied to a metering ammeter. The temperature sensor comprises an analog circuit portion, a digital circuit portion and a user ARM portion. The analog circuit portion comprises a positive temperature coefficient current generator in direct-proportion current bias with an absolute temperature, a bias current mirror array, a low-temperature drift coefficient reference current source, a temperature-sensitive transistor and an analog-to-digital conversion integrator. The digital circuit portion comprises a switch control logic, a digital code output, a digital counter and a shift register. The analog-to-digital conversion integrator has a sampling capacitor and an integrating capacitor, of which the capacitance is same; and bias current of the temperature-sensitive transistor is biased by six unit current mirrors in turns in a proportion of 5:1. According to a temperature trimming method for the temperature sensor, the number of the bias current mirrors is 6, wherein 5 paths of currents are used for coarse tuning, and the other one path of current is used for fine tuning; when the output bias of the counter is relatively large, the 5 paths of coarse-tuning currents are used; and when the output of the counter is between the two paths of unit currents, fine tuning is used.