Page 1 of 1

PWM on ATMEGA162

Posted: Wed Mar 11, 2009 10:52 am
by joopspiegel
HELP!!!!!! :-) :lol:

I'm a newby on fc so perhaps i ask something stupid. I like to use PWM on port OC1B(PE2) and make a little fc program on a Atmel stk500 board. When i take a look with the scope nothing is happening. After some experiments i found out that OC1A(PD5) is working well. But OC1B will not work at all!
I drop a component PWM(0) on my form.
Call the component macro's with
Enable(1)
SetDutyCycle(1,50)
Enable(2)
SetDutyCycle(2,200)
I also let a led flashing on another port (PB0) and that is working fine.
I've changed the chip but it still not works! An other funny thing is that i can call the macro's with any device (i.e. 3) number and there will be no error message.
Can anybodyy tell me what is went wrong here? :shock:

Kind regards,
Joop