1294 views|0 replies

3836

Posts

19

Resources
The OP
 

MSP430F5529 generates PWM waves with CCS [Copy link]

It is probably that a PWM wave of a certain frequency is generated by the clock. Using FPGA can get a more perfect waveform, but if only a CLK wave is provided, F5529LP can do it completely. #include

unsigned int temp; int main(void) { WDTCTL = WDTPW | WDTHOLD; //Turn off watchdog //Initialize P1DIR |= BIT0; P1OUT |= BIT0; P1SEL |= BIT2; //Output from P1.2 P1DIR |= BIT2; //Initialize timer TA0CTL |= TASSEL_2 + ID_0 ; TA0CCTL1 = OUTMOD_7; TA0CCR0 = /*Period*/; //Change me TA0CCR1 = /*Duty*/; //Change me __delay_cycles(2000); __bis_SR_register(LPM4_bits + GIE); return 0; }

This post is from Microcontroller MCU
 

Guess Your Favourite
Just looking around
Find a datasheet?

EEWorld Datasheet Technical Support

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京B2-20211791 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号
快速回复 返回顶部 Return list