- Fixed a bug in el737sec which made scans fail badly
- Enhanced phytron driver with another parameter
This commit is contained in:
@@ -172,6 +172,16 @@ proc el737readvalues {} {
|
||||
sct send RA
|
||||
return el737val
|
||||
}
|
||||
#--------------------------------------------------
|
||||
proc swapFirst {l} {
|
||||
set m1 [lindex $l 0]
|
||||
set cts [lindex $l 1]
|
||||
lappend res $cts $m1
|
||||
for {set i 2} {$i < [llength $l]} {incr i} {
|
||||
lappend res [lindex $l $i]
|
||||
}
|
||||
return $res
|
||||
}
|
||||
#---------------------------------------------------
|
||||
# There are two types of reponses to the RA command:
|
||||
# the old form with 5 values and the new one
|
||||
@@ -189,12 +199,14 @@ proc el737val {} {
|
||||
set root [sctroot]
|
||||
if {[llength $l] > 5} {
|
||||
set l2 [lrange $l 1 end]
|
||||
set l2 [swapFirst $l2]
|
||||
hupdate ${root}/values [join $l2]
|
||||
set time [lindex $l 0]
|
||||
hupdate ${root}/time $time
|
||||
} else {
|
||||
set last [expr [llength $l] - 1]
|
||||
set l2 [lrange $l 0 $last]
|
||||
set l2 [swapFirst $l2]
|
||||
hupdate ${root}/values [join $l2]
|
||||
set time [lindex $l $last]
|
||||
hupdate ${root}/time $time
|
||||
@@ -295,7 +307,7 @@ proc MakeSecEL737 {name netaddr} {
|
||||
$conname write $path
|
||||
hsetprop $path read el737threshread
|
||||
hsetprop $path el737thresh el737thresh
|
||||
$conname poll $path 60
|
||||
# $conname poll $path 60
|
||||
|
||||
$conname debug -1
|
||||
|
||||
|
||||
Reference in New Issue
Block a user