legacy-circuit-mockups

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Legacy Circuit Mockups

复古电路模型制作

A skill for creating breadboard circuit mockups and visual diagrams for retro computing and electronics projects. This skill leverages HTML5 Canvas drawing mechanisms to render interactive circuit layouts featuring vintage components like the 6502 microprocessor, 555 timer ICs, EEPROMs, and 7400-series logic gates.
这是一项为复古计算和电子项目创建面包板电路模型和可视化图表的技能。该技能利用HTML5 Canvas绘图机制渲染交互式电路布局,包含6502微处理器、555定时器IC、EEPROM和7400系列逻辑门等老式元件。

When to Use This Skill

何时使用此技能

  • User asks to "create a breadboard layout" or "mockup a circuit"
  • User wants to visualize component placement on a breadboard
  • User needs a visual reference for building a 6502 computer
  • User asks to "draw a circuit" or "diagram electronics"
  • User wants to create educational electronics visuals
  • User mentions Ben Eater tutorials or retro computing projects
  • User asks to mockup 555 timer circuits or LED projects
  • User needs to visualize wire connections between components
  • 用户要求“创建面包板布局”或“制作电路模型”
  • 用户希望可视化面包板上的元件放置
  • 用户需要构建6502计算机的视觉参考
  • 用户要求“绘制电路”或“制作电子图表”
  • 用户想要创建电子教学可视化内容
  • 用户提到Ben Eater教程或复古计算项目
  • 用户要求制作555定时器电路或LED项目模型
  • 用户需要可视化元件之间的导线连接

Prerequisites

前提条件

  • Understanding of component pinouts from bundled reference files
  • Knowledge of breadboard layout conventions (rows, columns, power rails)
  • 了解捆绑参考文件中的元件引脚分布
  • 熟悉面包板布局规范(行、列、电源轨)

Supported Components

支持的元件

Microprocessors & Memory

微处理器与存储器

ComponentPinsDescription
W65C02S40-pin DIP8-bit microprocessor with 16-bit address bus
28C25628-pin DIP32KB parallel EEPROM
W65C2240-pin DIPVersatile Interface Adapter (VIA)
6225628-pin DIP32KB static RAM
元件引脚数描述
W65C02S40引脚DIP带16位地址总线的8位微处理器
28C25628引脚DIP32KB并行EEPROM
W65C2240引脚DIP多功能接口适配器(VIA)
6225628引脚DIP32KB静态RAM

Logic & Timer ICs

逻辑与定时器IC

ComponentPinsDescription
NE5558-pin DIPTimer IC for timing and oscillation
740014-pin DIPQuad 2-input NAND gate
740214-pin DIPQuad 2-input NOR gate
740414-pin DIPHex inverter (NOT gate)
740814-pin DIPQuad 2-input AND gate
743214-pin DIPQuad 2-input OR gate
元件引脚数描述
NE5558引脚DIP用于定时和振荡的定时器IC
740014引脚DIP四2输入与非门
740214引脚DIP四2输入或非门
740414引脚DIP六反相器(非门)
740814引脚DIP四2输入与门
743214引脚DIP四2输入或门

Passive & Active Components

无源与有源元件

ComponentDescription
LEDLight emitting diode (various colors)
ResistorCurrent limiting (configurable values)
CapacitorFiltering and timing (ceramic/electrolytic)
CrystalClock oscillator
SwitchToggle switch (latching)
ButtonMomentary push button
PotentiometerVariable resistor
PhotoresistorLight-dependent resistor
元件描述
LED发光二极管(多种颜色)
电阻器限流(可配置阻值)
电容器滤波和定时(陶瓷/电解)
晶体时钟振荡器
开关拨动开关(锁存型)
按钮瞬时按键
电位器可变电阻器
光敏电阻光敏型电阻器

Grid System

网格系统

javascript
// Standard breadboard grid: 20px spacing
const gridSize = 20;
const cellX = Math.floor(x / gridSize) * gridSize;
const cellY = Math.floor(y / gridSize) * gridSize;
javascript
// Standard breadboard grid: 20px spacing
const gridSize = 20;
const cellX = Math.floor(x / gridSize) * gridSize;
const cellY = Math.floor(y / gridSize) * gridSize;

Component Rendering Pattern

元件渲染模式

javascript
// All components follow this structure:
{
  type: 'component-type',
  x: gridX,
  y: gridY,
  width: componentWidth,
  height: componentHeight,
  rotation: 0,  // 0, 90, 180, 270
  properties: { /* component-specific data */ }
}
javascript
// All components follow this structure:
{
  type: 'component-type',
  x: gridX,
  y: gridY,
  width: componentWidth,
  height: componentHeight,
  rotation: 0,  // 0, 90, 180, 270
  properties: { /* component-specific data */ }
}

Wire Connections

导线连接

javascript
// Wire connection format:
{
  start: { x: startX, y: startY },
  end: { x: endX, y: endY },
  color: '#ff0000'  // Wire color coding
}
javascript
// Wire connection format:
{
  start: { x: startX, y: startY },
  end: { x: endX, y: endY },
  color: '#ff0000'  // Wire color coding
}

Step-by-Step Workflows

分步工作流程

Creating a Basic LED Circuit Mockup

创建基础LED电路模型

  1. Define breadboard dimensions and grid
  2. Place power rail connections (+5V and GND)
  3. Add LED component with anode/cathode orientation
  4. Place current-limiting resistor
  5. Draw wire connections between components
  6. Add labels and annotations
  1. 定义面包板尺寸和网格
  2. 放置电源轨连接(+5V和GND)
  3. 添加带正负极方向的LED元件
  4. 放置限流电阻器
  5. 绘制元件之间的导线连接
  6. 添加标签和注释

Creating a 555 Timer Circuit

创建555定时器电路

  1. Place NE555 IC on breadboard (pins 1-4 left, 5-8 right)
  2. Connect pin 1 (GND) to ground rail
  3. Connect pin 8 (Vcc) to power rail
  4. Add timing resistors and capacitors
  5. Wire trigger and threshold connections
  6. Connect output to LED or other load
  1. 将NE555 IC放置在面包板中央通道两侧
  2. 将引脚1(GND)连接到地轨
  3. 将引脚8(Vcc)连接到电源轨
  4. 添加定时电阻器和电容器
  5. 连接触发和阈值引脚
  6. 将输出连接到LED或其他负载

Creating a 6502 Microprocessor Layout

创建6502微处理器布局

  1. Place W65C02S centered on breadboard
  2. Add 28C256 EEPROM for program storage
  3. Place W65C22 VIA for I/O
  4. Add 7400-series logic for address decoding
  5. Wire address bus (A0-A15)
  6. Wire data bus (D0-D7)
  7. Connect control signals (R/W, PHI2, RESB)
  8. Add reset button and clock crystal
  1. 将W65C02S放置在面包板中央
  2. 添加28C256 EEPROM用于程序存储
  3. 放置W65C22 VIA用于I/O
  4. 添加7400系列逻辑门进行地址解码
  5. 连接地址总线(A0-A15)
  6. 连接数据总线(D0-D7)
  7. 连接控制信号(R/W, PHI2, RESB)
  8. 添加复位按钮和时钟晶体

Component Pinout Quick Reference

元件引脚快速参考

555 Timer (8-pin DIP)

555定时器(8引脚DIP)

PinNameFunction
1GNDGround (0V)
2TRIGTrigger (< 1/3 Vcc starts timing)
3OUTOutput (source/sink 200mA)
4RESETActive-low reset
5CTRLControl voltage (bypass with 10nF)
6THRThreshold (> 2/3 Vcc resets)
7DISDischarge (open collector)
8VccSupply (+4.5V to +16V)
引脚名称功能
1GND接地(0V)
2TRIG触发(< 1/3 Vcc时启动定时)
3OUT输出(可源/ sink 200mA电流)
4RESET低电平有效复位
5CTRL控制电压(用10nF电容旁路)
6THR阈值(> 2/3 Vcc时复位)
7DIS放电(集电极开路)
8Vcc电源(+4.5V至+16V)

W65C02S (40-pin DIP) - Key Pins

W65C02S(40引脚DIP)- 关键引脚

PinNameFunction
8VDDPower supply
21VSSGround
37PHI2System clock input
40RESBActive-low reset
34RWBRead/Write signal
9-25A0-A15Address bus
26-33D0-D7Data bus
引脚名称功能
8VDD电源
21VSS接地
37PHI2系统时钟输入
40RESB低电平有效复位
34RWB读/写信号
9-25A0-A15地址总线
26-33D0-D7数据总线

28C256 EEPROM (28-pin DIP) - Key Pins

28C256 EEPROM(28引脚DIP)- 关键引脚

PinNameFunction
14GNDGround
28VCCPower supply
20CEChip enable (active-low)
22OEOutput enable (active-low)
27WEWrite enable (active-low)
1-10, 21-26A0-A14Address inputs
11-19I/O0-I/O7Data bus
引脚名称功能
14GND接地
28VCC电源
20CE芯片使能(低电平有效)
22OE输出使能(低电平有效)
27WE写使能(低电平有效)
1-10, 21-26A0-A14地址输入
11-19I/O0-I/O7数据总线

Formulas Reference

公式参考

Resistor Calculations

电阻器计算

  • Ohm's Law: V = I × R
  • LED Current: R = (Vcc - Vled) / Iled
  • Power: P = V × I = I² × R
  • 欧姆定律: V = I × R
  • LED电流: R = (Vcc - Vled) / Iled
  • 功率: P = V × I = I² × R

555 Timer Formulas

555定时器公式

Astable Mode:
  • Frequency: f = 1.44 / ((R1 + 2×R2) × C)
  • High time: t₁ = 0.693 × (R1 + R2) × C
  • Low time: t₂ = 0.693 × R2 × C
  • Duty cycle: D = (R1 + R2) / (R1 + 2×R2) × 100%
Monostable Mode:
  • Pulse width: T = 1.1 × R × C
多谐振荡模式:
  • 频率: f = 1.44 / ((R1 + 2×R2) × C)
  • 高电平时间: t₁ = 0.693 × (R1 + R2) × C
  • 低电平时间: t₂ = 0.693 × R2 × C
  • 占空比: D = (R1 + R2) / (R1 + 2×R2) × 100%
单稳态模式:
  • 脉冲宽度: T = 1.1 × R × C

Capacitor Calculations

电容器计算

  • Capacitive reactance: Xc = 1 / (2πfC)
  • Energy stored: E = ½ × C × V²
  • 容抗: Xc = 1 / (2πfC)
  • 存储能量: E = ½ × C × V²

Color Coding Conventions

颜色编码规范

Wire Colors

导线颜色

ColorPurpose
Red+5V / Power
BlackGround
YellowClock / Timing
BlueAddress bus
GreenData bus
OrangeControl signals
WhiteGeneral purpose
颜色用途
红色+5V / 电源
黑色接地
黄色时钟 / 定时
蓝色地址总线
绿色数据总线
橙色控制信号
白色通用

LED Colors

LED颜色

ColorForward Voltage
Red1.8V - 2.2V
Green2.0V - 2.2V
Yellow2.0V - 2.2V
Blue3.0V - 3.5V
White3.0V - 3.5V
颜色正向电压
红色1.8V - 2.2V
绿色2.0V - 2.2V
黄色2.0V - 2.2V
蓝色3.0V - 3.5V
白色3.0V - 3.5V

Build Examples

构建示例

Build 1 — Single LED

示例1 — 单LED电路

Components: Red LED, 220Ω resistor, jumper wires, power source
Steps:
  1. Insert black jumper wire from power GND to row A5
  2. Insert red jumper wire from power +5V to row J5
  3. Place LED with cathode (short leg) in row aligned with GND
  4. Place 220Ω resistor between power and LED anode
元件: 红色LED、220Ω电阻器、跳线、电源
步骤:
  1. 将黑色跳线从电源GND连接到A5行
  2. 将红色跳线从电源+5V连接到J5行
  3. 将LED阴极(短脚)插入与GND对齐的行
  4. 在电源和LED阳极之间放置220Ω电阻器

Build 2 — 555 Astable Blinker

示例2 — 555多谐振荡器

Components: NE555, LED, resistors (10kΩ, 100kΩ), capacitor (10µF)
Steps:
  1. Place 555 IC straddling center channel
  2. Connect pin 1 to GND, pin 8 to +5V
  3. Connect pin 4 to pin 8 (disable reset)
  4. Wire 10kΩ between pin 7 and +5V
  5. Wire 100kΩ between pins 6 and 7
  6. Wire 10µF between pin 6 and GND
  7. Connect pin 3 (output) to LED circuit
元件: NE555、LED、电阻器(10kΩ、100kΩ)、电容器(10µF)
步骤:
  1. 将555 IC跨放在中央通道上
  2. 将引脚1连接到GND,引脚8连接到+5V
  3. 将引脚4连接到引脚8(禁用复位)
  4. 在引脚7和+5V之间连接10kΩ电阻器
  5. 在引脚6和7之间连接100kΩ电阻器
  6. 在引脚6和GND之间连接10µF电容器
  7. 将引脚3(输出)连接到LED电路

Troubleshooting

故障排除

IssueSolution
LED doesn't lightCheck polarity (anode to +, cathode to -)
Circuit doesn't powerVerify power rail connections
IC not workingCheck VCC and GND pin connections
555 not oscillatingVerify threshold/trigger capacitor wiring
Microprocessor stuckCheck RESB is HIGH after reset pulse
问题解决方案
LED不亮检查极性(阳极接+,阴极接-)
电路无供电验证电源轨连接
IC不工作检查VCC和GND引脚连接
555不振荡验证阈值/触发电容器接线
微处理器死机检查RESB在复位脉冲后是否为高电平

References

参考资料

Detailed component specifications are available in the bundled reference files:
  • 555.md - Complete 555 timer IC specification
  • 6502.md - MOS 6502 microprocessor details
  • 6522.md - W65C22 VIA interface adapter
  • 28256-eeprom.md - AT28C256 EEPROM specification
  • 6C62256.md - 62256 SRAM details
  • 7400-series.md - TTL logic gate pinouts
  • assembly-compiler.md - Assembly compiler specification
  • assembly-language.md - Assembly language specification
  • basic-electronic-components.md - Resistors, capacitors, switches
  • breadboard.md - Breadboard specifications
  • common-breadboard-components.md - Comprehensive component reference
  • connecting-electronic-components.md - Step-by-step build guides
  • emulator-28256-eeprom.md - Emulating 28256-eeprom specification
  • emulator-6502.md - Emulating 6502 specification
  • emulator-6522.md - Emulating 6522 specification
  • emulator-6C62256.md - Emulating 6C62256 specification
  • emulator-lcd.md - Emulating a LCD specification
  • lcd.md - LCD display interfacing
  • minipro.md - EEPROM programmer usage
  • t48eeprom-programmer.md - T48 programmer reference
详细的元件规格可在捆绑的参考文件中找到:
  • 555.md - 完整555定时器IC规格
  • 6502.md - MOS 6502微处理器详情
  • 6522.md - W65C22 VIA接口适配器
  • 28256-eeprom.md - AT28C256 EEPROM规格
  • 6C62256.md - 62256 SRAM详情
  • 7400-series.md - TTL逻辑门引脚分布
  • assembly-compiler.md - 汇编编译器规格
  • assembly-language.md - 汇编语言规格
  • basic-electronic-components.md - 电阻器、电容器、开关
  • breadboard.md - 面包板规格
  • common-breadboard-components.md - 综合元件参考
  • connecting-electronic-components.md - 分步构建指南
  • emulator-28256-eeprom.md - 28256 EEPROM仿真规格
  • emulator-6502.md - 6502仿真规格
  • emulator-6522.md - 6522仿真规格
  • emulator-6C62256.md - 6C62256仿真规格
  • emulator-lcd.md - LCD仿真规格
  • lcd.md - LCD显示接口
  • minipro.md - EEPROM编程器使用方法
  • t48eeprom-programmer.md - T48编程器参考