You could be low on freon which is telling the sensor/switch there isn't enough pressure in the system so its not sending power to the compressor.