Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 22 Jul 2016 18:35:56 +0200
From:      "O. Hartmann" <ohartman@zedat.fu-berlin.de>
To:        freebsd-usb@freebsd.org, FreeBSD CURRENT <freebsd-current@freebsd.org>
Subject:   Digi Watchport/T temperature sensor as /dev/ttyU
Message-ID:  <20160722183556.2fc39fd7.ohartman@zedat.fu-berlin.de>

next in thread | raw e-mail | index | archive | help
--Sig_/yU=6rfK1L/9sco8CZOexKVw
Content-Type: text/plain; charset=US-ASCII
Content-Transfer-Encoding: quoted-printable


For temperature monitoring, we have a bunch of Digi Watchport/T sensors:=20

http://ftp1.digi.com/support/documentation/90000406_H.pdf

They work well with CentOS 5/6 systems and there is also a Nagios plugin, w=
ritten in
Perl, which makes those sensors usable with Nagios/Icinga/Icinga2:=20
=20
https://exchange.nagios.org/directory/Plugins/System-Metrics/Environmental/=
check_watchptTemp/details

When attached to FreeBSD 12-CURRENT, the sensor is seen as a generic USB de=
vice, for
instance

ugen2.7: <WatchportT Digi International> at usbus2, cfg=3D0 md=3DHOST spd=
=3DFULL (12Mbps)
pwr=3DON (80mA)

I tried to load any available USB serial port/adaptor driver available to m=
ake this
sensor attach as a ttyU? as it does in Linux (/dev/ttyUSB), but no luck so =
far. I'm not
familiar with serial consoles or the derial capabilities of FreeBSD, so i m=
ight have
overseen something essential. I'd like to access the sensor to retrieve tem=
perature data,
even if it is in a crude way. Poking around with USB, I found that the sens=
or device does
release some informations, so hopefully there is a way to make it look like=
 a tty, see my
attempts to get some informations out of the device below.

If someone has some help, hints or advice, I'd appreciate an email (please =
CC me, I do
not subscribe the QUESTION list).

Thanks in advance,

Oliver


# usbconfig -u 2 -a 7 dump_device_desc
ugen2.7: <WatchportT Digi International> at usbus2, cfg=3D0 md=3DHOST spd=
=3DFULL (12Mbps)
pwr=3DON (80mA)

  bLength =3D 0x0012=20
  bDescriptorType =3D 0x0001=20
  bcdUSB =3D 0x0110=20
  bDeviceClass =3D 0x00ff  <Vendor specific>
  bDeviceSubClass =3D 0x0000=20
  bDeviceProtocol =3D 0x00ff=20
  bMaxPacketSize0 =3D 0x0008=20
  idVendor =3D 0x1608=20
  idProduct =3D 0x0304=20
  bcdDevice =3D 0x0100=20
  iManufacturer =3D 0x0001  <Digi International>
  iProduct =3D 0x0002  <Watchport/T>
  iSerialNumber =3D 0x0003  <W82765150-0>
  bNumConfigurations =3D 0x0001=20


# usbconfig -u 2 -a 7 dump_all_config_desc
ugen2.7: <WatchportT Digi International> at usbus2, cfg=3D0 md=3DHOST spd=
=3DFULL (12Mbps)
pwr=3DON (80mA)


 Configuration index 0

    bLength =3D 0x0009=20
    bDescriptorType =3D 0x0002=20
    wTotalLength =3D 0x0027=20
    bNumInterfaces =3D 0x0001=20
    bConfigurationValue =3D 0x0001=20
    iConfiguration =3D 0x0000  <no string>
    bmAttributes =3D 0x00a0=20
    bMaxPower =3D 0x0028=20

    Interface 0
      bLength =3D 0x0009=20
      bDescriptorType =3D 0x0004=20
      bInterfaceNumber =3D 0x0000=20
      bAlternateSetting =3D 0x0000=20
      bNumEndpoints =3D 0x0003=20
      bInterfaceClass =3D 0x00ff  <Vendor specific>
      bInterfaceSubClass =3D 0x0000=20
      bInterfaceProtocol =3D 0x00ff=20
      iInterface =3D 0x0000  <no string>

     Endpoint 0
        bLength =3D 0x0007=20
        bDescriptorType =3D 0x0005=20
        bEndpointAddress =3D 0x0081  <IN>
        bmAttributes =3D 0x0002  <BULK>
        wMaxPacketSize =3D 0x0040=20
        bInterval =3D 0x0000=20
        bRefresh =3D 0x0000=20
        bSynchAddress =3D 0x0000=20

     Endpoint 1
        bLength =3D 0x0007=20
        bDescriptorType =3D 0x0005=20
        bEndpointAddress =3D 0x0001  <OUT>
        bmAttributes =3D 0x0002  <BULK>
        wMaxPacketSize =3D 0x0040=20
        bInterval =3D 0x0000=20
        bRefresh =3D 0x0000=20
        bSynchAddress =3D 0x0000=20

     Endpoint 2
        bLength =3D 0x0007=20
        bDescriptorType =3D 0x0005=20
        bEndpointAddress =3D 0x0087  <IN>
        bmAttributes =3D 0x0003  <INTERRUPT>
        wMaxPacketSize =3D 0x0008=20
        bInterval =3D 0x0001=20
        bRefresh =3D 0x0000=20
        bSynchAddress =3D 0x0000=20


--Sig_/yU=6rfK1L/9sco8CZOexKVw
Content-Type: application/pgp-signature
Content-Description: OpenPGP digital signature

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iQEcBAEBCAAGBQJXkktsAAoJEOgBcD7A/5N8z34H/j3Zg8eBnzTHXMRX4sTeqQYd
gojIaaCkejI5svgzT5UcpDBe7OVizZWNWtJCC+KkMoDKlKlfqMO85Qgd9rSVKw6c
NGksLFPH5JHtxXQjYzEQBP4AI5ZifT99WIumyARHLS3okohi8mafyuzRIstetgTp
c861/u6LjMGDXWgMl+c8E3Ds7khi2RQbl3wetPKhfAvziGlTZBIxEjre8rlgHD81
6y2mbTrkWVRpl4A1lHdHFhvb/zvXP8gJva2G/z8ao08rUFqJj1cL4t50/5ZQSaGY
LUqi4LCRClVUDlM0Ex3BmhgGjeRvTg8tjQqbWZGeSxZykpqHG8DhLP8on2U9BkM=
=D3zW
-----END PGP SIGNATURE-----

--Sig_/yU=6rfK1L/9sco8CZOexKVw--



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