Forum - MCS Electronics

 

FAQFAQ SearchSearch RegisterRegister Log inLog in

3 PWM on M324P

 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    www.mcselec.com Forum Index -> BASCOM-AVR Archive
View previous topic :: View next topic  
Author Message
hobby

Bascom Member



Joined: 12 Apr 2004
Posts: 107
Location: Brussels

belgium.gif
PostPosted: Wed Jun 11, 2014 3:15 pm    Post subject: 3 PWM on M324P Reply with quote

Hi All,

I have problem to configure the 3 PWM on M324P:

Code:

$regfile = "m324pdef.dat"
$crystal = 8000000
$hwstack = 40
$swstack = 30
$framesize = 40

Config Timer1 = Pwm , Pwm = 8 , Prescale = 1 ,  Compare A Pwm = Clear down
Config Timer2 = Pwm , Prescale = 8 , Compare_A_Pwm = Clear_Up , Pwm = On , Compare_A = Set , Async = Off

Start Timer1
Start Timer2

do
      Pwm1a = 255
      Pwm1b = 255
      Pwm2a = 255
      waitms 350

      Pwm1a = 0
      Pwm1b = 0
      Pwm2a = 0
      waitms 350
loop
end

I have only OC2A (PORTD.7) works.
Any id for what.

Thanks
Olivier

(BASCOM-AVR version : 2.0.7.6 , Latest : 2.0.7.7 )
Back to top
View user's profile
hobby

Bascom Member



Joined: 12 Apr 2004
Posts: 107
Location: Brussels

belgium.gif
PostPosted: Wed Jun 11, 2014 10:02 pm    Post subject: Reply with quote

Hi All,

In old time, i have writed this for M644P (and run):

Code:

Config Timer1 = Pwm , Prescale = 1 , Pwm = 8 , Compare A Pwm = Clear Down , Compare B Pwm = Clear Down
Config Timer2 = Pwm , Prescale = 1 , Compare A Pwm = Clear Down , Compare B Pwm = Clear Down
 


But not works with M324P and Bascom 2.0.7.7

Why ? , any idea ?

Best regards
Olivier
Back to top
View user's profile
Display posts from previous:   
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    www.mcselec.com Forum Index -> BASCOM-AVR Archive All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum