The first
vending machine was also one of his constructions, when a coin was introduced via a slot on the top of the machine, a set amount of holy water was dispensed. This was included in his list of inventions in his book, "Mechanics and Optics". When the coin was deposited, it fell upon a pan attached to a lever. The lever opened up a valve which let some water flow out. The pan continued to tilt with the weight of the coin until it fell off, at which point a counter-weight would snap the lever back up and turn off the valve.
[9]