Maker Pro
Maker Pro

UDP, Telnet

J

John Larkin

Jan 1, 1970
0
Can anybody explain to me, in 9000 words or less, the difference
between UDP and Telnet? I'll be shipping ASCII data strings between a
PC and one of my boxes over 10/100 ethernet, nothing complex.

My PC has Telnet.exe, which lets me test a telnet connection by just
typing, but I don't see a corresponding UDP thingie.

John
 
I

Ian Stirling

Jan 1, 1970
0
John Larkin said:
Can anybody explain to me, in 9000 words or less, the difference
between UDP and Telnet? I'll be shipping ASCII data strings between a
PC and one of my boxes over 10/100 ethernet, nothing complex.

My PC has Telnet.exe, which lets me test a telnet connection by just
typing, but I don't see a corresponding UDP thingie.

UDP is just IP packets, with nothing else round them.
There is no congestion control, recovery from lost packets, ...

TCP uses IP to transmit streams of data (telnet, http, ...) and has
functions to ensure good behaviour with other users, and means to
recover from lost packets.
 
E

Eric

Jan 1, 1970
0
Ian said:
UDP is just IP packets, with nothing else round them.
There is no congestion control, recovery from lost packets, ...

TCP uses IP to transmit streams of data (telnet, http, ...) and has
functions to ensure good behaviour with other users, and means to
recover from lost packets.

And telnet is an application. "Telnet" is related to "UDP" like "fruit"
is related to "tree".

Telnet is an application that creates data. UDP breaks the data up into
chunks. UDP also takes chunks of data and reassembles them. Then there's
the network layer (this is where the IP in TCP/IP lives). The network
layer takes the chunks of data and figures out how to route it to its
destination. The physical layer is the medium over which the data travels
(twisted pair ethernet, wi-fi, etc.)
 
T

Tim Auton

Jan 1, 1970
0
John Larkin said:
Can anybody explain to me, in 9000 words or less, the difference
between UDP and Telnet? I'll be shipping ASCII data strings between a
PC and one of my boxes over 10/100 ethernet, nothing complex.

My PC has Telnet.exe, which lets me test a telnet connection by just
typing, but I don't see a corresponding UDP thingie.

Telnet is a program, rather than a protocol (a terminal emulator to be
precise). You really want to know the difference between UDP and TCP.
UDP is a very basic protocol, without most of the niceties provided by
TCP. If you want to ensure all your data gets there with UDP you have
to write your own protocol on top. It's much easier to use TCP, which
gives some guarantees about your data getting there intact (it
provides checksums, re-tries, re-sorts out of order packets etc.).
Most familiar protocols on the net use TCP (http, ftp, smtp, pop3...).
UDP is used by games and streaming media, where some data loss can be
tolerated and out-of-order packets aren't much use.

The common programming interface to TCP/IP is sockets (Windows sockets
- Winsock, unix sockets...). That deals with all the hassle and you
just get all your data intact, in order at the other end (within
reason, you get errors after too many re-tries of course, but it will
correct for some packet loss and corruption). You can use sockets in
most decent languages (and seamlessly between languages and operating
systems) - VB, Perl, C, Java... whatever you are comfortable with.

Basically, you need a good reason not to use TCP/IP and a socket API.


Tim
 
M

Mike Page

Jan 1, 1970
0
John said:
Can anybody explain to me, in 9000 words or less, the difference
between UDP and Telnet? I'll be shipping ASCII data strings between a
PC and one of my boxes over 10/100 ethernet, nothing complex.

My PC has Telnet.exe, which lets me test a telnet connection by just
typing, but I don't see a corresponding UDP thingie.

John

Telnet is strictly a protocol (see RFC854), but is used loosely to
denote ASCII transfers. Telnet clients are useful for getting started,
but they're not binary safe. There are also some odd rules about
ends-of-line.
 
T

Tim Auton

Jan 1, 1970
0
Tim Auton said:
Telnet is a program, rather than a protocol (a terminal emulator to be
precise).

Correction: Telnet is a program AND a protocol. But anyway, it runs
over TCP/IP so the rest of what I said stands.


Tim
 
I

Ian Stirling

Jan 1, 1970
0
Eric said:
And telnet is an application. "Telnet" is related to "UDP" like "fruit"
is related to "tree".

I'd say Telnet is to UDP as fruit is to peanuts.

Supported by the same thing, but rather different in many ways.

I've got a UDP "telnet" program.
netcat, it explicitly refers to the fact that it can be used like this
in the documentation, and gives an example of how to connect a shell
to it.
(all packets sent to the shell until it terminates, all output it sends
sent over UDP.)
Packet loss is a problem of course.
 
A

Abacus-Ri

Jan 1, 1970
0
Just recently I'm finish project using UDP.
Connecting input on RS232 port I convert data and calculate it and send it
to all computers inside local intranet with selected IP address.
I'm used Power Basic 7.02 and there is nice explanation about
UDP,TCP/IP,TELNET and serial data protocol.

In fact to use UDP you must have data which are changed so often
(example>data acquisition) and it is not important to receive feedback from
receiver, to not lose time.
If you need acknowledge from receiver you must use TCP/IP..
If you want to see example I will send you on your private mail.
Rgds,
Damir
 
J

John Larkin

Jan 1, 1970
0
Just recently I'm finish project using UDP.
Connecting input on RS232 port I convert data and calculate it and send it
to all computers inside local intranet with selected IP address.
I'm used Power Basic 7.02 and there is nice explanation about
UDP,TCP/IP,TELNET and serial data protocol.

In fact to use UDP you must have data which are changed so often
(example>data acquisition) and it is not important to receive feedback from
receiver, to not lose time.
If you need acknowledge from receiver you must use TCP/IP..
If you want to see example I will send you on your private mail.
Rgds,
Damir

Great! I use PowerBasic, mostly the DOS version, but I have the
Windows versions too. My customer wants to talk to my box using UDP,
so I plan to use the Lantronix ethernet cube and I'll need to invent a
command protocol (all hex ASCII, most likely) and then I'll need a way
to test it all. I'd appreciate seeing some sample code. I'm jjlarkin
atsign highlandtechnology dotsign com. Thanks!

I did find a freebie...

http://www.snapfiles.com/get/bluesport.html

which looks sort of like the Windows telnet.exe program, but does UDP
too. At least I can use this to type simple commands at first, just to
get the link working.

John
 
M

Michael Furman

Jan 1, 1970
0
John said:
Can anybody explain to me, in 9000 words or less, the difference
between UDP and Telnet? I'll be shipping ASCII data strings between a
PC and one of my boxes over 10/100 ethernet, nothing complex.

UDP is just like a telephone - you can talk to somebody about anythig -
depending on who is listenimg.

Telnet is the same, but with a sepecial person on another side who
understand
a number of different requests and will do whatever you request.
My PC has Telnet.exe, which lets me test a telnet connection by just
typing, but I don't see a corresponding UDP thingie.

You need some other (then Telnet.exe) that after you start it will accept
your ASCI data (for example "copy").
 
J

John Larkin

Jan 1, 1970
0
Can anybody explain to me, in 9000 words or less, the difference
between UDP and Telnet? I'll be shipping ASCII data strings between a
PC and one of my boxes over 10/100 ethernet, nothing complex.

My PC has Telnet.exe, which lets me test a telnet connection by just
typing, but I don't see a corresponding UDP thingie.

John


Well, I figured a couple of things out.

UDP is "User Datagram Protocol."

"Datagram" means "any hunk of octets that you care to care about."

"Octet" means "byte."

and UDP is a simple way of hanging a header on a datagram and shipping
it inside an IP packet, which goes inside an Ethernet packet. The
Xport brick can transparently send/receive serial binary data via UDP
packets, if you set everything up right and watch the timing.

Not bad, once you translate this stuff into plain English.

John
 
R

Richard Henry

Jan 1, 1970
0
John Larkin said:
Well, I figured a couple of things out.

UDP is "User Datagram Protocol."

"Datagram" means "any hunk of octets that you care to care about."

"Octet" means "byte."

"Octet" means "group of 8". Not all bytes are 8 bits.
 
J

John Larkin

Jan 1, 1970
0
"Octet" means "group of 8". Not all bytes are 8 bits.

Oh, sure, how silly of me; lots of people still use 5-bit Baudot codes
for their Ethernet teletype machines.

John
 
K

K Williams

Jan 1, 1970
0
John said:
Oh, sure, how silly of me; lots of people still use 5-bit Baudot
codes for their Ethernet teletype machines.

The *fact* is that "byte" == "character". Many machines have had
"byte" sizes of other than 8-bits. It was IBM that forced this
non-convention. Some 6 processors had a byte size of 6, even. If
one is writing writing portable code one should follow the
conventions. "Octet" is indeed the appropriate term here.
 
I

Iwo Mergler

Jan 1, 1970
0
* UDP as a protocol packages data into packets and routes them
to the destination. The UDP header has fields for source/destination
address, source/destination port and checksum. There is no protection
against lost or duplicated packages. If you want that, you have to do
it yourself or use TCP.

* TCP, like UDP builds on the basic IP protocol. TCP is connection
oriented. That is, it can be regarded as a pipe - you put one or more
bytes into one end and they fall out the other. The protocol makes
sure that the data is actually received at the other end. Lost or
garbled packages are handled via timout/retry.

* Telnet is a slim protocol on top of TCP which allows negociation of
terminal types and similar. You can use a telnet client (Telnet.exe)
to make a TCP connection, the Telnet negociacion is not compulsory.

I'm afraid I don't know much about what applications are available
for Windows, but it's relatively simple to write your own.

http://msdn.microsoft.com/library/d...s/winsock/winsock/ipv4_only_client_code_2.asp

Kind regards,

Iwo
 
Top