docs: what a mechanical dp can actually mean when the memory is electronic

The question that exposes the gap in the previous note: if the ring lives in a
6116, what is a mechanical pointer pointing at?  The honest answer is that dp is
an address, so there are three coherent designs and they are different machines.

A. a mechanical address register.  The physical position of a 64 position device
(uniselector, or stepper plus ratchet) feeds A0..A5 of the SRAM through its
contact bank.  The position is genuinely part of the machine state and the panel
pointer does not lie, but it only selects which byte is addressed -- it is not
the byte.  Cheap (50-200 CNY) and two days of work, so it stays N1.

B. a drum.  Eight tracks by 64 cells rotating under fixed read and write heads:
then the memory itself is mechanical, dp becomes the phase of the rotation, >
waits for the next cell pulse, < waits almost a full turn, and + or - does a
read-modify-write between two heads one cell apart.  Expensive and months of
machining, but it is the 1950s machine.

C. a magnetostrictive delay line.  512 bits of sound circulating in a loop of
nickel wire with a transducer at each end: the ring is literally a loop, there
are no bearings and no heads to wear, > is free (wait for the next time slot), <
costs at most one revolution (0.5 ms at 1 Mbit/s).  An order of magnitude cheaper
than the drum and still electrically genuine, but it needs winding, biasing and
scope time.

Recommendation stays: A first because it is cheap and it is honest about being an
address register, then C if the wish is for the memory itself to be mechanical,
with B kept for when there must be a spinning drum.  The section now says all of
this, and the summary table no longer claims dp can simply "be mechanical".
This commit is contained in:
dsh committed 2026-11-20 16:43:57 +08:00
1 parent 1e7acc018e
commit a5dfd70499
1 file changed
+37 -11
+37 -11
View File
@@ -9,8 +9,8 @@
| 部分 | 能机械吗 | 为什么 |
|---|---|---|
| **程序纸带**(51 378 条) | ✗ | 2.54 mm 孔距下 130 m;0.2 mm 光学带也要 10 m,而且读头精度不现实。**必须电子**(27C512 EPROM) |
| 数据环(64 格 × 8 bit) | 勉强 | 512 个继电器/磁芯 ✗ 不可能手做;**留电子**(6116) |
| **`dp` 指针** | ✓✓ | 64 个位置、走一步退一步 —— 电话交换机的**步进器(uniselector)** 就是为这个生的 |
| 数据环(64 格 × 8 bit) | 勉强 | 512 个继电器/磁芯 ✗ 手做不出来。默认用 6116(电子);真要机械就整条换成转鼓或磁致伸缩延迟线(§2.1 的 B / C)—— 那时"记忆"本身才是机械的 |
| **`dp` 指针** | ✓✓ 但要看怎么定义 | 记忆是电子时,机械件只能当**地址寄存器**(位置触点直接当 `A0..A5`),不是"那格的值";要让记忆也是机械的,就得走 B(转鼓)或 C(延迟线)—— 见 §2.1 |
| **步数** | ✓ | 电磁计数器,每步"咔"一声 |
| **输入 / 输出** | ✓✓ | 纸带/卡片读入、纸带打孔/绘图仪输出、真键盘 |
| **时钟** | ✓ | 手摇曲柄、凸轮节拍器 |
@@ -20,20 +20,46 @@
## 2. 机械件的清单(按"每块钱换来的手感"排序)
### 2.1 `dp` = 64 位棘轮步进器 ★★★
### 2.1 `dp` 怎么做成机械 ★★★
这是最值钱的一项:`>`/`<` 占全部步数的 **71~73%**(`tape_run --profile` 实测),也就是说这
台机器**大部分时间在移动指针**。把它做成机械的,机器就真的在"咔哒咔哒"地走格子。
| 方案 | 件 | 价格 | 说明 |
|---|---|---|---|
| **电话步进器(uniselector)** | 二手拆机 | ¥50~200 | 64 个位置、棘轮 + 电磁驱动、自带**归位触点**(home)✓;步进器按脉冲前进,反向用一个"倒转"线圈或第二组电刷 |
| **步进电机 + 棘轮/日内瓦机构** | 28BYJ-48 + 3D 打印件 | ¥30 | 便宜、好控制(ULN2003 四相),反向容易;位置用**光电码盘**读回 |
| **旋转电磁铁 + 棘爪** | 旋转电磁铁 | ¥40 | 单步式,最像原件,但反向要另设计 |
| **机械计数轮 + 光电索引** | 旧电表/里程表 | ¥20 | 只能显示,不能驱动 ✗ 当"读数窗"用 |
**先回答一个问题:数据环是电子的(6116),那 `dp` 机械起来是什么意思?**
`dp` 是**地址**。所以"机械 dp"只有三种自洽的读法,选错一种就变成装饰:
| 做法 | `dp` 是什么 | 数据在哪 | 钱/难度 | 诚实评价 |
|---|---|---|---|---|
| **A. 机械地址寄存器**(点唱机式) | 一个 64 位的**物理位置**,位置触点/码盘直接当 6116 的 `A0..A5` | 6116 | ¥50~200,两天 | ✓ 真的:机器状态里那个位置就是机械件;但它只是"选哪一格",**不是那格的值** |
| **B. 转鼓**(1950 年代式) | 鼓的**相位**(等第几个格脉冲) | 鼓上的磁道 | ¥1000+,几个月 | ✓ 真记忆也是机械的,`dp` 变成"时间";`<` 要等近一圈,`+` 要双头读改写 |
| **C. 磁致伸缩延迟线**(水银延迟线的钢线版) | 声波何时回到换能器(**时间**) | 镍线里的声波 | ¥200~500,要调模拟 | ✓ 环"字面意义"上是个环;**没有运动件**,但记忆是机械波 |
三种都成立,但它们是**不同的机器**:
* **A** 里机械件是"地址寄存器"(早年的步进器/旋转开关就这么当寄存器用),数据的读写仍然是
TTL + SRAM。它的好处是简单、可靠,而且面板上的指针**不说谎**:指针在哪,机器就在读哪一格。
它的局限正是你指出的:**指针机械、存储电子** —— 看着像"机械存储器",其实不是。
* **B** 才让"数据环"本身变成机械结构:盘/鼓转,读头写头固定,`>` 就是等下一个格脉冲
(77 µs@3000rpm、64 格/圈),`<` 要等 63 格,`+`/`-` 用**相隔一格的读头和写头**做读改写。
这时 `dp` 仍然是一个**计数相位的计数器**(数脉冲),只不过它数的东西是机械转出来的 ——
这才是"dp 是机械的"最严格的形态。
* **C** 是最省件的一条:一条镍线绕成环,两端各一个换能器,512 bit 串行在里头跑。
一圈 0.5 ms 的话,`>` 免费(等到下一个时隙),`<` 最多 0.5 ms,`+`/`-` 读改写也只要一次
绕环。**没有轴承、没有磁头、没有磨损**,只有一根在振动的线 —— 环在物理上就是个环。
代价是要自己绕线、做偏置磁铁、调放大和整形(有 DIY 先例,但要示波器)。
**建议**:先做 **A**(当"机械地址寄存器",和电子记忆并存,两天能转起来),把它当 N1;
如果手感不够、想要"记忆本身也是机械的",再上 **C**(比 B 便宜一个数量级,而且是真正的
"环"),B 留给"必须有个转动的鼓"的场合。
| A 用到的件 | 价格 | 说明 |
|---|---|---|
| **电话步进器(uniselector)** | ¥50~200 二手 | 64 位、棘轮 + 电磁驱动、**自带归位触点**;反向靠第二组电刷或倒转线圈 |
| **28BYJ-48 步进电机 + 棘轮/日内瓦机构** | ¥30 + 3D 打印件 | 好驱动(ULN2003),反向容易,位置用光电码盘读回 |
| **旋转电磁铁 + 棘爪** | ¥40 | 单步式最像原件,反向要另设计 |
| 位置读回 | ¥10 | 步进器用 64 位格雷码触点组,或光电码盘 + 74LS244 缓冲 → 6116 的 `A0..A5` |
位置读回:步进器用**触点组**(64 位格雷码盘,6 位),或光电码盘 + 比较器;读回值就是
`dp` 的 6 位地址,送进 6116 ✓。**home 触点**顺便做复位 ✓。
### 2.2 步数 = 电磁计数器 ★★