VTech Alphabert s Magic Readport User Manual Page 29

  • Download
  • Add to my manuals
  • Print
  • Page
    / 80
  • Table of contents
  • BOOKMARKS
  • Rated. / 5. Based on customer reviews
Page view 28
BM Dept., Govt. Engg. College, Gandhinagar Page 29
EXPERIMENT NO. 7
Aim: Generate external interrupt INT0 and INT1 by connecting push button switch. Glow LEDs
connected at port P1 one by one when interrupt INT0 occurs. LEDs should flash when interrupt
INT1 occurs.
Circuit Diagram:
Program:
org 00h
ajmp start
org 03h ; Vector location for External interrupt INT0
ajmp sequence ; Jump to sequence program
reti
org 13h ; Vector location for External interrupt INT1
ajmp flash ; Jump to flash program
reti
start: mov IE,#10000101B ;Enable External interrupts
setb IT1 ; Negative edge trigger for INT1
setb IT0 ; Negative edge trigger for INT0
mov P1,#00h ; Port P1 output port
flash: mov P1,#0ffh ; Make all LEDs OFF
acall delay
mov P1,#00h ; Make all LEDs ON
acall delay
Page view 28
1 2 ... 24 25 26 27 28 29 30 31 32 33 34 ... 79 80

Comments to this Manuals

No comments