Regen sct drivers after refactoring

This commit is contained in:
Douglas Clowes
2014-09-29 15:38:32 +10:00
parent 814c8741c3
commit 29650b420c
20 changed files with 1014 additions and 322 deletions

View File

@@ -205,6 +205,7 @@ proc ::scobj::shutters::mkDriver { sct_controller name device_class simulation_f
set scobj_hpath /sics/${name}
hfactory ${scobj_hpath}/fast_shutter plain user text
hsetprop ${scobj_hpath}/fast_shutter read ${ns}::getValue ${scobj_hpath} read_switch_pair {MG @IN[5], @IN[6]}
hsetprop ${scobj_hpath}/fast_shutter read_switch_pair ${ns}::read_switch_pair ${scobj_hpath}
@@ -218,6 +219,13 @@ proc ::scobj::shutters::mkDriver { sct_controller name device_class simulation_f
hsetprop ${scobj_hpath}/fast_shutter sdsinfo "::nexus::scobj::sdsinfo"
hsetprop ${scobj_hpath}/fast_shutter type "part"
if {[string equal -nocase "${simulation_flag}" "false"]} {
${sct_controller} poll ${scobj_hpath}/fast_shutter 1
} else {
::scobj::shutters::sics_log 9 "simulation_flag=${simulation_flag} => No poll/write for shutters"
}
hfactory ${scobj_hpath}/rough_100 plain user text
hsetprop ${scobj_hpath}/rough_100 read ${ns}::getValue ${scobj_hpath} read_switch_pair {MG @IN[15], @IN[16]}
hsetprop ${scobj_hpath}/rough_100 read_switch_pair ${ns}::read_switch_pair ${scobj_hpath}
@@ -235,6 +243,14 @@ proc ::scobj::shutters::mkDriver { sct_controller name device_class simulation_f
hsetprop ${scobj_hpath}/rough_100 sdsinfo "::nexus::scobj::sdsinfo"
hsetprop ${scobj_hpath}/rough_100 type "part"
if {[string equal -nocase "${simulation_flag}" "false"]} {
${sct_controller} poll ${scobj_hpath}/rough_100 1
${sct_controller} write ${scobj_hpath}/rough_100
} else {
::scobj::shutters::sics_log 9 "simulation_flag=${simulation_flag} => No poll/write for shutters"
}
hfactory ${scobj_hpath}/rough_40 plain user text
hsetprop ${scobj_hpath}/rough_40 read ${ns}::getValue ${scobj_hpath} read_switch_pair {MG @IN[13], @IN[14]}
hsetprop ${scobj_hpath}/rough_40 read_switch_pair ${ns}::read_switch_pair ${scobj_hpath}
@@ -252,20 +268,17 @@ proc ::scobj::shutters::mkDriver { sct_controller name device_class simulation_f
hsetprop ${scobj_hpath}/rough_40 sdsinfo "::nexus::scobj::sdsinfo"
hsetprop ${scobj_hpath}/rough_40 type "part"
hsetprop ${scobj_hpath} data "true"
hsetprop ${scobj_hpath} klass "@none"
hsetprop ${scobj_hpath} nxsave "true"
hsetprop ${scobj_hpath} type "part"
if {[string equal -nocase "${simulation_flag}" "false"]} {
${sct_controller} poll ${scobj_hpath}/fast_shutter 1
${sct_controller} poll ${scobj_hpath}/rough_100 1
${sct_controller} poll ${scobj_hpath}/rough_40 1
${sct_controller} write ${scobj_hpath}/rough_100
${sct_controller} write ${scobj_hpath}/rough_40
} else {
::scobj::shutters::sics_log 9 "simulation_flag=${simulation_flag} => No poll/write for shutters"
}
hsetprop ${scobj_hpath} data "true"
hsetprop ${scobj_hpath} klass "@none"
hsetprop ${scobj_hpath} nxsave "true"
hsetprop ${scobj_hpath} type "part"
hsetprop ${scobj_hpath} klass ${device_class}
hsetprop ${scobj_hpath} data true
hsetprop ${scobj_hpath} debug_threshold 5