The role of the piston is to transfer force, whether it is made of compressed air or oil, to the crankshaft. It does this by pushing the gas from one end of the piston rod to the opposing end. Compressed gas is used because it has natural characteristics to give the piston the volume it requires to be pushed and pulled. Without it, the piston would be rendered useless.
Pistons can also be used for pumps, but the mechanism works differently. Instead of transferring force to the crankshaft, the force is transferred from the crankshaft to the piston for the purpose of ejecting the fluid contained within the cylinder.
Oil is pumped through the end of the piston and, in turn, pushes the rod through the cylinder, thus creating a force to be exerted, depending upon the machine or engine. By controlling the amount of oil or air that is pumped through the valve, the accuracy of the force can be easily maneuvered. This movement or force is activated by the use of control valves that are positioned inside the cab of an earthmoving machine, where the driver's seat is positioned.
Pistons consist of piston rings, a seal that lines the outer edges of the piston. Piston rings prevent gas from leaking during compression and combustion, as well as preventing oil from leaking into the sump and causing it to burn and evaporate.