20070331

Serial Speed-shifting demons

A fellow called Jerry Roy emailed me, asking if I knew how to connect a Cisco AUX port to a Topglobal Phoebus EVDO router console. There were a few thing he needed to work out...

1) the Cisco RJ45 to EVDO Mini-DIN-8 cable wiring
2) the configuration settings on the Cisco
3) why his old Cisco config clues didn't work right

Jerry is no slouch at this stuff, and had configured Cisco gear for reverse-TCP conection to the AUX port in the past, but this one was baffling him. He had a mini-DIN to DE-9 modem cable, but it wasn't playing nicely with the Cisco adapter. When he connected to the AUX port over the network, he got a Cisco login instead of the EVDO. Solving this took us about a week, including emailing to the vendor's support staff and the EVDO manufacturer in China to clarify signalling info and determine what wires needed connect to which pins. Once we had what we thought were the right pins, we still saw garbage on start-up, which made us try a variety of settings (even though the console speed was set to 9600 8-N-1).

We determined that the exec/no exec flag had changed in a major Cisco IOS revision from 12.2 to 12.3, so his abbreviated configuration commands needed to be amended. (It doesn't hurt to invoke a 'default' setting, so my Cisco config clues are a good start, if you're using reverse-TCP to get to Cisco ports.)

Jerry finally determined that the Tpoglobal Phoebus EVDO device runs its console at 115.2k 8-N-1, but he couldn't get any reponse from the console after the startup...because the OS then changes the EVDO console to the user-defined speed. The EVDO was running POST at one speed (spewing garbage at the modem/console), then silently shifting speed to a different, user-specifiable speed. He eventually set the user-defined speed for 115.2k, so the speeds would be consistent.

What made this so hard;
a) cisco changed the 'default' functions for local login (exec) between major IOS versions
b) vendor docs used unusual signal names (TD+, TD-, etc.) without input/output clues
c) molded cables, and unusual connectors made it hard to determine cable pinouts.
d) Roy didn't have any signal testing gear besides a voltmeter.
e) vendor docs didn't mention that P.O.S.T. messages would always be at 115.2 kbps

Developers Clue #1: If you think this speed shifting is a good idea, at least end the POST with a tag indicating that "POST is done, switching to OS console speed", even if you can't indicate what the new speed might be.

Developers Clue #2: If you think this speed shifting is a good idea, in the code that allows the user to set/check the definable console speed, you should also retun a note that the POST speed will remain at [speed], so the user is reminded that there will be a difference. (Or add an option to set the speed "Same as P.O.S.T. console speed".)

Tech Writers Clue: If the system console can be set for two different speeds, the cases need to be called out in the manual.

Here's the cable diagram Jerry came up with (in case someone else needs it) with the pin numbers shuffled to see where loops occur;
Cisco AUX           EVDO console
RJ45M mini-DIN-8M refer to my Signals page
1 RTS -->(nc) (nc) --> DCD 1 for connector pinout info
3 TD -->------------> RD 3
6 RD <------------<-- TD 5 8 CTS <------------<-- RTS 6 4 GND ---+-----------> GND 4
| (nc) --> CTS 2
5 gnd ---' (loop Cisco pins 4 to 5)
2 DTR -->-. (nc) --> DSR 7
7 DSR <---' (loop Cisco pins 2 to 7)
Since the EVDO apparently doesn't have a DTR output, we looped the Cisco hardware handshake lines. (For use connecting to other consoles, I would usually pass these to the 'far side', so the far device could tell if the cable was plugged in AND the near device was turned on. After all, that's what these leads were designed to do.) If you care about hardware flow control (RTS/CTS), you could also connect Cisco pin 1 to EVDO pin 7.

-Z-

No comments: