Are you measuring the HPWM pin directly with your Analogue Voltmeter? It's not going to give sensible readings. unless it's spec'd at 250Hz and able to respond to tiny pulses.
Connect your PWM pin to a Resistor (eg 10K). The other end of the Resistor goes to the +ve side of a Capacitor (eg 1uF), -ve end of which connects to 0v. Take your DC meter measurement from across the Capacitor.
Now as long as your meter is not something silly like a moving-iron type, and has a reasonably high impedance (eg 20kR/v) so as not to load the Capacitor too much, you should see a stable voltage proportional to your POT setting. If you bought your meter from the cheap side of town, and it's impedance is nearer 2kR/v (or less), then reduce the value of the Resistor (eg 4K7). The bigger the load you put across the Capacitor, the greater the 'ripple' on the DC level. Increase the frequency of the HPWM (eg to around 1kHz) to provide some compensation.
Usual practice is to buffer the PWM with an op-amp to give you a stable voltage to play with unaffecetd by varying loads.
Bookmarks