title Module from library BASE_2 : HHMMSS name ('HHMMSS') maclib baselib.lib ; Convert time to format hh:mm:ss ; Copyright (C) Werner Cirsovius ; Hohe Weide 44 ; D-20253 Hamburg ; Tel.: +49-40-4223247 ; Version 1.0 December 1992 ; ENTRY Reg HL points to string to be filled ; Reg B holds character to be stored at the end ; Reg C holds delimiter between data ; EXIT Reg HL points to end character entry hhmmss ext getclk,putbcd hhmmss: push de push hl call getclk ; Get clock pop hl push bc ld b,3 ; Set loop time1: ld a,(de) inc de call putbcd ; Save time ld (hl),c inc hl djnz time1 dec hl pop bc ld (hl),b ; Close line pop de ret end