Principle of measuring internal resistance of new energy batteries