From owner-freebsd-questions@FreeBSD.ORG Thu Mar 4 16:20:56 2010 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B35FB1065672 for ; Thu, 4 Mar 2010 16:20:56 +0000 (UTC) (envelope-from martin@dc.cis.okstate.edu) Received: from dc.cis.okstate.edu (dc.cis.okstate.edu [139.78.103.93]) by mx1.freebsd.org (Postfix) with ESMTP id 872588FC15 for ; Thu, 4 Mar 2010 16:20:56 +0000 (UTC) Received: from dc.cis.okstate.edu (localhost.cis.okstate.edu [127.0.0.1]) by dc.cis.okstate.edu (8.14.2/8.13.8) with ESMTP id o24GKkGG006499; Thu, 4 Mar 2010 10:20:47 -0600 (CST) (envelope-from martin@dc.cis.okstate.edu) Message-Id: <201003041620.o24GKkGG006499@dc.cis.okstate.edu> To: Olivier GARNIER MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <6497.1267719646.1@dc.cis.okstate.edu> Date: Thu, 04 Mar 2010 10:20:46 -0600 From: Martin McCormick Cc: freebsd-questions@freebsd.org Subject: Re: RS232 / TCP converter and BSD. X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 04 Mar 2010 16:20:56 -0000 Olivier GARNIER writes: > I have a weather station (Lacross WS2350). (can be connect by USB / > RS232). > > I want to get data from a FreeBSD server 70 meter from the weather station > (with http://www.wviewweather.com/ software). > > I already have a RJ45 cable between the two objects. > > I wish i could get a RS232 to RJ45 connecter like this one : > http://www.lextronic.fr/P6554-convertisseur-tcpip--rs232-cse-h53.html > > And use it to connect the weather station to the RJ45 network, and then > get > data from my BSD. > > > > The bad point is that the soft witch are given with the RS232 to RJ45 > translater are for windows, and it make a virtual port on windows. > > I don't know if it will work on BSD. > > If it does not work, i'll be oblige to buy another RJ45 to RS232 > translater... and it's not cheap. You did not say what version of FreeBSD you are using and it does make a difference. The usb port stack was rewritten for FreeBSD8.0 so that probably works best. I tried to attach a usb converter to a FreeBSD6.3 system and it never worked. Different models of RS-232 converters may work fine. I just could not get these to work at all under 6.3. RJ45 plugs and CAT3 or CAT5 Ethernet-style cables are frequently used to carry RS-232 signals so the only somewhat unusual device you will need to procure is a plug adaptor such as one made by Modtap which simply has a RJ45 female on one edge and a male or female RS-232 9 or 25-pin plug or socket on the other edge. These adaptors have no IC's or intelligence built in to them. They just route the conductors in the CATx cable to the right pins. You may have to actually build the adaptor to your needs but these things at least used to be fairly common. The actual RS-232 to usb port converters are relatively inexpensive these days and they do have processors built in to them as well as charge pumps to generate the +-12 volts for RS-232 devices. Some of them are built to work fine under systems other than Windows boxes and others may only work under Windows so you will need to be sure that the one you want to use works. So, in short, you need a plug adaptor to make the RJ45 cable useble with RS-232 devices and you also need any of the common RS-232 to usb converters to actually connect the cable to your FreeBSD computer. As long as the usb-RS-232 converter actually works and produces a new ttyUSBx device, the brand is not that critical. Martin McCormick WB5AGZ Stillwater, OK Systems Engineer OSU Information Technology Department Telecommunications Services Group