home *** CD-ROM | disk | FTP | other *** search
/ ticalc.org / ticalc_org_rev_b.iso / archives / 82 / asm / source / ash / showpic.asm < prev   
Encoding:
Assembly Source File  |  2001-07-01  |  2.0 KB  |  85 lines

  1. ; *** ShowPic ver 1.1 (C) 1997 by Dines Justesen ***
  2. ;
  3. ; This is a very simpel greyscale test, 4 pictures
  4. ; are display right after each other as fast as
  5. ; possible (no interrupts or delays).
  6. ;
  7. ; This program does not use the rutine from the rom to
  8. ; display the pictures, because the rutine is not
  9. ; very well written.
  10. ;
  11. ; The pictures are taken from a similar TI85 program,
  12. ; but since i no longer have the program  do not know
  13. ; who made them.
  14. ;
  15. ; History:
  16. ;  1.0 : First version reæeased
  17. ;  1.1 : Pictures are now included in the program (the other
  18. ;        method used too many of the ti82 vars, and was too
  19. ;        complicated).
  20.  
  21. #INCLUDE "ti82.h"
  22. #INCLUDE "graph.h"
  23.  
  24. ;--------------------------------------------------------------------------
  25. ; Definitions
  26. ;--------------------------------------------------------------------------
  27.  
  28. #DEFINE ShowPic(addr) LD HL,addr \ CALL ShowPicture \ CALL GET_KEY \ CP $37 \ JR Z,Exit
  29.  
  30. ;--------------------------------------------------------------------------
  31. ; Program
  32. ;--------------------------------------------------------------------------
  33.  
  34. .ORG START_ADDR
  35. .DB "ShowPic ver 1.1 by DJ",0
  36.         TEXT_START
  37.         ROM_CALL(CLEARLCD)
  38. Loop:
  39.         ShowPic(Pic1)
  40.         ShowPic(Pic2)
  41.         ShowPic(Pic3)
  42.         ShowPic(Pic4)
  43.         JR Loop
  44. Exit:
  45.         TEXT_END
  46.         RET
  47.  
  48. ShowPicture:
  49.         DI
  50.         LD A,7
  51.         CALL $7F3
  52.         OUT ($10),A
  53.         LD A,$80
  54. LineLoop:
  55.         LD D,A          ; Save currect coloum
  56.         CALL $7F3
  57.         OUT ($10),A
  58.         LD A,$20        ; Goto top
  59.         CALL $7F3
  60.         OUT ($10),A
  61.         LD BC,$0C11     ; 40 bytes to port 10
  62. WriteLoop:              ; Write them
  63.         NEG
  64.         NEG
  65.         NEG
  66.         NEG
  67.         OUTI
  68.         JR NZ,WriteLoop
  69.         LD A,D
  70.         INC A
  71.         CP $C0
  72.         JR NZ,LineLoop
  73.         EI
  74.         RET
  75.  
  76. Pic1:
  77. #INCLUDE "PIC1.INC"
  78. Pic2:
  79. #INCLUDE "PIC2.INC"
  80. Pic3:
  81. #INCLUDE "PIC3.INC"
  82. Pic4:
  83. #INCLUDE "PIC4.INC"
  84. .END
  85.