模拟摄像头和网络摄像头
It’s a pandemic outside, many of us are working from home, and I found myself buying a webcam for the first time since the last century. I was not the only one.
我是外面的大流行病,我们许多人在家中工作,而我发现自己自上世纪以来首次购买了摄像头。 我不是唯一的一个 。
The webcams out there today, they do the job. You just plug them in and get a pretty nice video feed. But they’re not exactly design icons. I thought that, maybe, we can do a little better.
今天有网络摄像头,他们可以完成工作。 您只需插入它们,即可获得非常漂亮的视频供稿。 但是它们并非完全是设计图标。 我认为,也许我们可以做得更好。
Allow me to take you back to the year 2003. The iPod is still a thing. It’s playing “Hey Ya!” by OutKast. You can get an iBook in white plastic. Life is good. Apple is also selling a webcam. They call it the iSight, and it’s a beautiful piece of design and engineering. It even comes with a travel case and multiple different stands. You can find pictures of it in all its glory on Andrew Kim’s blog.
请允许我把你带回前作 2003年。而iPod仍然是一个事。 在播放“嘿,呀!” 由OutKast撰写 。 您可以购买白色塑料的iBook。 生活很好。 苹果还销售网络摄像头。 他们称它为iSight ,这是设计和工程的绝妙部分。 它甚至配有旅行箱和多个不同的架子。 您可以在Andrew Kim的博客中找到有关它的所有图片。
Apple hasn’t sold another iSight since 2006 and the downside of 17-year-old consumer electronics is that they are 17 years old. 640x480 is not a camera resolution anymore, it’s an app icon. Remember Firewire? I don’t.
自2006年以来,苹果就没有再出售过iSight,而拥有17年历史的消费类电子产品的不利之处在于它们已有17年历史了。 640x480不再是相机分辨率,它是一个应用程序图标。 还记得火线吗? 我不。
![Image for post](https://img-blog.csdnimg.cn/img_convert/6318b8880b8bb6c61612f9e30b9f133f.png)
In the year 2020, video is 4K — or at least HD. And if you’re not using some form of USB, what are you even doing? The iSight’s industrial design is beautiful, but its electronics are from another decade. This needed to be rectified.
在2020年,视频将达到4K或至少达到高清。 而且,如果您不使用某种形式的USB,您甚至在做什么? iSight的工业设计很漂亮,但其电子产品又是十年来的。 这需要纠正。
As you may know, I have a history of stuffing electronics into beautiful household objects. I just can’t help it.
如您所知,我有将电子设备塞入漂亮的家用物品的历史 。 我就是无能为力。
To get started, I ordered an original and unopened iSight camera off eBay. The box it came in was — of course — a perfect cube. Taking it apart was fairly straightforward. You can watch other people do it, if you like.
首先,我从eBay订购了未打开的iSight原始相机。 当然,它带来的盒子是一个完美的立方体。 将其拆开是相当简单的。 如果愿意,您可以看别人做 。
Why don’t we just put a whole computer running Linux in there?
我们为什么不在那里放置一台运行Linux的整个计算机呢?
With the original guts removed, it was time to figure out what to put inside. I tried a few modern webcams, but none of them would fit. Besides, I thought, why don’t we just put a whole computer running Linux in there? The Raspberry Pi Zero fits the iSight’s dimensions almost perfectly and, incredibly, it costs only $5.
去除了胆量之后,就该弄清楚放入里面的物品了。 我尝试了一些现代的网络摄像头,但都不适合。 此外,我想,为什么我们不只是在其中放置一台运行Linux的整个计算机呢? Raspberry Pi Zero几乎完美地适合了iSight的尺寸,令人难以置信的是,它的价格仅为5美元。
![Image for post](https://img-blog.csdnimg.cn/img_convert/592d4f566a4a7684afb8852d53b36cb5.png)
Raspberry Pi recently released the High Quality Camera and I really wanted to use it for this project, but unfortunately, it’s too big for the profile of the iSight. So instead, I used the older, but smaller and cheaper, Camera Module V2. For under $30, you still get 1080p video at 30 frames per second. It just won’t have the nice depth of field of the HQ camera and its larger lenses.
Raspberry Pi最近发布了High Quality Camera ,我真的很想在此项目中使用它,但不幸的是,对于iSight的配置而言,它太大了。 因此,我改用了较旧的,但更小,更便宜的Camera Module V2 。 不到30美元,您仍然可以每秒30帧的速度获得1080p视频。 它只是没有HQ相机及其较大镜头的景深。
I decided to keep only the externally visible parts of the original iSight assembly: the perforated aluminum tube, the lens cover, and the plastic inserts at the back and bottom. I tossed out the camera module, all the other electronics, and the frame holding everything together — but not before I measured all the sizes and positions exactly, so I could later reproduce them in my custom frame.
我决定只保留iSight原始组件的外部可见部分:带Kong的铝管,镜头盖以及背面和底部的塑料插件。 我扔掉了摄像头模块,所有其他电子设备以及将所有东西固定在一起的框架,但是在我精确测量所有尺寸和位置之前没有这么做,因此以后可以在自定义框架中复制它们。
![Image for post](https://img-blog.csdnimg.cn/img_convert/6e87044ae931e8d5c5722ff1a553c280.png)
To create a 3D model of the frame, I opened the 3D design tool Fusion 360, imported models of the Raspberry Pi and camera, and sculpted an iSight-sized tube around them with all the necessary screw threads and other nooks. I sent out the result to be 3D-printed and ordered a few smaller parts like screws and cables.
为了创建框架的3D模型,我打开了3D设计工具Fusion 360 ,导入了Raspberry Pi和相机的模型,并在它们周围雕刻了一个iSight尺寸的管,并带有所有必要的螺纹和其他角。 我发出了要进行3D打印的结果,并订购了一些较小的零件,例如螺钉和电缆。
![Image for post](https://img-blog.csdnimg.cn/img_convert/7fde427c2113e7f14371eedf30fab811.png)
I splurged on a nice 3D print with the VeroClear PolyJet material, which has an impressive resolution of 16µm. That’s perfect for details like tiny screw threads, but you could probably get away with something cheaper. Then again, details matter, even for things unseen.
我用VeroClear PolyJet材料在漂亮的3D打印上进行了喷洒 ,其分辨率达到了16µm。 这对于像细小螺纹这样的细节来说是完美的,但是您可能会得到便宜的东西。 再说一次,细节很重要,即使对于看不见的东西也是如此 。
![Image for post](https://img-blog.csdnimg.cn/img_convert/022431a4334050676b5193ec7b12d787.png)
Now, all that’s left is for our Raspberry Pi to pretend to be a webcam. Luckily, that’s already a thing. Being a USB webcam essentially means implementing the UVC standard and redirecting the camera’s video feed. David Hunt’s blog post explains nicely how to do just that.
现在,剩下的就是让我们的Raspberry Pi假装成网络摄像头。 幸运的是,这已经是一回事了。 成为USB网络摄像头实质上意味着实施UVC标准并重定向摄像头的视频源。 David Hunt的博客文章很好地解释了如何做到这一点。
So there you have it. An Apple iSight, resurrected from obsolescence by stuffing a Raspberry Pi inside. I call it the “PiSight” and there’s absolutely nothing you can do about that.
所以你有它。 通过将Raspberry Pi塞入其中,使Apple iSight从过时的状态中恢复过来。 我称它为“ PiSight”,您对此绝对无能为力。
![Image for post](https://img-blog.csdnimg.cn/img_convert/7ba4d6fb24fd82e12f43f3d4aaac0da1.png)
The PiSight actually works like you’d expect it to. Just plug in the USB cable and the camera will show up in your video conferencing app of choice. The image quality is quite good, possibly better than the built-in camera of today’s MacBooks.
PiSight实际上像您期望的那样工作。 只需插入USB电缆,摄像机就会显示在您选择的视频会议应用程序中。 图像质量相当好,可能比当今MacBook的内置摄像头更好。
Just in case you’re not completely taken aback by the absurdity of this project and are now considering building your very own PiSight, rest assured that I’m making everything available as open source.
万一您对这个项目的荒谬性不完全感到吃惊,并且现在正在考虑构建自己的PiSight,请放心,我将所有内容作为开源提供。
The GitHub repo has a list of parts and where to get them, the 3D-print-ready model of the frame, and the source code. I’m thinking it should be possible to get the total cost down to under $150. I had to spend a bit more than that because I needed to experiment and opted for higher-end materials.
GitHub存储库中包含部件列表以及在何处获得部件,框架的3D打印就绪模型以及源代码。 我认为应该有可能将总成本降低到$ 150以下。 我不得不花更多的钱,因为我需要进行实验并选择高端材料。
![Image for post](https://img-blog.csdnimg.cn/img_convert/ce75317b019575c5113f38932065cb97.png)
![Image for post](https://miro.medium.com/max/9999/1*T1nFxVJxzGtobe6pYvXATQ.jpeg)
![Image for post](https://img-blog.csdnimg.cn/img_convert/24d00e280ae706a7e47511653866aae4.png)
I had to leave quite a few ideas on the table to finish the project, which does open up the possibility of a V2 someday.
我不得不在桌面上留下很多想法来完成该项目,这确实有可能使V2成为可能。
I would really like to make the Raspberry Pi HQ camera fit, possibly using a custom circuit board. It’s also one thing to make the camera look exactly like the original product from the outside, but it would be nice to make it my own and add some accents to the design. Then there’s this interesting iris mechanism in the iSight. You rotate the lens to open it up, which then automatically launches the (since discontinued) iChat app. I did keep the sensor that triggers this feature, so I just need to hook it up and do something interesting with it.
我真的很想使Raspberry Pi HQ相机合适,可能使用定制的电路板。 使相机看起来与外部原始产品完全一样是一回事,但最好将其制成我自己的产品并在设计中添加一些重点。 然后,iSight中有一个有趣的虹膜机制。 旋转镜头以将其打开,然后自动启动(自停产后) iChat应用程序。 我确实保留了触发此功能的传感器,所以我只需要挂接它并对其进行一些有趣的操作。
But all that is for another day.
但是,所有这些都是另一天。
翻译自: https://onezero.medium.com/todays-webcams-are-boring-so-i-brought-back-a-classic-291cc7c94c76
模拟摄像头和网络摄像头