# WiFiX-Enhanced Wiring Diagram ## πŸ”Œ Complete Connection Map ### Visual Wiring Layout ``` β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ BREADBOARD LAYOUT β”‚ β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€ β”‚ Top Rail: 3.3V Power β”‚ β”‚ Bottom Rail: GND β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ ESP32 β”‚ β”‚ OLED β”‚ β”‚ SD CARD β”‚ β”‚ BW16 β”‚ β”‚ DevKit β”‚ β”‚ Display β”‚ β”‚ Module β”‚ β”‚ Module β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ CONNECTION DETAILS β”‚ β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€ β”‚ Power Connections: β”‚ β”‚ β”œβ”€ ESP32 3.3V β†’ Top Rail (+) β”‚ β”‚ β”œβ”€ ESP32 GND β†’ Bottom Rail (-) β”‚ β”‚ β”œβ”€ Top Rail β†’ OLED VCC, SD VCC, BW16 VCC β”‚ β”‚ └─ Bottom Rail β†’ OLED GND, SD GND, BW16 GND β”‚ β”‚ β”‚ β”‚ Signal Connections: β”‚ β”‚ β”œβ”€ ESP32 GPIO21 β†’ OLED SDA (Blue Wire) β”‚ β”‚ β”œβ”€ ESP32 GPIO22 β†’ OLED SCL (Yellow Wire) β”‚ β”‚ β”œβ”€ ESP32 GPIO23 β†’ SD MOSI (Green Wire) β”‚ β”‚ β”œβ”€ ESP32 GPIO19 β†’ SD MISO (Orange Wire) β”‚ β”‚ β”œβ”€ ESP32 GPIO18 β†’ SD CLK (Purple Wire) β”‚ β”‚ β”œβ”€ ESP32 GPIO5 β†’ SD CS (White Wire) β”‚ β”‚ β”œβ”€ ESP32 GPIO16 β†’ BW16 TX (Gray Wire) β”‚ β”‚ └─ ESP32 GPIO17 β†’ BW16 RX (Brown Wire) β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ ``` ## 🎨 Color-Coded Wiring Scheme ### Wire Color Standards ``` πŸ”΄ Red: Power (3.3V) ⚫ Black: Ground (GND) πŸ”΅ Blue: I2C SDA 🟑 Yellow: I2C SCL 🟒 Green: SPI MOSI 🟠 Orange: SPI MISO 🟣 Purple: SPI CLK βšͺ White: SPI CS πŸ”˜ Gray: UART TX 🟀 Brown: UART RX ``` ### Physical Wiring Map ``` ESP32 DevKit (30-pin) Layout: β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ 3.3V [●]──────────────────────────────┐ β”‚ β”‚ GND [●]──────────────────────────────┼──┐ β”‚ β”‚ [ ] [ ] D23 (MOSI) ────────┐ β”‚ β”‚ β”‚ β”‚ [ ] [ ] D22 (SCL) ─────────┼──┐ β”‚ β”‚ β”‚ β”‚ [ ] [ ] D21 (SDA) ─────────┼──┼─── β”‚ β”‚ β”‚ [ ] [ ] D19 (MISO) ────────┼─── β”‚ β”‚ β”‚ β”‚ [ ] [ ] D18 (CLK) ─────────┼──┼─── β”‚ β”‚ β”‚ [ ] [ ] D5 (CS) ───────────┼──┼──┼─── β”‚ β”‚ [ ] [ ] D17 (TX) ──────────┼──┼──┼──┼──┐ β”‚ β”‚ [ ] [ ] D16 (RX) ──────────┼──┼──┼──┼──┼──┐ β”‚ β”‚ GND [●]──────────────────────────┼──┼──┼──┼──┼──┐ β”‚ β”‚ [ ] [●] D2 (LED) β”‚ β”‚ β”‚ β”‚ β”‚ β”‚ β”‚ β”‚ [ ] [ ] β”‚ β”‚ β”‚ β”‚ β”‚ β”‚ β”‚ β”‚ [ ] [ ] β”‚ β”‚ β”‚ β”‚ β”‚ β”‚ β”‚ β”‚ [ ] [ ] β”‚ β”‚ β”‚ β”‚ β”‚ β”‚ β”‚ β”‚ 3.3V [●]β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”Όβ”€β”€β”Όβ”€β”€β”Όβ”€β”€β”Όβ”€β”€β”˜ β”‚ β”‚ EN [●] β”‚ β”‚ β”‚ β”‚ β”‚ β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”Όβ”€β”€β”Όβ”€β”€β”Όβ”€β”€β”˜ β”‚ β”‚ β”‚ β”‚ β”‚ β”‚ β–Ό β–Ό β–Ό β–Ό β–Ό OLED Connections: SD Card: BW16: β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ VCC [●]─────┼─── Red Wire β”‚ VCC [●]─────┼─── Red β”‚ VCC [●]─────┼─── Red to 3.3V Rail β”‚ β”‚ to 3.3V Railβ”‚ β”‚ to 3.3V Railβ”‚ β”‚ GND [●]─────┼─── Black Wire β”‚ GND [●]─────┼─── Black β”‚ GND [●]─────┼─── Black to GND Rail β”‚ β”‚ to GND Rail β”‚ β”‚ to GND Rail β”‚ β”‚ SDA [●]─────┼─── Blue Wire β”‚ MOSI[●]─────┼─── Green β”‚ TX [●]─────┼─── Gray to GPIO21 β”‚ β”‚ to GPIO23 β”‚ β”‚ to GPIO16 β”‚ β”‚ SCL [●]─────┼─── Yellow Wire β”‚ MISO[●]─────┼─── Orange β”‚ RX [●]─────┼─── Brown to GPIO22 β”‚ β”‚ to GPIO19 β”‚ β”‚ to GPIO17 β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β”‚ CLK [●]─────┼─── Purple β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β”‚ to GPIO18 β”‚ β”‚ CS [●]─────┼─── White β”‚ to GPIO5 β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ ``` ## πŸ”§ Breadboard Layout ### Recommended Breadboard Sections ``` Full-Size Breadboard (830 tie-points): β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ A1-A30: ESP32 DevKit β”‚ β”‚ B1-B30: Power distribution β”‚ β”‚ C1-C30: OLED Display connections β”‚ β”‚ D1-D30: SD Card connections β”‚ β”‚ E1-E30: BW16 connections β”‚ β”‚ F1-F30: Spare/Expansion β”‚ β”‚ G1-G30: Spare/Expansion β”‚ β”‚ H1-H30: Spare/Expansion β”‚ β”‚ I1-I30: Spare/Expansion β”‚ β”‚ J1-J30: Spare/Expansion β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ Specific Layout: β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ Row 1-5: Power rails (3.3V top, GND bottom) β”‚ β”‚ Row 6-10: ESP32 main placement β”‚ β”‚ Row 11-15: OLED display area β”‚ β”‚ Row 16-20: SD card module area β”‚ β”‚ Row 21-25: BW16 module area β”‚ β”‚ Row 26-30: Status LEDs/Expansion β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ ``` ## πŸ“ Wire Length Guidelines ### Maximum Recommended Lengths ``` I2C Connections (OLED): β”œβ”€ SDA: ≀30cm (12 inches) β”œβ”€ SCL: ≀30cm (12 inches) └─ Use twisted pairs for longer runs SPI Connections (SD Card): β”œβ”€ MOSI: ≀15cm (6 inches) β”œβ”€ MISO: ≀15cm (6 inches) β”œβ”€ CLK: ≀15cm (6 inches) β”œβ”€ CS: ≀15cm (6 inches) └─ Keep all SPI wires same length UART Connections (BW16): β”œβ”€ TX: ≀50cm (20 inches) β”œβ”€ RX: ≀50cm (20 inches) └─ Use shielded cable for long runs Power Connections: β”œβ”€ 3.3V: ≀10cm (4 inches) recommended β”œβ”€ GND: As short as possible └─ Use thicker wire for power (22-24 AWG) ``` ## ⚑ Power Distribution ### Current Requirements by Module ``` ESP32 DevKit: β”œβ”€ Normal operation: 80-120mA β”œβ”€ WiFi active: 160-260mA └─ Peak current: 500mA BW16 Module: β”œβ”€ Normal operation: 60-100mA β”œβ”€ WiFi active: 120-200mA └─ Peak current: 300mA OLED Display: β”œβ”€ Normal operation: 15-25mA └─ All pixels on: 40mA SD Card Module: β”œβ”€ Idle: 5-10mA β”œβ”€ Active: 50-100mA └─ Peak current: 150mA Total System: β”œβ”€ Average current: 200-300mA β”œβ”€ Peak current: 800-1000mA └─ Recommended supply: 3.3V @ 1.5A ``` ## πŸ” Testing Connections ### Visual Inspection Checklist ``` βœ“ All power connections correct (3.3V, not 5V) βœ“ Common ground established between all modules βœ“ Signal wire colors match standard βœ“ No loose connections or stray wire strands βœ“ No short circuits between adjacent pins βœ“ Wire insulation not damaged βœ“ Breadboard connections firm ``` ### Continuity Testing ``` Use multimeter continuity mode: 1. ESP32 3.3V β†’ each module VCC 2. ESP32 GND β†’ each module GND 3. ESP32 GPIO21 β†’ OLED SDA 4. ESP32 GPIO22 β†’ OLED SCL 5. ESP32 GPIO23 β†’ SD MOSI 6. ESP32 GPIO19 β†’ SD MISO 7. ESP32 GPIO18 β†’ SD CLK 8. ESP32 GPIO5 β†’ SD CS 9. ESP32 GPIO16 β†’ BW16 TX 10. ESP32 GPIO17 β†’ BW16 RX ``` ### Power-On Test Sequence ``` Step 1: Power supply test β”œβ”€ Connect USB to ESP32 β”œβ”€ Measure 3.3V rail: 3.2-3.4V expected β”œβ”€ Measure total current: <100mA expected └─ Check for hot components Step 2: Module detection β”œβ”€ Upload test sketch β”œβ”€ Check serial output β”œβ”€ Verify OLED display β”œβ”€ Test SD card detection └─ Confirm BW16 communication Step 3: Full system test β”œβ”€ Upload main firmware β”œβ”€ Check WiFi network appears β”œβ”€ Test captive portal β”œβ”€ Verify credential storage └─ Confirm all features working ``` ## 🚨 Common Wiring Mistakes ### Power Related ``` ❌ Using 5V instead of 3.3V β†’ WILL DAMAGE MODULES ❌ Insufficient power supply β†’ Unstable operation ❌ Missing common ground β†’ Communication failures ❌ Long power wires β†’ Voltage drop issues ``` ### Signal Related ``` ❌ Swapped TX/RX connections β†’ No communication ❌ I2C pull-up resistors missing β†’ Unreliable operation ❌ SPI wires too long β†’ Data corruption ❌ Crossed signal wires β†’ Interference ``` ### Mechanical ``` ❌ Loose breadboard connections β†’ Intermittent faults ❌ Wire strands touching β†’ Short circuits ❌ Insufficient wire gauge β†’ Voltage drop ❌ Poor strain relief β†’ Broken connections ``` ## πŸ”§ Troubleshooting Wiring Issues ### System Won't Power On ``` 1. Check power supply voltage (3.3V Β±5%) 2. Verify polarity (no reversed connections) 3. Test for short circuits (multimeter) 4. Check current draw (should be <100mA idle) 5. Inspect for damaged components ``` ### OLED Display Not Working ``` 1. Verify I2C connections (SDA/SCL not swapped) 2. Check I2C address (usually 0x3C) 3. Test with I2C scanner sketch 4. Add pull-up resistors (4.7kΞ©) if needed 5. Check power supply stability ``` ### SD Card Not Detected ``` 1. Verify all SPI connections 2. Check CS pin configuration 3. Test with different SD card 4. Format card as FAT32 5. Check SPI speed (try slower) ``` ### BW16 Not Communicating ``` 1. Verify TX/RX connections (crossover) 2. Check baud rate (115200) 3. Test with serial loopback 4. Verify BW16 firmware loaded 5. Check antenna connection ``` --- **Remember**: Measure twice, cut once. Double-check all connections before powering on!