The DAQ and control system for the CMS Phase-1 pixel detector upgrade