Advertisement
tmax

Untitled

Aug 14th, 2012
131
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.22 KB | None | 0 0
  1.    //(1/Clock)*4*T2div*(PR2+1) = Periodo
  2.    setup_ccp1(CCP_OFF);
  3.    setup_timer_2(T2_DIV_BY_1,82,1);      //Frecuencia de 30120 Hz
  4.    setup_ccp1(CCP_PWM);
  5.    
  6.    //duty cycle = value / [4*(PR2+1)]
  7.    set_pwm1_duty(0);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement