From: sparky4 Date: Sat, 23 May 2015 21:39:06 +0000 (-0500) Subject: added memory images~ X-Git-Url: http://4ch.mooo.com/gitweb/?a=commitdiff_plain;h=b94851eef9966b4d5e1f2da0f3266182ff0a5a47;p=16.git added memory images~ new file: doc/fig1-1_i.pcx new file: doc/fig1-1_i.png new file: doc/upmem.pcx modified: src/lib/exmm/emm.c --- diff --git a/doc/fig1-1_i.pcx b/doc/fig1-1_i.pcx new file mode 100644 index 00000000..0de1cbde Binary files /dev/null and b/doc/fig1-1_i.pcx differ diff --git a/doc/fig1-1_i.png b/doc/fig1-1_i.png new file mode 100644 index 00000000..76eb39d6 Binary files /dev/null and b/doc/fig1-1_i.png differ diff --git a/doc/upmem.pcx b/doc/upmem.pcx new file mode 100644 index 00000000..e3532d9e Binary files /dev/null and b/doc/upmem.pcx differ diff --git a/src/lib/exmm/emm.c b/src/lib/exmm/emm.c index f50a91aa..aed6c3b7 100644 --- a/src/lib/exmm/emm.c +++ b/src/lib/exmm/emm.c @@ -19,7 +19,9 @@ #include #include -#include "memory.h" +#include "memory.h" + +#define PEMMDATAPAGENUM 4 void TransformData(char *pEmmData, unsigned int len) { @@ -71,7 +73,7 @@ int main(int argc, char *argv[]) printf("Map 1st 4 pages\n"); - MapEMM(hEData, 0, 4); // load 1st 4 pages into page frame: 0-3 + MapEMM(hEData, 0, PEMMDATAPAGENUM); // load 1st 4 pages into page frame: 0-3 //memset(pEmmData, 0x0e, 64000u); //0000 printf("(advi*EMMPAGESIZE)=%lu\n", advi); memset(pEmmData, atoi(argv[1]), 0xffff);//sizeof(atoi(argv[1])));//((EMMCoreLeft())*EMMPAGESIZE)); @@ -123,7 +125,7 @@ int main(int argc, char *argv[]) }*/ if(!atoi(argv[3])) { - UnmapEMM(hEData, 0, 4); // should unmap before freeing + UnmapEMM(hEData, 0, PEMMDATAPAGENUM); // should unmap before freeing //printf("after EMS *pEmmData=%c\n", *pEmmData); printf("Close emm\n"); EMMFree(hEData); // finished with the file data