Testing 10KHz signal revealed issue with new_max logic. Error occurred when a maximum occurred two clocks after the previous.