NEC PD75P402 Uživatelský manuál Strana 149

  • Stažení
  • Přidat do mých příruček
  • Tisk
  • Strana
    / 195
  • Tabulka s obsahem
  • KNIHY
  • Hodnocené. / 5. Na základě hodnocení zákazníků
Zobrazit stránku 148
138
CHAPTER 6. INTERRUPT FUNCTIONS
(2) Example using INTBT, INT0 (falling edge active), and INTCSI
Reset
MOV
MOV
CLR1
EI
EI
EI
EI
RETI
<INT0 Service Program>
INT0
A, #1
IM0, A
IRQ0
IEBT
IE0
IECSI
; MBE = 0
Status 0
Status 1
Status 0
<Main Program>
All interrupts disabled and status 0 set by RESET input.
INT0 set to falling edge active.
Interrupts enabled by EI and EI IE××× instructions.
On fall of INT0, INT0 interrupt service program is started, status is changed to 1 and all interrupts are
disabled.
RETI instruction effects return from interrupt, restores status to 0, and enables interrupts.
4
Zobrazit stránku 148
1 2 ... 144 145 146 147 148 149 150 151 152 153 154 ... 194 195

Komentáře k této Příručce

Žádné komentáře