Dear forum,
I am learning the coder capabilities and have connected a Nucleo-F303Re board to PLECS with success.
I connected a potentiometer to an analog input pin. This pin is then read into the carrier for a PWM generator set up using TIM1.
The PWM duty cycle seems to be possible to vary with fine resolution when I measure on the hardware.
However, in the simulation (looking at the scope), I get discrete steps of 0.25 in duty. I.e. the duty shown is either 0, 0.25, 0.5, 0.75 or 1
Even when I create a loopback from the output pins for the PWM, back to digital input pins and try to read them in the scope (in external mode), I get the same corse resolution in the PLECS scope.
Any idea why this could be? Could it have something to do with the update rate of the scope?
Reading the ADC pin shows fine resolution in the scope also in external mode. Thank you.