2017년 8월 25일 금요일
2017년 7월 11일 화요일
2017년 7월 4일 화요일
2017년 6월 20일 화요일
급탕 온수탱크시스템
Sub 순환auto()
while 1
a1 = GetTagVal("순환1")
a2 = GetTagVal("순환2")
a3 = GetTagVal("순환자동")
if a3 = 1 then
SetTagVal "순환1",1
SetTagVal "순환2",0
Sleep(5000)
SetTagVal "순환2",1
SetTagVal "순환1",0
Sleep(5000)
end if
Wend
End Sub
//////////////////////////////
Sub 대류auto()
while 1
a1 = GetTagVal("대류1")
a2 = GetTagVal("대류2")
a3 = GetTagVal("대류자동")
if a3 = 1 then
SetTagVal "대류1",1
SetTagVal "대류2",0
Sleep(4000)
SetTagVal "대류2",1
SetTagVal "대류1",0
Sleep(4000)
end if
Wend
End Sub
//////////////////////////////////
Sub 증기auto()
bu7 = GetTagVal("증기자동")
aa2 = GetTagVal("탱크온도")
aa4 = GetTagVal("급탕")
while bu7=1
a = aa4-aa2
if a>5 then
b=100
elseif a<-5 then
b=0
else
b=(a+5)*10
end if
SetTagVal "증기밸브",b
Sleep(100)
bu7 = GetTagVal("증기자동")
aa2 = GetTagVal("탱크온도")
aa4 = GetTagVal("급탕")
wend
if bu7=0 then SetTagVal "증기밸브",0
End Sub
2017년 5월 30일 화요일
급배기팬 모니터링 시스템
=====================
Sub main()
runscript("timeon")
End Sub
=====================
Sub timeon()
a=0
while 1
SetTagVal "time",a
if a<24 then a=a+1
if a=24 then a=0
sleep(1000)
wend
End Sub
=====================
Sub autoon()
ti=GetTagVal("time")
au=GetTagVal("auto")
if au=1 then
if 5<ti and ti<22 then
SetTagVal "화장배기",1
SetTagVal "복도배기",1
SetTagVal "로비1급기",1
SetTagVal "로비1배기",1
Else
SetTagVal "화장배기",0
SetTagVal "복도배기",0
SetTagVal "로비1급기",0
SetTagVal "로비1배기",0
end if
if 8<ti and ti<19 then
SetTagVal "사무2급기",1
SetTagVal "사무2배기",1
SetTagVal "사무3배기",1
SetTagVal "사무4배기",1
Else
SetTagVal "사무2급기",0
SetTagVal "사무2배기",0
SetTagVal "사무3배기",0
SetTagVal "사무4배기",0
end if
Else
SetTagVal "사무2급기",0
SetTagVal "사무2배기",0
SetTagVal "사무3배기",0
SetTagVal "사무4배기",0
SetTagVal "화장배기",0
SetTagVal "복도배기",0
SetTagVal "로비1급기",0
SetTagVal "로비1배기",0
end if
=====================
피드 구독하기:
글 (Atom)

























