MB95630H Series
MN702-00009-1v0-E
FUJITSU SEMICONDUCTOR LIMITED
453
CHAPTER 21 MULTI-PULSE GENERATOR
21.8 Sample Program for Multi-pulse Generator
MOVW
PCNT1,A
;Enables PPG output in normal polarity
;Enables 16-bit PPG timer
;Software triggers PPG
;Select PWM mod
;Clears interrupt flag, and starts counter
MOVW
A,#0103H
MOVW
OPCR,A
;Enable OPT0 and OPT1 output
;Sets OPDBRH0/OPDBRL0 write method for data
transfer
;Enable write timing interrupt
;Clears interrupt flag
MOVW
A,#0009H
MOVW
OPDBR0,A
;Sets OPT0 pin as PPG output
;Sets OPT1 pin as inverted PPG output
;Starts data transfer
SETI
;Interrupt enable
LOOP:
MOV
A,#00H
;Endless loop
MOV
A,#01H;
JMP
LOOP;
;-------Interrupt program-------------------------------------------------------------------------------------
WARI:
CLRB
WTIF
;Clears interrupt request flag
; ;
; User processing
; :
RETI
;Returns from interrupt
CODE ENDS
;-------Vector setting------------------------------------------------------------------------------------------
VECT
CSEG
ABS
ORG
0FFDAH
;Sets vector for interrupt #16 (0x10)
DW WARI
ORG
0FFFCH
;Sets reset vector
DW 0000H
;Sets single-chip mode
DW START
VECT ENDS
END
START
END
Содержание MB95630H Series
Страница 2: ......
Страница 4: ......
Страница 8: ...iv ...
Страница 20: ...xvi ...
Страница 106: ...MB95630H Series 86 FUJITSU SEMICONDUCTOR LIMITED MN702 00009 1v0 E CHAPTER 6 I O PORT 6 2 Configuration and Operations ...
Страница 282: ...MB95630H Series 262 FUJITSU SEMICONDUCTOR LIMITED MN702 00009 1v0 E CHAPTER 14 LIN UART 14 8 Notes on Using LIN UART ...
Страница 642: ...MB95630H Series 622 FUJITSU SEMICONDUCTOR LIMITED MN702 00009 1v0 E APPENDIX A Instruction Overview A 5 Instruction Map ...
Страница 644: ......