There are 2 clocks for PIC18F4550: one for USB and one for CPU. They can relate.
I want the microcontroller to run at 48MHz for the program/instruction, the CPU clock (FOSC).
To achieve 48MHz we have to use an external crystal and set it as primary oscillator – datasheet page 34. OSCCON bits SCS1:SCS0=00. I tried with 20MHz and 16MHz crystal and of course different settings for configuration bits at division for PLL.
In the present examples I have chosen 16 MHz external crystal, then the division is 4, because we have to get 4Mhz before PLL – datasheet page 26:
https://ww1.microchip.com/downloads/en/DeviceDoc/39632e.pdf
Then we get 96MHz after PLL and then for USB is divided by 2 and we get 48Mhz for USB, but is not my concern now.
The 96 MHz is also divided by 2 when we choose PLL postscaler CPUDIV equal with 2 and the CPU gets 48MHz.
When we work with internal oscillator, then we are limited at 8MHz for FOSC, forget about USB, is not what I am interested.
That is proved in reality on the bench with a real PIC18F4550 and a real oscilloscope.
The problem that I raised here is strictly related with Proteus.
I want PIC18F4550 CPU to run at 48 MHz in Proteus. That it fails.
If you look at the screenshots (pictures) in the folder Proteus from my link above, you can see that I did specify the CPU frequency in that Edit box inside the Proteus and I mentioned it 48MHz.
I want 48 MHz for the CPU and that should be mentioned inside Proteus where is that Edit box, isn’t’ it?
Then why do I see 4 MHz in your screenshot?