Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 9 Mar 2009 12:35:17 +0100
From:      Hans Petter Selasky <hselasky@c2i.net>
To:        freebsd-usb@freebsd.org
Subject:   Re: 1wire sensor with ugen...
Message-ID:  <200903091235.19268.hselasky@c2i.net>
In-Reply-To: <6721d4100903081516v19e46090if41d373b82b476c3@mail.gmail.com>
References:  <6721d4100903081516v19e46090if41d373b82b476c3@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sunday 08 March 2009, Conall O'Brien wrote:
> Hello,
>
> I've a 1wire USB device with a temperature sensor which I'm trying to set
> up. My FreeBSD 7.x (RELENG_7) system detects it on boot and IDs it
> correctly:
>
> ugen1: <DLP Design DLP-TEMP, class 0/0, rev 2.00/6.00, addr 3> on uhub0
>
> which results in /dev/ugen1 , /dev/ugen1.1 and /dev/ugen1.2 devices all
> being created.
>
>
> The sensor should be accessible as a straight serial device (9600 baud,
>
> etc), but my attempts using pyserial aren't working:
> >>> s = serial.Serial('/dev/ugen1', 9600, timeout=1)
> >>> s.read(10)
>
> Traceback (most recent call last):
>   File "<stdin>", line 1, in <module>
>   File "build/bdist.freebsd-7.1-STABLE-amd64/egg/serial/serialposix.py",
> line 344, in read
> serial.serialutil.SerialException: Port not open
>
> >>> s.isOpen()
>
> False
>
>
> I don't have much experience working directly with ugen devices, so any
> advice to get this working would be appreciated.
>
>
> Thanks!

Hi,

Ugen devices do not support setting the baud rate ... You need to add your 
device to the "ugensa" driver or make it look like a generic "umodem" device.

--HPS



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200903091235.19268.hselasky>