4 ms·
One thing that I think is really cool about Chrome Apps is that you can write USB drivers in Javascript that will run on any platform that runs Chrome or Chromi
by jrockway 13y ago
One thing that I think is really cool about Chrome Apps is that you can write USB drivers in Javascript that will run on any platform that runs Chrome or Chromium. This means that if you want to make a hardware device that syncs with the cloud, all you have to do is write what is essentially a web app, and anyone with Windows, OS X, Linux, or Chrome OS can use your thing.
I'm personally working on a Chrome SDR app for the Funcube Dongle, so you can just install an app from the Web Store, plug the thing in, and start listening to any radio transmission from .5MHz to 2GHz. (The only snag is that the HTML5 audio API doesn't give you 192kHz sound samples, so I think I'm going to have to read them directly via USB. Fun.)
- hosay123 13y agoFirefox OS is working on the same feature (google 'WebUSB')
- nraynaud 13y agoyeah, same here, I'm writing a CNC controller, the UI is a google chrome packaged app talking on USB. it's a pain to use, with all the restriction, the buggy API (it doesn't crash, it just hangs, you can't investigate) and the browser bugs (I have to use a canary for development, I'm really far from a release).
- kevingadd 13y agoThe documentation says chrome.usb only works on Chrome OS, are you sure it works in the actual browser? Last time I looked into this stuff it's nontrivial to let arbitrary user-mode applications manipulate arbitrary USB devices on Windows, so I'd be impressed if they got it working in a secure fashion and deployed it to the open web.
- jrockway 13y agoI only have linux machines, but yes, I'm sure it works on Linux.
- nraynaud 13y agoChrome packaged apps give the same api in the browser as in chrome OS. The whole trick of packaged apps, is to get the same API on all OS. And along the way, google gets apps for chrome OS. I guess it's some kind of chicken and egg problem, to use the OS you need apps, but developers only develop if there are users. By having apps working on various OS the entice developers to create stuff that will also work in Chrome OS.
- nabeards 13y agoThey do work in the browser, but also do have some issues in Windows (especially XP). I provided bug information and offered any assistance possible, but got nowhere. We ended up rolling with a Qt WebView wrapper and I rewrote the USB calls. Haven't had any issues since.
- Gormo 13y ago> if you want to make a hardware device that syncs with the cloud ...you can equip that device with one of the many standard, open protocols already in ubiquitous use. Browser-based hardware drivers in JavaScript? Seriously?
- jrockway 13y agoPlease give me an example of one of these. I'm thinking about things like Garmin Connect or Fitbit here.
- Gormo 13y agoAn example of one of what, open-standard data exchange protocols? There are many options at each of the OSI layers. Why implement low-level hardware handshaking via JavaScript in the browser, if all you want to do is sync application data?