llvm-mos-sdk
Classes | Macros | Enumerations | Functions | Variables
cpm.h File Reference
#include <stdint.h>
Include dependency graph for cpm.h:

Go to the source code of this file.

Classes

struct  DRIVER
 

Macros

#define cpm_get_user()   cpm_get_set_user(0xff)
 
#define cpm_set_user(u)   cpm_get_set_user(u)
 

Enumerations

enum  {
  CPME_OK = 0x00, CPME_NOBLOCK = 0x01, CPME_DISKFULL = 0x02, CPME_CANTCLOSE = 0x03,
  CPME_NOEXTENT = 0x04, CPME_DIRFULL = 0x05, CPME_BADFCB = 0x09, CPME_FAILED = 0xff
}
 
enum  { CONIO_READ_POLLING = 0xff00, CONIO_READ_BLOCKING = 0xfd00 }
 

Functions

void cpm_printstring (const char *s)
 
uint8_t cpm_readline (uint8_t *buffer)
 
uint8_t cpm_open_file (FCB *fcb)
 
uint8_t cpm_close_file (FCB *fcb)
 
uint8_t cpm_findfirst (FCB *fcb)
 
uint8_t cpm_findnext (FCB *fcb)
 
uint8_t cpm_delete_file (FCB *fcb)
 
uint8_t cpm_read_sequential (FCB *fcb)
 
uint8_t cpm_write_sequential (FCB *fcb)
 
uint8_t cpm_make_file (FCB *fcb)
 
uint8_t cpm_rename_file (RCB *rcb)
 
void cpm_set_dma (void *ptr)
 
uint8_t * cpm_get_allocation_vector (void)
 
uint8_t cpm_set_file_attributes (FCB *fcb)
 
DPBcpm_get_dpb (void)
 
uint8_t cpm_read_random (FCB *fcb)
 
uint8_t cpm_write_random (FCB *fcb)
 
void cpm_seek_to_end (FCB *fcb)
 
void cpm_seek_to_seq_pos (FCB *fcb)
 
uint8_t cpm_write_random_filled (FCB *fcb)
 
const char * cpm_parse_filename (const char *buffer)
 
uint16_t cpm_bios_seldsk_i (uint8_t disk)
 
DPHcpm_bios_seldsk (uint8_t disk)
 
void cpm_bios_setsec (uint32_t *sector)
 
void cpm_bios_setdma (void *dma)
 
void cpm_bios_adddrv (DRIVER *driver)
 
void * cpm_bios_finddrv (uint16_t id)
 

Variables

 FCB
 
 RCB
 
 DIRE
 
 DPB
 
 DPH
 
FCB cpm_fcb
 
FCB cpm_fcb2
 
uint8_t cpm_default_dma [128]
 
uint8_t cpm_ram []
 
uint8_t cpm_cmdlinelen
 
char cpm_cmdline [0x7f]
 
uint8_t cpm_errno
 
uint8_t mem
 
uint8_t end
 

Macro Definition Documentation

◆ cpm_get_user

#define cpm_get_user ( )    cpm_get_set_user(0xff)

◆ cpm_set_user

#define cpm_set_user (   u)    cpm_get_set_user(u)

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
CPME_OK 
CPME_NOBLOCK 
CPME_DISKFULL 
CPME_CANTCLOSE 
CPME_NOEXTENT 
CPME_DIRFULL 
CPME_BADFCB 
CPME_FAILED 

◆ anonymous enum

anonymous enum
Enumerator
CONIO_READ_POLLING 
CONIO_READ_BLOCKING 

Function Documentation

◆ cpm_bios_adddrv()

void cpm_bios_adddrv ( DRIVER driver)

◆ cpm_bios_finddrv()

void* cpm_bios_finddrv ( uint16_t  id)

◆ cpm_bios_seldsk()

DPH* cpm_bios_seldsk ( uint8_t  disk)

◆ cpm_bios_seldsk_i()

uint16_t cpm_bios_seldsk_i ( uint8_t  disk)

◆ cpm_bios_setdma()

void cpm_bios_setdma ( void *  dma)

◆ cpm_bios_setsec()

void cpm_bios_setsec ( uint32_t *  sector)

◆ cpm_close_file()

uint8_t cpm_close_file ( FCB fcb)

◆ cpm_delete_file()

uint8_t cpm_delete_file ( FCB fcb)

◆ cpm_findfirst()

uint8_t cpm_findfirst ( FCB fcb)

◆ cpm_findnext()

uint8_t cpm_findnext ( FCB fcb)

◆ cpm_get_allocation_vector()

uint8_t* cpm_get_allocation_vector ( void  )

◆ cpm_get_dpb()

DPB* cpm_get_dpb ( void  )

◆ cpm_make_file()

uint8_t cpm_make_file ( FCB fcb)

◆ cpm_open_file()

uint8_t cpm_open_file ( FCB fcb)

◆ cpm_parse_filename()

const char* cpm_parse_filename ( const char *  buffer)

◆ cpm_printstring()

void cpm_printstring ( const char *  s)

◆ cpm_read_random()

uint8_t cpm_read_random ( FCB fcb)

◆ cpm_read_sequential()

uint8_t cpm_read_sequential ( FCB fcb)

◆ cpm_readline()

uint8_t cpm_readline ( uint8_t *  buffer)

◆ cpm_rename_file()

uint8_t cpm_rename_file ( RCB rcb)

◆ cpm_seek_to_end()

void cpm_seek_to_end ( FCB fcb)

◆ cpm_seek_to_seq_pos()

void cpm_seek_to_seq_pos ( FCB fcb)

◆ cpm_set_dma()

void cpm_set_dma ( void *  ptr)

◆ cpm_set_file_attributes()

uint8_t cpm_set_file_attributes ( FCB fcb)

◆ cpm_write_random()

uint8_t cpm_write_random ( FCB fcb)

◆ cpm_write_random_filled()

uint8_t cpm_write_random_filled ( FCB fcb)

◆ cpm_write_sequential()

uint8_t cpm_write_sequential ( FCB fcb)

Variable Documentation

◆ cpm_cmdline

char cpm_cmdline[0x7f]

◆ cpm_cmdlinelen

uint8_t cpm_cmdlinelen

◆ cpm_default_dma

uint8_t cpm_default_dma[128]

◆ cpm_errno

uint8_t cpm_errno

◆ cpm_fcb

FCB cpm_fcb

◆ cpm_fcb2

FCB cpm_fcb2

◆ cpm_ram

uint8_t cpm_ram[]

◆ DIRE

DIRE

◆ DPB

DPB

◆ DPH

DPH

◆ end

uint8_t end

◆ FCB

FCB

◆ mem

uint8_t mem

◆ RCB

RCB