rc/dcf_sync: Refactor into a state machine
rc/dcf_sync: Tidy up constant names and documentation
rc/dcf_sync: Style fixes and tidy up
rc/dcf_sync: Style fix - always bracket conditionals
rc/dcf_sync: Fix vertical alignment