# โš™๏ธ Samson eFit Module โ€“ Internal README (MVP Implementation) ## ๐ŸŽฏ Purpose Build a compact, motor-controlled resistance unit with basic wireless control and encoder-based feedback. Stay within MVP scope and avoid feature creep until core functionality works. --- ## ๐Ÿงญ MVP Core Goals - Smooth electronic resistance using BLDC + driver - Wireless control of load (ESP32 โ†’ PWM) - Encoder-based feedback to maintain commanded resistance - Basic safety limits (current/thermal) - Minimal UI (phone/Pi/serial) --- ## ๐Ÿ“ฆ Current Components (Received) | # | Component | Purpose | Notes | |---|-----------|---------|------| | 1 | Waveshare 4" Round DSI Touch Display | UI | Use later; not MVP-critical | | 2 | AS5600 Magnetic Encoders (5 pcs) | Angle/rep sensing | High priority for control loop | | 3 | Milwaukee M18 Battery Adapters (2 pcs) | Power source | Portable demos; regulate as needed | | 4 | 400W BLDC Motor Controllers (2 pcs) | Motor driving | PWM control with FWD/REV/Brake | --- ## ๐Ÿงฉ High-Level Architecture (MVP) - **ESP32**: PWM output + encoder reading + wireless interface - **BLDC Driver**: Drives motor phases based on PWM - **AS5600 Encoder**: Shaft position/velocity feedback over IยฒC - **Power**: 18V battery via adapter (regulate for ESP32) - **UI**: Minimal (phone > Pi display for later) --- ## ๐Ÿ› ๏ธ Implementation Order (Milestones) 1) Bench-test BLDC controller + motor (no load) 2) Read encoder position/velocity reliably 3) Close feedback loop (PWM adjusted from encoder) 4) Add safety limits (brake/stop/overcurrent handling) 5) Wireless interface to set target resistance 6) Optional: Pi display UI after stable MVP --- ## ๐Ÿ’ป Firmware Tasks (ESP32) - PWM generation + tuning - Encoder IยฒC driver (AS5600) - Resistance control loop (angle/speed โ†’ PWM adjust) - Safety watchdogs (fault detection) - Simple wireless command interface --- ## ๐Ÿ”ฉ Hardware Tasks - Encoder magnet mounting on pulley/shaft - Secure motor + driver on bench fixture - Power routing + regulation - Fusing + emergency stop provisions --- ## ๐Ÿ”‹ Power Notes - M18 battery: 18V nominal - Driver acceptable: 6โ€“60V - ESP32 requires regulated 5V/3.3V - Add DC-DC regulator if powering both from same source --- ## ๐Ÿšซ Scope Limiters (Avoid Feature Creep) Not MVP: - Full AI workout planning - Cloud accounts or server database - Advanced touchscreen interface - Subscription model MVP success = controllable electronic resistance + encoder feedback loop. --- ## ๐Ÿงช Testing Targets - Commanded resistance holds within stable margin - Encoder data noise acceptable - No uncontrolled torque spikes - Safe stop behavior verified --- ## ๐Ÿ“ Notes to Ourselves If it does not directly help us **control and stabilize resistance**, it waits until after MVP.