Skip to content
Sean P. Harrington edited this page Feb 26, 2025 · 3 revisions

Aq+ Gamepad

by Sean P. Harrington

Updated 26 Feb 2025


Overview:

The Aq+ Gamepad is a modern game controller for Aquarius and Aquarius+ 8-bit Z80-based computers. It features either wired (Mini/Micro/MX expander required for original Aquarius) or wireless (Aquarius+) connectivity, and emulates the original Aquarius Hand Controller in a form-factor that is more comfortable and fun to use.

The system was developed using an ESP32-S3-DevKitC module as the microcontroller and BLE (Bluetooth Low Energy) as the wireless solution. It is configured using the Arduino Core, and uses the "ESP32-S3-Box" board profile. Additionally, BLE connectivity is coded using the ESP32-BLE-Gamepad library, which itself relies on the NimBLE-Arduino library. The RGB LED serves as a system status indicator and uses the Adafruit NeoPixel library. All libraries can be loaded through the Arduino Library Manager. The system also features a LiPo (lithium polymer) battery, with smart charging.

The system uses the Preferences library to save in non-volatile storage (NVS) the settings specific to the individual device, such as X, Y, & battery trim settings, serial number, unit name, etc. These settings will get removed if the Tools > Erase All Flash Before Sketch Upload option is enabled. So ensure that it is shown as DISABLED.

Features:

To-Do List:

  • Web/GUI interface for prefs & settings
  • Test for & recover from Bluetooth "slave" disconnections (Aq+ power cycle, Aq+ ESP32 reset)

Revisions

  • 0.5.0, 26 FEB 2025
  • 0.4.0, 24 FEB 2025
  • 0.3.0, 22 FEB 2025
  • 0.2.2, 21 FEB 2025
    • Fixed XY dead zone issues
    • Commented legacy code
    • Turned all main loop processes into funtions
    • Created TRIM variables for thumb stick
  • 0.2.1, 18 FEB 2025
    • Fixed NeoPixel error (logging was too verbose)
  • 0.2.0, 12 FEB 2025
    • Added 1+3+5 wired chord to AQ button
  • 0.1.9, 03 DEC 2024
    • Created state machine for LED/Battery
  • 0.1.8, 30 NOV 2024
    • Remapped GPIO pin assignments after PCB rework
  • 0.1.7, 19 NOV 2024
    • Added SettingsManagerESP32 to save persistent variables (changed to Preferences library)
  • 0.1.6, 17 NOV 2024
    • Added battery divider sense pin
  • 0.1.5, 17 NOV 2024
    • Switched back to GPIO rather than Shift Register
  • 0.1.4, 16 NOV 2024
    • Reworked analog angle calculations from Aq+ ESP32 code
    • Created buttonByte and thumbByte to combine into dataByte
  • 0.1.3, 11 NOV 2024
    • Shift register implemented for wired connections (unsuccessful)
    • Turn button components into arrays and loop
  • 0.1.2, 09 NOV 2024
    • Button alignment with Xbox mappings
    • Thumbstick scaling fixed
    • Buttons transitioned to single-pin (from matrix)
  • 0.1.1, 08 NOV 2024
    • Button matrix (unsuccessful)
  • 0.1.0, 07 NOV 2024
    • Initial version, using Gamepad example (four buttons)
    • Installed Arduino bootloader
    • Identified compatible Board profile (ESP32-S3-Box)

Links & References:

Clone this wiki locally