MikroElektronika PIC Microcontrollers PIC16 Datenblatt Seite 127

  • Herunterladen
  • Zu meinen Handbüchern hinzufügen
  • Drucken
  • Seite
    / 194
  • Inhaltsverzeichnis
  • FEHLERBEHEBUNG
  • LESEZEICHEN
  • Bewertet. / 5. Basierend auf Kundenbewertungen
Seitenansicht 126
Programming PIC Microcontrollers in BASIC - mikroElektronika
5.2.13.2 PWM_Change_Duty – Changes duty ratio
Prototype sub procedure PWM_Change_Duty(dim New_Duty as byte)
Description Routine changes duty ratio. <New_Duty> takes values from 0 to 255, where 0 is 0% duty ratio, 127 is 50% duty
ratio, and 255 is 100% duty ratio. Other values for specific duty ratio can be calculated as (Percent*255)/100.
Example
while true
Delay_ms(100)
j = j + 1
PWM_Change_Duty(j)
wend
5.2.13.3 PWM_Start – Starts PWM
Prototype sub procedure PWM_Start
Description Starts PWM.
Example
PWM_Start
http://www.mikroelektronika.co.yu/english/product/books/picbasicbook/05.htm (85 sur 112)05/11/2004 02:20:53
Seitenansicht 126
1 2 ... 122 123 124 125 126 127 128 129 130 131 132 ... 193 194

Kommentare zu diesen Handbüchern

Keine Kommentare