Improve response of t0_chopper_id command by working around the chopsel IO
Box communications problems.
This commit is contained in:
@ -5,15 +5,19 @@ namespace eval chopper {
|
||||
}
|
||||
|
||||
if {$::chopper::sim_mode == false} {
|
||||
MakeAsyncProtocol std
|
||||
std sendterminator "0x0D0x0A0"
|
||||
std replyterminator "0x0D0x0A00x20"
|
||||
MakeAsyncQueue chopsel std chopsel1-bilby 30000
|
||||
MakeAsyncProtocol chopsel_ap
|
||||
chopsel_ap sendterminator "0x0D0x0A0"
|
||||
# Append space to reply terminator to match terminator from the 'get master chopper' reply
|
||||
chopsel_ap replyterminator "0x0D0x0A00x20"
|
||||
MakeAsyncQueue chopsel chopsel_ap chopsel1-bilby 30000
|
||||
# Set timeout to 100ms to improve response for all the other replies that just end with crlf
|
||||
chopsel timeout 100
|
||||
# Send something to get the dopey welcome and help messages out of the way
|
||||
chopsel send x
|
||||
}
|
||||
::utility::macro::getset int t0_chopper_id {args} {
|
||||
if {$::chopper::sim_mode == false} {
|
||||
if {$args == ""} {
|
||||
chopsel send {get master chopper}
|
||||
return "t0_chopper_id = [SplitReply [chopsel send {get master chopper}]]"
|
||||
} else {
|
||||
chopsel send "get master chopper"
|
||||
|
Reference in New Issue
Block a user