ocssw  1.0
Classes | Defines
/disk01/web/ocssw/build/inc/swfinc/initsetup.h File Reference

(r8085/r3)

#include "usrhdr.h"
#include "usrmac.h"
#include "initsetup_proto.h"

Go to the source code of this file.

Classes

struct  initParamType
struct  initBlockType

Defines

#define PARAMBLOCK_INC   5
#define PARAMTYPE_intType   1
#define PARAMTYPE_shortType   2
#define PARAMTYPE_longType   3
#define PARAMTYPE_floatType   4
#define PARAMTYPE_doubleType   5
#define paramblockdef(bnam)   initBlockType bnam
#define paramblockinit(bnam, fnam)
#define paramblockinc(bnam)
#define PARAMTYPECONST(typ)   PARAMTYPE_ ## typ ## Type
#define paramdef(nam, typ)   typ nam
#define parammark(bnam, nam, typ, cnt)

Define Documentation

#define PARAMBLOCK_INC   5

Definition at line 32 of file initsetup.h.

#define paramblockdef (   bnam)    initBlockType bnam

Definition at line 60 of file initsetup.h.

#define paramblockinc (   bnam)
Value:
{ \
    if (bnam.nuse >= bnam.nmax) { \
        bnam.nmax += PARAMBLOCK_INC ; \
        bnam.params = (initParamType *)realloc(bnam.params,bnam.nmax * sizeof(initParamType)) ; \
    } \
}

Definition at line 69 of file initsetup.h.

#define paramblockinit (   bnam,
  fnam 
)
Value:
{ \
    bnam.fname = fnam; \
    bnam.name = #bnam ; \
    bnam.nmax = 0 ; \
    bnam.nuse = 0 ; \
    bnam.params = NULL ; \
}

Definition at line 61 of file initsetup.h.

#define paramdef (   nam,
  typ 
)    typ nam

Definition at line 77 of file initsetup.h.

#define parammark (   bnam,
  nam,
  typ,
  cnt 
)
Value:
{ \
    /* increase holding area if needed */ \
    paramblockinc(bnam) ; \
    /* fill in values in the structure */ \
    bnam.params[bnam.nuse].name = #nam ; \
    bnam.params[bnam.nuse].type = PARAMTYPECONST(typ) ; \
    bnam.params[bnam.nuse].count = cnt ; \
    bnam.params[bnam.nuse].size = sizeof(typ) ; \
    bnam.params[bnam.nuse].data = (void *)&(nam) ; \
    /* increase counter */ \
    bnam.nuse ++ ; \
}

Definition at line 78 of file initsetup.h.

#define PARAMTYPE_doubleType   5

Definition at line 38 of file initsetup.h.

#define PARAMTYPE_floatType   4

Definition at line 37 of file initsetup.h.

#define PARAMTYPE_intType   1

Definition at line 34 of file initsetup.h.

#define PARAMTYPE_longType   3

Definition at line 36 of file initsetup.h.

#define PARAMTYPE_shortType   2

Definition at line 35 of file initsetup.h.

#define PARAMTYPECONST (   typ)    PARAMTYPE_ ## typ ## Type

Definition at line 76 of file initsetup.h.