If the mechanical energy is instead converted to electricity , the machine is called a wind generator , wind turbine , wind power unit ( WPU ) , wind energy converter ( WEC ) , or aerogenerator . If the mechanical energy is used to produce electricity , the device may be called a wind generator or wind charger .