Wait for the wisest of all counselors, time.
The mathematician and engineer Heron (also known as Hero) of Alexandria, Egypt, (Greek: Ἥρων ὁ Ἀλεξανδρεύς) is considered the greatest experimenter of antiquity and representer of the Roman and Hellenistic scientific tradition. Much of Heron’s original manuscripts and designs have been lost (he wrote at least 13 books), but fortunately, some of his works were preserved mainly in Arabic manuscripts.
Heron (c. 10–70 AD) was most probably of Greek origin, although a few historians believe that he was Babylonian or Mesopotamian. From his writings, it is reasonable to deduce that he taught at the Museum in Alexandria, which included the famous Library of Alexandria. Admittedly some of Heron’s ideas were derived from the earlier works of Ctesibius of Alexandria, Philon of Byzantion, and Archimedes.
Survived to the present works of Heron are:
1. Metrica—Three books for the determination of areas and volume of objectives.
2. Pneumatica (Spiritalia)—Two books, a collection of around 80 mechanical apparatus, that work with air, steam, or hydraulic pressure.
3. Belopoeica—A collection of war machines (artillery).
4. Mechanica—Three books on how to move heavy objects using gears, winches, pulleys, screws, wedges, levers, cranes, and sledges.
5. Dioptra—Practical and mathematical methods for land surveying. It also included information about the Dioptra, the forerunner of the modern theodolite, which allowed surveyors to calculate angles and heights with great precision. The text also described the odometer, used for calculating distances via the rotation of a wheel of known circumference.
6. Catoptrica—For the geometric linear propagation of light, reflection, and use of mirrors.
And the most important book in the context of this site:
7. Automata (Περὶ αὐτομάτων)—A collection of constructions called miracles (thaumata) for temples. Heron describes automatic rotating objectives, noise such as thunder, automatic opening and closing doors, statues that pour wine, etc.
In his work Automata, Heron describes the workings of several bird automatons, several other automatic devices are described in Pneumatica. Hero also invented many mechanisms for the Greek theater, including an entirely mechanical play almost ten minutes in length, powered by a binary-like system of ropes, knots, and simple machines operated by a rotating cylindrical cogwheel. The sound of thunder was produced by the mechanically-timed dropping of metal balls onto a hidden drum. Heron constructed a three-wheeled cart that could carry a group of automata to the front of a stage where they would perform for an audience. Power came from a falling weight that pulled on a string wrapped around the cart’s drive axle.
It is believed that Heron described also the first odometer (device for measuring distance). He built a slot machine (insert a coin and it dispenses holy water), a hydraulic mechanism for mysteriously opening temple doors when a burnt offering heated water beneath the altar, and a cute little engine that whirled around under the force of steam through it.
Let’s examine one of the automata from the book Pneumatica. It is for an automaton, which may be made to drink at any time, a liquid being presented to it.
…by the aid of running water, the animal may be made to drink on the revolution of a carved figure of Pan. Let A B C D be a pedestal, air-tight on every side, and divided into two chambers by a partition. On the surface place the animal, and let the tube E F G pass through its mouth. Within the pedestal, in the lower chamber, let there be a bent siphon, H K L, the lower leg projecting from the bottom: and let a funnel, M N, pass through the middle of the partition, its tube reaching nearly to the bottom. On the pedestal A B C D place another pedestal, 0 X, on which the figure of Pan, P R, is to stand, having attached to it the rod S which projects below into the pedestal. To S let the tube T U be fastened, at the end of which is the cup U Q, attached to and communicating with the tube. Let the tube be of such a length that, when the figure P R turns round, the cup U Q will be directly above the funnel M N. On the pedestal, and communicating with it, and directly above the funnel M N, place the cup W Y. Let the stream Z, (which must be greater than the discharge through the siphon H K L), flow into W Y: the liquid will pass through M N into the lower part of the pedestal, the contained air passing out through E F G: and now the pedestal will continue full as the influx is greater than the discharge. But, when we turn the figure P R round, the cup U Q will intercept the stream Z, which will pass elsewhere through the tube T U, and, as the water no longer flows into the lower chamber of the pedestal, the siphon H K L will empty it, and the air will enter through E F G. Thus when the cup is applied, the animal will drink as before.
Another interesting automaton from Pneumatica. This time for an automaton, the head of which continues attached to the body, after a knife has entered the neck at one side, passed completely through it, and out at the other; the animal will drink immediately after the operation.
An animal shall be made to drink while it is being severed in two. In the mouth of the animal (upper left figure), let there be a tube, A B, and in the neck another, C D, passing along through one of the outer feet. Between these tubes let a male cylinder, E F, pass, to which are attached toothed bars, G and H. Above G place a portion of a toothed wheel, K, and, in like manner, beneath H a portion of a toothed wheel, L. Overall let there be a wheel, M, the inner rim of which is thicker than the outer; and let sections be cut out of this wheel by the three circles M, N, and X, so that the interval between each division may be equal to the radius of the wheel. Let the rim or felly be likewise divided by the circles, so that the circumference of the wheel will no longer be a circle. Having made an incision, 0 P, in the upper part of the neck, and severed the head within the incision, make in it a circular Cavity broader below than above, as it were a female tube shaped like an axe, which will contain two sides of the hexagon inscribed in the circle. Let this cavity be it S, in which the entire rim M N X will revolve in such a manner that, before one division disappears, the beginning of the next will succeed, and similarly with the third: so that, if a pin be inserted through the wheel, the wheel will revolve, and the head of the animal adhere to the neck. Now, if a knife is passed down through the incision 0 P, it will enter one of the clefts of the wheel M, and confine it in the circular cavity; and, descending lower, it will touch the projecting tooth of the part K of the wheel, which, being forced downwards, will fit its teeth into those of the bar G, and the bar being pushed back will bring the cylinder out of the tube A B. The knife, passing through the intervening space, will still descend and fall upon the projecting tooth of part L of the wheel; and this, being forced downwards, and fitting its teeth into the toothed bar H, will drive the cylinder out of C D and fit it into A B. This cylinder is an interior tube fitted into the two tubes, that, namely, in the mouth of the animal, and that reaching from the incision in the neck to the hinder foot. When the knife has passed quite through the neck, and the tube E F has touched both A B and c D, let water be offered to the animal, and a pair of sliding tubes, placed under the herdsman, be turned round. When the herdsman revolves, the water above will flow downwards along tube C D E F A B, and the current of air caused by the stream of water will attract the water offered to the mouth of the animal. Of course, the sliding tubes are so arranged that, as the herdsman turns round, the holes in them coincide. The same result can be brought about without the aid of a stream of water in the following manner. Take once more a pedestal perfectly air-tight, A B C D (lower left figure), having a partition across the middle, E F. Let the tube from the mouth of the animal, G H K, lead into the pedestal, and another tube, L M N, pass through the surface A D and the partition E F. In the tube, L M N, perforate a hole, X, just above the partition E F, and let another tube, 0 P, fit into it closely, having a hole, R, corresponding with the hole X. To the tube O P attach a figure of Pan, or some other figure with a fierce look, and, when the figure is turned towards the animal, it shall not drink, as though frightened; when the figure turns away, it shall drink. Now, if we pour water into the compartment A D E F through a hole, G’, which must afterward be carefully closed with wax or some other substance, it will be found that, if the holes R and X are made to coincide, the water which was poured in will pass into the compartment E B C F. As A D E F becomes empty, it will attract the air through the mouth of the figure, which will then drink when a cup is presented to it.
It seems also that the use of an analog train of gear wheels (linked so that each time one wheel completes a revolution the next wheel turns one-tenth of a revolution, thus recording a carry in many types of mechanical calculating machines) is very ancient and appears in the works of Heron of Alexandria.