Fun challenge: cat-5 cable tester

D

DJ Delorie

Jan 1, 1970
0
I had this idea, and toyed with it a while (including some computer
simulations), but didn't go very far with it. I thought I'd post it
here in case anyone wants a brain teaser for the weekend.

Consider this tool: a cat-5 cable tester.

Goal: To make a tester that works entirely from the user's side,
without needing batteries at the far end.

Circuit:

+-----+
| | P0/AD0 R1 R11
| |----------\/\/\--< <--------> >----\/\/\ ---+
| | P1/AD0 R2 R12 |
| |----------\/\/\--< <--------> >----\/\/\ ---+
| | P2/AD2 R3 R13 |
| |----------\/\/\--< <--------> >----\/\/\ ---+
| | P3/AD3 R4 R14 |
| |----------\/\/\--< <--------> >----\/\/\ ---+
| uP | P0/AD0 R5 R15 |
| |----------\/\/\--< <--------> >----\/\/\ ---+
| | P1/AD0 R6 R16 |
| |----------\/\/\--< <--------> >----\/\/\ ---+
| | P2/AD2 R7 R17 |
| |----------\/\/\--< <--------> >----\/\/\ ---+
| | P3/AD3 R8 R18 |
| |----------\/\/\--< <--------> >----\/\/\ ---+
| | cable
+-----+

The idea is that each GPIO pin can either drive high, drive low, or
measure the voltage present. I.e. you're creating a programmable
resistor divider network. So you can set up various combinations of
resistors being driven from various combinations of voltages, and use
the A/D converters to measure the voltage, and compare with what you
"think" it should be.

The challenge: Select values of R1..R18 such that you can accurately
detect the following cable errors:

* shorts between any N (2..8) conductors.
* opens in any one or more conductor.
* swapped (or N>2 miswired) conductors.

Bonus points for minimizing the number of A/D bits you need.

My idea was to provide eight red/green or RGB leds on the uP side to
indicate the status of each conductor (green=OK, other
combinations=various error conditions), with a serial or usb port for
diagnostics to a laptop. I have a cable tester now, but the battery
is at one end and the lights are at the other.
 
A

Art

Jan 1, 1970
0
Intriguing, is it meant to check the cable terminated (While Connected) to
another header or open ended? That also may be a consideration. I presume
from your post that you are pluging the cable into a socket having these
paticular terminations and reading through the cable to the other end?
Correct?
 
T

The Real Andy

Jan 1, 1970
0
I had this idea, and toyed with it a while (including some computer
simulations), but didn't go very far with it. I thought I'd post it
here in case anyone wants a brain teaser for the weekend.

Consider this tool: a cat-5 cable tester.

Goal: To make a tester that works entirely from the user's side,
without needing batteries at the far end.

Circuit:

+-----+
| | P0/AD0 R1 R11
| |----------\/\/\--< <--------> >----\/\/\ ---+
| | P1/AD0 R2 R12 |
| |----------\/\/\--< <--------> >----\/\/\ ---+
| | P2/AD2 R3 R13 |
| |----------\/\/\--< <--------> >----\/\/\ ---+
| | P3/AD3 R4 R14 |
| |----------\/\/\--< <--------> >----\/\/\ ---+
| uP | P0/AD0 R5 R15 |
| |----------\/\/\--< <--------> >----\/\/\ ---+
| | P1/AD0 R6 R16 |
| |----------\/\/\--< <--------> >----\/\/\ ---+
| | P2/AD2 R7 R17 |
| |----------\/\/\--< <--------> >----\/\/\ ---+
| | P3/AD3 R8 R18 |
| |----------\/\/\--< <--------> >----\/\/\ ---+
| | cable
+-----+

The idea is that each GPIO pin can either drive high, drive low, or
measure the voltage present. I.e. you're creating a programmable
resistor divider network. So you can set up various combinations of
resistors being driven from various combinations of voltages, and use
the A/D converters to measure the voltage, and compare with what you
"think" it should be.

The challenge: Select values of R1..R18 such that you can accurately
detect the following cable errors:

* shorts between any N (2..8) conductors.
* opens in any one or more conductor.
* swapped (or N>2 miswired) conductors.

Bonus points for minimizing the number of A/D bits you need.

My idea was to provide eight red/green or RGB leds on the uP side to
indicate the status of each conductor (green=OK, other
combinations=various error conditions), with a serial or usb port for
diagnostics to a laptop. I have a cable tester now, but the battery
is at one end and the lights are at the other.


Its been a while, but back when i was an electrician, we had these
neat little testers that cost about $2000 Aussie dollars. You plug a
little passive device in one end, the instrument in the other. It
would then map out on its graphic lcd the actual pinout, the loss, the
length of the cable and the position of the break if any. Given some
domain/network data it could even show you routes, network statistic,
analyse connection issues ect.

I am guessing that now days you could get something similar for a lot
less, and with more features. For a simple go/no go test you can get
some pretty basic testers for a very reasonable sum. Hardley worth
reinventing the wheel.
 
D

DJ Delorie

Jan 1, 1970
0
Art said:
Intriguing, is it meant to check the cable terminated (While
Connected) to another header or open ended? That also may be a
consideration. I presume from your post that you are pluging the
cable into a socket having these paticular terminations and reading
through the cable to the other end? Correct?

there are two parts to the tester - the part with the uP (R1..R8) and
the "fob" that connects on the far end of the cable (R11..R18). The
two ends don't have to be near each other, but both ends of the cable
have something plugged into them. The goal, however, is to have
nothing active - no lights or batteries - on the far end, so
everything is controlled from the near end. My current tester
requires you to go back and forth, since the battery is on one end and
the lights are on the other end.

For testing wall jacks, you'd just use a known-good patch cable to
connect the tester to the wall jack.
 
D

DJ Delorie

Jan 1, 1970
0
The Real Andy said:
Hardley worth reinventing the wheel.

It's not about reinventing the wheel, it's about challenging yourself
to think and to make something with your own two hands. Heck, I
already have a cable tester, it's not like I need two.

Some people do this for fun, you know ;-)
 
L

Luhan

Jan 1, 1970
0
DJ said:
It's not about reinventing the wheel, it's about challenging yourself
to think and to make something with your own two hands. Heck, I
already have a cable tester, it's not like I need two.

Some people do this for fun, you know ;-)

Not to mention the financial advange, especially if you have more time
than money.

Luhan
 
M

Michael A. Terrell

Jan 1, 1970
0
DJ said:
I had this idea, and toyed with it a while (including some computer
simulations), but didn't go very far with it. I thought I'd post it
here in case anyone wants a brain teaser for the weekend.

Consider this tool: a cat-5 cable tester.

Goal: To make a tester that works entirely from the user's side,
without needing batteries at the far end.

Circuit:

+-----+
| | P0/AD0 R1 R11
| |----------\/\/\--< <--------> >----\/\/\ ---+
| | P1/AD0 R2 R12 |
| |----------\/\/\--< <--------> >----\/\/\ ---+
| | P2/AD2 R3 R13 |
| |----------\/\/\--< <--------> >----\/\/\ ---+
| | P3/AD3 R4 R14 |
| |----------\/\/\--< <--------> >----\/\/\ ---+
| uP | P0/AD0 R5 R15 |
| |----------\/\/\--< <--------> >----\/\/\ ---+
| | P1/AD0 R6 R16 |
| |----------\/\/\--< <--------> >----\/\/\ ---+
| | P2/AD2 R7 R17 |
| |----------\/\/\--< <--------> >----\/\/\ ---+
| | P3/AD3 R8 R18 |
| |----------\/\/\--< <--------> >----\/\/\ ---+
| | cable
+-----+

The idea is that each GPIO pin can either drive high, drive low, or
measure the voltage present. I.e. you're creating a programmable
resistor divider network. So you can set up various combinations of
resistors being driven from various combinations of voltages, and use
the A/D converters to measure the voltage, and compare with what you
"think" it should be.

The challenge: Select values of R1..R18 such that you can accurately
detect the following cable errors:

* shorts between any N (2..8) conductors.
* opens in any one or more conductor.
* swapped (or N>2 miswired) conductors.

Bonus points for minimizing the number of A/D bits you need.

My idea was to provide eight red/green or RGB leds on the uP side to
indicate the status of each conductor (green=OK, other
combinations=various error conditions), with a serial or usb port for
diagnostics to a laptop. I have a cable tester now, but the battery
is at one end and the lights are at the other.


How is it going to detect split pairs or miswired connectors?


--
Service to my country? Been there, Done that, and I've got my DD214 to
prove it.
Member of DAV #85.

Michael A. Terrell
Central Florida
 
D

Damir

Jan 1, 1970
0
It's not about reinventing the wheel, it's about challenging yourself
to think and to make something with your own two hands. Heck, I
already have a cable tester, it's not like I need two.

Some people do this for fun, you know ;-)

He is "to smart" to understand. :)
 
J

jasen

Jan 1, 1970
0
I had this idea, and toyed with it a while (including some computer
simulations), but didn't go very far with it. I thought I'd post it
here in case anyone wants a brain teaser for the weekend.

Consider this tool: a cat-5 cable tester.

Goal: To make a tester that works entirely from the user's side,
without needing batteries at the far end.

Circuit:

+-----+
| | P0/AD0 R1 R11
| |----------\/\/\--< <--------> >----\/\/\ ---+ .....
| | P3/AD3 R8 R18 |
| |----------\/\/\--< <--------> >----\/\/\ ---+
| | cable
+-----+
The idea is that each GPIO pin can either drive high, drive low, or
measure the voltage present. I.e. you're creating a programmable
resistor divider network. So you can set up various combinations of
resistors being driven from various combinations of voltages, and use
the A/D converters to measure the voltage, and compare with what you
"think" it should be.

The challenge: Select values of R1..R18 such that you can accurately
detect the following cable errors:

* shorts between any N (2..8) conductors.
* opens in any one or more conductor.
* swapped (or N>2 miswired) conductors.

Bonus points for minimizing the number of A/D bits you need.


maybe 1n914 diodes in a ring topology at the far end.
then it can be done using 1 bit at the UP end.

+-----+
| | D0
| |--------+---------< <--------> >-+-->|----.
| | D1 `-\/\/\-+ `------. |
| |--------+-------|-< <--------> >-+-->|--' |
| | D2 `-\/\/\-+ `------. |
| |--------+-------|-< <--------> >-+-->|--' |
| | D3 `-\/\/\-+ `------. |
| |--------+-------|-< <--------> >-+-->|--' |
| uP | D4 `-\/\/\-+ `------. |
| |--------+-------|-< <--------> >-+-->|--' |
| | D5 `-\/\/\-+ `------. |
| |--------+-------|-< <--------> >-+-->|--' |
| | D6 `-\/\/\-+ `------. |
| |--------+-------|-< <--------> >-+-->|--' |
| | D7 `-\/\/\-+ `------. |
| |--------+-------|-< <--------> >-+-->|--' |
| | `-\/\/\-+ cable `-----|<-'
+-----+ |
0V --+--

how it is you is you drive the pins high one at at time and
see which and how many of the other pins are pulled high by the diodes.

the two diodes between D0-D7 will dive a double drop which will reduce by
one the number of highs seen. so you can find pin 1/8 on the plug

My idea was to provide eight red/green or RGB leds on the uP side to
indicate the status of each conductor (green=OK, other
combinations=various error conditions), with a serial or usb port for
diagnostics to a laptop. I have a cable tester now, but the battery
is at one end and the lights are at the other.

. .
. .
| // // |
+-->|-+-|<--+
| R | G |
. \  .
. / .
\ .
| | .
DN|--------+-[10K]--+--------|---<
| | |
`-[100K]-+
|
 
D

DJ Delorie

Jan 1, 1970
0
jasen said:
What this doesn't give though is any way individualise the
unpowered terminators to identify one cable from the other

Yeah, the fact that the diodes are all the same does that. With
resistors, you can make them all different values.
for that you'd need a micro or similar on the far end...

I thought of that, with diodes to leech power from whatever pins were
high or low, running something like asynchronous i2c on each of the
eight conductors.

I worried that shorts in the cable would damage the micros.
 
T

The Real Andy

Jan 1, 1970
0
It's not about reinventing the wheel, it's about challenging yourself
to think and to make something with your own two hands. Heck, I
already have a cable tester, it's not like I need two.

Some people do this for fun, you know ;-)

It thats the case, then a 4017, 8 bicolour LED's + a handful of
resistors and capcitors.
 
D

DJ Delorie

Jan 1, 1970
0
The Real Andy said:
It thats the case, then a 4017, 8 bicolour LED's + a handful of
resistors and capcitors.

My existing tester does something like this, but the LEDs are on the
far end of the cable. The challenge is to figure out how to do it
with a resistor network on the far end of the cable, so the LEDs can
be on the same end as the uP.
 
J

jasen

Jan 1, 1970
0
How is it going to detect split pairs or miswired connectors?

It's not. most cheap testers only do continuity, and that catches over 99%
of wiring errors. pairing errors that otherwise test good reqire that the
same mistake be made at both ends.

if the run is long enough (I have no idea how to quantify long enough) it
may be possible to detect the differences pairs by the driveing them in
differential mode and measuring the response time somehow.

Bye.
Jasen
 
M

Michael A. Terrell

Jan 1, 1970
0
jasen said:
It's not. most cheap testers only do continuity, and that catches over 99%
of wiring errors. pairing errors that otherwise test good reqire that the
same mistake be made at both ends.

if the run is long enough (I have no idea how to quantify long enough) it
may be possible to detect the differences pairs by the driveing them in
differential mode and measuring the response time somehow.

Bye.
Jasen


TDR.



--
Service to my country? Been there, Done that, and I've got my DD214 to
prove it.
Member of DAV #85.

Michael A. Terrell
Central Florida
 
T

The Real Andy

Jan 1, 1970
0
My existing tester does something like this, but the LEDs are on the
far end of the cable. The challenge is to figure out how to do it
with a resistor network on the far end of the cable, so the LEDs can
be on the same end as the uP.

A diode on the far end of each pair.
 
DJ said:
It's not about reinventing the wheel, it's about challenging yourself
to think and to make something with your own two hands. Heck, I
already have a cable tester, it's not like I need two.

Some people do this for fun, you know ;-)

Most professionals do it for more than fun,
since the shop/PCB jerks never see the
advantage of doing it without batteries and music.
 
D

DJ Delorie

Jan 1, 1970
0
The Real Andy said:
A diode on the far end of each pair.

No, I'm pretty sure I said resistor network.

I'm rather disappointed in the response I've gotten from this. I've
seen a lot of people tell my why it's a bad design, or all the things
it can't do, or alternate ways to build cable testers, and yet NOBODY
has addressed the original challenge.

GIVEN THE SCHEMATIC I POSTED, what resistor values let you detect bad
cables (as far as the design allows) with the least ADC bits?
 
F

Fred Bloggs

Jan 1, 1970
0
DJ said:
No, I'm pretty sure I said resistor network.

I'm rather disappointed in the response I've gotten from this. I've
seen a lot of people tell my why it's a bad design, or all the things
it can't do, or alternate ways to build cable testers, and yet NOBODY
has addressed the original challenge.

GIVEN THE SCHEMATIC I POSTED, what resistor values let you detect bad
cables (as far as the design allows) with the least ADC bits?

Well the least you can do is one A/D resolution cell per fault type with
exactly one fault, then exactly two, then three, etc up to the limit
with the maximum number of faults possible. Maybe a 20-bit job will do.
 
D

DJ Delorie

Jan 1, 1970
0
Fred Bloggs said:
Well the least you can do is one A/D resolution cell per fault type
with exactly one fault, then exactly two, then three, etc up to the
limit with the maximum number of faults possible. Maybe a 20-bit job
will do.

Except that you have eight A/Ds and you can reconfigure the rest of
the pins to drive high or low. I've gotten it down to about 12-13
bits so far, with random fiddling.

Part of the challenge is to come up with the techniques for setting up
the tests - whether to drive H or L, or tri-state, what to measure and
for what, etc.
 
R

Richard Henry

Jan 1, 1970
0
Sort of semi-OT:

I have a misty distant memeory that the CAT-5 designation actually
referred to plenum wiring flame-proof and smoke-proof qualities, and
had nothing to do with the number of conductors, their twistedness, or
the type of connectors. Am I thinking of something else?
 
Top