![Microchip Technology MCP1252 Скачать руководство пользователя страница 24](http://html1.mh-extra.com/html/microchip-technology/mcp1252/mcp1252_user-manual_1785980024.webp)
00016R1.asm Source Code
©
2005 Microchip Technology Inc.
DS51551A-page 20
TABLE C-1:
00016R1.ASM
;**********************************************************************
; *
; Filename: 00016R1.asm *
; Date: 31aug04 *
; File Version: pp1 *
; *
; Author: M Waldron *
; Company: MCHP *
; 10f204/ 10f206 PWM to control LED driver *
; *
;**********************************************************************
; *
; Files required: *
; *
; *
; *
;**********************************************************************
; *
; Notes: Changed file name, added led_medhi routine, *
; adjusted intensity of various modes. PB 3/29/05 *
; *
; *
; *
; *
;**********************************************************************
list p=10f206 ; list directive to define processor
#include <p10f206.inc> ; processor specific variable definitions
__CONFIG _CP_OFF & _WDT_OFF & _MCLRE_OFF & _IntRC_OSC
; ‘__CONFIG’ directive is used to embed configuration data within .asm file.
; The labels following the directive are located in the respective .inc file.
; See respective data sheet for additional information on configuration word.
;constants
;increase led_xxx_on to increase intensity ( value must be less than period value)
;increase period to reduce PWM frequency and increase PWM resolution
led_hi_on = 0x16 ;on loops for high brightness mode
led_hi_off = 0x11 ;off loops for high brightness mode, value will be calculated
by the program (10)
led_medhi_on = 0x08 ;on loops for medium_high brightness mode
led_medhi_off = 0x11 ;off loops for high brightness mode (11)
led_med_on = 0x06 ;on loops for medium brightness mode
led_med_off = 0x11 ;off loops for high brightness mode (11)
led_low_on = 0x05 ;on loops for low brightness mode
led_low_off = 0x12 ;off loops for high brightness mode (12)
period = 0x0E ;total loops per PWM period
max_time = 0xff ;on time before unit swithces back to sleep
;variables
mode = 0x13 ;current mode ( high, med, lo )
counter = 0x14 ;hi and low time counter
debounce = 0x15 ;debounce counter
flag = 0x16 ;debounce control flags
Содержание MCP1252
Страница 1: ...2005 Microchip Technology Inc DS51551A MCP1252 Charge Pump Backlight LED Demo Board User s Guide...
Страница 17: ...Schematic and Layouts 2005 Microchip Technology Inc DS51551A page 13 A 3 BOARD TOP ASSEMBLY DRAWING M...
Страница 19: ...Schematic and Layouts 2005 Microchip Technology Inc DS51551A page 15 A 5 BOARD BOTTOM LAYER FROM TOP...
Страница 20: ...MCP1252 Charge Pump Backlight LED Demo Board User s Guide DS51551A page 16 2005 Microchip Technology Inc NOTES...
Страница 22: ...MCP1252 Charge Pump Backlight LED Demo Board User s Guide DS51515A page 18 2005 Microchip Technology Inc NOTES...
Страница 29: ...00016R1 asm Source Code 2005 Microchip Technology Inc DS51551A page 25 NOTES...