CFPRIME IECMNT                                                          IECMNT      1
C***********************************************************************RIGHTE      1
C*                                                                     *RIGHTE      2
C*        Extended Transient-Midterm Stability Program (ETMSP)         *RIGHTE      3
C*        ====================================================         *RIGHTE      4
C*                                                                     *RIGHTE      5
C*       Copyright (C) (1993) Electric Power Research Institute        *RIGHTE      6
C*                                                                     *RIGHTE      7
C* EPRI reserves all rights in the software and associated             *RIGHTE      8
C* documentation as delivered. The software and its associated         *RIGHTE      9
C* documention or any portion thereof may not be reproduced in any form*RIGHTE     10
C* whatsoever without the consent of EPRI, except as explicity provided*RIGHTE     11
C* for by license. Licensee shall submit a detailed description to EPRI*RIGHTE     12
C* of any changes or modifications to the software within two (2)      *RIGHTE     13
C* months after such changes or modifications are made. At EPRI's sole *RIGHTE     14
C* discretion, the software, as changed or modified, shall be given a  *RIGHTE     15
C* new designation sufficiently different from its then current        *RIGHTE     16
C* designation as to prevent mistake,confusion, or deception as between*RIGHTE     17
C* the current software as changed or modified.                        *RIGHTE     18
C*                                                                     *RIGHTE     19
C* A license under EPRI's rights in the software can be obtained       *RIGHTE     20
C* directly from EPRI.                                                 *RIGHTE     21
C*                                                                     *RIGHTE     22
C* This program and supporting materials may be independently available*RIGHTE     23
C* from Electric Power Software centre (EPSC) for an appropriate       *RIGHTE     24
C* distribution fee. The EPSC is a service of                          *RIGHTE     25
C*                                                                     *RIGHTE     26
C*                    Power Computing Company                          *RIGHTE     27
C*                    1930 Hi Line                                     *RIGHTE     28
C*                    Dallas, Tx 75207                                 *RIGHTE     29
C*                                                                     *RIGHTE     30
C* NEITHER EPRI, ANY MEMBER OF EPRI, NOR ANY PERSON OR  ORGANIZATION   *RIGHTE     31
C* ACTING ON BEHAVE OF THEM:                                           *RIGHTE     32
C*                                                                     *RIGHTE     33
C* 1. MAKE ANY WARRANTY OR REPRESENTATION WHATSOEVER, EXPRESS OR       *RIGHTE     34
C*    IMPLIED, INCLUDING ANY WARRANTY OF MERCHANTABILITY OR FITNESS OR *RIGHTE     35
C*    ANY PURPOSE WITH RESPECT TO THE SOFTWARE OR ITS ASSOCIATED       *RIGHTE     36
C*    DOCUMENTATION; OR                                                *RIGHTE     37
C*                                                                     *RIGHTE     38
C* 2. ASSUMES ANY LIABILITY WHATSOEVER WITH RESPECT TO ANY USE OF THE  *RIGHTE     39
C*    SOFTWARE OR ITS ASSOCIATED DOCUMENTATION OR ANY PORTION THEREOF  *RIGHTE     40
C*    OR WITH RESPECT TO ANY DAMAGES WHICH MAY RESULT FROM SUCH USE.   *RIGHTE     41
C*                                                                     *RIGHTE     42
C* THIS NOTICE MAY NOT BE REMOVED FROM THE SOFTWARE BY ANY USER        *RIGHTE     43
C* THEREOF.                                                            *RIGHTE     44
C*                                                                     *RIGHTE     45
C***********************************************************************RIGHTE     46
      SUBROUTINE IECMNT(IU,DATCMT,NCARD,ICMT,NOMORE)                    IECMNT      3
CD                                                                      IECMNT      4
CD     TO READ COMMENT CARDS FROM IEEE FORMAT DYNAMIC DATA.             IECMNT      5
CD                                                                      IECMNT      6
      INCLUDE 'CNUNIT.INS'                                              IECMNT      7
      INCLUDE 'CNMSG.INS'                                               IECMNT      8
C                                                                       IECMNT      9
      CHARACTER*80 DATCMT(NCARD),LINE                                   IECMNT     10
      LOGICAL NOMORE                                                    IECMNT     11
C                                                                       IECMNT     12
      CALL BLANK(DATCMT,20)                                             IECMNT     13
      ICMT=0                                                            IECMNT     14
      NOMORE=.FALSE.                                                    IECMNT     15
C                                                                       IECMNT     16
      CALL GETLIN(IU,LINE)                                              IECMNT     17
      IF (LINE(1:5).EQ.'IEEND') THEN                                    IECMNT     18
         NOMORE=.TRUE.                                                  IECMNT     19
         GOTO 10                                                        IECMNT     20
      ENDIF                                                             IECMNT     21
      IF (LINE(2:21).NE.'DESCRIPTIVE COMMENTS') THEN                    IECMNT     22
        WRITE(MSG(1),3000)                                              IECMNT     23
        WRITE(MSG(3),3020)                                              IECMNT     24
        WRITE(MSG(2),3010) LINE(2:21)                                   IECMNT     25
        CALL PRTMSG(3)                                                  IECMNT     26
        LINE='IECMNT: IEEE COMMENT HEADING CARD ERROR'                  IECMNT     27
        CALL ASTOP(LINE,39)                                             IECMNT     28
      ELSE IF (LINE(46:60).NE. 'SYSTEM MVA BASE') THEN                  IECMNT     29
        WRITE(MSG(1),3000)                                              IECMNT     30
        WRITE(MSG(3),3020)                                              IECMNT     31
        WRITE(MSG(2),3030) LINE(46:60)                                  IECMNT     32
        CALL PRTMSG(3)                                                  IECMNT     33
        LINE='ROUTINE IECNMT IEEE SYSTEM MVA BASE CARD ERROR'           IECMNT     34
        CALL ASTOP(LINE,46)                                             IECMNT     35
      ELSE                                                              IECMNT     36
        ICMT=ICMT+1                                                     IECMNT     37
        DATCMT(ICMT)=LINE                                               IECMNT     38
      ENDIF                                                             IECMNT     39
C                                                                       IECMNT     40
   1  CONTINUE                                                          IECMNT     41
      CALL GETLIN(IU,LINE)                                              IECMNT     42
      IF (LINE(2:5).NE.'-999') THEN                                     IECMNT     43
        IF (LINE(2:15) .EQ. 'GENERATOR DATA') THEN                      IECMNT     44
           WRITE(MSG(1),3000)                                           IECMNT     45
           WRITE(MSG(3),3020)                                           IECMNT     46
           WRITE(MSG(2),3040) LINE(2:15)                                IECMNT     47
           CALL PRTMSG(3)                                               IECMNT     48
           LINE='IECMNT: "-999" CARD MISSING'                           IECMNT     49
           CALL ASTOP(LINE,27)                                          IECMNT     50
        ENDIF                                                           IECMNT     51
        ICMT=ICMT+1                                                     IECMNT     52
        IF (ICMT.GT.NCARD) THEN                                         IECMNT     53
           ICMT=NCARD                                                   IECMNT     54
           WRITE(MSG(1),3000)                                           IECMNT     55
           MSG(2)=                                                      IECMNT     56
     *'           TOO MANY COMMENTS CARDS.  DATA READ IN IS:'           IECMNT     57
           MSG(3)=LINE                                                  IECMNT     58
           CALL PRTMSG(3)                                               IECMNT     59
        ELSE                                                            IECMNT     60
           DATCMT(ICMT)=LINE                                            IECMNT     61
        ENDIF                                                           IECMNT     62
        GOTO 1                                                          IECMNT     63
      ENDIF                                                             IECMNT     64
                                                                        IECMNT     65
   10 CONTINUE                                                          IECMNT     66
      RETURN                                                            IECMNT     67
C                                                                       IECMNT     68
 3000 FORMAT(' *** ERROR (IECMNT) READING IEEE FORMAT DYNAMIC'          IECMNT     69
     *,' DATA COMMENT CARDS.')                                          IECMNT     70
 3010 FORMAT(5X,'EXPECTING "DESRIPTIVE COMMENTS" IN COLUMNS 2 TO 21.')  IECMNT     71
 3020 FORMAT(5X,'DATA READ IN IS : ',A)                                 IECMNT     72
 3030 FORMAT(5X,'EXPECTING "SYSTEM MVA BASE" IN COLUMNS 46 TO 60.')     IECMNT     73
 3040 FORMAT(5X,'EXPECTING "-999" TO END COMMENTS')                     IECMNT     74
C                                                                       IECMNT     75
      END                                                               IECMNT     76
