¿Cómo genera zigbee ondas pwm en la pila de protocolos?
void Timer1Pwm_init(void)
{
PERCFG &= ~0x40; // Selecciona la posición 0 del temporizador/contador 1
P2DIR = (P2DIR & ~0xC0 ) | 0x80; //Dar prioridad al temporizador/contador 1
P0SEL |= 0x08; //Establecer P0_3 como periférico
T1CC0L = 0xff; >
T1CC0H = 0x7f;
T1CC1L = 0x78; // ciclo de trabajo PWM
T1CC1H = 0x10;
T1CCTL1 = 0x1c;
T1CTL |= 0x0f; // Divide por 128 y realiza el modo arriba y abajo
Return
}
void start_pwm(void)
{
Timer1Pwm_init();
return ;
}
#if 0
/*irq function*/
# pragma vector=T1_VECTOR
/__interrupt void T1_IRQ(void)
recuento de caracteres volátiles sin firmar = 0;< / p>
__interrupt void _irq_timer1( void)
{
//TODO....
}
# endif /*_irq_timer1*/