AIDA GELINA BRIKEN nToF CRIB ISOLDE CIRCE nTOFCapture DESPEC DTAS EDI_PSA 179Ta CARME StellarModelling DCF K40
  DESPEC  ELOG logo
Message ID: 26     Entry time: Sun Feb 3 16:01:49 2019
Author: TD 
Subject: Updated analyses GSIJan19/R1_0 - R10_0  
Summary statistics for WR test data files R1_0, R2_0, R3_0, R4_0, R7_0 and R10_0 (attachments 1-6)

Latest version of WR TDR data analyser (attachment 7)
Attachment 1: R1_0.out  539 kB  | Show | Hide all | Show all
Attachment 2: R2_0.out  26 kB  | Show | Hide all | Show all
Attachment 3: R3_0.out  287 kB  | Show | Hide all | Show all
Attachment 4: R4_0.out  11 kB  | Hide | Hide all | Show all
 *** TDR format 3.3.0 analyser - TD - January 2019
 ***            ADC data: block:   227 ptr:  4677 data: 0xC01B6E25 module:  0 fail: 0 range: 0 id:    27 channel: 27 adc: 28197  ts: 0x157CCF5D2D557EEA OLD: ts: 0x157CCF5D2D557F26 dt: 0x000000000000003C tag: 3 type: 0
 *** ERROR: READ I/O error:       5002
                   blocks:        382
          ADC data format:    3125366 (  302390.4 Hz)
        Other data format:       1686 (     163.1 Hz)
 Sample trace data format:          0 (       0.0 Hz)
         Undefined format:          0 (       0.0 Hz)
   Other data format type:      PAUSE:          0 (       0.0 Hz)
                               RESUME:          0 (       0.0 Hz)
                              SYNC100:        843 (      81.6 Hz)
                              WR48-63:        843 (      81.6 Hz)
                           FEE64 disc:          0 (       0.0 Hz)
                             MBS info:          0 (       0.0 Hz)
                           Other info:          0 (       0.0 Hz)

   ADC data range bit set:          0 (       0.0 Hz)

                Timewarps:        ADC:          1 (       0.1 Hz)
                                PAUSE:          0 (       0.0 Hz)
                               RESUME:          0 (       0.0 Hz)
                              SYNC100:          0 (       0.0 Hz)
                              WR48-63:          0 (       0.0 Hz)
                           FEE64 disc:          0 (       0.0 Hz)
                             MBS info:          0 (       0.0 Hz)
                            Undefined:          0 (       0.0 Hz)
                         Sample trace:          0 (       0.0 Hz)

 *** Timestamp elapsed time:       10.336 s
 FEE  elapsed dead time(s) elapsed idle time(s)
  1                0.000                0.000
  2                0.000                0.000
  3                0.000                0.000
  4                0.000                0.000
  5                0.000                0.000
  6                0.000                0.000
  7                0.000                0.000
  8                0.000                0.000
  9                0.000                0.000
 10                0.000                0.000
 11                0.000                0.000
 12                0.000                0.000
 13                0.000                0.000
 14                0.000                0.000
 15                0.000                0.000
 16                0.000                0.000
 17                0.000                0.000
 18                0.000                0.000
 19                0.000                0.000
 20                0.000                0.000
 21                0.000                0.000
 22                0.000                0.000
 23                0.000                0.000
 24                0.000                0.000
 25                0.000                0.000
 26                0.000                0.000
 27                0.000                0.000
 28                0.000                0.000
 29                0.000                0.000
 30                0.000                0.000
 31                0.000                0.000
 32                0.000                0.000

 *** Statistics
 FEE  ADC Data Other Data     Sample  Undefined      Pause     Resume    SYNC100    WR48-63       Disc        MBS      Other   HEC Data
  0     279514        146          0          0          0          0         73         73          0          0          0          0
  1     276547        152          0          0          0          0         76         76          0          0          0          0
  2     272645        146          0          0          0          0         73         73          0          0          0          0
  3     270155        140          0          0          0          0         70         70          0          0          0          0
  4     266947        144          0          0          0          0         72         72          0          0          0          0
  5     255558        140          0          0          0          0         70         70          0          0          0          0
  6     260113        150          0          0          0          0         75         75          0          0          0          0
  7     245839        140          0          0          0          0         70         70          0          0          0          0
  8     254067        140          0          0          0          0         70         70          0          0          0          0
  9     251449        128          0          0          0          0         64         64          0          0          0          0
 10     247982        136          0          0          0          0         68         68          0          0          0          0
 11     244550        124          0          0          0          0         62         62          0          0          0          0
 12          0          0          0          0          0          0          0          0          0          0          0          0
 13          0          0          0          0          0          0          0          0          0          0          0          0
 14          0          0          0          0          0          0          0          0          0          0          0          0
 15          0          0          0          0          0          0          0          0          0          0          0          0
 16          0          0          0          0          0          0          0          0          0          0          0          0
 17          0          0          0          0          0          0          0          0          0          0          0          0
 18          0          0          0          0          0          0          0          0          0          0          0          0
 19          0          0          0          0          0          0          0          0          0          0          0          0
 20          0          0          0          0          0          0          0          0          0          0          0          0
 21          0          0          0          0          0          0          0          0          0          0          0          0
 22          0          0          0          0          0          0          0          0          0          0          0          0
 23          0          0          0          0          0          0          0          0          0          0          0          0
 24          0          0          0          0          0          0          0          0          0          0          0          0
 25          0          0          0          0          0          0          0          0          0          0          0          0
 26          0          0          0          0          0          0          0          0          0          0          0          0
 27          0          0          0          0          0          0          0          0          0          0          0          0
 28          0          0          0          0          0          0          0          0          0          0          0          0
 29          0          0          0          0          0          0          0          0          0          0          0          0
 30          0          0          0          0          0          0          0          0          0          0          0          0
 31          0          0          0          0          0          0          0          0          0          0          0          0
 32          0          0          0          0          0          0          0          0          0          0          0          0

 *** Timewarps
 FEE       ADC      Pause     Resume    SYNC100    WR48-63       Disc        MBS  Undefined    Samples
  0          1          0          0          0          0          0          0          0          0
  1          0          0          0          0          0          0          0          0          0
  2          0          0          0          0          0          0          0          0          0
  3          0          0          0          0          0          0          0          0          0
  4          0          0          0          0          0          0          0          0          0
  5          0          0          0          0          0          0          0          0          0
  6          0          0          0          0          0          0          0          0          0
  7          0          0          0          0          0          0          0          0          0
  8          0          0          0          0          0          0          0          0          0
  9          0          0          0          0          0          0          0          0          0
 10          0          0          0          0          0          0          0          0          0
 11          0          0          0          0          0          0          0          0          0
 12          0          0          0          0          0          0          0          0          0
 13          0          0          0          0          0          0          0          0          0
 14          0          0          0          0          0          0          0          0          0
 15          0          0          0          0          0          0          0          0          0
 16          0          0          0          0          0          0          0          0          0
 17          0          0          0          0          0          0          0          0          0
 18          0          0          0          0          0          0          0          0          0
 19          0          0          0          0          0          0          0          0          0
 20          0          0          0          0          0          0          0          0          0
 21          0          0          0          0          0          0          0          0          0
 22          0          0          0          0          0          0          0          0          0
 23          0          0          0          0          0          0          0          0          0
 24          0          0          0          0          0          0          0          0          0
 25          0          0          0          0          0          0          0          0          0
 26          0          0          0          0          0          0          0          0          0
 27          0          0          0          0          0          0          0          0          0
 28          0          0          0          0          0          0          0          0          0
 29          0          0          0          0          0          0          0          0          0
 30          0          0          0          0          0          0          0          0          0
 31          0          0          0          0          0          0          0          0          0
 32          0          0          0          0          0          0          0          0          0

 *** Program elapsed time: 3507.020s (    0.109 blocks/s,   0.007 Mb/s)
Attachment 5: R7_0.out  11 kB  | Show | Hide all | Show all
Attachment 6: R10_0.out  11 kB  | Show | Hide all | Show all
Attachment 7: analyser.f  21 kB  | Hide | Hide all | Show all
      PROGRAM GREAT

C     Read and analyse GREAT format data - version 3.3.0
C
C     See:
C     http://npg.dl.ac.uk/documents/edoc504/edoc504.html
C     http://npg.dl.ac.uk/DataAcq/TSformat.html

      IMPLICIT NONE                                 
C
C     External functions
C
      EXTERNAL timestamp
C
      DOUBLE PRECISION dfloat
C
      INTEGER and
      INTEGER*8 iargc
      INTEGER rshift
      INTEGER*8 timestamp
C
      REAL secnds
C
C     Parameter variables
C
      INTEGER block_length
      PARAMETER (block_length = 16384)
C
C     Local variables
C
      CHARACTER*255 arg
      CHARACTER*(block_length*4) buffer
      CHARACTER*255 filename
C
      INTEGER adc_data, block_number, block_ptr, ch, channel
      INTEGER channel_ident, data_block(block_length)
      INTEGER*8 dead(32)
      INTEGER event, fail
      INTEGER*8 first_ts
      INTEGER i
      INTEGER*2 i2(2), i2_2(4)
      INTEGER i4, i4_2(2)
      INTEGER*8 i8, idle(32)
      INTEGER information, information_index, io_error, items(0:32,0:31)
      INTEGER j, j4
      INTEGER*8 last_ts
      INTEGER mbs_data, module
      INTEGER*8 pause(32)
      INTEGER range
      INTEGER*8 resume(32)
      INTEGER sample_length, sum(0:31)
      INTEGER*8 sync(32)
      INTEGER tag, tag_old
      INTEGER*8 ts
      INTEGER ts28, ts48, ts64
      INTEGER*8 ts_old
      INTEGER type, type_old
C
      LOGICAL verbose
C
      REAL dt, t1, t2

      EQUIVALENCE ( data_block, buffer )
      EQUIVALENCE ( i4, i2( 1 ) )
      EQUIVALENCE ( i8, i4_2(1) )

      SAVE data_block, block_ptr, block_number, event

C----67---------------------------------------------------------------72------80
C     Announce program

      WRITE( 6, 9000 )

C     Initialise variables

      block_ptr = 1
      block_number = 0
      event = 0

      i4 = 0
      i8 = 0

      ts_old = 0
      tag_old = 0
      type_old = 0
      first_ts = 0
      last_ts = 0
      ts28 = 0
      ts48 = 0
      ts64 = 0

      type = 0
      
      verbose = .FALSE.
      
      DO i = 0, 32
       DO j = 0, 31
        sum( j ) = 0
        items( i, j ) = 0
       ENDDO
      ENDDO

      DO i = 1, 32
       pause( i ) = -1
       resume( i ) = -1
       dead( i ) = 0
       sync( i ) = 0
       idle( i ) = 0
      ENDDO

C     Get input filename from command line argument

      DO i = 1, iargc()
       CALL getarg( i, arg )
       IF ( arg.EQ.'v') THEN
        verbose = .TRUE.
        write(6,*) ' verbose'
       ELSE
        filename = arg
       ENDIF
      ENDDO
      IF ( iargc().LT.1 .OR. iargc().GT.2 ) THEN
       WRITE( 6, * ) ' Usage: ./a.exe [v] <filename>'
       STOP
      ENDIF

      t1 = SECNDS( 0.0 )

C     Open file

      OPEN( 10, RECL = 4 * block_length,
     +      FILE = filename, STATUS = 'OLD', ACCESS = 'DIRECT' )

    1 CONTINUE

C     Read next block
C     Note: for FORTRAN direct I/O first block/record number is 1
C           for GREAT data format first (encoded) block/record number is 0

      block_number = block_number + 1

      READ( 10, REC = block_number, iostat=io_error, ERR=1000 ) buffer

      DO block_ptr = 7, data_block( 6 ) / 4 + 7, 2


       i4 = data_block( block_ptr )
       j4 = data_block( block_ptr + 1 )

       IF ( i4.EQ.Z'ffffffff' ) THEN
        GOTO 1
       ENDIF

       IF ( i4.EQ.Z'5e5e5e5e' ) THEN
        GOTO 1
       ENDIF

       tag = AND( RSHIFT( i4, 30 ), Z'00000003' )

       module = 0
       type = 0

C      tag = 3 = ADC data format
C      tag = 2 = Other data
C      tag = 1 = Sample trace buffer format
C      tag = 0 = undefined?

C----67---------------------------------------------------------------72------80
C     ADC data

       IF ( tag.EQ.3 ) THEN

        fail = AND( RSHIFT( i4, 29 ), Z'00000001' )

        IF ( fail.NE.0 ) THEN

         WRITE( 6, 9600 ) block_number, block_ptr, i4

        ENDIF

        range = AND( RSHIFT( i4, 28 ), Z'00000001' )
        channel_ident = AND( RSHIFT( i4, 16 ), Z'00000fff' )
        module = AND( RSHIFT( channel_ident, 6 ), Z'0000003f' )
        IF ( range.EQ.1 ) THEN
         items(module, 19 ) = items(module, 19 ) + 1
        ENDIF
        channel = AND( channel_ident, Z'0000003f' )
        adc_data = AND( i4, Z'0000ffff' )

        items(module, 0 ) = items(module, 0 ) + 1

        ts28 = AND( data_block( block_ptr + 1 ), Z'0fffffff' )

        ts = timestamp( ts64, ts48, ts28, type )

	IF ( ts.LT.ts_old ) THEN

	 items(module, 20 ) = items(module, 20 ) + 1

         WRITE( 6, 9710 ) block_number, block_ptr, i4, module, fail,
     +   range, channel_ident, channel, adc_data, ts, ts_old, ts_old-ts,
     +   tag_old, type_old
        ENDIF

        ts_old = ts
        tag_old = tag
        type_old = 0

        IF ( verbose ) THEN 
         WRITE( 6, 9700 ) block_number, block_ptr, i4, module, fail,
     +   range, channel_ident, channel, adc_data, ts
        ENDIF

        ch = channel + ( module - 1 ) * 64 + ( range * 2048 )

C----67---------------------------------------------------------------72------80
C     Other information

       ELSEIF( tag.EQ.2 ) THEN

        module = AND( RSHIFT( i4, 24 ), Z'0000003f' )
        type = AND( RSHIFT( i4, 20 ), Z'0000000f' )
        information = AND( i4, Z'000fffff' )

        items(module, 1 ) = items(module, 1 ) + 1

        ts28 = AND( data_block( block_ptr + 1 ), Z'0fffffff' )

        IF ( type.EQ.2 ) THEN

C----67---------------------------------------------------------------72------80
C     PAUSE timestamp

         items(module, 4 ) = items(module, 4 ) + 1

        ts48 = information
C        ts = timestamp( ts48, ts28, type )

         ts = timestamp( ts64, ts48, ts28, type )

         IF ( ts.LT.ts_old ) THEN

          items(module, 21 ) = items(module, 21 ) + 1

         ENDIF
         ts_old = ts
         type_old = type
         tag_old = tag
         pause( module ) = ts

         IF ( verbose ) THEN 
          WRITE( 6, 9800 ) block_number, block_ptr, i4, module, type,
     +     information, ts
         ENDIF

        ELSEIF( type.EQ.3 ) THEN

C----67---------------------------------------------------------------72------80
C     RESUME timestamp

         items(module, 5 ) = items(module, 5 ) + 1

         ts48 = information
C         ts = timestamp( ts48, ts28, type )

         ts = timestamp( ts64, ts48, ts28, type )

         IF ( ts.LT.ts_old ) THEN

          items(module, 22 ) = items(module, 22 ) + 1

         ENDIF
         ts_old = ts
         type_old = type
         tag_old = tag
         resume( module ) = ts

         IF ( resume( module ).GE.0 
     +         .AND.
     +        pause( module ).GE.0 
     +          .AND.
     +        resume( module ).GE.pause( module ) ) THEN
          dead( module ) = ( resume( module ) - pause( module ) ) 
     +                     + dead( module )
          pause( module ) = -1
          resume( module ) = -1
         ENDIF

         IF ( verbose ) THEN 
          WRITE( 6, 9810 ) block_number, block_ptr, i4, module, type,
     +     information, ts
         ENDIF

        ELSEIF( type.EQ.4 ) THEN

C----67---------------------------------------------------------------72------80
C     SYNC100 timestamp/White Rabbit Timestamp Marker (bits 28-47)

         items(module, 6 ) = items(module, 6 ) + 1

... 457 more lines ...
ELOG V3.1.4-unknown