Hi:
in the past, when it wanted to work with the USB, I entered normally to the EasyHID and it generated the code, soon it added what needed and compiled, and in the short while to load hex in the Winpic, had to modify the division of the PLL to the one of the crystal that used, therefore could not use the F10 key so that it loaded the HEX and it directly programs the Pic micro by that change that it had to do, now to loooong time since I began with this, I have watched the fuses and I have made the next configurations to have change nothing in winpic:
@CONFIG_REQ
@PLL_REQ
@__config config1l, PLLDIV_3_1 & CPUDIV_2_1 & USBDIV_2_1
@__config config1h, FOSC_HSPLL_HS_1
@WATCHDOG_REQ
@__config config2h, WDT_OFF_2 & WDTPS_128_2
@DEBUG_REQ
@__config config4l, LVP_OFF_4 & ICPRT_OFF_4 & XINST_OFF_4 & DEBUG_OFF_4
@__config config3h, PBADEN_OFF_3
The PLLDIV_3_1, is the PLL dicision, you can see al PLL divisions here:
PLLDIV_1_1 Oscillator not divided
PLLDIV_2_1 Oscillator divided by 2
PLLDIV_3_1 Oscillator divided by 3
PLLDIV_4_1 Oscillator divided by 4
PLLDIV_5_1 Oscillator divided by 5
PLLDIV_6_1 Oscillator divided by 6
PLLDIV_10_1 Oscillator divided by 10
PLLDIV_12_1 Oscillator divided by 12
This configuration may be added to our code to program directly the Pic micro.
I hope that helps you in your USB projects.
Regards