jmce - 1_02

jmce.sim.cpm
Class DPB

java.lang.Object
  extended by jmce.sim.cpm.DPB
Direct Known Subclasses:
DPB3740, DPBYAHD, DPBZPHD

public class DPB
extends java.lang.Object

CP/M Disk parameter block.

This class rappresent a CP/M 2.2 Disk Parameter Block.

Version:
1.00
Author:
Mario Viara

Field Summary
static int AL0
          Directory allocation map byte 0 AT 09
static int AL1
          Directory allocation map byte 0 AT 0A
static int BLM
          Data allocation block mask
static int BSH
          Block shift factor.
static int CHS
          Number of checked sector for disk change. 2 Bytes AT 0B
static int DRM
          Total number of directory - 1. 2 Bytes AT 07
static int DSM
          Total number of block -1. 2 Bytes AT 05
static int EXM
          Extent mask number of extents per directory.
static int OFF
          Number of reserved track. 2 Byte at 0D
static int SECSIZ
          Sector size for CP/M 2.2 disk
static int SPT
          Total number of 128 bytes sector per track. (2 bytes) AT 0
 
Constructor Summary
DPB(int spt, int bsh, int blm, int exm, int dsm, int drm, int al0, int al1, int cks, int off)
           
 
Method Summary
 int getAL0()
           
 int getAL1()
           
 int getBLM()
           
 int getBSH()
           
 int getDRM()
          Get number of directory - 1
 int getDSM()
          Return the total number of block.
 int getEXM()
           
 int getOFF()
           
 int getSPT()
          Return the number of 128 bytes sector x track
 int getTRK()
           
 void setTranslation(int[] vector)
           
 int translateSector(int s)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

SECSIZ

public static final int SECSIZ
Sector size for CP/M 2.2 disk

See Also:
Constant Field Values

SPT

public static final int SPT
Total number of 128 bytes sector per track. (2 bytes) AT 0

See Also:
Constant Field Values

BSH

public static final int BSH
Block shift factor. Ex 3 Block size is 128 << 3 == 1024.AT 2

See Also:
Constant Field Values

BLM

public static final int BLM
Data allocation block mask. (2 ^ BSH) - 1. AT 03

See Also:
Constant Field Values

EXM

public static final int EXM
Extent mask number of extents per directory. AT 04

See Also:
Constant Field Values

DSM

public static final int DSM
Total number of block -1. 2 Bytes AT 05

See Also:
Constant Field Values

DRM

public static final int DRM
Total number of directory - 1. 2 Bytes AT 07

See Also:
Constant Field Values

AL0

public static final int AL0
Directory allocation map byte 0 AT 09

See Also:
Constant Field Values

AL1

public static final int AL1
Directory allocation map byte 0 AT 0A

See Also:
Constant Field Values

CHS

public static final int CHS
Number of checked sector for disk change. 2 Bytes AT 0B

See Also:
Constant Field Values

OFF

public static final int OFF
Number of reserved track. 2 Byte at 0D

See Also:
Constant Field Values
Constructor Detail

DPB

public DPB(int spt,
           int bsh,
           int blm,
           int exm,
           int dsm,
           int drm,
           int al0,
           int al1,
           int cks,
           int off)
Method Detail

getSPT

public int getSPT()
Return the number of 128 bytes sector x track


getDSM

public int getDSM()
Return the total number of block.


getDRM

public int getDRM()
Get number of directory - 1


getBSH

public int getBSH()

getOFF

public int getOFF()

setTranslation

public void setTranslation(int[] vector)

translateSector

public int translateSector(int s)

getAL0

public int getAL0()

getAL1

public int getAL1()

getBLM

public int getBLM()

getTRK

public int getTRK()

getEXM

public int getEXM()

jmce - 1_02