F1F0 ATP synthase (ATPase) either facilitates the synthesis of ATP in the mitochondrial membranes and bacterial inner membranes in a process driven by the proton moving force (pmf), or uses the energy from ATP hydrolysis to pump protons against the concentration gradient across the membrane. ATPase is composed of two rotary motors, F0 and F1, which generate the opposing rotation and compete for control of their shared central gamma-shaft. Here we present a self-consistent physical model of the F1 motor as a simplified two-state Brownian ratchet based on the asymmetry of torsional elastic energy of the coiled-coil gamma-shaft. This stochastic model unifies the physical description of linear and rotary motors and explains the stepped unidirectional rotation of the $gamma$-shaft, in agreement with the `binding-change ideas of Boyer. Substituting the model parameters, all independently known from recent experiments, our model quantitatively reproduces the ATPase operation, e.g. the `no-load angular velocity is ca. 400~rad/s anticlockwise at 4 mM ATP, in close agreement with experiment. Increasing the pmf torque exerted by F0 can slow, stop and overcome the torque generated by F1, switching from ATP hydrolysis to synthesis at a very low value of `stall torque. We discuss the matters of the motor efficiency, which is very low if calculated from the useful mechanical work it produces - but is quite high when the `useful outcome is measured in the number of H+ pushed against the chemical gradient in the F1 ATP-driven operation.