Multi-purpose device controller
Group 36
Kenny Dao
Johnny Blanc
Jason Jean-Louis
Mohammed Talib Hamed Rashid Al Fahdi
1
Meet THE team
Kenny Dao: is a 24-year-old Computer Engineer with hopes of landing a software engineering job. Currently,
Kenny is working as an IT service desk intern at a South Florida based company.
Johnny Blanc: is a 29-year-old Computer Engineer who is currently an IT intern with hopes of a career in
software engineering.
Jason Jean-Louis: is a 25-year-old Computer Engineer from West Palm Beach with hopes of pursuing a
career in embedded programming.
Mohammed Talib Hamed Rashid Al Fahdi: is a 24-year-old Electrical Engineer. Mohammed hopes to pursue
a career in hardware design and work for major companies that relates to power like Google.
2
Problem statement
• Current controllers are limited in their compatibility, leading to fragmented gaming
experiences for users who own multiple gaming platforms.
• In response to the growing demand for versatile gaming controllers capable of
seamlessly connecting to various gaming consoles, there exists a need for a multi-
device controller solution.
• The issue of stick drift, characterized by the unintended and gradual movement of
gaming controller joysticks due to wear and tear, presents a significant challenge to
gamers seeking precise control.
• Necessity for a solution that accommodates both wireless and wired connectivity
options.
3
Project description
• Design a controller with a Hall Effect joystick mechanism to effectively eliminate stick
drift issues.
• Our controller serves as a reliable gaming peripheral that adapts to the user's platform
of choice, eliminating the need for multiple controllers and enhancing convenience.
• We enable wireless connectivity, reducing cable clutter and enhancing user mobility.
Gamers can enjoy seamless connections to their devices, whether it's a gaming
console, PC, or mobile device, providing them with the freedom to move and game
without constraints.
4
Problems to consider
• Technical Compatibility Issues: Ensuring seamless compatibility across multiple gaming platforms may pose
technical challenges due to differences in hardware, software, and communication protocols.
• Cost of Production: Integrating advanced features such as Hall Effect joystick mechanisms and Bluetooth
connectivity may significantly increase the production costs, potentially impacting the affordability of the
controller for consumers.
• Reliability and Performance: While aiming to eliminate stick drift, ensuring the reliability and long-term
performance of the controller's components, especially the joystick mechanism, is crucial to maintaining precise
input and overall gaming experience.
• Battery Life and Power Consumption: Implementing Bluetooth connectivity for wireless operation necessitates
careful consideration of battery life and power consumption. Balancing the need for extended playtime with
efficient power management is essential to prevent frequent recharging or battery replacement.
5
Goals and Objectives
• Goal: Durable controller with universal compatibility across consoles.
• Objectives:
o Eliminate stick drift with Hall Effect joysticks.
o Multi-console compatibility for seamless switching.
o Bluetooth connectivity for wireless freedom.
• Stretch Goals:
o Software for personalized settings and configurations.
o Broader console compatibility.
o Rubberized exterior for enhanced grip.
6
Specifications
Operating Time 5.6 Hours
Recharge Time 1.5 Hours
Power Consumption 1.4005 W
Latency 3.36 ms
Bluetooth Range 23.2 Feet
Speaker 300Hz to 8kHz range / 68dB
7
Prototype Design Concept
8
Hardware Diagram
9
Comparison and Selection of Hardware
• MCU • Reasonings
• ESP32 • MCU
• STM32F411
• Arduino Nano RP2040 • ESP32 for ease of use and Bluetooth
capabilities
• Power Source
• Power Source
• Lithium-ion
• Lithium-polymer • Lithium-polymer for the size, power output and
• Nickel-Metal Hydride protection IC
• Power Bank • Analog Sticks
• Analog sticks • Hall effect for the longevity
• Hall Effect Joystick • LEDs
• Joystick • Adafruit 5050 RGB LED with Integrated Driver
• LEDs Chip for price in bulk
• Adafruit 5050 RGB LED with Integrated
Driver Chip
• WL-SFTW SMT Full-color TOP LED
10
MCU Comparison
MCU ESP32 STM32F411 Arduino Nano
RP2040
Processor Dual- ARM Cortex- Dual-core
core Tensilica M4 100 MHz ARM Cortex-M0+
LX6 160/240 MHz 133 MHz
RAM 520 KB 256 KB 264 KiB
Wireless Built-in Wi-Fi and No Bluetooth LE
Connectivity BLE (external modules only (external
needed) modules needed)
Digital Pins 34 GPIOs 32 GPIOs 30 GPIOs
Analog Inputs 12-bit ADC 12-bit ADC 12-bit ADC with
with 18 Channels with 16 channels 2 channels
Price $5-$10 $5-$10 $5
11
MCU Selection: ESP32
•Built-in Bluetooth: Connect wirelessly to various platforms like PCs, tablets, and smartphones - no
external modules needed.
•Powerful Processing: Dual-core CPU and ample RAM handle complex inputs and low latency for smooth
gameplay.
•Low Power Consumption: Ideal for battery-powered controllers, extending playtime on a single charge.
•Open-Source Friendly: Large community and plenty of libraries & tutorials for easy development.
•Cost-Effective: Affordable option compared to dedicated gaming controller chips.
•Future-Proof: Support for latest Bluetooth LE standards ensures compatibility with upcoming devices.
12
Analog Sticks Comparison
Joy Stick Hall Effect Potentiometer
Rotary Mechanism Magnetic Sensor Resistive Wiper
Potentiometer Non-Contact Contact
Longevity Over 10 Million 500,000 – 1 Million
Cycles Cycles
Cost Higher Lower
13
Analog Stick Selection: Hall Effect
•Ditch the Drift: No physical contact means eliminating stick drift, a common issue with
traditional potentiometers.
•Enhanced Durability: Magnetic sensing resists wear and tear, extending controller life
and reducing repair needs.
•Greater Accuracy: Higher resolution compared to potentiometers leads to smoother,
more nuanced control.
•Lower Latency: Less physical interaction minimizes signal noise, potentially reducing
input lag.
14
Buttons Comparison
Button Tactile Switch Mechanical
Push Button
Size Miniature Can Vary in Size
Tactile "Clicky Feel" No
Feedback
Durability High Can Vary
Actuation Force Low Can Vary
Cost Lower - Can Vary
Moderate
15
Button Selection: Tactile Switch
•Perfect for tight spaces: Miniature size allows for more ergonomic controller design.
•Clear feedback: Clicky feel lets you know exactly when a button is pressed, improving
gaming performance.
•Built to last: High durability (over 10 million cycles) ensures buttons can withstand
intense gaming sessions.
•Reduces fatigue: Low actuation force makes rapid button presses less tiring.
•Affordable: Generally, a cost-effective option for gaming controllers.
•Quiet clicks: Provides audible feedback without being distracting during gameplay.
16
Speaker
Speaker WSPH-1805W Passive Buzzer
Sound Quality Wider Frequency Range, Limited Tones
Richer Sound
Volume Decent Volume for Close- Lower Volume
Range
Power Consumption Low Power Required Low
Cost Low Low
Complexity Requires Amplifier Circuit Simple to Integrate
Versatility Can Produce Various Limited Sound Options
Sounds
17
Speaker Selection: WSPH-1805w
•Compact size: Being a miniature speaker (likely less than 20mm diameter based on the model number),
it's ideal for space-constrained applications like portable gaming controllers.
•Decent power: With a 1W rating, it offers sufficient volume for close-range audio applications in
controllers.
•Wide frequency response: Covering 300Hz to 8kHz range, it should handle most audio cues and sound
effects in games.
•General-purpose design: The 8-ohm impedance makes it compatible with various amplifier circuits
commonly found in controllers.
•Potentially cost-effective: While specific pricing information isn't readily available, miniature speakers
like this tend to be affordable.
18
LEDs comparison
LEDs Adafruit 5050 RGB LED Individual RGB LED
Driver Chip Integrated Requires External
Resistors
Control Complexity Requires MCU and Requires Resistors for
Library Each Color Channel
Customization Can be Controlled Can be Individually
Individually Controlled
Wiring Complexity Simpler More Complex
Cost Higher Lower
19
LED Selection: Adafruit 5050 RGB LED
•Simpler wiring: Requires only three wires (power, ground, data) compared to separate
wires for red, green, and blue with resistors for individual LEDs.
•Easier control: Integrated driver chip simplifies communication with the LED using a
microcontroller and library.
•Individual control: Each LED can be controlled independently, allowing for a wider
range of lighting effects compared to basic on/off control for individual LEDs with
resistors.
•Learning platform: A good option for learning about addressable LEDs without overly
complex wiring.
20
Power Distribution Table
Component Voltage (V) Current (mA) Power (Watts)
Charging LEDs x3 5 45 0.225
Programmable LEDs (WS2812) x3 3.7 150 0.555
ESP32 3.3 150 0.495
Speaker 3.3 10 0.033
Joysticks x2 3.3 20 0.066
Buttons x8 3.3 8 0.0265
21
Battery Comparison
Feature LP653042 AA Batteries Battery Pack
(1500mAh)
Capacity 820mAh 2400mAh 1500mAh
(combined)
Weight 46g 70g 120g
(approximate) (approximate)
Cost $10-$15 $2-$5 (batteries) $15-$20
+ charger
Environmental Low High (disposable) Moderate
Impact (rechargeable) (rechargeable)
Temperature -20°C to +60°C -20°C to +50°C -10°C to +40°C
Tolerance
Safety Features Over charge and None May have some
discharge short
circuit protection
22
Battery Selection: LP653042
•Extended Playtime: High capacity 820mAh ensures longer gaming sessions without interruption.
•Reliable Performance: Lithium-ion technology provides consistent power delivery throughout your
gameplay.
•Lightweight Design: Weighs only 46g, minimizing controller weight for comfortable and fatigue-free play.
•Rechargeable Convenience: Eliminate the need for disposable batteries, saving money and reducing
environmental impact.
•Safety Features: Built-in protection against overcharge, over-discharge, and short circuits for peace of
mind.
•Temperature Tolerance: Operates reliably within a wide temperature range (-20°C to +60°C), suitable for
various environments.
23
Voltage Regulator
Voltage Regulator TPS62840DLCR UA7824CKCS
Type Switching Linear
Input Range 1.8 – 6.5V (3.7V) 7V - 20V
Output Adjustable (3.3v) Fixed (5V)
Output Current 750mA 100mA
Efficiency Higher Lower
Price Moderate Lower
24
Voltage Regulator Circuit
25
Regulator Selection: TPS62840DLCR
•Wider input range: Works with various battery options (Lipo, NiMH) used
in controllers.
•Adjustable output: Can power different components with varying voltage
needs (e.g., LEDs vs motors).
•Higher output current: Suitable for powering more demanding
components you might add to your controller.
•Higher efficiency: Saves battery life in your custom controller.
•Smaller size: Takes up less space within the controller's shell. 26
PCB SCHEMATIC
27
PCB BOARD SCHEMATIC
28
Software Flowchart
29
Comparison and Selection of software
• Programming Language • Reasonings
• C • C
• Python
• ESP32 for ease of use and Bluetooth
• Java
capabilities
• JavaScript
• C# • Arduino
• IDE • Lithium-polymer for the size, power output and
protection IC
• Arduino
• Code Composer Studio • BLE
• Visual Studio Code • Consumes significantly less power compared
• Connections to classic Bluetooth, enabling longer battery
life.
• Bluetooth Low Energy
• Wifi
• Radio Frequency
30
Wireless Comparison
Communication BLE (Bluetooth Low Wi-Fi Radio Frequency
Energy)
Latency Low Moderate to High Variable
Power Consumption Low High Variable
Range Up to 10 meters Up to 30 Meters Variable
Compatibility Broad (smartphones, PCs, Moderate (PCs, some Variable
tablets) consoles)
Cost Lower Higher Variable
Security Built-in security features Requires additional security Variable
measures
31
Wireless Communication Selection: BLE
•Low Latency: Enjoy responsive gameplay with minimal input lag.
•Power Efficiency: Extends battery life for longer gaming sessions without frequent charging.
•Wide Compatibility: Connects to various devices like PCs, tablets, and smartphones offering platform
flexibility.
•Secure Communication: Built-in security features protect data privacy during gameplay.
•Simple Integration: Requires less complex hardware compared to other wireless protocols.
•Future-Proof: Supports latest Bluetooth LE standards for broad device compatibility.
•Low Cost: Enables affordable controller design without sacrificing performance.
32
Nim-BLE
• Enables ESP32 to communicate wirelessly with BLE-enabled devices.
• Low Power Consumption: Essential for gaming controllers, prolonging battery
life.
• Compatibility: Works seamlessly with ESP32.
• Comprehensive API: Facilitates BLE functionalities.
• Security: Ensures data protection during wireless communication.
• Flexibility: Customizable BLE profiles to suit gaming controller requirements.
33
Connection Test
34
Language Comparison
Feature C MicroPython Arduino C++
Performance High Moderate Moderate
Hardware Access Direct Limited Moderate
Memory Management Manual Garbage Collection Semi-Automatic
Community and Vast Growing Very Large
Resources
Error Handling Manual Checks Automatic Semi-Automatic
Portability High Limited Moderate
35
Language Selection: C
• Direct Hardware Access: Control peripherals like buttons, joysticks, and sensors with precise timing
crucial for gameplay.
• Efficiency and Speed: Compiled language minimizes overhead, maximizing responsiveness and
minimizing latency for smooth gameplay.
• Wide Toolchain Support: Abundance of open-source compilers, debuggers, and libraries readily
available.
• Mature and Stable: Long history and active development ensure reliability and compatibility.
• Large Community & Resources: Benefit from the shared knowledge and experience of many
developers.
• Future-Proof: Widely used in professional game development and embedded systems.
36
Accuracy/Responsiveness Techniques
• Polling
• Polling involves continuously checking the state of each button or input at regular intervals.
• Provides a straightforward implementation for detecting input, ensuring responsiveness in
gameplay.
• Dead zone
• Dead zones are regions around the center position of joysticks where no input is registered.
• Implemented to filter out small unintended movements or inaccuracies in the joystick's
resting position.
• Improves the user experience by making the joystick feel more stable and responsive, especially
in games requiring precise control.
• Debouncing
• Debouncing cleans up jittery button presses.
• It ensures a single press is registered even if the button contacts bounce slightly.
37
Polling
Feature Polling Interrupts
Complexity Simpler to More complex,
implement requires interrupt
handling code
CPU Usage Wastes CPU cycles More efficient, CPU
constantly checking only works when
for input input occurs
Input Latency Potentially high Lower latency, CPU
latency depending notified immediately
on polling frequency of input
Deterministic Input Guaranteed to Relies on timing of
check for input at other processes,
regular intervals input might be
delayed
38
Dead Zone
39
Debouncing
40
Complications
• Ground Pin
• Connectivity
• Programming
Circuit
41
Division of Work
Tasks Primary Secondary
PCB Design Mohammed Jason
Component Specification and Jason Mohammed
Ordering
Analog Sitck and Button Calibration John Kenny
Bluetooth Connectivity Kenny Jason
Microcontroller Programming Kenny John
Hardware Assembly Everyone N/A
Battery Regulation Mohammed Jason
42
Budget/Bill of Materials
Parts Quantity Price ($)
MCU 4 4.50
Hall Effect 10 1.35
Joysticks
USB-C 5 6.32
Connection
Port
Push Buttons 20 0.90
Custom PCB 15 21.26
Rechargeable 3 10
Li-Po Battery
Addressable 15 7.45
LEDs
Programming 3 7
Circuit
Total 75 532.75
43