Advertisement
Eeems

Untitled

Jun 11th, 2011
183
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.34 KB | None | 0 0
  1. Sleep:
  2. ld a, 2
  3. out (10h), a ; Disable LCD
  4. di ; And interrupts, for now
  5. im 1 ; interrupt mode 1, for cleanliness
  6. ei ; Enable interrupting when ON is pressed
  7. ld a, 1h
  8. out (03h), a ; ON
  9. halt ; and halt :)
  10. ld a, 0Bh ; Reset the interrupts
  11. out (03h), a
  12. ld a, 3
  13. out (10h), a ; Enable the screen
  14. ret
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement