for all the others who are lookin for tcpquery info
like how to log in ts2 using telnet
whts the command set of ts2
and the explanation of the pl command output
go here
GO HERE
i couldnt wait ur answer maletin

But if u could comment a bit ur code .... would be nice