Yesterday in 1866, the U.S. Army adopted machine guns for the first time. Or, well, almost machine guns: the Gatling gun, first patented in 1862, wasn't fully mechanical. Someone still had to crank it by hand make the gun fire. In an era of warfare remembered for muskets and bayonets, the Gatling gun was a terrifying leap forward.
How it worked: The shooter turns a crank, which pushes a firing pin into a loaded, ready barrel at the top of the gun. When the firing pin sets off the bullet, the next barrel moves into place and the just-fired barrel moves toward the ground, where it drops the spent bullet casing. Then, the turning motion brings the barrel up to a hopper of ammunition, where the next shot is loaded into the barrel. A firing pin then connects with the bullet in the newly loaded barrel, and the gun fires. This happens for all six barrels, as fast as the crank can be turned-up to 200 shots per minute. (Here's a helpful animation of this process.)
Pictured above is the patent for an improved version of the gun made in 1865. This is the version first officially adopted by the U.S. Army, though technically not the first used. That distinction goes to the 1862 model. During the Civil War, Major General Benjamin Butler purchased a dozen for his forces and used them fighting near Petersburg, Va.
While Gatling guns didn't change the outcome of the Civil War (unlike some technology that certainly could have), they played a major part in the colonial wars of the next 50 years. During that time, the Maxim gun appeared, a true machine gun that replaced Gatling guns by the start of World War I.
Musing on the Maxim gun's role in colonial wars, British poet Hilaire Belloc quipped "Whatever happens, we have got / The Maxim gun, and they have not." The bloodiness of WWI, with tens of thousands dying in single days while charging machine guns, is in no small part a result of this evolution in weaponry.