He then captured Yi and Pu Prefectures again, but then suffered several defeats by Tang forces. He thus wrote the new military governor of Tianping, Zhang Xi (), asking Zhang to ask for a Tang commission on his behalf. At Zhang's request, Emperor Xizong commissioned Huang as a general of the imperial guards, but ordered him to report to Yun Prefecture to disarm before he would report to the capital Chang'an.
He recaptured Yi and Pu Prefectures but suffered defeats from Tang forces. Consequently, he wrote to Zhang Xi (), the new military governor of Tianping, asking him to request a Tang commission on his behalf. Emperor Xizong then appointed Huang as a general of the imperial guards, with instructions for him to report to Yun Prefecture for disarmament before proceeding to Chang'an.