They drive atmospheric circulation. The sun does not heat the earth evenly. The parts that are heated up more form the low-pressure systems where air masses move in from high-pressure systems to form winds. These air masses are also deflected by Coriolis effect caused by earth’s rotation.