SUBROUTINE UA_SHDR ( report, lenr, irptr, iret ) C************************************************************************ C* UA_SHDR * C* * C* This subroutine decodes the header from an upper-air report. * C* * C* UA_SHDR ( REPORT, LENR, IRPTR, IRET ) * C* * C* Input parameters: * C* REPORT CHAR* Report * C* LENR INTEGER Length of REPORT * C* * C* Input and output parameters: * C* IRPTR INTEGER Pointer within REPORT * C* * C* Output parameters: * C* IRET INTEGER Return code: * C* 0 = Normal return * C* -1 = critical error in REPORT * C* or reached end of REPORT * C** * C* Log: * C* J. Ator/NCEP 03/96 * C* J. Ator/NCEP 12/97 New interface format, style changes * C* J. Ator/NCEP 10/99 Clean up function declarations * C************************************************************************ INCLUDE 'GEMPRM.PRM' INCLUDE 'uacmn.cmn' C* CHARACTER*(*) report C------------------------------------------------------------------------ iret = 0 C IF ( ( stntyp .eq. SHIP ) .or. ( stntyp .eq. MOBIL ) ) THEN C C* Decode the ship or mobil land station ID. C CALL UA_STID ( report, lenr, irptr, iret ) IF ( iret .lt. 0 ) THEN RETURN END IF END IF C C* Decode the date (i.e. day/hour). C CALL UA_DDTE ( report, lenr, irptr, iret ) IF ( iret .lt. 0 ) THEN RETURN END IF C IF ( stntyp .eq. LAND ) THEN C C* Decode the land station number. C CALL UA_STNM ( report, lenr, irptr, iret ) IF ( iret .lt. 0 ) THEN RETURN END IF ELSE C C* Decode the latitude, longitude, and marsden square. C CALL UA_DLLM ( report, lenr, irptr, iret ) IF ( iret .lt. 0 ) THEN RETURN END IF C IF ( stntyp .eq. MOBIL ) THEN C C* Decode the elevation. C CALL UA_MELV ( report, lenr, irptr, iret ) IF ( iret .lt. 0 ) THEN RETURN END IF END IF END IF C* RETURN END