80-Bus News

  

January-February 1983, Volume 2, Issue 1











Page 23 of 56











23

If no errors occur, SIMON transfers program control to 00002H, in the COLD Boot. The first instruction is a LD HL, ADDR where ADDR is the start address of the CCP – DS00H in the case under discussion. The BOOT now reads in more sectors from the disk, loading the data direct to D800H and so on, until the system is all loaded. Near the end of the BOOT isa JP ADDR1 instruction, where ADDR1 is the cold start address of the CBIOS. (OEREOOH in this case).

(N.B. ADDR and ADDR1 are both relocation addresses, altered by MOVCPM, and they will vary with system size.)

in at sk te i ee i i KEEREEEEE

The System Track on the Disk.

ee tS NS SS Sm Sm

Ke ee ee 20 x 512 bytes = 10K bytes total--------------.-.. >

Sec.No=0 1 2 3 4 5 6 7 8 9 1011 121314 15 1617 18 19 [--] [--1--1--1--] [--1--1--1--1--1--1--] [--1--1--1--1--1--1--1--]

sector 0 = .5K 1 1 1 including 1 1 L Cold Boot Loader i i 1 1 1 1

Sectors 1 – 4 Sectors 5 – 11 Sectors 12 – 19

= 2K CP/M CCP = 4.5K BDOS Space for CBIOS

(4K Maximum )

Figure 2. System Track Layout

Fig.2 shows diagramatically how CP/M relates to the Disk. The GEMINI DS/DD system uses Tracks of 10 sectors on each side of the disk. The tracks of side O and side 1 combine to make up one 20 sector track. Fach sector holds 512 bytes (.5K) of data so the total capacity of one track is 10K bytes. There are 35 tracks, numbered from 0 to 34, so disk capacity is 350K. Track 0 is reserved for the CP/M system, and eight sectors (4K) of track 1 are reserved for the Directory. This leaves 336K for user programs. Fig. 2 shows that sector 0 of the system track holds the COLD BOOT LOADER. The CCP is in sectors 1-4, and the BDOS in sectors 5-11. This leaves a maximum of ® sectors for the CBIOS. (4K)

A look at the RAM MAP in Fig. 3 shows that CBIOS space is available from OREOOH to OFFFFH, equal to 4.5K. When I assemble SYS the final size is around 4.5% including workspaces and buffers (and also includes neariy 400 bytes for code expansion). There is enough of room in RAM for SYS CBIOS but there is a shortfall of .5K on the disk.

The clue to the solution of this problem lies in the paragraph above. There is no real need to hold Buffer space on the Disk as it is only used when the system is running in RAM. There are 512 bytes for a sector byffer and 128 bytes for a directory buffer located near the start of the Disk Routines in the SYS Source code. If the System track is examined with a PEEK program, these Buffers appear as large blocks of OO characters within the BIOS sectors. I moved these two Buffers by deleting their definition statements at the old position in the ‘SYS’ source code, and re-entering them after the CBIOS Workspace at the end of the Source Code. To make the addresses come right it was also necessary to delete three assembler directives – ".dephase” at the end of Read Section, just before the workspace, and the “org pbios+11a0h" and ".phase bios16+11a0h" directives just at the start of the workspace. The net result is that the operative SYS code and workspace only ammount to about 3.5K bytes. (The workspace should be held on


This is an OCR’d version of the scanned page and likely contains recognition errors.











Page 23 of 56