Are you using PWM to control the motors? Either way, let's assume 0 is off, and 255 is full on.

Let's say your speed of your robot is 150 PWM duty cycle.

The output of the PID will be some number that you add to one wheel's power, and subtract from the other. SO if your PID says turn left by +10, One wheel will get 160 , the other 140. Turn right would be -10, or 140, 160 on the wheels.

The two inputs would be goal heading, and actual heading, just like your usual PID; but you would have to handle 'wrap around'. IE, if set heading was 5 degrees, and actual was 355; your error would be +10, not -350.