PWM output question

Started by soso soso April 3, 2006
Hi ~

I have a question about PWM output of BX24.
I use BX24's PWM output to control a dc motor with driver LM18200L, and I set the PWM rate-setting as 1 and 8-bit mode so that the freq of PWM is about 14kHz. But, suddenly, the PWM doesn't work, there is a bias voltage, about 2.5V, so that PWM output wont go to 0V, and it is not a square wave. I have checked the PWM output with provided dual PWM output program, I still cant find out the problem.

Please help, is my BX24 or Timer 1 broken? or any other reason? And how to fix it?

Thanks
Owen


_______________________________________
YM - uT
NSWABͤiHdUTAAWNYݨܳC
http://messenger.yahoo.com.hk




Yahoo! Groups Links
> ... suddenly, the PWM doesn't work...

Timer1 has two output pins; on the BX-24, pins 26 and 27. They are
electrically identical except that pin 26 has an LED and dropping
resistor connected to it. Because of that, pin 26 will not show the
voltages of an unconnected pin that you might expect. +2.5v on that
pin is not unreasonable if the pin is floating or lightly loaded.

I suggest two things:
- change your code to control pin 27 (see the Dual-PWM appnote)
- use Timer2 (although it, also, has an LED connected to it).

I'll bet you have a code problem (did you set the pin for output?) and
the odd voltage is due to the LED and pin mode.

You'll not be able to repair the BX-24 if you've damaged the pin 26
driver.
Tom

Yahoo! Groups Links