When creating a peripheral for a mobile phone, an obvious path is to create a companion app with which to talk to it. But as we all know today’s app is tomorrow’s non-functional abandonware, so to give his infrared camera a long life, [Cezar Chirila] made it talk WebUSB to a browser instead.
The hardware is conventional enough, a FLIR sensor talking to an RP2040. There’s very little in the way of supporting circuitry save for a power supply regulator, as so much that might be on a standalone project is already present in the USB host device. Running the thing is as simple as going to a landing page in a browser that supports WebUSB, and using the camera. The whole lot is in a GitHub repository, if you’re interested.
We’re big fans of WebUSB, for exactly the reason it’s been used here. While there are a few browser features which have been deprecated over the years — who remembers the BLINK and MARQUEE HTML tags — it’s likely WebUSB won’t be one of them. This could only be topped by having the microcontroller share a small USB disk with the landing page as an HTML file.
Meanwhile if you’re strapped for cash, there are cheaper thermal cameras out there.

Cool use of a FLIR lepton it looks like. The carriers are so expensive! I have a busted ulefone armor 9t that I want to use the sensor out of
Says here it contains a FLIR Lepton 2.5.
Here’s the teardown guide. If you’re not trying to leave anything but the bolometer intact, it would be a pretty easy job:
https://www.youtube.com/watch?v=u97fsFiVQg0
He gets to the FLIR sensor around 8:33. There seem to be some breakout boards for it that are around $15, but some of them are indeed super-expensive… When will the prices on these dang things come down?
Cant comment on the lepton but for the tau2 I just got samples of the connector and hand balled my breakout boards with the pinout docs.
Thank you Mr. noname! Will investigate. Son had it and managed to break that weird extending USB-C port and it just died.
I wonder about putting the webpage for accessing it’s usb camera on the device itself, having it show up as a mass storage device and auto
runs the file when it’s plugged in.
I’d love that, but i noticed for other web/hardware combination i developed for myself (in this case WebNFC) you need an https connection. Don’t think that is possible when opening the file from the device as a mass storage device. WebNFC was also only in beta on a chrome browser. Don’t think it will ever grow out of beta nor to other browsers.
Apple will just block any feature that comes to the W3C that might let web browsers compete with native apps. So all these cool features will only be available in Chrome. Oh, and when you install Chrome on iOS, it’s not Chrome, it’s Safari which is intentionally limited so that it doesn’t compete with native apps where Apple can extract $$$ from app developers.
Not sure why we needed to invent serial to browser…
I for one am really reluctant to give more power and low-level access to my browser but I have to recognize that webserial is really useful to talk with peripherals and webUSB to flash them. I also enjoy webMIDI very much. provided that the specs do’nt move too much (no breaking change), that’s would be a win for software longevity.
It’s much safer to let the browser access a single serial device that you’ve explicitly selected than to install a native app that can browse and access devices and files on your system without asking.
Seriously! Mozilla’s stubborn refusal to provide support for these protocols smacks of “we don’t actually care if you get hacked, we just don’t want the responsibility”.
Forcing you to use an unrestricted native app instead of a sandboxed environment because it’s conceivably imperfect is some grade-A doublethink.
Getting flashbacks of “developer aesthetics” arguments Mozilla was using when they decided to go against WebSQL :|
Old man here. Why not make the microcontroller an HTML and FTP server so that it works with all browsers?
HTTPS required for WebUSB.
Plus your device would need to have a network connection to be an HTML server, which means you need to handle WiFi + security, you’re at risk of old WiFi stuff getting retired (WAP etc).
But mainly if it’s networked, this is all pointless – just make it offer a streaming protocol like RTSP.
Having never worked with a thermal camera before, my first thought was “Why not just make this a UVC device…?” But a single glance at the project page answered that; in hindsight, of course you’d need a lot more controls/tuning parameters than that allows for, the data feed is probably going to be distinct from plain-old video.
Looks like a rad project, well executed! Great job.
If only Apple would let the WebUSB spec move forward in W3C. They block it because it would let web browsers (mobile) be just a little bit competitive with native apps – and Apple blocks it so they can force developers to write native apps where Apple can extract 30% of all purchases through the apps.
Instead Apple blocks WebUSB, WebBluetooth and other specs without even suggesting any changes or fixes. They just block. Apple is holding back web browser progress.
Chromium or derivative, nothing else. Which is why i’m not a fan of WebUSB, aside from security concerns.