Save 5T magnet sensor reading and setpoint.

This commit is contained in:
Ferdi Franceschini
2014-07-16 11:27:13 +10:00
parent de264c5f02
commit 0e53fe3757
2 changed files with 15 additions and 3 deletions

View File

@ -286,12 +286,15 @@ proc ::scobj::tsi_smc::mkDriver { sct_controller name id } {
hsetprop ${scobj_hpath}/setpoint driveable value
hsetprop ${scobj_hpath}/setpoint control true
hsetprop ${scobj_hpath}/setpoint data true
hsetprop ${scobj_hpath}/setpoint mutable false
hsetprop ${scobj_hpath}/setpoint mutable true
hsetprop ${scobj_hpath}/setpoint nxsave true
hsetprop ${scobj_hpath}/setpoint lowerlimit 0
hsetprop ${scobj_hpath}/setpoint upperlimit 500.0
hsetprop ${scobj_hpath}/setpoint tolerance 10
hsetprop ${scobj_hpath}/setpoint permlink data_set "B[format "%02d" ${id}]SP01"
hsetprop ${scobj_hpath}/setpoint @description "B[format "%02d" ${id}]SP01"
hsetprop ${scobj_hpath}/setpoint oldval 0.0
hsetprop ${scobj_hpath}/setpoint klass "sensor"
hsetprop ${scobj_hpath}/setpoint sdsinfo "::nexus::scobj::sdsinfo"
hsetprop ${scobj_hpath}/setpoint settle_time "5"
hsetprop ${scobj_hpath}/setpoint type "drivable"
@ -301,16 +304,20 @@ proc ::scobj::tsi_smc::mkDriver { sct_controller name id } {
hfactory ${scobj_hpath}/value plain user float
hsetprop ${scobj_hpath}/value control true
hsetprop ${scobj_hpath}/value data true
hsetprop ${scobj_hpath}/value mutable false
hsetprop ${scobj_hpath}/value mutable true
hsetprop ${scobj_hpath}/value nxsave true
hsetprop ${scobj_hpath}/value permlink data_set "B[format "%02d" ${id}]S01"
hsetprop ${scobj_hpath}/value @description "B[format "%02d" ${id}]S01"
hsetprop ${scobj_hpath}/value oldval 0.0
hsetprop ${scobj_hpath}/value klass "NXsensor"
hsetprop ${scobj_hpath}/value sdsinfo "::nexus::scobj::sdsinfo"
hsetprop ${scobj_hpath}/value type "part"
hsetprop ${scobj_hpath}/value units "G"
hsetprop ${scobj_hpath}/value nxalias "${name}_value"
hsetprop ${scobj_hpath} control "true"
hsetprop ${scobj_hpath} data "true"
if {[string equal -nocase [SplitReply [environment_simulation]] "false"]} {
${sct_controller} write ${scobj_hpath}/setpoint
} else {

View File

@ -14,13 +14,18 @@ driver tsi_smc = {
control = true;
data = true;
nxsave = true;
group_property 'data' = true
group_property 'control' = true
var 'value' = {permlink = 'B.S01'};
var 'value' = {permlink = 'B.S01'; mutable = true; property klass = 'NXsensor'};
var setpoint = {
permlink = 'B.SP01';
writeable = 1;
write_function = setGauss;
lowerlimit = 0; upperlimit = 500.0; tolerance = 10;
property settle_time = 5;
mutable = true;
property klass = 'sensor';
driveable = 'value';
};
};