Files

296 lines
17 KiB
HTML
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>PCM1808+PCM5102 I2S HAT — PCB Preview</title>
<style>
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
background: #0d0d0d;
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
display: flex;
flex-direction: column;
align-items: center;
padding: 40px 20px;
color: #e0e0e0;
}
h1 { font-size: 1.4rem; margin-bottom: 8px; }
.subtitle { color: #999; font-size: 0.85rem; margin-bottom: 30px; }
.container {
display: flex;
flex-wrap: wrap;
gap: 40px;
justify-content: center;
max-width: 1100px;
}
.board-card {
background: #1a1a1a;
border: 1px solid #333;
border-radius: 12px;
padding: 24px;
}
.board-card h2 {
font-size: 0.85rem;
color: #999;
text-transform: uppercase;
letter-spacing: 0.5px;
margin-bottom: 16px;
}
svg text { font-family: 'Courier New', monospace; }
.specs {
background: #1a1a1a;
border: 1px solid #333;
border-radius: 12px;
padding: 24px;
min-width: 280px;
align-self: flex-start;
}
.specs h2 {
font-size: 0.85rem;
color: #999;
text-transform: uppercase;
letter-spacing: 0.5px;
margin-bottom: 16px;
}
.spec-table { width: 100%; font-size: 0.82rem; }
.spec-table td { padding: 6px 4px; border-bottom: 1px solid #222; }
.spec-table td:first-child { color: #666; white-space: nowrap; padding-right: 16px; }
.spec-table td:last-child { color: #e0e0e0; }
.label { color: #4fc3f7; }
.footnote { color: #666; font-size: 0.75rem; margin-top: 16px; }
.accent { color: #66bb6a; }
.cost { color: #ffa726; }
</style>
</head>
<body>
<h1>🎸 PCM1808+PCM5102 I2S HAT</h1>
<div class="subtitle">65×56mm 2-layer PCB — 1590B Compatible — Rev 1.0</div>
<div class="container">
<div class="board-card">
<h2>Top View (Component Side)</h2>
<svg width="460" height="396" viewBox="0 0 460 396">
<!-- Board outline -->
<rect x="10" y="10" width="440" height="376" rx="4" fill="#0a1a0a" stroke="#2a5a2a" stroke-width="2"/>
<!-- Board edge highlight -->
<rect x="11" y="11" width="438" height="374" rx="3" fill="none" stroke="#1a3a1a" stroke-width="0.5"/>
<!-- Mounting holes -->
<circle cx="31" cy="31" r="11" fill="#0d0d0d" stroke="#444" stroke-width="1.5"/>
<circle cx="31" cy="31" r="8" fill="none" stroke="#333" stroke-width="0.5"/>
<circle cx="429" cy="31" r="11" fill="#0d0d0d" stroke="#444" stroke-width="1.5"/>
<circle cx="429" cy="31" r="8" fill="none" stroke="#333" stroke-width="0.5"/>
<circle cx="31" cy="365" r="11" fill="#0d0d0d" stroke="#444" stroke-width="1.5"/>
<circle cx="31" cy="365" r="8" fill="none" stroke="#333" stroke-width="0.5"/>
<circle cx="429" cy="365" r="11" fill="#0d0d0d" stroke="#444" stroke-width="1.5"/>
<circle cx="429" cy="365" r="8" fill="none" stroke="#333" stroke-width="0.5"/>
<!-- RPi 40-pin header J1 -->
<rect x="170" y="14" width="120" height="40" rx="3" fill="rgba(79,195,247,0.15)" stroke="#4fc3f7" stroke-width="1.5"/>
<text x="230" y="38" text-anchor="middle" fill="#4fc3f7" font-size="9">J1 — RPi 40-Pin Header</text>
<!-- Pin 1 marker -->
<circle cx="176" cy="20" r="3" fill="#4fc3f7" opacity="0.5"/>
<!-- I2S bus label -->
<rect x="50" y="70" width="80" height="18" rx="3" fill="rgba(251,191,36,0.15)" stroke="#fbbf24" stroke-width="1" stroke-dasharray="3,2"/>
<text x="90" y="83" text-anchor="middle" fill="#fbbf24" font-size="8">I2S Bus (BCLK/LRCLK/DIN/DOUT)</text>
<!-- AMS1117-3.3 LDO U1 -->
<rect x="40" y="100" width="70" height="30" rx="3" fill="rgba(239,83,80,0.15)" stroke="#ef5350" stroke-width="1.5"/>
<text x="75" y="115" text-anchor="middle" fill="#ef5350" font-size="9">U1</text>
<text x="75" y="125" text-anchor="middle" fill="#ef5350" font-size="7">AMS1117-3.3</text>
<!-- Decoupling caps near LDO -->
<rect x="115" y="105" width="14" height="10" rx="2" fill="rgba(255,255,255,0.1)" stroke="#666" stroke-width="1"/>
<text x="122" y="119" text-anchor="middle" fill="#888" font-size="6">C1</text>
<rect x="115" y="120" width="14" height="10" rx="2" fill="rgba(255,255,255,0.1)" stroke="#666" stroke-width="1"/>
<text x="122" y="134" text-anchor="middle" fill="#888" font-size="6">C2</text>
<!-- TL072 Preamp U2 -->
<rect x="40" y="155" width="90" height="45" rx="4" fill="rgba(102,187,106,0.15)" stroke="#66bb6a" stroke-width="1.5"/>
<text x="85" y="172" text-anchor="middle" fill="#66bb6a" font-size="9">U2 — TL072</text>
<text x="85" y="184" text-anchor="middle" fill="#66bb6a" font-size="7">Dual JFET Op-Amp</text>
<text x="85" y="195" text-anchor="middle" fill="#888" font-size="6">Half 1: Preamp · Half 2: Buffer</text>
<!-- Feedback resistors R3 R4 -->
<rect x="135" y="165" width="14" height="10" rx="2" fill="rgba(255,255,255,0.1)" stroke="#666" stroke-width="1"/>
<text x="142" y="179" text-anchor="middle" fill="#888" font-size="6">R3</text>
<rect x="135" y="180" width="14" height="10" rx="2" fill="rgba(255,255,255,0.1)" stroke="#666" stroke-width="1"/>
<text x="142" y="194" text-anchor="middle" fill="#888" font-size="6">R4</text>
<!-- Input jack J2 -->
<rect x="10" y="145" width="26" height="55" rx="4" fill="rgba(251,191,36,0.12)" stroke="#fbbf24" stroke-width="1.5"/>
<text x="23" y="168" text-anchor="middle" fill="#fbbf24" font-size="7">J2</text>
<text x="23" y="180" text-anchor="middle" fill="#fbbf24" font-size="6">Input</text>
<!-- Arrow from jack to preamp -->
<line x1="36" y1="172" x2="40" y2="177" stroke="#666" stroke-width="1"/>
<polygon points="38,172 40,170 44,177 40,178" fill="#666"/>
<!-- Caps near preamp -->
<rect x="135" y="155" width="14" height="10" rx="2" fill="rgba(255,255,255,0.1)" stroke="#666" stroke-width="1"/>
<rect x="155" y="155" width="14" height="10" rx="2" fill="rgba(255,255,255,0.1)" stroke="#666" stroke-width="1"/>
<text x="162" y="169" text-anchor="middle" fill="#888" font-size="6">R1,R2</text>
<!-- PCM1808 ADC U3 -->
<rect x="40" y="220" width="85" height="40" rx="4" fill="rgba(167,139,250,0.15)" stroke="#a78bfa" stroke-width="1.5"/>
<text x="82" y="240" text-anchor="middle" fill="#a78bfa" font-size="9">U3 — PCM1808</text>
<text x="82" y="252" text-anchor="middle" fill="#a78bfa" font-size="7">24-bit Stereo ADC</text>
<!-- PCM5102 DAC U4 -->
<rect x="200" y="220" width="85" height="40" rx="4" fill="rgba(79,195,247,0.15)" stroke="#4fc3f7" stroke-width="1.5"/>
<text x="242" y="240" text-anchor="middle" fill="#4fc3f7" font-size="9">U4 — PCM5102</text>
<text x="242" y="252" text-anchor="middle" fill="#4fc3f7" font-size="7">32-bit Stereo DAC</text>
<!-- ADC decoupling caps -->
<rect x="155" y="215" width="14" height="10" rx="2" fill="rgba(255,255,255,0.1)" stroke="#666" stroke-width="1"/>
<text x="162" y="229" text-anchor="middle" fill="#888" font-size="6">C6</text>
<rect x="155" y="230" width="14" height="10" rx="2" fill="rgba(255,255,255,0.1)" stroke="#666" stroke-width="1"/>
<text x="162" y="244" text-anchor="middle" fill="#888" font-size="6">C7</text>
<!-- DAC decoupling caps -->
<rect x="175" y="215" width="14" height="10" rx="2" fill="rgba(255,255,255,0.1)" stroke="#666" stroke-width="1"/>
<text x="182" y="229" text-anchor="middle" fill="#888" font-size="6">C8</text>
<rect x="175" y="230" width="14" height="10" rx="2" fill="rgba(255,255,255,0.1)" stroke="#666" stroke-width="1"/>
<text x="182" y="244" text-anchor="middle" fill="#888" font-size="6">C9</text>
<!-- I2S connection lines between ADC and DAC -->
<line x1="125" y1="230" x2="200" y2="230" stroke="#fbbf24" stroke-width="1" stroke-dasharray="3,2"/>
<line x1="125" y1="240" x2="200" y2="240" stroke="#fbbf24" stroke-width="1" stroke-dasharray="3,2"/>
<line x1="125" y1="250" x2="200" y2="250" stroke="#fbbf24" stroke-width="1" stroke-dasharray="3,2"/>
<text x="162" y="262" text-anchor="middle" fill="#fbbf24" font-size="6">BCLK · LRCLK · DIN</text>
<!-- DC-blocking cap C5 -->
<rect x="155" y="195" width="14" height="10" rx="2" fill="rgba(255,255,255,0.1)" stroke="#666" stroke-width="1"/>
<text x="162" y="209" text-anchor="middle" fill="#888" font-size="6">C5</text>
<!-- Output RC filter -->
<rect x="290" y="225" width="40" height="20" rx="3" fill="rgba(255,255,255,0.08)" stroke="#666" stroke-width="1"/>
<text x="310" y="235" text-anchor="middle" fill="#888" font-size="7">R5+C10</text>
<text x="310" y="242" text-anchor="middle" fill="#666" font-size="6">330Ω+10µF</text>
<!-- Output jack J3 -->
<rect x="335" y="145" width="26" height="55" rx="4" fill="rgba(251,191,36,0.12)" stroke="#fbbf24" stroke-width="1.5"/>
<text x="348" y="168" text-anchor="middle" fill="#fbbf24" font-size="7">J3</text>
<text x="348" y="180" text-anchor="middle" fill="#fbbf24" font-size="6">Output</text>
<!-- DAC to output path -->
<line x1="285" y1="240" x2="335" y2="172" stroke="#888" stroke-width="1" stroke-dasharray="4,2"/>
<!-- Output buffer resistor R6 -->
<rect x="290" y="195" width="20" height="12" rx="2" fill="rgba(255,255,255,0.1)" stroke="#666" stroke-width="1"/>
<text x="300" y="203" text-anchor="middle" fill="#888" font-size="6">R6</text>
<!-- 3.3V rail indicator -->
<rect x="50" y="275" width="100" height="16" rx="3" fill="rgba(239,83,80,0.08)" stroke="#ef5350" stroke-width="1" stroke-dasharray="2,2"/>
<text x="100" y="287" text-anchor="middle" fill="#ef5350" font-size="7">⎇ 3.3V Rail (5V → AMS1117)</text>
<!-- GND flood fill text -->
<text x="230" y="320" text-anchor="middle" fill="#444" font-size="8">GND Flood Fill (both layers)</text>
<text x="230" y="330" text-anchor="middle" fill="#444" font-size="8">Star Ground at RPi GND pin</text>
<!-- Power section label -->
<rect x="40" y="95" width="80" height="18" rx="3" fill="rgba(239,83,80,0.08)" stroke="#ef5350" stroke-width="0.5"/>
<text x="80" y="107" text-anchor="middle" fill="#ef5350" font-size="7">Power Regulation</text>
<!-- Dimension arrows -->
<line x1="10" y1="390" x2="450" y2="390" stroke="#555" stroke-width="0.5" marker-start="url(#arrow)" marker-end="url(#arrow)"/>
<text x="230" y="384" text-anchor="middle" fill="#666" font-size="8">65mm</text>
<line x1="458" y1="10" x2="458" y2="386" stroke="#555" stroke-width="0.5" marker-start="url(#arrow)" marker-end="url(#arrow)"/>
<text x="454" y="200" text-anchor="middle" fill="#666" font-size="8" transform="rotate(90,454,200)">56mm</text>
<defs>
<marker id="arrow" viewBox="0 0 10 10" refX="5" refY="5" markerWidth="6" markerHeight="6" orient="auto">
<path d="M 0 0 L 10 5 L 0 10" fill="none" stroke="#555" stroke-width="1"/>
</marker>
</defs>
</svg>
</div>
<div class="specs">
<h2>Board Specifications</h2>
<table class="spec-table">
<tr><td>Dimensions</td><td>65 × 56mm (1590B)</td></tr>
<tr><td>Layers</td><td>2-layer FR4, 1.6mm</td></tr>
<tr><td>Surface Finish</td><td>ENIG (gold) preferred</td></tr>
<tr><td>Min Trace</td><td>0.254mm (10mil)</td></tr>
<tr><td>Min Hole</td><td>0.3mm</td></tr>
<tr><td>Mounting</td><td>4× M2.5, 3.2mm holes</td></tr>
<tr><td colspan="2" style="padding-top:16px; border:none;"></td></tr>
<tr><td colspan="2" style="font-weight:600; border-bottom:1px solid #444;">Signal Chain</td></tr>
<tr><td>Input</td><td>Guitar → <span class="label">J2</span> (6.35mm TS)</td></tr>
<tr><td>Preamp</td><td><span class="label">U2</span> TL072 — 20dB gain</td></tr>
<tr><td>ADC</td><td><span class="label">U3</span> PCM1808 — 24-bit/48kHz I2S</td></tr>
<tr><td>DAC</td><td><span class="label">U4</span> PCM5102A — 32-bit I2S</td></tr>
<tr><td>Output</td><td><span class="label">J3</span> (6.35mm TS) via RC filter</td></tr>
<tr><td colspan="2" style="padding-top:16px; border:none;"></td></tr>
<tr><td colspan="2" style="font-weight:600; border-bottom:1px solid #444;">Power</td></tr>
<tr><td>Regulator</td><td><span class="label">U1</span> AMS1117-3.3 (5V→3.3V)</td></tr>
<tr><td>Decoupling</td><td>100nF + 10µF per IC</td></tr>
<tr><td>Ground</td><td>Star ground, GND flood fill</td></tr>
<tr><td colspan="2" style="padding-top:16px; border:none;"></td></tr>
<tr><td colspan="2" style="font-weight:600; border-bottom:1px solid #444;">I2S Bus (GPIO)</td></tr>
<tr><td>BCLK</td><td>GPIO18 (Pin 12)</td></tr>
<tr><td>LRCLK</td><td>GPIO19 (Pin 35)</td></tr>
<tr><td>DIN (to RPi)</td><td>GPIO20 (Pin 38) ← PCM1808</td></tr>
<tr><td>DOUT (from RPi)</td><td>GPIO21 (Pin 40) → PCM5102</td></tr>
<tr><td colspan="2" style="padding-top:16px; border:none;"></td></tr>
<tr><td colspan="2" style="font-weight:600; border-bottom:1px solid #444;">Cost</td></tr>
<tr><td>Board + Components</td><td class="cost"><strong>~$29.25</strong></td></tr>
<tr><td>+ Enclosure (1590B)</td><td class="cost"><strong>~$41.75</strong></td></tr>
<tr><td>Qty 5 @ JLCPCB</td><td class="cost"><strong>~$146.25</strong></td></tr>
</table>
<div class="footnote">
⚠️ PCB layout shown is a schematic-derived approximation — the KiCad PCB file (commit 0ae2ca6) has the board outline and mounting holes. Component footprints need human placement review before Gerber export. Open in KiCad to see the actual routed layout.
</div>
</div>
</div>
<div style="margin-top: 30px; max-width: 860px; width: 100%;">
<div style="background: #1a1a1a; border: 1px solid #333; border-radius: 12px; padding: 20px;">
<h2 style="color: #999; font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 12px;">Schematic Preview (from KiCad .sch file)</h2>
<div style="display: grid; grid-template-columns: 1fr 1fr; gap: 8px; font-size: 0.8rem;">
<div style="background: #111; border: 1px solid #222; border-radius: 6px; padding: 12px;">
<div style="color: #4fc3f7; font-weight: 600; margin-bottom: 6px;">Page 1 — Power</div>
<div>5V rail → <span style="color:#ef5350;">U1 AMS1117</span> → 3.3V</div>
<div>C1 (10µF) + C2 (100nF) input decoupling</div>
<div>C3 (10µF) + C4 (100nF) output decoupling</div>
</div>
<div style="background: #111; border: 1px solid #222; border-radius: 6px; padding: 12px;">
<div style="color: #66bb6a; font-weight: 600; margin-bottom: 6px;">Page 2 — RPi Header</div>
<div><span style="color:#4fc3f7;">J1</span> 2×20 stacking header</div>
<div>All 40 GPIO pins pass through</div>
<div>I2S: BCLK(18) LRCLK(19) DIN(20) DOUT(21)</div>
</div>
<div style="background: #111; border: 1px solid #222; border-radius: 6px; padding: 12px;">
<div style="color: #66bb6a; font-weight: 600; margin-bottom: 6px;">Page 3 — Preamp</div>
<div><span style="color:#fbbf24;">J2</span> Guitar in → R1(1MΩ) pulldown</div>
<div>→ R2(10k) → <span style="color:#66bb6a;">U2 TL072</span> non-inv (+) input</div>
<div>Gain = 1 + R3(100k)/R4(10k) = <strong>~20dB</strong></div>
<div>→ C5(10µF) DC-block → PCM1808</div>
</div>
<div style="background: #111; border: 1px solid #222; border-radius: 6px; padding: 12px;">
<div style="color: #a78bfa; font-weight: 600; margin-bottom: 6px;">Page 4 — ADC + DAC</div>
<div><span style="color:#a78bfa;">U3 PCM1808</span>: I2S, 48kHz, always active</div>
<div>C6(100nF) + C7(10µF) decoupling</div>
<div><span style="color:#4fc3f7;">U4 PCM5102</span>: low-latency filter, unmuted</div>
<div>C8(100nF) + C9(10µF) decoupling</div>
<div>Output → R5(330Ω) + C10(10µF) → <span style="color:#fbbf24;">J3</span></div>
</div>
<div style="background: #111; border: 1px solid #222; border-radius: 6px; padding: 12px;">
<div style="color: #888; font-weight: 600; margin-bottom: 6px;">Page 5 — Output Buffer</div>
<div>U2 TL072 (half 2): output buffer stage</div>
<div>R6(10k) feedback resistor</div>
</div>
<div style="background: #111; border: 1px solid #222; border-radius: 6px; padding: 12px;">
<div style="color: #888; font-weight: 600; margin-bottom: 6px;">I2S Bus Labels</div>
<div>Global net labels: <span style="color:#fbbf24;">I2S_BCLK</span>, <span style="color:#fbbf24;">I2S_LRCLK</span></div>
<div><span style="color:#fbbf24;">I2S_DIN</span> (RPi←ADC), <span style="color:#fbbf24;">I2S_DOUT</span> (RPi→DAC)</div>
</div>
</div>
</div>
</div>
</body>
</html>