cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1240
Views
0
Helpful
11
Replies

STUN and Modems (RS232) - Silly question maybe

Tim Smith
Level 4
Level 4

Hi Guys,

Any ideas on whether this is possible?

I have two cisco routers connected via a WAN.

I have a radio modem at the far side with an RS232 connection and a PC / Server at the local end.

Could STUN be used to extend the serial connection between the RS232 port on the PC to the remote radio modem?

Anyone done this before?

Is there an easier way?

Cheers,

Tim.

11 Replies 11

ehirsel
Level 6
Level 6

I believe that STUN is only used to tunnel SDLC frames; this is from reading the Cisco doc on STUN.

So unless the PC is running software that emulates an IBM 3174 cluster controller or an as/400 type of controller (such as a 5394) you won't be able to use STUN.

From reading your topology description, is this an accurate picture?

Radio Modem--Router---WAN---Router--PC

If that is the case, then this may work, assuming that you have a routed wan link:

On the router closest to the PC, allow the pc to telnet to the far router. On that far router (the one closest to the Radio Modem), allow a reverse telnet to the modem.. This is basically running a routed telnet session over the wan, and then running a reverse telnet on the target side. Reverse Telent usually runs over rs-232 serial/console connections as a means of providing for out-of-band management access in a secure manner.

Let me know if this helps.

Thanks for the response,

Topology is as follows

Radio Modem-RS232-Router-WAN-Router-RS232-PC

So the only issue is the PC leg is actually expecting the data via it's serial port.

I dont think this is going to be an easy task.

Cheers,

Tim

What OS is running on the PC? I was thinking that it was a client, instead of a server. I do know that varios flavors of UNIX can work with the serial with regards to telnet and ssh.

dwind
Level 1
Level 1

If the frames are delimited by flag characters - x'7e' then stun basic could be used. If they are delimited by syns x'32' then it might be possible to use bstun. If it is asyn and there is a known startign and ending character then it is possible to use bstun async tunneling.

Thanks that is great information.

The application is Wenco Mining telemetry.

Which of the above categories would a standard pc modem fit into if any?

Do we have any other options for this kind of serial over IP functionality?

Cheers,

Tim

Hi Tim,

A "standard" PC serial port is bound to be asynchronous. There are synchronous serial (ISA and PCI) adapters. But the built in serial port will be asynch, so you've got about 4 choices:

1. Reverse telnet / TCP Stream - Widely used, well understood, reliable, and probably should be your first choice. The disadvantages are that it has no concept of serial frames, and any layer 2 protocol that may depend on them. This could result in bursts of bytes being delivered at the far end that can not be processed, or TCP retransmissions could defeat the layer 2 mechanisms.

http://www.cisco.com/warp/public/700/14.shtml

2. BSTUN ASP - Designed to handle asynch serial block protocols, optional reliability and sequencing enforcement, and flexible configuration. The down side is primarily that you need to find out (sniff) something about what's on the wire to understand how to configure it, and there is some possibility that some prtocol rule will prevent ASP from being usable.

http://www.cisco.com/univercd/cc/td/doc/product/software/ios112/asp.htm

Also search on several additions - "asp sof", "asp eof", "asp rx-ift".

3. UDPTN - The major advantage of UDPTN is that is uses multicast to send serial traffic to multiple locations. This probably isn't helpful here. But also, because it uses UDP, it's less likely to exhibit the bursting effect of reverse telnet, and won't create retransmissions that could interfere with layer 2 protocols.

http://www.cisco.com/univercd/cc/td/doc/product/software/ios120/120newft/120t/120t5/asyncudp.htm

4. CEoIP - Network modules that can be added to routers, and provide bit level transparent transport of virtually any serial protocol. Probably the only disadvantage is some additional cost. http://cisco.com/en/US/products/hw/routers/ps259/products_data_sheet09186a00802045f5.html

How you approach this sort of depends on what you have to work with, serial datascope, access to test time on live or simulated gear, documentation on Wenco Mining telemetry, a desire to hack or study.

Hope this helps.

Rgds, Dan

I looked Wenco Mining telemetry on the web and couldn't figure out what type it is. Can you find out what encapsulation they use - async, bisync or hdlc/sdlc?

Thanks

Dennis

Hi,

This is the reply from wenco regarding data format, i have also asked the question regarding the encap.

The data exchange protocol only demands that all messages are terminated with "00,FF,FF,FF" (hex, of course).

This, of course, means that we cannot send this termination pattern in the data itself. However, we effectively do this, but doing "byte-stuffing" to ensure that if any occurrences of "00,FF,FF,FF" do appear in the data itself, then it is replaced by "00, FF, FF, FE, FF" where that extra "FE" is stripped out by the reception side.

No cisco protocols will do byte substitution.

I suspect it is a asynchronous protocol and

you maybe able to get

bstun protocol-group 1 async-generic

working.

I thinl you were sent the web pages for this previous.

Thanks

Dennis

We have set this up on the bench with two pc's in the aux ports at each end.

Running hyper terminal, we can see the characters from each end come through both ways.

With async-generic do we need to know the frame format or will it just forward everything received?

We are hopefully testing with the actual equipment this week.

I probably have a setup that could benefit from this. Containing a serial terminal connected across an ip network to a main unit at the other end. RS232 running 9600 baud.

Could you possible post some snippets from your config ?

Best Regards,

Review Cisco Networking for a $25 gift card