DataMuseum.dk

Presents historical artifacts from the history of:

CP/M

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

See our Wiki for more about CP/M

Excavated with: AutoArchaeologist - Free & Open Source Software.


top - download

⟦e2c9f2899⟧ TextFile

    Length: 2048 (0x800)
    Types: TextFile
    Names: »STRKONV.A86«

Derivation

└─⟦490a8e2df⟧ Bits:30003937 SW1501 RcComal-80 v3.0 (thykier)
    └─ ⟦this⟧ »STRKONV.A86« 
└─⟦72a4952a6⟧ Bits:30004362 SW1501 RcComal-80 v3.0
    └─ ⟦this⟧ »STRKONV.A86« 
└─⟦dcb507fe6⟧ Bits:30003936 SW1501 RcComal-80 v3.0 (ils)
    └─ ⟦this⟧ »STRKONV.A86« 

TextFile


CSEG

CSEG
VER		DW 	VERSNO		;
PACKTYPE	DW	ASSEMBLER	;
DOC		DW	DSTRKONV	;
INIT		DW	OFFSET FINITO	;
EXIT		DW	0		;


       		DB	5, 'UPPER'	;	procedure upper(REF mystr$);
		DB	PROC		;
		DW	OFFSET DUPPER	;
		DW	OFFSET XUPPER	;
		DB	1		;	1 parameter
      		DB	5, 'MYSTR'	;
		DB	REF+STRING,0	;	simple REF string

       		DB	5, 'LOWER'	;	procedure lower(REF mystr$);
		DB	PROC		;
		DW	OFFSET DLOWER	;
		DW	OFFSET XLOWER	;
		DB	1		;	1 parameter
      		DB	5, 'MYSTR'	;
		DB	REF+STRING,0	;	simple REF string


		DB	0		;	ikke flere proc og func
		DW	OFFSET RESERVER	;
		DW	ASSEMBLER	;


INCLUDE	ASSEMBL.A86



DSTRKONV DW	LENGTH DSTR		;
DSTR	DB	'konverterer strenge til små eller store bogstaver'


DLOWER	DW	LENGTH DLSTR		;
DLSTR	DB	'konverterer strengparameteren til små bogstaver'


XLOWER:	MOV	BP,RESERVER+6		;
	PUSH	DS			;
	MOV	DS,4ÆBPÅ		;	get_segment_for_parameter;
	MOV	ES,4ÆBPÅ		;	get_segment_for_parameter;
	MOV	SI,6ÆBPÅ		;	get_address_for_parameter;
	INC	SI			;	skip_max_length_of_parameter;
	INC	SI			;
	LODS	AX			;	get_length_of_parameter;
	MOV	CX,AX			;
L10:	OR	CL,CL			;
	JZ	L30			;
	MOV	DI,SI			;
	LODSB				;
	CMP	AL,'A'			;
	JB	L20			;
	CMP	AL,'Å'			;
	JA	L20			;
	ADD	AL,32			;
	STOSB				;
L20:	DEC	CX			;
	JMPS	L10			;
L30:	POP	DS			;
	JMP	FINITO			;



DUPPER	DW	LENGTH DUSTR		;
DUSTR	DB	'konverterer strengparameteren til store bogstaver'


XUPPER:	MOV	BP,RESERVER+6		;
	PUSH	DS			;
	MOV	DS,4ÆBPÅ		;	get_segment_for_parameter;
	MOV	ES,4ÆBPÅ		;	get_segment_for_parameter;
	MOV	SI,6ÆBPÅ		;	get_address_for_parameter;
	INC	SI			;	skip_max_length_of_parameter;
	INC	SI			;
	LODS	AX			;	get_length_of_parameter;
	MOV	CX,AX			;
U10:	OR	CL,CL			;
	JZ	U30			;
	MOV	DI,SI			;
	LODSB				;
	CMP	AL,'a'			;
	JB	U20			;
	CMP	AL,'å'			;
	JA	U20			;
	SUB	AL,32			;
	STOSB				;
U20:	DEC	CX			;
	JMPS	U10			;
U30:	POP	DS			;
	JMP	FINITO			;



END

«eof»