Two Components Working Together
Though a diesel generator is a single device that functionally converts diesel fuel into electricity, it is, in essence, two separate devices that work together in order to produce power. A diesel engine burns diesel fuel in order to produce motion for the generator, which converts the motion into electricity by using electromagnets. The two components (the engine and the electromagnetic generator) are connected by a crankshaft, facilitating the easy transfer of the motion produced by the diesel engine to the magnets of the generator assembly.
Powering the Diesel Engine
The small internal combustion engine of a diesel generator operates just like any other small engine; though a number of fuels can be used to power similar engines, diesel is generally preferred for generators because of its ability to burn but not explode. The fuel tank of the diesel engine is filled, and the engine is started (sometimes with a key or automatic starter, though pull-start engines are quite common on diesel generators as well). A throttle and governor are used to keep the speed of the diesel engine under control in order to standardize the power output of the generator while also preventing damage to components that could be caused by the engine operating at too high of a speed.
As the diesel engine turns the crankshaft that connects to the generator, the central axle of the generator is spun within a chamber containing electromagnets. This high-speed motion causes an electric current to be produced, which is then available for use by any equipment that is plugged in to the diesel generator. The governor switch that helps to control the diesel engine's speed allows for increases in engine speed when the produced electricity is being used, leading to the engine revving up as needed in order to make sure that the amount of electricity provided by the diesel generator doesn't drop suddenly whenever plugged-in power tools or other electronic devices are in use.