A ratchet mechanism means that the shaft can only turn in one direction. Random motions in the gas will cause atoms to bombard the fins. Statistical fluctuations make it likely that at some point there will be more impacts on one side of the fins than on another. If this happens then the shaft will be turned. However, the ratchet means that the shaft can only turn in one direction. Thus, the wheel will turn in only one direction forever and can be used to generate power.
How it doesn't work