Forums

RJ-45 for instrument interface

Started by Steve Wilson March 12, 2018
"Steve Wilson" <no@spam.com> wrote in message 
news:XnsA8A35AE053D3Eidtokenpost@69.16.179.23...
> Since modern computers have no serial or parallel interfaces, the old GPIB > and RS-232 interfaces are obsolete. There have been discussions about > other > interfaces such as HDMI, but the connector is a bit large. > > Consider a setup with a controller connected to the LAN. It may need to > connect to several or dozens of separate boxes for measurement and control > functions. Is it a good idea to use RJ-45 for these interfaces also? > > The connectors are small, locking, bidirectional, high speed, cable length > up to 300m, very inexpensive, readily available, and have sufficient pins > for most needs. > > https://en.wikipedia.org/wiki/Modular_connector > > The RJ-45 pinouts are well defined and can probably be used as is. One > issue is with POE, power over ethernet. The voltage applied can be 48V, > which could destroy most electronics if not controlled. The spec says it > can only be applied if there is a proper handshake between source and > load, > but that could go awry. > > The cables can be double-shielded and come in various lengths and colors. > Here are some examples: > > "When a regular shield is not enough, L-com's exclusive double-shielded > SF/UTP patch cables are ideal. Category 6 tested, these cables use L-com's > superior shielding to drastically reduce EMI/RFI interference using a 100% > foil plus a 65% braid shield. The Low Smoke Zero Halogen jacket allows > this > industrial patch cable to meet today's environmental and safety > requirements. With 26 AWG stranded conductors, this cable is flexible and > easy to install even in tight spaces. We stock in full lengths up to 100 > feet so that equipment runs can be pulled directly and simply plugged into > either end." > > https://tinyurl.com/pf3p4xg > > "Tera Grand - Premium CAT7 Double Shielded 10 Gigabit 600MHz Ethernet > Patch > Cable for Modem Router LAN Network - Built with Gold Plated & Shielded > RJ45 > Connectors, 3 Feet White" > > https://tinyurl.com/ya472pcr > > "Cat 7 Shielded Ethernet Cable 5 ft 6 Pack ( Highest Speed Cable ) Cat7 > Flat Ethernet Patch Cables - Internet Cable for Modem, Router, LAN, > Computer - Compatible with Cat 5e, Cat 6 Network" > > https://tinyurl.com/y7sfsx9w > > What are your thoughts?
Max length for Ethernet over copper is 100 meters. If you need to go farther, use fiber. Regards
Gerhard Hoffmann <gerhard@hoffmann-hochfrequenz.de> wrote:

> Am 12.03.2018 um 21:20 schrieb Steve Wilson:
>> Thanks. I'm thinking to use HTML as the interface to the host, so I >> probably want full Linux.
> That would be the style like it is used with the Red Pitaya.
> < https://www.redpitaya.com/c96/stemsuplabsup-125-14 >
> I have one here, but this WebInterfave / Vivado style > is quite different from the C/VHDL mode I am used to. > It's only the cultural shock. :-)
> regards, Gerhard
Thanks, but this is not to interface to existing commercial test equipment. It's a general interface to custom designs. I'm thinking of the html interface used to configure a router. You can enter numbers and use checkboxes to set options. DD-WRT, Tomato, and OpenWRT might be a place to start. Here's a link to an Infoworld review: https://tinyurl.com/ybknaftb
Jeff Liebermann <jeffl@cruzio.com> wrote:

> On Mon, 12 Mar 2018 20:10:47 GMT, Steve Wilson <no@spam.com> wrote: > >>I do not need or want POE, I'm just concerned about someone plugging a >>cable in the wrong socket. > > If you need some entertainment, try plugging a USB Type A plug into an > RJ45 ethernet jack. It fits quite nicely. If the vendor supplies > passive DC power: > <https://help.ubnt.com/hc/en-us/articles/115000263008--UniFi-Understandin > g-PoE-and-How-UniFi-Devices-are-Powered#active%20vs%20passive> on the > RJ45 jack, the metal USB connector shield will blow a fuse or a current > limiter (hopefully with foldback) will limit the amount of smoke > generated. There are vendors out there that supply 5V, 12V, or 24VDC on > the ethernet jack, with maybe some protection. For example, the above > URL shows that Ubiquiti still supplies 24VDC passive power on some > products. I haven't had time to tear one of their power injectors apart > to see what's inside. I haven't had any problems with them, so as long > as I don't do something dumb, I guess I'm ok. > >>When you say "deliver full power", does that mean the POE can deliver >>partial power by itself or if it is misconfigured? > > No. DC power is delivered only after the negotiated handshake and > identification ceremony. You can short the PoE power wires to each > other or to ground with creating a problem. However, connecting the > power wires across the ethernet data lines will be a big problem > because they're looking into a DC coupled transformer with about 0.5 > ohms resistance. I don't recall the fusing current, but it's not > much. That won't happen with 802.3af style active PoE, but is real > possibility with passive PoE. > >>I don't want to have to >>deal with 48V no matter what other faults may exist. 48V is not the >>problem, the difficulty is getting rid of the heat. I could add a >>shutdown circuit, but that adds complexity and another failure mode. > > The PoE chips deal with the 48V for you. I'll assume that the heat > you're worried about is whatever gets hot if things go awry. As I > mentioned, nothing is going to blow up, get hot, fuse, or explode with > proper 802.3af chips, but might with passive power. > > I don't have a problem with complexity if it also adds safety. I'm > not suggesting that it's foolproof. Our technology is quite good at > producing better fools: > <https://community.spiceworks.com/topic/313729-almost-fried-my-switch-wit > h-poe-injector> > <https://www.reddit.com/r/sysadmin/comments/4lbnq7/til_never_test_a_passi > ve_poe_connection_on_a_non/> If you tried to design a PoE system that is > rugged, reliable, foolproof, and safe, you'll probably end up with > something similar to 802.3af. Spare yourself the effort and just use > the available technology and chips.
Thanks again for the excellent advice. I'm not trying to run POE. I'm just trying to protect agains accidentally plugging into an existing POE jack. If there is 48V in the jack, my regulator would have to survive while dissipating extra heat. I'll add a shutdown circuit to disable the connection if the voltage exceeds +5V or so. I know you say it should not be a problem since the handshake is so complex, but things do go awry. I'd hate to have to argue with a customer that my equipment failed because there was excessive voltage on the plug:)
Jeff Liebermann <jeffl@cruzio.com> wrote:
>>When you say "deliver full power", does that mean the POE can deliver >>partial power by itself or if it is misconfigured?
> No. DC power is delivered only after the negotiated handshake and > identification ceremony. You can short the PoE power wires to each > other or to ground with creating a problem. However, connecting the > power wires across the ethernet data lines will be a big problem > because they're looking into a DC coupled transformer with about 0.5 > ohms resistance. I don't recall the fusing current, but it's not > much. That won't happen with 802.3af style active PoE, but is real > possibility with passive PoE.
I finally got a chance to look up passive poe. Thanks for mentioning it. That's exactly the kind of thing I was worried about. I'll add a shutdown circuit to disable the connection and light a fault led. Of course, I'll take power from the passive poe to do this:)
AT Tuesday 13 March 2018 00:58, Phil Hobbs wrote:

> On 03/12/2018 12:00 PM, John Larkin wrote: >> On Mon, 12 Mar 2018 11:26:56 -0400, Phil Hobbs >> <pcdhSpamMeSenseless@electrooptical.net> wrote: >> >>> On 03/12/2018 10:59 AM, John Larkin wrote: >>>> On Mon, 12 Mar 2018 12:56:00 GMT, Steve Wilson <no@spam.com> wrote: >>>> >>>>> Since modern computers have no serial or parallel interfaces, the old >>>>> GPIB and RS-232 interfaces are obsolete. There have been discussions >>>>> about other interfaces such as HDMI, but the connector is a bit large. >>>>> >>>>> Consider a setup with a controller connected to the LAN. It may need >>>>> to connect to several or dozens of separate boxes for measurement and >>>>> control functions. Is it a good idea to use RJ-45 for these interfaces >>>>> also? >>>>> >>>>> The connectors are small, locking, bidirectional, high speed, cable >>>>> length up to 300m, very inexpensive, readily available, and have >>>>> sufficient pins for most needs. >>>>> >>>>> https://en.wikipedia.org/wiki/Modular_connector >>>>> >>>>> The RJ-45 pinouts are well defined and can probably be used as is. One >>>>> issue is with POE, power over ethernet. The voltage applied can be >>>>> 48V, which could destroy most electronics if not controlled. The spec >>>>> says it can only be applied if there is a proper handshake between >>>>> source and load, but that could go awry. >>>>> >>>>> The cables can be double-shielded and come in various lengths and >>>>> colors. Here are some examples: >>>>> >>>>> "When a regular shield is not enough, L-com's exclusive >>>>> double-shielded SF/UTP patch cables are ideal. Category 6 tested, >>>>> these cables use L-com's superior shielding to drastically reduce >>>>> EMI/RFI interference using a 100% foil plus a 65% braid shield. The >>>>> Low Smoke Zero Halogen jacket allows this industrial patch cable to >>>>> meet today's environmental and safety requirements. With 26 AWG >>>>> stranded conductors, this cable is flexible and easy to install even >>>>> in tight spaces. We stock in full lengths up to 100 feet so that >>>>> equipment runs can be pulled directly and simply plugged into either >>>>> end." >>>>> >>>>> https://tinyurl.com/pf3p4xg >>>>> >>>>> "Tera Grand - Premium CAT7 Double Shielded 10 Gigabit 600MHz Ethernet >>>>> Patch Cable for Modem Router LAN Network - Built with Gold Plated & >>>>> Shielded RJ45 Connectors, 3 Feet White" >>>>> >>>>> https://tinyurl.com/ya472pcr >>>>> >>>>> "Cat 7 Shielded Ethernet Cable 5 ft 6 Pack ( Highest Speed Cable ) >>>>> Cat7 Flat Ethernet Patch Cables - Internet Cable for Modem, Router, >>>>> LAN, Computer - Compatible with Cat 5e, Cat 6 Network" >>>>> >>>>> https://tinyurl.com/y7sfsx9w >>>>> >>>>> What are your thoughts? >>>> >>>> Putting an FTDI USB-to-serial chip on your board is the easiest way to >>>> interface a small instrument. Your internal uP sees a serial >>>> interface, and the control computer sees a usb-serial chip. Most OS's >>>> are familiar with the FTDI chip. >>>> >>>> It's equivalent to burying a USB-serial dongle inside your gadget. Use >>>> USB hubs and cables. >>>> >>>> If you need to go long distances, go Ethernet but that's a bit more >>>> work. >>> >>> We use FTDIs too. The problem in Windows is that you don't know how the >>> ports are going to enumerate, so it's hard to use multiple instruments. >> >> All of our gadgets ID themselves with model number and serial number, >> so an app can scan all the serial ports, looking for devices. That is >> a mild nuisance, but it works. > > Well, you guys get a gold star then. ;) Not everybody does that, > unfortunately. > >> >>> >>> The Prologix GPIB-Ethernet can run a few GPIB instruments, but not a >>> whole rack-full. >> >> Do people still make instruments with GPIB? It's getting old. > > Yup. Generally along with Ethernet and/or USB. > >> >> We use Ethernet a lot too, both inside gadgets running Linux and bare >> metal, with "discrete" uPs and with SOCs. There are learning curves, >> but it becomes routine after the first one. >> >> We recently persuaded the GbE interface of a ZYNQ to talk to a 100 >> Mbit PHY. That saved a lot of balls and long PCB traces. > > I've never actually implemented an Ethernet instrument--most of my stuff > is still one-offs and proofs-of-concept. With DFH on full time and more > licensing stuff in the works, that may change. > > Cheers > > Phil Hobbs >
With such unique identifications and some udev magic (SYMLINK+=...) you can even have device names automatically assigned in Linux. -- Reinhardt
On Monday, March 12, 2018 at 8:28:20 PM UTC-4, John Larkin wrote:
> We use the B+K 844 USB programmers, which are actually rebrands of > some box made in eastern Europe. They work great. >
BK-867 here. Wonderful device! I have a (much) older one, but it started to become a hassle keeping a Windows-95/XP machine around to run it. And it doesn't handle many of the newer chips without jumping through a lot of hoops.
On Monday, March 12, 2018 at 8:37:42 PM UTC-4, pcdh...@gmail.com wrote:
Thanks guys.
I'm going to look into those FTDI chips in more detail.
On Tuesday, March 13, 2018 at 6:48:23 AM UTC-4, mpm wrote:

BTW: A little off topic maybe...?

It too bad that IrDA hasn't really seemed to garner wide-spread use as a short-range bi-directional data interface.

Even my cell phone, (Samsung Galaxy S5) only offers one-way IR, and I'm not even sure if that's IrDA.

Seems like a dirt-cheap way to get something done.

On 13/03/2018 01:59, John Larkin wrote:
> On Mon, 12 Mar 2018 12:56:00 GMT, Steve Wilson <no@spam.com> wrote: > >> Since modern computers have no serial or parallel interfaces, the old GPIB >> and RS-232 interfaces are obsolete. There have been discussions about other >> interfaces such as HDMI, but the connector is a bit large. >> >> Consider a setup with a controller connected to the LAN. It may need to >> connect to several or dozens of separate boxes for measurement and control >> functions. Is it a good idea to use RJ-45 for these interfaces also? >> >> The connectors are small, locking, bidirectional, high speed, cable length >> up to 300m, very inexpensive, readily available, and have sufficient pins >> for most needs. >> >> https://en.wikipedia.org/wiki/Modular_connector >> >> The RJ-45 pinouts are well defined and can probably be used as is. One >> issue is with POE, power over ethernet. The voltage applied can be 48V, >> which could destroy most electronics if not controlled. The spec says it >> can only be applied if there is a proper handshake between source and load, >> but that could go awry. >> >> The cables can be double-shielded and come in various lengths and colors. >> Here are some examples: >> >> "When a regular shield is not enough, L-com's exclusive double-shielded >> SF/UTP patch cables are ideal. Category 6 tested, these cables use L-com's >> superior shielding to drastically reduce EMI/RFI interference using a 100% >> foil plus a 65% braid shield. The Low Smoke Zero Halogen jacket allows this >> industrial patch cable to meet today's environmental and safety >> requirements. With 26 AWG stranded conductors, this cable is flexible and >> easy to install even in tight spaces. We stock in full lengths up to 100 >> feet so that equipment runs can be pulled directly and simply plugged into >> either end." >> >> https://tinyurl.com/pf3p4xg >> >> "Tera Grand - Premium CAT7 Double Shielded 10 Gigabit 600MHz Ethernet Patch >> Cable for Modem Router LAN Network - Built with Gold Plated & Shielded RJ45 >> Connectors, 3 Feet White" >> >> https://tinyurl.com/ya472pcr >> >> "Cat 7 Shielded Ethernet Cable 5 ft 6 Pack ( Highest Speed Cable ) Cat7 >> Flat Ethernet Patch Cables - Internet Cable for Modem, Router, LAN, >> Computer - Compatible with Cat 5e, Cat 6 Network" >> >> https://tinyurl.com/y7sfsx9w >> >> What are your thoughts? > > Putting an FTDI USB-to-serial chip on your board is the easiest way to > interface a small instrument. Your internal uP sees a serial > interface, and the control computer sees a usb-serial chip. Most OS's > are familiar with the FTDI chip. > > It's equivalent to burying a USB-serial dongle inside your gadget. Use > USB hubs and cables.
Meh, I have had annoyance when I wanted to locate such an instrument more than 25m from the computer that controlled it. (And incidentally the cable had to be chopped, fed through a small hole and reterminated which is not nice with USB.) I could have opened the instrument and removed the FTDI chip and replaced it with a MAX232 or equivalent, but that would void the instrument warranty. I considered trying to buy/make the opposite of a FTDI chip (USB host with a uart) but that is a massive pain because USB is so complicated. Also, such an instrument (with built-in FTDI) is impractical to interface to e.g. an Arduino or other simple microcontroller, if you wanted to do that. You need a real OS with USB stack, but sometimes it is better to avoid putting a real PC or even a RPi in your test system, because then the corporate IT department feels entitled to mess with it, install corporate spyware and updates that break it, etc. Really, if you want to sell me something that looks like a FTDI dongle connected to an instrument with a serial port, then put a real serial port on the instrument and screw on a FTDI dongle, on the outside. Yes it is a waste of a dollar worth of level shifters but it is better. No, I don't care if it will confuse millenials with that strange ancient connector. Actually, go ahead, hook up and require all of the handshaking pins, just to mess with them.
On Tue, 13 Mar 2018 03:52:05 -0700 (PDT), mpm <mpmillard@aol.com>
wrote:

>On Tuesday, March 13, 2018 at 6:48:23 AM UTC-4, mpm wrote: > >BTW: A little off topic maybe...? > >It too bad that IrDA hasn't really seemed to garner wide-spread use as a short-range bi-directional data interface. > >Even my cell phone, (Samsung Galaxy S5) only offers one-way IR, and I'm not even sure if that's IrDA. > >Seems like a dirt-cheap way to get something done.
It would be nice if everything were wireless. We wouldn't need a tangle of hubs and cables. -- John Larkin Highland Technology, Inc lunatic fringe electronics