Tweaked HR code, needed to enable ADC