问题
I was wondering if anyone had any experience getting RFID readers to work through WebUSB. The reader I'm using is the https://www.parallax.com/product/28340 .
From what I've read, I'd have to write a driver to read from the device. I was just wondering if anyone has done any work regarding this and what they ended up doing.
The goal here is to read RFID tags without using another application to feed it to the web application.
Thanks!
回答1:
The USB variant of that RFID reader uses an FTDI FT232R chip to provide a serial-to-USB interface. If the host operating system has a driver for this chip or the FTDI Virtual COM port drivers are installed then the browser will be unable to connect to the device when your application requests it through the WebUSB API because the USB interface presented by the device will already be claimed by the driver.
If you are able to guarantee that the Virtual COM port driver is not loaded then you will be able to write a driver using the WebUSB API to control the device.
来源:https://stackoverflow.com/questions/45151918/webusb-and-rfid-readers