Assembly language training course - apologies for the delay in the release of the second lesson in our training course.

╔══════════════════════════════ ═══════════════════════════════╗
║ ▒▒░░░░░░░░░░░░░░▒▒ Assembly language training course ▒▒░░░░░░░░░░░▒▒ ║
╚══════════════════════════════ ═══════════════════════════════╝

 (C) WLODEK BLACK

Hello friends! First of all, I want to apologize for
delay in the release of the second lesson of our training course. EU-
Is the programmer always missing one byte to accommodate
entire program, then I was missing one (well, maybe two) minutes -
you to tidy up the source text of the second lesson.  De-
The point is that these texts were written at one time for the platform
MSX, which is similar to the Spectrum mainly in its use
the same processor. But the text format is far from ZX-Word-ish
go and is 80 characters per line in the YAB encoding
TsDEFGH..." And now there’s time for recoding and rearranging
and it wasn’t enough! By the way, the examples in it are entirely MSX...
In order not to disfigure the text with ridiculous corrections, I, perhaps,
I’ll put everything as it is, and I’ll provide links to Spectrum as additional
nious comments. :-)

		   002h. MICROPROCESSOR Z80A.

   For a programmer, a processor is primarily a set of registers, in
which you can place data and perform transformations on them
vaniya. Here is a complete list of registers on the Z80A processor:

PC - 16-bit program counter. Contains those
     current address in memory froma sample of co-codes is made
     mand. The natural course of program execution is from the youngest
     addresses to elders.

A - 8-bit accumulator register. Is the main one for pro-
     conducting arithmetic and logical operations over 8-bit
     data.

F - register of flags (signs). Individual bits of this register
     carry information about the results of arithmetic, logical
     and some other operations (for example, shifts) (signs
     zero, carry, negative number, etc.).   In some
     In some cases, registers A and F can be treated as 16-bit
     naya pair AF.

	General purpose register group: H,L,D,E,B,C:

The name "general purpose registers" means that these registers
can be used simply for storing data. To work with 16-
By bit data they can be combined into pairs HL, DE, BC.
As 16-bit pairs, these registers have a wider purpose.
tion:

HL - provides the most powerful indirect memory addressing;
     used as a 16-bit battery in opera-
     tions over 16-bit data.  The mnemonic is derived from
     the words High (upper) and Low (lower);

DE - can be used for indirect addressing of the battery;

BC - used for indirect addressing of 64 KB pro-
     I/O device destinations;  can also indirectly
     address the battery.

Notes:1. Features of register pairs are mentioned only in
in my general form;
2. Their use will be discussed in detail later,
For now, you can ignore the unclear terms.

		Index register group:

IX and IY are 16-bit index registers. Their use is particularly
but it is convenient when processing tables, lists, etc. structures, since
they provide easy access to data based on the principle: known
the address of the beginning of the array and the number of the array element, and to obtain the required
The value of the array element is determined.

			Other registers:

SP - 16-bit stack pointer.  The stack is
     a memory area allocated anywhere in RAM, organized
     according to the principle of a stack of sheets of paper: it is filled sequentially
     It’s clear how sheets of paper are placed one on top of the other.  Last-
     The sheet placed on the bottom is removed first. The stack is used to
     temporary storage of return addresses from subroutines (analogue
     BASIC structure GOSUB - RETURN) and 16-bit values
     ny any register pairs. SP indicates the last occupied
     that cell, as if preparing to read it immediately.  Stack
     "grows" down (from high to low addresses).

I - interrupt vector register; a detailed conversation will follow;

R - RAM regeneration register. This is an auxiliary register,
     the value of which is determined by the hardware features -
     mi computer. The thing is,what is the so-called "dynamic"
     RAM" requires periodic access to it, otherwise it will
     “forgets” the information stored in it. But when performing re-
     the processor does not
     applies at all or applies very rarely. With the help of re-
     hyster R processor continuously, sequentially and invisibly
     for the executable program, it enumerates memory addresses, ensuring
     maintaining the storage of information. If register R
     did not exist, the electrical circuit would have to be complicated
     computer, introducing into it a separate device for regenerating
     tions of memory. The R register is accessible by software; since he is working
     melts independently, it can be used to obtain
     tea numbers.

    Additional set of registers: A',F',H',L',D',E',B',C':

These registers are completely similar to their main "doubles", but
Only one of the sets can be accessed. With the help of intended
commands assigned for this purpose, you can switch to another set, and
all commands accessing these registers will act on
newly connected set. The previous set will become inactive,
but the data in its registers is retained. Both sets are completely ra-
have legal rights. It is impossible to programmatically determine which of them is physically
chesically active. Existing switching commands affect
separately for AF and HL, DE, BC.
Except the EX teamAF,AF',the symbol "'" is not used in mnemonics
commands For other registers it is used only in descriptions,
in order to emphasize that we are talking about an alternative register.

[End of text 2].
						WLODEK BLACK

Share your thoughts about the article