📄 ex3a.asm
字号:
;= ex3a.asm ====================================================================
;
; Copyright (C) 2003 Nordic VLSI ASA
;
; Author(s) : Ole Saether
; Support mail : nrfprog@nvlsi.no
;
; DESCRIPTION:
;
; PWM example program.
;
; The functionality is the same as in ex3c.c.
;
; ASSEMBLER:
;
; You need as31.exe to assemble this program. it can be downloaded from this
; web page: http://www.pjrc.com/tech/8051/
;
; $Revision: 1 $
;
;===============================================================================
.equ P0_ALT, 0x95
.equ PWMCON, 0xa9
.equ PWMDUTY, 0xaa
mov P0_ALT, #0x80 ; Enable PWM output
mov PWMCON, #0xc0 ; Enable 8 bit PWM with min prescaler
mov PWMDUTY, #10 ; High 10 out of 255 periods
here: sjmp here
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -