Deja Vu #07
31 декабря 1997

CODING - The printing of tektstovyh lines of BASIC.

<b>CODING</b> - The printing of tektstovyh lines of BASIC.
AY-Track: LOW CODER'S LYRIC (ON FUNTOP'98)
__________________________________________


(C) Andrew Strelnikov
__________________________________________



        The printing process



   The programs at Basic'e commonly used procedures for 
printing a native. To do this, they connect to the new channel 
and print plain PRINT, or placed in

RAM pre-prepared messages and transmit them to the procedure of 
printing the address using the POKE. Propose another way. Data 
is transmitted via a user function. Text is placed in the REM 
lines. Address Text is calculated by number of the first first

line with the text. Symbol of the end of the text is missing. 
End of the text determined by the absence of the operator REM 
at the beginning of the next Basic line. As an example, cite

the simple procedure of printing, which uses
PZUshnuyu RST 16.

; How to print the group of text strings
; Of BASIC.
And (c) Strelnikov AS
; Def fn a (n, x, y, t, p, b) = adr
; N - number of first-line with text
; X, y - coordinates
; T, p, b, - attributes (ink, paper, bright)
; Newline 13 (VC)
The text is placed behind the operator in REM
; Multiple lines.
; Print lines until it encounters
; Line that starts with another
; (Not REM) operator.


      ORG 40000

      LD A, 2

      CALL 5633; open channel 2

, The definition addresses the first line of text


      LD HL, (23563); defadd

      INC HL

      INC HL

      CALL 13236

      CALL 7833

      PUSH BC

      POP HL

      CALL 6510

      LD DE, 5

      ADD HL, DE; now in HL address text

                 And after REM

Setting of print attributes


      LD IX, (23563); Defadd

      LD A, 16

      RST 1916

      LD A, (IX +28); ink

      RST 1916

      LD A, 17

      RST 1916

      LD A, (IX +36); paper

      RST 1916

      LD A, 19

      RST 1916

      LD A, (IX +44); bright

      RST 1916


Setting of printing position


      LD B, (IX +12); x

      LD C, (IX +2); y
START LD A, 22; at

      RST 1916

      LD A, C; y

      RST 1916

      LD A, B; x

      RST 1916


; Print

PRN LD A, (HL); have a symbol

      CP 13; checking code VC

      JR 2, PS; if so, the procedure ne
                  , Maps the line

      RST 16; print symbol

      INC HL; increment pointer

                  ; Text

      JR PRN; seal. symbol

; Newline: increase y by 1
S address is increased by 5 (go to the next, blowing line, 
where after REM is The text: 2 byte line number 2 bytes long, 
and on-line, and 1 byte - code 13 previous ; Line).


PS INC C; y = y +1

      LD DE, 5

      ADD HL, DE; adr = adr +5

      LD A, (HL); if there

      CP 234; code REM - skip

      INC HL; it and print

      JR Z, START; the next line if

                   Nay - reset
END CALL 3405; temporal attributes

      RET; output


   This program, in many cases more convenient than just PRINT. 
It prints a few lines in the given coordinates. Can used to 
print the menu descriptions and etc.





Other articles:

Aperativchik - On the control of the shell DEJA VU

Aperativchik - New Issue DEJA VU ...

Topic - The reality of the association AMAZING MAKING SOFT.

Topic - My Choice - PC.

Topic - Absentee virtual festival in Poland - Complex Compo.

Topic - Chronology of Spectrum in the USSR / CIS.

drop of solder - Reserves ZX-Spectrum.

drop of solder - Connecting the SMM to the ZX-Spectrum-y.

drop of solder - Wiring 1Mb pin SIMM to a computer such as the Pentagon.

drop of solder - More RAM: the cache.

drop of solder - The emulator ROMs for the computer ZX-Spectrum v1.0.

drop of solder - Finalization of the Pentagon to work with high-density disks.

SOFTWARE - New demoscene: ENTER the MIND, LOST MEMORY, PARANOIA, GARLIC RESPIRATION, CRAZY LOVE, MORBID VISION, AIR SPACE, REFRESH, TV-X, HIGHER STSTE.

SOFTWARE - New game programs: ADMIRAL demo, KOLOBOK ZOOM 2, HOMER SIMPSON IN RUSSIA, THE BLACK RAVEN 2, BOOVIE 2.

SOFTWARE - New System Software: UNIVERSAL VIEWER v1.0, MODERN WORD v1, GLOBAL COMMANDER v1.21, BEST VIEW v2.4, REFRESH OPTIMIZER.

SOFTWARE - Complete walkthrough "Mirror".

SOFTWARE - plans to build ELITE filled with graphics.

CODING - DITHERING - dithering as it is.

CODING - The printing of tektstovyh lines of BASIC.

CODING - Adapting programs to TR-DOS (load levels)

ANOTHER WORLD - PENTIUM II Xeon - high-speed version of the processor.

ANOTHER WORLD - wrangle (about the magazine AMIGA RULES).

ANOTHER WORLD - The case of Moscow Hacker.

Hall of Fame - Excerpts from a conversation on the second day of Fun Top-98: Alex (R), Kano, Boss, Mitchell, Daniel, Serzh.

Hall of Fame - An Interview with XPEh.

Hall of Fame - What is the creator of Tetris is engaged in MicroSoft.

Hall of Fame - Crime - a hit by Triumph: the history of the Spectrum in Chelyabinsk.

Hall of Fame - Presumption of innocence: the illegal distribution of the magazine.

Hall of Fame - Irish Stew (demos of programs).

Hall of Fame - VIRTUAL TR-DOS - what is it? (On the Internet site). News.

Hall of Fame - No comment.

Hall of Fame - On the intro and demah, etc., that you can not do cool.

Hall of Fame - On CD-ROM project from the city of Kemerovo.

Seven and 1 / 2 - Fun Russian radio.

Seven and 1 / 2 - Jokes about programmers.

Seven and 1 / 2 - VIRTUAL-but AMIG-LIMITED syndrome VI or Siberian nuggets: Adventures Kemerovo spektrumistov.

attempt at writing - An excerpt from the novel: Labyrinth of Reflections.

attempt at writing - Poems Bazhenova: pent, ponimaesh-sh-NIL ... reasons to rejoice a bit early October rain, cold ..., REMEMBER!, Loneliness, Waves splash over poop ... ozhdayas, we are here and die ... At perekretke two worlds.

attempt at writing - Notes by the Editor.

attempt at writing - The Nine Lives of Clare.

Advertising - Advertisements and announcements ...


Темы: Игры, Программное обеспечение, Пресса, Аппаратное обеспечение, Сеть, Демосцена, Люди, Программирование

Similar articles:
Overview of new products - Alcemist.
Iron - Connection Pal / Secam modulator of Dendy.
Entry - the contents of rooms.

В этот день...   23 November