G
Guest
I work for a telecom company.
We need to get data from our 5ESS switches to be consumed by a .NET app.
The data I am getting back is incomplete.
For example, the beginning of the first line recvd from the device should
read:
SWT5 5e16(2) 02.00
Instead I get
a bunch of gibberish then SWT5
The text greeting message that comes up above the login prompt
gets cut up (some chars are dropped) followed by a
(tab or LF) then the text greeting continues then cuts of a few chars again
followed by another (tab or LF), etc..
The login prompt should be:
login:
But instead I get:
a TAB char
or
TAB and n:
Like a lot of examples, I am using TCPClient, incoming data into a byte array
and displaying the string data in a textbox so I can see it.
Dim responseData As [String] = [String].Empty
data = New [Byte](2048) {}
Dim bytes As Int32 = st.Read(data, 0, data.Length)
responseData = System.Text.Encoding.ASCII.GetString(data, 0, bytes)
txtRetVal.Text += responseData.ToString
I have done this against UNIX applications in the past the same way without
issue.
Also, the switch will send some data, pause, then send more until I get the
results I am expecting.
It does not all happen at once. The login greeting/prompt will come in
thirds in a normal telnet session.
I cannot find any info anywhere that will help me here.
I thought maybe I needed term emulation but then I will get a large block of
the greeting message intact. If I needed emulation wouldn't it be consistant?
Thanks
We need to get data from our 5ESS switches to be consumed by a .NET app.
The data I am getting back is incomplete.
For example, the beginning of the first line recvd from the device should
read:
SWT5 5e16(2) 02.00
Instead I get
a bunch of gibberish then SWT5
The text greeting message that comes up above the login prompt
gets cut up (some chars are dropped) followed by a
(tab or LF) then the text greeting continues then cuts of a few chars again
followed by another (tab or LF), etc..
The login prompt should be:
login:
But instead I get:
a TAB char
or
TAB and n:
Like a lot of examples, I am using TCPClient, incoming data into a byte array
and displaying the string data in a textbox so I can see it.
Dim responseData As [String] = [String].Empty
data = New [Byte](2048) {}
Dim bytes As Int32 = st.Read(data, 0, data.Length)
responseData = System.Text.Encoding.ASCII.GetString(data, 0, bytes)
txtRetVal.Text += responseData.ToString
I have done this against UNIX applications in the past the same way without
issue.
Also, the switch will send some data, pause, then send more until I get the
results I am expecting.
It does not all happen at once. The login greeting/prompt will come in
thirds in a normal telnet session.
I cannot find any info anywhere that will help me here.
I thought maybe I needed term emulation but then I will get a large block of
the greeting message intact. If I needed emulation wouldn't it be consistant?
Thanks