.TITLE CDATDA .IDENT /V01/ .ENABLE LC ; ; This module forms part of the suite of Date Routines returning the ; current date in one of the following forms, or converting one form to ; another. ; Form I - Day, Month & Year since 1950 as 3 byte values ; Form A - ASCII DD-MMM-YY ; Form D - Integer*2 days since 1st January 1950 ; Form E - Integer*2 encoded date ; Form W - Weekday Number (0 = Sunday) ; ; Author: V01 30-Jun-80 Phil Stephensen-Payne ; ; Calling Sequence: ; ; This subroutine is called via the standard FORTRAN calling sequence as: ; ; CALL CDATDA (DAYNO,DATE [,STATUS]) ; or ; STATUS = CDATDA (DAYNO,DATE) ; or ; CALL CDATDA from MACRO-11 (with R5=0) ; ; Where: ; DAYNO = Number of days since 1/1/50 (1/1/50 = 1) ; (R1 for MACRO calls) ; DATE = ASCII date in form DD-MMM-YY ; (address in R1 for input,R4 for output for MACRO calls) ; STATUS = Optional error return ; ; Errors returned: ; ; STATUS = 0 if the operation was successful ; = -1 if a parameter error was detected ; = -2 if an invalid input date was specified ; ; External references: ; ; This module calls the subroutines PRMCHK,DISP,GETD,PUTA,CDATDI,CDATIA ; ; ; CDATDA:: CALL DISP ; Call the dispatcher .WORD GETD ; Get Type D .WORD CDATDI ; Convert to Type I .WORD CDATIA ; Convert that to Type A .WORD PUTA ; And store A .END