Hello everybody.
I would like to ask about the period and duty cycle quantities when generating a PWM signal.
1) First I am using a PIC18F2550 so I suppose that my Fosc = 1MHz. (I read this on the data sheet, is there a way to check this??)
2) Now I have to set the PWM period or frequency (the inverse).
How do I set this? What quantities are recommended for PWM period?
(i am planning to use this to control a motor, but in the meantime I am also trying to control a LED brightness too)
I heard there are some recommendations for choosing a period so that the motor does not generate a human audible sound?
I would really much appreciate your thoughts on this, I have read already PLENTY of pages on PWM and I know the concept but the points above are still unclear
1) The oscillation frequency is depending on how you configure the PIC.
2) For the PWM duty cycle and frequency/period, you can also set it. Read the datasheet of the PIC for how to do it.
A hint for you, at 50 or 60 Hz alternating current, you won't see the light bulb flickering will you?