Hi, the following diff adds support for an USB ANT+ receiver which is used to communicate with wireless fitness tracking devices. The USB device appears as a serial interface. I just add the device ID to the existing uscom(4) driver and enabled it in GENERIC. I don't know why it was deactivated. But, I tested the uscom(4) driver with my ANT device with OpenBSD-current on amd64, i386, macppc and sparc64.
The device attache with this message: uscom0 at uhub0 port 1 configuration 1 interface 0 "Dynastream Innovations ANT USB-m Stick" rev 2.00/1.00 addr 2 ucom0 at uscom0 portno 0 It works well on every tested architecture. I got a valid binary error message from the ANT device by the following test command: # cu -l /dev/cuaU0 | od -h ... a4 01 ae 00 0b ... Did I test enough to enable this driver by default in GENERIC? Or did I miss something else? bye, Jan Index: share/man/man4/uscom.4 =================================================================== RCS file: /cvs/src/share/man/man4/uscom.4,v retrieving revision 1.2 diff -u -p -r1.2 uscom.4 --- share/man/man4/uscom.4 25 Mar 2014 07:10:34 -0000 1.2 +++ share/man/man4/uscom.4 9 Aug 2018 18:24:50 -0000 @@ -34,6 +34,7 @@ driver: .Bd -literal -offset indent HP 39G HP 49G +Dynastream ANT USB-m Stick .Ed .Sh SEE ALSO .Xr tty 4 , Index: sys/arch/amd64/conf/GENERIC =================================================================== RCS file: /cvs/src/sys/arch/amd64/conf/GENERIC,v retrieving revision 1.457 diff -u -p -r1.457 GENERIC --- sys/arch/amd64/conf/GENERIC 3 Aug 2018 01:50:14 -0000 1.457 +++ sys/arch/amd64/conf/GENERIC 9 Aug 2018 18:22:33 -0000 @@ -230,6 +230,8 @@ umct* at uhub? # MCT USB-RS232 serial a ucom* at umct? uslcom* at uhub? # Silicon Laboratories CP210x serial ucom* at uslcom? +uscom* at uhub? # Simple USB serial adapters +ucom* at uscom? uark* at uhub? # Arkmicro ARK3116 serial ucom* at uark? moscom* at uhub? # MosChip MCS7703 serial Index: sys/arch/i386/conf/GENERIC =================================================================== RCS file: /cvs/src/sys/arch/i386/conf/GENERIC,v retrieving revision 1.833 diff -u -p -r1.833 GENERIC --- sys/arch/i386/conf/GENERIC 3 Aug 2018 01:50:14 -0000 1.833 +++ sys/arch/i386/conf/GENERIC 9 Aug 2018 18:22:33 -0000 @@ -246,6 +246,8 @@ umct* at uhub? # MCT USB-RS232 serial a ucom* at umct? uslcom* at uhub? # Silicon Laboratories CP210x serial ucom* at uslcom? +uscom* at uhub? # Simple USB serial adapters +ucom* at uscom? uark* at uhub? # Arkmicro ARK3116 serial ucom* at uark? moscom* at uhub? # MosChip MCS7703 serial Index: sys/arch/macppc/conf/GENERIC =================================================================== RCS file: /cvs/src/sys/arch/macppc/conf/GENERIC,v retrieving revision 1.264 diff -u -p -r1.264 GENERIC --- sys/arch/macppc/conf/GENERIC 14 Feb 2018 23:51:49 -0000 1.264 +++ sys/arch/macppc/conf/GENERIC 9 Aug 2018 18:22:33 -0000 @@ -223,6 +223,8 @@ umct* at uhub? # MCT USB-RS232 serial a ucom* at umct? uslcom* at uhub? # Silicon Laboratories CP210x serial ucom* at uslcom? +uscom* at uhub? # Simple USB serial adapters +ucom* at uscom? uark* at uhub? # Arkmicro ARK3116 serial ucom* at uark? moscom* at uhub? # MosChip MCS7703 serial Index: sys/arch/sparc64/conf/GENERIC =================================================================== RCS file: /cvs/src/sys/arch/sparc64/conf/GENERIC,v retrieving revision 1.307 diff -u -p -r1.307 GENERIC --- sys/arch/sparc64/conf/GENERIC 28 Aug 2017 19:32:53 -0000 1.307 +++ sys/arch/sparc64/conf/GENERIC 9 Aug 2018 18:22:33 -0000 @@ -193,6 +193,8 @@ umct* at uhub? # MCT USB-RS232 serial a ucom* at umct? uslcom* at uhub? # Silicon Laboratories CP210x serial ucom* at uslcom? +uscom* at uhub? # Simple USB serial adapters +ucom* at uscom? uark* at uhub? # Arkmicro ARK3116 serial ucom* at uark? uipaq* at uhub? # iPAQ serial adapter Index: sys/dev/usb/usbdevs =================================================================== RCS file: /cvs/src/sys/dev/usb/usbdevs,v retrieving revision 1.690 diff -u -p -r1.690 usbdevs --- sys/dev/usb/usbdevs 19 Jul 2018 17:33:26 -0000 1.690 +++ sys/dev/usb/usbdevs 9 Aug 2018 18:22:33 -0000 @@ -1638,6 +1638,7 @@ product DVICO RT3070 0xb307 RT3070 product DYNASTREAM ANTDEVBOARD 0x1003 ANT dev board product DYNASTREAM ANT2USB 0x1004 ANT2USB product DYNASTREAM ANTDEVBOARD2 0x1006 ANT dev board +product DYNASTREAM ANTUSBM 0x1009 ANTUSB-m Stick /* EasyDisk products */ product EASYDISK EASYDISK 0x0005 Flash Disk Index: sys/dev/usb/usbdevs.h =================================================================== RCS file: /cvs/src/sys/dev/usb/usbdevs.h,v retrieving revision 1.702 diff -u -p -r1.702 usbdevs.h --- sys/dev/usb/usbdevs.h 19 Jul 2018 17:33:42 -0000 1.702 +++ sys/dev/usb/usbdevs.h 9 Aug 2018 18:22:33 -0000 @@ -1,4 +1,4 @@ -/* $OpenBSD: usbdevs.h,v 1.702 2018/07/19 17:33:42 sthen Exp $ */ +/* $OpenBSD$ */ /* * THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT. @@ -1645,6 +1645,7 @@ #define USB_PRODUCT_DYNASTREAM_ANTDEVBOARD 0x1003 /* ANT dev board */ #define USB_PRODUCT_DYNASTREAM_ANT2USB 0x1004 /* ANT2USB */ #define USB_PRODUCT_DYNASTREAM_ANTDEVBOARD2 0x1006 /* ANT dev board */ +#define USB_PRODUCT_DYNASTREAM_ANTUSBM 0x1009 /* ANTUSB-m Stick */ /* EasyDisk products */ #define USB_PRODUCT_EASYDISK_EASYDISK 0x0005 /* Flash Disk */ Index: sys/dev/usb/usbdevs_data.h =================================================================== RCS file: /cvs/src/sys/dev/usb/usbdevs_data.h,v retrieving revision 1.696 diff -u -p -r1.696 usbdevs_data.h --- sys/dev/usb/usbdevs_data.h 19 Jul 2018 17:33:42 -0000 1.696 +++ sys/dev/usb/usbdevs_data.h 9 Aug 2018 18:22:33 -0000 @@ -1,4 +1,4 @@ -/* $OpenBSD: usbdevs_data.h,v 1.696 2018/07/19 17:33:42 sthen Exp $ */ +/* $OpenBSD$ */ /* * THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT. @@ -2872,6 +2872,10 @@ const struct usb_known_product usb_known { USB_VENDOR_DYNASTREAM, USB_PRODUCT_DYNASTREAM_ANTDEVBOARD2, "ANT dev board", + }, + { + USB_VENDOR_DYNASTREAM, USB_PRODUCT_DYNASTREAM_ANTUSBM, + "ANTUSB-m Stick", }, { USB_VENDOR_EASYDISK, USB_PRODUCT_EASYDISK_EASYDISK, Index: sys/dev/usb/uscom.c =================================================================== RCS file: /cvs/src/sys/dev/usb/uscom.c,v retrieving revision 1.5 diff -u -p -r1.5 uscom.c --- sys/dev/usb/uscom.c 2 Sep 2016 09:14:59 -0000 1.5 +++ sys/dev/usb/uscom.c 9 Aug 2018 18:22:33 -0000 @@ -52,7 +52,8 @@ struct ucom_methods uscom_methods = { }; static const struct usb_devno uscom_devs[] = { - { USB_VENDOR_HP, USB_PRODUCT_HP_HPX9GP } + { USB_VENDOR_HP, USB_PRODUCT_HP_HPX9GP }, + { USB_VENDOR_DYNASTREAM, USB_PRODUCT_DYNASTREAM_ANTUSBM } }; int uscom_match(struct device *, void *, void *);
signature.asc
Description: PGP signature