Regenerate template drivers
This commit is contained in:
@@ -287,8 +287,8 @@ proc ::scobj::huber_pilot::setValue {tc_root nextState cmd_str} {
|
||||
handle_exception ${catch_status} ${catch_message}
|
||||
}
|
||||
|
||||
proc ::scobj::huber_pilot::mkDriver { sct_controller name } {
|
||||
::scobj::huber_pilot::sics_log 9 "::scobj::huber_pilot::mkDriver for ${name}"
|
||||
proc ::scobj::huber_pilot::mkDriver { sct_controller name ip_address tcp_port } {
|
||||
::scobj::huber_pilot::sics_log 9 "::scobj::huber_pilot::mkDriver ${sct_controller} ${name} ${ip_address} ${tcp_port}"
|
||||
set ns "[namespace current]"
|
||||
set catch_status [ catch {
|
||||
|
||||
@@ -445,22 +445,22 @@ namespace eval ::scobj::huber_pilot {
|
||||
namespace export mkDriver
|
||||
}
|
||||
|
||||
proc add_huber_pilot {name IP port} {
|
||||
proc add_huber_pilot {name ip_address tcp_port} {
|
||||
set catch_status [ catch {
|
||||
::scobj::huber_pilot::sics_log 9 "add_huber_pilot ${name} ${IP} ${port}"
|
||||
::scobj::huber_pilot::sics_log 9 "add_huber_pilot ${name} ${ip_address} ${tcp_port}"
|
||||
if {[string equal -nocase [SplitReply [environment_simulation]] "false"]} {
|
||||
if {[string equal -nocase "aqadapter" "${IP}"]} {
|
||||
::scobj::huber_pilot::sics_log 9 "makesctcontroller sct_${name} aqadapter ${port}"
|
||||
makesctcontroller sct_${name} aqadapter ${port}
|
||||
if {[string equal -nocase "aqadapter" "${ip_address}"]} {
|
||||
::scobj::huber_pilot::sics_log 9 "makesctcontroller sct_${name} aqadapter ${tcp_port}"
|
||||
makesctcontroller sct_${name} aqadapter ${tcp_port}
|
||||
} else {
|
||||
::scobj::huber_pilot::sics_log 9 "makesctcontroller sct_${name} std ${IP}:${port}"
|
||||
makesctcontroller sct_${name} std ${IP}:${port}
|
||||
::scobj::huber_pilot::sics_log 9 "makesctcontroller sct_${name} std ${ip_address}:${tcp_port}"
|
||||
makesctcontroller sct_${name} std ${ip_address}:${tcp_port}
|
||||
}
|
||||
} else {
|
||||
::scobj::huber_pilot::sics_log 9 "[environment_simulation] => No sctcontroller for huber_pilot"
|
||||
}
|
||||
::scobj::huber_pilot::sics_log 1 "::scobj::huber_pilot::mkDriver sct_${name} ${name}"
|
||||
::scobj::huber_pilot::mkDriver sct_${name} ${name}
|
||||
::scobj::huber_pilot::sics_log 1 "::scobj::huber_pilot::mkDriver sct_${name} ${name} ${ip_address} ${tcp_port}"
|
||||
::scobj::huber_pilot::mkDriver sct_${name} ${name} ${ip_address} ${tcp_port}
|
||||
} catch_message ]
|
||||
handle_exception ${catch_status} ${catch_message}
|
||||
}
|
||||
@@ -496,8 +496,8 @@ proc ::scobj::huber_pilot::read_config {} {
|
||||
} elseif { [dict exists $v "asyncqueue"] } {
|
||||
set asyncqueue [dict get $v "asyncqueue"]
|
||||
if { [string equal -nocase ${asyncqueue} "sct"] } {
|
||||
set IP [dict get $v ip]
|
||||
set PORT [dict get $v port]
|
||||
set ip_address [dict get $v ip]
|
||||
set tcp_port [dict get $v port]
|
||||
}
|
||||
} else {
|
||||
if { [dict exists $v "asyncprotocol"] } {
|
||||
@@ -511,15 +511,15 @@ proc ::scobj::huber_pilot::read_config {} {
|
||||
}
|
||||
}
|
||||
set asyncqueue ${name}_queue
|
||||
set IP [dict get $v ip]
|
||||
set PORT [dict get $v port]
|
||||
MakeAsyncQueue ${asyncqueue} ${asyncprotocol} ${IP} ${PORT}
|
||||
set ip_address [dict get $v ip]
|
||||
set tcp_port [dict get $v port]
|
||||
MakeAsyncQueue ${asyncqueue} ${asyncprotocol} ${ip_address} ${tcp_port}
|
||||
if { [dict exists $v "timeout"] } {
|
||||
${asyncqueue} timeout "[dict get $v "timeout"]"
|
||||
}
|
||||
}
|
||||
if { [string equal -nocase ${asyncqueue} "sct"] } {
|
||||
add_huber_pilot ${name} ${IP} ${PORT}
|
||||
add_huber_pilot ${name} ${ip_address} ${tcp_port}
|
||||
} else {
|
||||
add_huber_pilot ${name} "aqadapter" ${asyncqueue}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user