Flush stdout after each new bit so that we get a live view.
Add GETBIT_XMIT , used when all input is high (i.e. DCF77 transmitter if off).
Add two new fields to struct hardware:
- active_high (boolean): if set, an input '1' means an active pulse and
  an input '0' means a passive pulse. If not set, an input '1' means a
  passive pulse and an input '0' means an active pulse.
- min_len: minimum length for a second in pulses as percentage of freq
  (not used yet), useful against "holes" in the radio signal.

Make margin an integer instead of a long.
Move reception of a signal pulse into a new function get_pulse() and use
the hw.active_high field.
Update some comments.
Do not decode this bit any further in case of an I/O error.
Require no high pulses (or 1 because of the edge detection) instead of
few enough high pulses for the end-of-minute marker.
Merge the code to determine the character to log with the code to
update the resulting state.
Do not forget to update the buffer which holds the seconds in live mode!
New sample hardware.txt:
- reduce sampling frequency from 1000 Hz to 100 Hz
- increase allowed error margin to 3% (sometimes the active part of a pulse
  is up to 30 ms too short)
- Add values for min_len (90%) and active_high (1)