Show HN: I replaced a $120k bowling center system with $1,600 in ESP32s

Show HN: I replaced a $120k bowling center system with $1,600 in ESP32s

I might be the only SRE on Earth with his own bowling center. It’s a more in-depth gig than you’d think. My family and I bought an abandoned 8-lane bowling center in the rural mid-west. In our small town there weren’t many recreation options for families. You’ve heard of a food desert? This is an R&R desert.

我可能是地球上唯一一个拥有自己保龄球馆的站点可靠性工程师(SRE)。这份工作比你想象的要深入得多。我和家人买下了一家位于美国中西部农村、已经废弃的 8 球道保龄球馆。在我们这个小镇,家庭娱乐的选择并不多。你听说过“食物沙漠”吗?这里就是一片“休闲娱乐沙漠”。

It had been abandoned for a good reason. The roof leaks, the electrical system was constantly surging, and my 70-year-old bowling equipment (still) doesn’t work perfectly. The system that keeps your score is particularly interesting to me. It’s the thing you watch during your game, but it fades into the background beyond that. Turns out these things are really cool, but absurdly expensive.

它被废弃是有原因的。屋顶漏水,电力系统经常出现浪涌,而且我那 70 年历史的保龄球设备(至今)仍无法完美运行。计分系统尤其让我感兴趣。它是你在比赛时盯着看的东西,但除此之外,它往往会被人忽略。事实证明,这些东西非常酷,但价格也贵得离谱。

Ours was installed in 2008 and cost six figures. It’s calculating ball speed and trajectory, camera-based pin detection (object detection and trig, on ICs!), runs the fouling, the animations, the pinsetting machine and ball return. Very cool stuff for its age.

我们的系统安装于 2008 年,花费了六位数。它能计算球速和轨迹,通过摄像头进行球瓶检测(在集成电路上实现目标检测和三角函数运算!),并控制犯规判定、动画显示、球瓶重置机和回球系统。以它那个年代的技术来说,非常酷。

From the business perspective, my facility only cost me $105k. To forklift-replace the score keeping system runs anywhere between $80-$120k, depending on features, vendor, and unit age. No upgrades or service contracts, mind you, and every feature and customization is a new line item. That’s for a 1:1 replacement on a system installed in 2008. Incredible, given how fast the tech world moves.

从商业角度来看,我的整个设施才花了 10.5 万美元。而要彻底更换计分系统,费用在 8 万到 12 万美元之间,具体取决于功能、供应商和设备年限。请注意,这还不包括升级或服务合同,而且每一项功能和定制都需要额外付费。这仅仅是针对 2008 年安装的系统进行 1:1 的更换。考虑到科技界的发展速度,这简直不可思议。

Replacement parts cost a shocking $4000 per pair of lanes. But wait, the bowling machines themselves are 70 years old, so what’s this “advanced” system actually doing back there? Actuating a single relay to trigger that big old machine. Everything else is strictly mechanical. Meanwhile I’ve got a six-figure invoice in my hand. I’m upset.

更换零件的费用竟然高达每对球道 4000 美元。但等等,保龄球机本身已经 70 岁了,那么这个所谓的“先进”系统在后台到底在做什么呢?仅仅是驱动一个继电器来触发那台老旧的大机器。其他一切都是纯机械的。与此同时,我手里却拿着一张六位数的账单。我很不爽。

Given the state of open hardware, computer vision, real-time event streaming, and open source running megascale products worldwide, there had to be a way to do this myself.

考虑到目前开源硬件、计算机视觉、实时事件流以及支撑全球超大规模产品的开源技术的发展现状,我一定能找到一种方法自己搞定。

So far I’ve built an equivalent prototype for about $200 per lane-pair, $400 if you’re fancy. ESP32 and ESPNow with an RS485 fallback, reporting to a raspberry pi lane computer that’s really just redis and a state machine bolted to an ESP32 gateway for the mesh.

到目前为止,我已经构建了一个等效原型,每对球道成本约为 200 美元,如果追求高级一点则为 400 美元。它使用 ESP32 和 ESPNow,并带有 RS485 备用方案,向一台树莓派球道计算机报告数据。这台计算机本质上只是运行 Redis 和状态机,并通过 ESP32 网关连接到网状网络。

Since it’s all ESP32, I’ve got a fistful of spare controllers in a drawer, pre-flashed or waiting to be. All common off-the-shelf hardware: microcontrollers wired to relays, optocouplers, and IR-break-beam sensors, each running slightly different firmware. Writing the firmware and protocol is the actual hard part.

因为全部基于 ESP32,我的抽屉里有一大把备用控制器,有的已经烧录好固件,有的正等待烧录。所有硬件都是常见的现成产品:微控制器连接到继电器、光耦和红外对射传感器,每个控制器运行略有不同的固件。编写固件和协议才是真正的难点。

It’s an ESPNow star-topology mesh: each node emits events from its sensors and accepts commands for its controls, reporting to a gateway node connected to the raspi over UART. From there it’s event streaming: RX packets get translated and tossed into redis, commands relay back out to the mesh as needed. RS485 sits underneath as a wired fallback for noisy RF environments.

这是一个 ESPNow 星型拓扑网状网络:每个节点从传感器发出事件并接收控制指令,然后报告给通过 UART 连接到树莓派的网关节点。从那里开始是事件流处理:接收到的数据包被转换并存入 Redis,指令根据需要转发回网状网络。RS485 作为有线备用方案,用于应对射频干扰严重的环境。

Once the data’s in redis, it’s familiar middleware/React/websocket/pub-sub stuff. Any React dev can build their own UI and bowling animations. Since it all runs on commodity hardware, I can do legit anything I want as the proprietor, and I own all my data. Repairs take five minutes; I can swap the rig on a lane pair in under 10. I’d bet a house like mine could go from zero to running in an hour or two.

一旦数据进入 Redis,剩下的就是熟悉的中间件/React/WebSocket/发布-订阅模式了。任何 React 开发人员都可以构建自己的 UI 和保龄球动画。由于一切都在通用硬件上运行,作为业主,我可以随心所欲地进行任何操作,并且我拥有所有数据。维修只需五分钟;我可以在 10 分钟内更换一对球道的设备。我敢打赌,像我这样的球馆,一两个小时内就能从零开始运行起来。

We’re calling it OpenLaneLink, and I plan to open source the hardware, firmware, and software stack when it’s ready. Bowling is fun, and I want to help keep it affordable for alleys like mine. I hate vendor lock-in. I’m not a fan of closed systems, calling support for every hiccup, or paying to “white label” my own equipment. Want to go Tron-themed for a night? Good luck finding a neon neumorphic theme in something bought at the turn of the century.

我们将它命名为 OpenLaneLink,并计划在准备就绪后开源硬件、固件和软件栈。保龄球很有趣,我想帮助像我这样的球馆保持低成本运营。我讨厌供应商锁定。我不喜欢封闭系统,不喜欢每次出点小问题都要打客服电话,也不喜欢为自己的设备贴牌付费。想在晚上搞个《创:战纪》(Tron)主题?在世纪之交买的设备里找霓虹拟态主题,祝你好运吧。

All that bugged me. Sure, bowling equipment is niche, but the open hardware and software landscape is amazing. Thanks for reading! Let me know if anyone’s interested in more posts about this bowling nonsense.

所有这些都让我感到困扰。当然,保龄球设备属于小众领域,但开源硬件和软件的前景非常广阔。感谢阅读!如果有人对更多关于这些保龄球琐事的文章感兴趣,请告诉我。