Merge branch 'master' of gitlab.psi.ch-samenv:samenv/sea

This commit is contained in:
2022-10-24 14:46:21 +02:00
6 changed files with 27 additions and 12 deletions

View File

@ -2,7 +2,7 @@ Comment: 30.07.2021, FP and CMN, 16mK--2.3K extrapolated elsewhere
Sensor Model: RX-1000-BF0.007 Sensor Model: RX-1000-BF0.007
Serial Number: U08127 Serial Number: U08127
Data Format: 4 (Log Ohms/Kelvin) Data Format: 4 (Log Ohms/Kelvin)
SetPoint Limit: 0.0282 (Kelvin) SetPoint Limit: 20 (Kelvin)
Temperature coefficient: 1 (Negative) Temperature coefficient: 1 (Negative)
Number of Breakpoints: 198 Number of Breakpoints: 198

View File

@ -1,7 +1,7 @@
Sensor Model: RX-1000-BF0.007 Sensor Model: RX-1000-BF0.007
Serial Number: U08130 Serial Number: U08130
Data Format: 4 (Log Ohms/Kelvin) Data Format: 4 (Log Ohms/Kelvin)
SetPoint Limit: 0.0167 (Kelvin) SetPoint Limit: 10 (Kelvin)
Temperature coefficient: 1 (Negative) Temperature coefficient: 1 (Negative)
Number of Breakpoints: 198 Number of Breakpoints: 198

View File

@ -73,6 +73,6 @@ dil extVersion 1
catch {default ts control} catch {default ts control}
catch {default ts heaterselect} catch {default ts heaterselect}
#makeMotorValve vb ${dilts}:3004 makeMotorValve vb ${dilts}:3004
#makeMotorValve vm ${dilts}:3006 makeMotorValve vm ${dilts}:3006

View File

@ -228,7 +228,7 @@ proc stdConfig::ccu4 {{title CCU4} args} {
node hea out node hea out
prop label "add. He channels" prop label "add. He channels"
prop enum 0,1,6 prop enum 0,1,6=6
node hch out -int node hch out -int
prop label "LHe channel" prop label "LHe channel"

View File

@ -45,8 +45,8 @@ proc luft::writeCf {} {
} else { } else {
luft::set_error "epics error: $val $errtxt" luft::set_error "epics error: $val $errtxt"
} }
if {[scan [lindex [sct target] 0] %d period]} { catch {
sct timeout [expr [clock seconds] + $period + 10] sct timeout [expr [clock seconds] + $timeout + 10]
} }
return idle return idle
} }

View File

@ -16,6 +16,7 @@ proc readpipe {} {
puts stdout "> $line" puts stdout "> $line"
} }
if {[eof $sea(pipe)]} { if {[eof $sea(pipe)]} {
puts stdout EOF
exit exit
} }
lassign $line adr date time value lassign $line adr date time value
@ -65,7 +66,12 @@ set env(EPICS_CA_AUTO_ADDR_LIST) NO
set env(PATH) $env(PATH):/afs/psi.ch/project/sinq/rhel7/stow/base-3.15.5/bin/linux-x86_64-debug/ set env(PATH) $env(PATH):/afs/psi.ch/project/sinq/rhel7/stow/base-3.15.5/bin/linux-x86_64-debug/
set sea(debug) [lindex "$argv 0" 0] set sea(debug) [lindex "$argv 0" 0]
set sea(heartbeat) 300 if {$sea(debug) eq "1"} {
set sea(heartbeat) 20
} else {
set sea(heartbeat) 300
set sea(debug) 0
}
# connect to sea server prep0 # connect to sea server prep0
set sea(sock) [socket samenv.psi.ch 8640] set sea(sock) [socket samenv.psi.ch 8640]
@ -78,15 +84,14 @@ if {$sea(debug)} {
set cmd "/afs/psi.ch/project/sinq/rhel7/stow/base-3.15.5/bin/linux-x86_64-debug/camonitor [array names values]" set cmd "/afs/psi.ch/project/sinq/rhel7/stow/base-3.15.5/bin/linux-x86_64-debug/camonitor [array names values]"
set ret [catch {set proc [exec ps ax -o pid,args | grep $cmd]} msg] set ret [catch {set proc [exec ps ax -o pid,args | grep $cmd]} msg]
set killed [list]
if {$ret == 0} { if {$ret == 0} {
foreach line [split $proc "\n"] { foreach line [split $proc "\n"] {
set l [split [string trim $line]] set l [split [string trim $line]]
set c [lrange $l 1 end] set c [lrange $l 1 end]
if {"$c" eq "$cmd"} { if {"$c" eq "$cmd"} {
# process was still running # process was still running
if {$sea(debug)} { lappend killed [lindex $l 0]
puts stdout "kill $proc ($c)"
}
exec kill -9 [lindex $l 0] exec kill -9 [lindex $l 0]
} }
} }
@ -95,5 +100,15 @@ if {$ret == 0} {
set sea(pipe) [open "|$cmd" r] set sea(pipe) [open "|$cmd" r]
fileevent $sea(pipe) readable readpipe fileevent $sea(pipe) readable readpipe
puts stdout [pid $sea(pipe)] set mypid [pid $sea(pipe)]
set f [open $env(HOME)/monitfiles/luft_camonitor.pid w]
puts $f $mypid
close $f
puts stdout $mypid
if {[llength $killed] > 0 && $sea(debug)} {
puts stdout "killed $killed"
}
seacom "clientlog luft started"
vwait forever vwait forever