Go to the documentation of this file. 50 #include <sys/types.h> 53 #define DFmovmem(from, to, len) bcopy(from, to, len) 56 #define UINT16READ(p, x) { x = ((*p++) & 255)<<8; x |= (*p++) & 255; } 57 #define INT16READ(p, x) { x = (*p++)<<8; x |= (*p++) & 255; } 58 #define INT32READ(p, x) { x = (*p++)<<24; x|=((*p++) & 255)<<16; \ 59 x|=((*p++) & 255)<<8; x|=(*p++) & 255; } 60 #define UINT16WRITE(p, x) { *p++ = (x>>8) & 255; *p++ = x & 255; } 61 #define INT16WRITE(p, x) { *p++ = (x>>8) & 255; *p++ = x & 255; } 62 #define INT32WRITE(p, x) { *p++ = (x>>24) & 255; *p++ = (x>>16) & 255; \ 63 *p++ = (x>>8) & 255; *p++ = x & 255; } 65 #define DF_CREAT(name, prot) creat(name, prot) 67 #define DF_MT DFMT_IRIX 72 #if ! defined mc68010 && ! defined mc68020 && ! defined mc68030 76 #define DFmovmem(from, to, len) memcpy(to, from, len) 78 #define UINT16READ(p, x) { x = ((*p++) & 255)<<8; x |= (*p++) & 255; } 79 #define INT16READ(p, x) { x = (*p++)<<8; x |= (*p++) & 255; } 80 #define INT32READ(p, x) { x = (*p++)<<24; x|=((*p++) & 255)<<16; \ 81 x|=((*p++) & 255)<<8; x|=(*p++) & 255; } 82 #define UINT16WRITE(p, x) { *p++ = (x>>8) & 255; *p++ = x & 255; } 83 #define INT16WRITE(p, x) { *p++ = (x>>8) & 255; *p++ = x & 255; } 84 #define INT32WRITE(p, x) { *p++ = (x>>24) & 255; *p++ = (x>>16) & 255; \ 85 *p++ = (x>>8) & 255; *p++ = x & 255; } 87 #define DF_CREAT(name, prot) creat(name, prot) 88 #define DF_MT DFMT_IBM6000 92 #if ! defined mc68010 && ! defined mc68020 && ! defined mc68030 97 #define uint8 unsigned char 98 #define int16 short int 99 #define uint16 unsigned short int 100 #define int32 long int 101 #define uint32 unsigned long int 102 #define float32 float 103 #define DFmovmem(from, to, len) memcpy(to, from, len) 105 #define UINT16READ(p, x) { x = ((*p++) & 255)<<8; x |= (*p++) & 255; } 106 #define INT16READ(p, x) { x = (*p++)<<8; x |= (*p++) & 255; } 107 #define INT32READ(p, x) { x = (*p++)<<24; x|=((*p++) & 255)<<16; \ 108 x|=((*p++) & 255)<<8; x|=(*p++) & 255; } 109 #define UINT16WRITE(p, x) { *p++ = (x>>8) & 255; *p++ = x & 255; } 110 #define INT16WRITE(p, x) { *p++ = (x>>8) & 255; *p++ = x & 255; } 111 #define INT32WRITE(p, x) { *p++ = (x>>24) & 255; *p++ = (x>>16) & 255; \ 112 *p++ = (x>>8) & 255; *p++ = x & 255; } 114 #define DF_CREAT(name, prot) creat(name, prot) 115 #define DF_MT DFMT_APOLLO 121 #define DF_OPEN(x,y) fopen(x,y) 122 #define DF_CLOSE(x) fclose(x) 123 #define DF_SEEK(x,y,z) fseek(x,y,z) 124 #define DF_SKEND(x,y,z) fseek(x,y,z) 125 #define DF_TELL(x) ftell(x) 126 #define DF_READ(a,b,c,d) fread(a,b,c,d) 127 #define DF_WRITE(a,b,c,d) fwrite(a,b,c,d) 128 #define DF_FLUSH(a) fflush(a) 129 #define DF_OPENERR(f) (!(f)) 130 #define DF_RDACCESS "rb" 131 #define DF_WRACCESS "rb+" 134 #define DF_OPEN(x,y) open(x,y) 135 #define DF_CLOSE(x) close(x) 136 #define DF_SEEK(x,y,z) lseek(x,y,z) 137 #define DF_SKEND(x,y,z) lseek(x,-1*y,z) 138 #define DF_TELL(x) lseek(x,0L,1) 139 #define DF_READ(a,b,c,d) read(d,a,b*c) 140 #define DF_WRITE(a,b,c,d) write(d,a,b*c) 141 #define DF_OPENERR(f) ((f) == -1) 143 #define DF_RDACCESS O_RDONLY 144 #define DF_WRACCESS O_RDWR
MISR Toolkit - Copyright © 2005 - 2020 Jet Propulsion Laboratory
Generated on Fri Jun 19 2020 22:49:52