[623] | 1 | HLCSMON1 ;SF-Utilities for Driver Program ;02/04/2004 10:25
|
---|
| 2 | ;;1.6;HEALTH LEVEL SEVEN;**15,40,49,65,109**;Oct 13, 1995
|
---|
| 3 | ;
|
---|
| 4 | ;This routine contains several entry points called from HLCSMON
|
---|
| 5 | ;no input parameters are required. All variables used which are
|
---|
| 6 | ;not newed here are newed in HLCSMON
|
---|
| 7 | ;
|
---|
| 8 | DISPLAY ;display link info
|
---|
| 9 | ;turn of line wrap
|
---|
| 10 | S HLXX=0,X=0 X ^%ZOSF("RM")
|
---|
| 11 | F S HLXX=$O(HLARYD(HLXX)) Q:(HLXX'>0) D WLINE(HLXX)
|
---|
| 12 | ;DISPLAY INCOMING FILER STATUS
|
---|
| 13 | S HLXX=$$CNTFLR^HLCSUTL2("IN")
|
---|
| 14 | ;ONLY UPDATE SCREEN IF COUNT HAS CHANGED
|
---|
| 15 | I (HLXX'=+HLRUNCNT) D
|
---|
| 16 | .D WDATA(5,17,"","",$J(" ",31)),WDATA^HLCSMON1(5,17,"","","Incoming filers running => ",35)
|
---|
| 17 | .I (HLXX) D WDATA(32,17,"","",HLXX)
|
---|
| 18 | .I ('HLXX) D WDATA(32,17,IOINHI,IOINORM,"Zero")
|
---|
| 19 | .S $P(HLRUNCNT,"^",1)=HLXX
|
---|
| 20 | ;DISPLAY OUTGOING FILER STATUS
|
---|
| 21 | S HLXX=$$CNTFLR^HLCSUTL2("OUT")
|
---|
| 22 | ;ONLY UPDATE SCREEN IF COUNT HAS CHANGED
|
---|
| 23 | I (HLXX'=+$P(HLRUNCNT,"^",2)) D
|
---|
| 24 | .D WDATA(5,18,"","",$J(" ",31)),WDATA^HLCSMON1(5,18,"","","Outgoing filers running => ",35)
|
---|
| 25 | .I (HLXX) D WDATA(32,18,"","",HLXX)
|
---|
| 26 | .I ('HLXX) D WDATA(32,18,IOINHI,IOINORM,"Zero")
|
---|
| 27 | .S $P(HLRUNCNT,"^",2)=HLXX
|
---|
| 28 | S X=$$TM^%ZTLOAD
|
---|
| 29 | I X'=$G(HLTMSTAT) D
|
---|
| 30 | .S HLTMSTAT=X
|
---|
| 31 | .S HLXX=$S('HLTMSTAT:"***TASKMAN NOT RUNNING!!!***",1:"")
|
---|
| 32 | .I 'HLTMSTAT D WDATA^HLCSMON1(45,17,IOELEOL_IOBON_IORVON,IOBOFF_IORVOFF,HLXX) I 1
|
---|
| 33 | .E D WDATA(45,17,IOELEOL,"",$J("TaskMan running ",16)) ;D WDATA(5,19,IOELALL,"","")
|
---|
| 34 | S X=$$STAT^HLCSLM
|
---|
| 35 | I X'=$G(HLLMSTAT) D
|
---|
| 36 | .S HLLMSTAT=X Q:HLLMSTAT=3
|
---|
| 37 | .S HLXX=$S('HLLMSTAT:"***LINK MANAGER NOT RUNNING!!!***",1:"")
|
---|
| 38 | .I 'HLLMSTAT D WDATA^HLCSMON1(45,18,IOELEOL_IOBON_IORVON,IOBOFF_IORVOFF,HLXX) I 1
|
---|
| 39 | .E D WDATA^HLCSMON1(45,18,IOELEOL,"",$J("Link Manager running",18))
|
---|
| 40 | ;Turn terminal line wrap back on
|
---|
| 41 | D WDATA(45,19,IOELEOL,"",$$SLM^HLEVUTIL) ; HL*1.6*109
|
---|
| 42 | S X=IOM X ^%ZOSF("RM")
|
---|
| 43 | Q
|
---|
| 44 | ;
|
---|
| 45 | WLINE(HLXX) ;write line from HLARYD=current values, HLARYO=old values
|
---|
| 46 | ;if values haven't changed, don't do anything
|
---|
| 47 | I HLARYD(HLXX)]"",HLARYD(HLXX)=$G(HLARYO(HLXX)) Q
|
---|
| 48 | S HLARYO(HLXX)=HLARYD(HLXX),HLERR=$P(HLARYD(HLXX),U,8),DX=1
|
---|
| 49 | F X=1:1:7 S @$P("HLNODE^HLREC^HLPROC^HLSEND^HLSENT^HLDEV^HLSTAT",U,X)=$E($P(HLARYD(HLXX),U,X)_" ",1,8)
|
---|
| 50 | ;if link is in error, write node in rev. video
|
---|
| 51 | I HLERR]"" D WDATA(5,HLXX,IOBON_IORVON,IOBOFF_IORVOFF,HLNODE,8) S DX=14
|
---|
| 52 | ;Turn off terminal line wrap & inform O/S where cursor is located
|
---|
| 53 | S DY=HLXX X IOXY,^%ZOSF("XY")
|
---|
| 54 | W:HLERR="" ?5,HLNODE
|
---|
| 55 | W ?16,HLREC,?26,HLPROC,?37,HLSEND,?47,HLSENT,?58,HLDEV,?64,HLSTAT
|
---|
| 56 | Q
|
---|
| 57 | ;
|
---|
| 58 | WDATA(DX,DY,IO1,IO2,HLDATA,HLENGTH) ;
|
---|
| 59 | ;
|
---|
| 60 | ;First erase the data block then write to it. Attributes are
|
---|
| 61 | ;contained in IO1 & IO2
|
---|
| 62 | ;
|
---|
| 63 | N X S X=0 X ^%ZOSF("RM") X ^%ZOSF("XY")
|
---|
| 64 | ;Turn off terminal line wrap & inform O/S where cursor is located
|
---|
| 65 | I '$D(HLENGTH) S HLENGTH=$L(HLDATA)
|
---|
| 66 | X IOXY W IOSC,$E($J(" ",79),1,HLENGTH),IORC W IO1,$E(HLDATA,1,HLENGTH),IO2
|
---|
| 67 | S X=IOM X ^%ZOSF("RM")
|
---|
| 68 | ;Turn terminal line wrap back on
|
---|
| 69 | Q
|
---|