我做的一个软件:在 25MHz 486-SX 上运行 GPS
A software thing I built: GPS on a 25MHz 486-SX

原始链接: https://forum.vcfed.org/index.php?threads/a-software-thing-i-built-gps-on-a-25mhz-486-sx.1258966/

1993年,在消费级GPS设备普及之前,一位嵌入式系统开发人员接手了一项任务:在仅有25MHz主频的486-SX处理器上,构建一个高分辨率、实时的GPS动态地图显示系统。 由于该CPU缺乏数学协处理器,开发人员采用了“Hipparchus”库。该库利用泰森多边形(Voronoi Cells)技术,以高效的8位和16位整数运算替代了繁重的浮点三角函数运算。这种创新方法使软件能够每两秒更新一次1024x768分辨率的彩色显示,其性能表现远超多年后发布的第一代Garmin和Magellan设备。 由于客户公司破产,开发人员被迫交出了知识产权,且无法为其他感兴趣的合作方复刻该项目。当时他并不知道,通过“净室设计”可以合法地保护其底层架构。因此,这项领先现代智能手机集成GPS十余年的先驱技术,最终消失在了历史长河中。

这篇 Hacker News 的讨论围绕着一个项目展开,该项目在 25MHz 486-SX 处理器上实现了一个实时 GPS 驱动的动态地图。 讨论涵盖了几个技术主题: * **旧硬件与优化:** 参与者分享了关于早期手持式 GPS 设备(如使用 386 处理器的 Garmin eMap)的趣闻,并讨论了该项目如何利用沃罗诺伊图(Voronoi cells)和整数运算来避免繁重的浮点计算。 * **信号处理:** 讨论串解释了 GPS 信号捕获的“神奇”之处,详细说明了直接序列扩频(DSSS)和 Gold 码如何使设备能够从远低于热噪声水平的环境中提取信号。 * **地图投影:** 讨论中出现了一个关于墨卡托投影在导航中持续重要性的分支辩论,指出尽管与等面积投影相比其地缘政治准确性存在争议,但它对于地图应用而言仍具有功能上的必要性。 * **现代关联:** 用户将该项目对定点数学的巧妙应用与大模型(LLM)量化等现代技术进行了类比;另一些用户则回忆起早期移动数据的局限性,例如在有损的 9600 波特语音压缩链路上进行数据传输的艰辛。
相关文章

原文
I don't know if anybody cares about stuff like this, but I thought I'd share a quick story about a project I was hired to build back in the 90's as an embedded systems software developer. This is a project I wish I still had access to.

It's something I worked on where I was asked to build a "real-time GPS-driven moving map display" -- what we simply call a "GPS" today. Only today it's built into virtually every cellphone and tablet computer in the world.

I was asked to write this software so it ran on a hardware platform with a 25MHz 486-SX CPU, 32MB of RAM and the software would be in ROM. IIRC, the screen display was 1024x768. They gave me a laptop configured like that for testing. The 486-SX was the one without a math co-processor.

At the time, all of the math stuff I could find for GIS applications was built around heavy use of floating-point numbers and lots of trig formulas. (My BS was in Math/Computer Science.)

As it happened, a few months before that, an article was published in Dr. Dobb's Journal about a library that took a very different approach. It was called Hipparchus from a company named Geodesy. It used Voronoi Cells and reduced most math to 8- and 16-bit integer calculations with one or two single-precision floating-point calculations. It actually had higher resolution than Extended-precision floating point math!

I built a prototype with the code from that article, and was surprised how well it worked. I had the client buy a copy of the Hipparchus library and built a fully-working model. The client ran into some financial issues and I had to turn over all of the stuff to them. I have no idea what happened to it after that. They could have become a billion-dollar business.

Curiously, someone caught wind of what I had done and contacted me directly to see if I could do that for them. Unfortunately, I was just a contractor and didn't own the IP. It's worth mentioning that Phoenix Technologies took a "clean-room" approach to building their own BIOS for IBM PC clone vendors to use, and they never got sued for it. But it wasn't until 1989 that a lawsuit between Apple and Franklin computer resolved things in favor of the "clean-room" approach. Unfortunately, I wasn't aware of this stuff in 1993, or I would have known to simply start over with the specs.

Anyway, this was 5 years BEFORE anybody had ever seen a consumer-grade GPS device from Garmin or Magellan. The big problem they had was ... it took that long for an inexpensive CPU with sufficient floating-point speed to run traditional trig algorithms. And, what I had built was twice as fast as those first-gen devices! It was literally 10 years before anybody had a consumer-grade GPS that had similar performance to what I had built in 1993 that did not require a math co-processor, and it updated a 1024x768 color display every 2 seconds. Those first little consumer GPS devices had tiny 360x240 monochrome screens on them.

联系我们 contact @ memedata.com