U6,U7 comparators and U11 DPDT switch are used for debugger target voltage detection. Depending on the orientation of the USB cable either one of RSENSE0 and RSENSE1 will go high. Once that happens, due to the way the comparators are connected, DEBUG_EN will go high. When DEBUG_EN goes high, the DPDT switch will be triggered shorting HDK_VREF to VREGO_A and the target voltage is detected.