Electronic Components Datasheet Search
  English  ▼

Delete All
ON OFF
ALLDATASHEET.COM

X  

Preview PDF Download HTML

STC12C2052 Datasheet(PDF) 51 Page - List of Unclassifed Manufacturers

Part No. STC12C2052
Description  STC12C2052AD
Download  71 Pages
Scroll/Zoom Zoom In 100%  Zoom Out
Manufacturer  ETC1 [List of Unclassifed Manufacturers]
Direct Link  
Logo ETC1 - List of Unclassifed Manufacturers

STC12C2052 Datasheet(HTML) 51 Page - List of Unclassifed Manufacturers

Back Button STC12C2052 Datasheet HTML 47Page - List of Unclassifed Manufacturers STC12C2052 Datasheet HTML 48Page - List of Unclassifed Manufacturers STC12C2052 Datasheet HTML 49Page - List of Unclassifed Manufacturers STC12C2052 Datasheet HTML 50Page - List of Unclassifed Manufacturers STC12C2052 Datasheet HTML 51Page - List of Unclassifed Manufacturers STC12C2052 Datasheet HTML 52Page - List of Unclassifed Manufacturers STC12C2052 Datasheet HTML 53Page - List of Unclassifed Manufacturers STC12C2052 Datasheet HTML 54Page - List of Unclassifed Manufacturers STC12C2052 Datasheet HTML 55Page - List of Unclassifed Manufacturers Next Button
Zoom Inzoom in Zoom Outzoom out
 51 / 71 page
background image
宏晶科技:www.MCU-Memory.com   Mobile:13922805190(姚永平)   Tel:0755-82948409    Fax: 0755-82944243
宏晶科技:专业单片机 / 存储器供应商   www.MCU-Memory.com   STC12C2052AD 系列 1T 8051 单片机中文指南
51
;STC12C2052  系列单片机 PCA  功能
PWM  示例程序,使用 18.432MHz 晶振。
;------------------------------------------------------------
#include <..\PCA_2052_SFR.ASM>    ;定义 PCA 特殊功能寄存器
;------------------------------------------------------------
;定义常量
;pulse_width_MAX = pulse_width_MIN 时,  输出脉冲宽度不变。
pulse_width_MAX   EQU   0F0H        ;PWM 脉宽最大值, 占空比 = 93.75%
pulse_width_MIN   EQU   10H         ;PWM 脉宽最小值, 占空比 = 6.25%
step              EQU   38H         ;PWM 脉宽变化步长
;------------------------------------------------------------
;定义变量
pulse_width     EQU  30H
;------------------------------------------------------------
    ORG 0000H
    AJMP  main
;------------------------------------------------------------
    ORG 0050H
main:
    MOV   SP, #0E0H
    ACALL PCA_init
main_loop:
    ACALL PWM
    SJMP  main_loop
;------------------------------------------------------------
PCA_init:
    MOV   CMOD, #80H;           ;PCA 在空闲模式下停止 PCA 计数器工作
                                ;PCA 时钟模式为 fosc/12
                                ;禁止 PCA 计数器溢出中断
    MOV   CCON, #00H            ;禁止 PCA 计数器工作, 清除中断标志、计数器溢出标志
    MOV   CL, #00H              ;清 0 计数器
    MOV   CH, #00H
;-------------------------
;设置模块 0 为 8  位 PWM  输出模式, PWM  无需中断支持。脉冲在 P3.7(第 11 脚)输出
    MOV   CCAPM0, #42H          ;*** 示例程序核心语句, ---->0100,0010
    MOV   PCA_PWM0, #00H        ;*** 示例程序核心语句
;   MOV   PCA_PWM0, #03H        ;释放本行注释, PWM 输出就一直是 0, 无脉冲。
;-------------------------
;设置模块 1 为 8  位 PWM  输出模式, PWM  无需中断支持。脉冲在 P3.5(第 9 脚)输出
    MOV   CCAPM1, #42H          ;*** 示例程序核心语句, ---->0100,0010
    MOV   PCA_PWM1, #00H        ;*** 示例程序核心语句


Similar Part No. - STC12C2052

ManufacturerPart No.DatasheetDescription
List of Unclassifed Manufacturers
List of Unclassifed Man...
STC12C5402 ETC1-STC12C5402 Datasheet
1Mb / 149P
   STC12C5410AD
STC12C5402AD ETC1-STC12C5402AD Datasheet
1Mb / 149P
   STC12C5410AD
STC12C5404 ETC1-STC12C5404 Datasheet
1Mb / 149P
   STC12C5410AD
STC12C5404AD ETC1-STC12C5404AD Datasheet
1Mb / 149P
   STC12C5410AD
STC12C5406 ETC1-STC12C5406 Datasheet
1Mb / 149P
   STC12C5410AD
More results


Html Pages

1  2  3  4  5  6  7  8  9  10  11  12  13  14  15  16  17  18  19  20  21  22  23  24  25  26  27  28  29  30  31  32  33  34  35  36  37  38  39  40  41  42  43  44  45  46  47  48  49  50  51  52  53  54  55  56  57  58  59  60  61  62  63  64  65  66  67  68  69  70  71 


Datasheet Download

Go To PDF Page


Link URL




Privacy Policy
ALLDATASHEET.COM
Does ALLDATASHEET help your business so far?  [ DONATE ] 

About Alldatasheet   |   Advertisement   |   Datasheet Upload   |   Contact us   |   Privacy Policy   |   Link Exchange   |   Manufacturer List
All Rights Reserved©Alldatasheet.com


Mirror Sites
English : Alldatasheet.com  |   English : Alldatasheet.net  |   Chinese : Alldatasheetcn.com  |   German : Alldatasheetde.com  |   Japanese : Alldatasheet.jp
Russian : Alldatasheetru.com  |   Korean : Alldatasheet.co.kr  |   Spanish : Alldatasheet.es  |   French : Alldatasheet.fr  |   Italian : Alldatasheetit.com
Portuguese : Alldatasheetpt.com  |   Polish : Alldatasheet.pl  |   Vietnamese : Alldatasheet.vn
Indian : Alldatasheet.in  |   Mexican : Alldatasheet.com.mx  |   British : Alldatasheet.co.uk  |   New Zealand : Alldatasheet.co.nz