Steps to get my digitizer to work in Chrome OS - linux-kernel

I have a digitizer that functions as a HID absolute pointing device. It functions properly in Ubuntu 14.04, but doesn't work in Chrome OS. However, if I boot the chromebook into developer mode, I can see the device showing up, and I can capture input from the USB device.
I would have assumed that since Chrome OS supports external USB mice that this digitizer should work. Does this mean that the kernel used in Chrome OS uses an altered modules for HID devices? (The device uses the stock usbhid driver)
I'm not really sure where to start with this... do I need to write a custom driver to support the device, or do I need to alter the firmware of the device to conform to Chrome OS's implementation of HID?

Related

MacOS HID - USB control transfer - HID API/libusb MacOS

I am trying to get reports from a PS4 like controller for which I don't have access to firmware.
I've successfully managed to communicate with the device on Windows platform, but having trouble with MacOSX (tried MacOS 10.12).
On Windows I've used HidD_SetOutputReport()/HidD_GetInputReport() functions which means that the device expects the requests as Control Transfers. Interrupt Transfers' WriteFile()/ReadFile() don't seem to be able to send data where the device expects it.
HID API uses IOHIDDeviceSetReport() for the hid_write() function which seems to behave like Windows' WriteFile(). Also tried libusb but it fails when trying to usb_claim_interface() with "another process has device opened for exclusive access". libusb_detach_kernel_driver() is only implemented for linux. I could use the codeless kext approach but the device is a HID controller it is supposed to work without a driver.
Do you know of any ways of sending a Control Transfer on MacOS?

Using Motorola Symbol barcode scanner in Simple COM Port Emulation on Mac OS X

I have a Motorola Symbol DS6708 barcode scanner. I need to scan QR codes that are in binary. So, the default HID Keyboard Emulation mode will not work for me. I want to put the device into a serial device mode. I can put it into Simple COM Port Emulation mode, and the device appears on the USB bus. However, it doesn't appear as a serial device, and there's nothing in /dev that relates to the device.
The documentation refers to a driver for COM mode for Windows, but I don't see any drivers for Mac. Any tips to get this working?
Check around and see if you can figure it who manufactures the USB->serial chip in the device. If it is Prolific, there are open source Prolific drivers available for the Mac. If the bridge is TI, then see if you can suss out the model of the chip, since there is example source for drivers (compilable) available thought the TI developer program/portal.

Mac OS X driver to work with Linux USB composite gadget driver g_multi

I'm interested in using the Linux USB composite gadget driver g_multi in an embedded Linux device, for Ethernet-over-USB and serial-over-USB (the Ethernet-over-USB is compiled for RNDIS mode; I'm not interested in the mass storage function, so I've disabled it). I've tested it, and got it working fine with both Windows and Linux. However, brief testing with Mac OS X shows that OS X doesn't automatically load the drivers for it.
I know that in principle OS X has the capability for Ethernet-over-USB, because it works automatically with the Linux USB g_ether driver (compiled for RNDIS mode). Likewise OS X works with serial-over-USB with the Linux USB g_serial driver—I can connect to the USB serial port with ZOC. But it does nothing when the Linux device is running g_multi.
I can't find any documentation that says how OS X might be made to work with a Linux device running the g_multi driver. Has anyone succeeded in doing so?
Can it be done with some sort of simple OS X driver that basically tells OS X to load its drivers for each of the component functions (a bit like the INF files I'm using for Windows, which just tell Windows to load the standard Windows driver for Ethernet- and serial-over-USB)? If so, what is the procedure for doing that?
RNDIS is unfortunately not supported by MAC OS. You need a 3rd party driver, like https://www.joshuawise.com/horndis.

How do I communicate with a GPIO USB device in OS X?

I have a USB web camera from ViMicro that contains a GPIO chip. We have a microswitch wired to one of the IO pins and can read the status of the switch on Windows using an ActiveX control that was provided by ViMicro, named exvmuvc.ax. I need to duplicate this functionality using IOKit on OS X.
USBTrace from SysNucleus displays the conversation happening between the Windows system and the USB device, but I cannot duplicate this on the Mac.
Does anyone know of a software USB sniffer, like USBTrace, that works on OS X so that I can compare the packets? Also, is anyone familiar with this particular camera chip and its GPIO subsystem, even on Linux?
You could use usbtracer from Xcode, or you can try using using USB Prober with a debug release of IOUSBFamily, this will most likely output more information than you actually want. You may want to look at qa1370 for more information.
In general though, I'd recommend you get a hardware USB analyzer, they make this sort of thing much easier.

Custom USB Driver for Windows? Mac?

I'd like to modify a USB driver to send and receive USB data over a network.
Take for example, an iMac and a PC. I have an iPod plugged in to my PC (in NY). I want my iMac (in LA) to recognize the iPod as plugged in to a local USB port and be able to communicate with the iPod.
Forget my qualifications, or lack thereof (I have background in web, iOS apps, I've toyed with Java and C).
Where can I get source code for a USB driver for Windows that I can modify? Mac OS?
Any tips or pointers towards accomplishing my goal would be appreciated as well.
It looks like folks are coming up with something close to what you want. If you do decide to roll your own, the USB driver source you asked for is libusb.
On the Mac OS X end, drivers are built up in a stack. What you want to do should be relatively simple (nothing is really simple in kernel land). You need to create a driver that can communicate over ethernet with the PC and looks like a USB device to the driver matching software. Then everything else will happen automatically.
The source code is available for Apple's USB stack. You should also read about the IOKit API and IOKit device driver guidelines and IOKit fundamentals.
Oh yes and you say you have toyed with Java and C. To write device drivers on OS X, you'll need to learn some C++.
I suggest you to go see USBIP project. This is available on Linux and Windows, but not clear for MAC. If you can get a VHCI-Controller driver installed for MAC, we can kick start USBIP for MAC.
Sounds quite like this product, a bit unsure if theirs works over wide-area networks though.
I have a general idea of how I'd go about it, but not any specifics. Basically, I'd use the platform's driver development kit to write a USB device emulator on the client machine. I'd then add a virtual device to that system called "Networked USB Host", or something similar that maintains an open port to listen for communication from the server and passes it on to your virtual USB device. IIRC, the Windows DDK comes with a USB simulation framework that might be able to help you with this.
On the server, you'd have to hook into the USB subsystem to send raw USB packets to the client machine. libpcap and wireshark have USB capturing facilities for that, but I'm not sure if this works with winpcap and the Windows version of wireshark as well.
EDIT: Look at this for cross-platform USB capture alternatives.
You can buy OSR USB learning kit: https://www.osronline.com/custom.cfm?name=index_fullframeset.cfm&pageURL=https://www.osronline.com/store/index.cfm
This is actually small USB device with known interface. Windows Driver Kit (WDK) contains sample KMDF driver for this device: http://www.microsoft.com/whdc/driver/wdk/
This is good starting point to learn Windows Drivers development, and USB drivers development specifically. However, it is still far away from your problem solution.
Can't you use some sort of Remote Desktop?

Resources