DataMuseum.dk

Presents historical artifacts from the history of:

Commodore CBM-900

This is an automatic "excavation" of a thematic subset of
artifacts from Datamuseum.dk's BitArchive.

See our Wiki for more about Commodore CBM-900

Excavated with: AutoArchaeologist - Free & Open Source Software.


top - download

⟦5029a2ee6⟧ TextFile

    Length: 489 (0x1e9)
    Types: TextFile
    Notes: UNIX file
    Names: »sclear.c«

Derivation

└─⟦f27320a65⟧ Bits:30001972 Commodore 900 hard disk image with partial source code
    └─⟦2d53db1df⟧ UNIX V7 Filesystem
        └─ ⟦this⟧ »frankh/tmp/sclear.c« 
└─⟦f27320a65⟧ Bits:30001972 Commodore 900 hard disk image with partial source code
    └─⟦926b8033d⟧ UNIX V7 Filesystem
        └─ ⟦this⟧ »u/demo/slide/sclear.c« 

TextFile

#include <stdio.h>
#define SEG0 ((unsigned short *)(0x3a000000L))
#define SEG1 ((unsigned short *)(0x3b000000L))
#define YSPLIT 512
#define XMAX 1024
#define YMAX 800
#define BPW 16
#define XB (XMAX/BPW)

main(argc,argv)
char **argv;
{
	unsigned short n;
	unsigned short *sp;
	unsigned short c = 0;
	sp = SEG0;
	if((argc > 1)&&(**++argv == 'w')) 
		c = 0xffff;
	sp[0] = c;
	ldir(sp+1,sp,(unsigned int)32767);
	sp = SEG1;
	sp[0] = c;
	ldir(sp+1,sp,(unsigned int)((800-512) * (1024/16)));
}