Commit Graph

9 Commits

Author SHA1 Message Date
portersky 176a563400 docs: phase 4 uses userspace IOHIDUserDevice, not DriverKit
macOS has a user-space virtual HID device API (IOHIDUserDevice,
available since 10.15). No DriverKit extension is needed: the app
creates one virtual device per controller with our report descriptor.

Development works with SIP disabled and no Apple account (verified on
macOS 15.7 that creation fails with SIP enabled; dji-fpv3 and
ControlLab document the SIP-disabled dev workflow). Distribution with
SIP enabled requires the com.apple.developer.hid.virtual.device
entitlement from a paid Developer Program membership.

Co-Authored-By: qwen3.8-27b@q3_k_xl: researched virtual HID options
2026-08-29 15:49:30 +02:00
portersky fafca4c265 feat: add Xbox One HID report layout and mapping
Phase 4 foundation, independent of the presentation mechanism:

- hid/hid_report.hpp: standard Xbox One report layout (64-byte input:
  buttons/guide/triggers/sticks; 64-byte output: motors), the HID
  report descriptor, and GIP state to report mapping.
- make_input_report(): remaps GIP button bits to the standard Xbox
  bitmask, scales 10-bit triggers to 8-bit, sticks pass through.
- parse_output_report(): extracts motor intensities from output
  reports for the rumble relay; malformed reports stop the motors.
- test_hid: unit tests for the mapping, scaling, and descriptor.

Report packing verified with a descriptor walker: input and output
are exactly 64 bytes each. Next step is presentation via DriverKit,
which needs a Developer ID with the DriverKit entitlement.

Co-Authored-By: qwen3.8-27b@q3_k_xl: implemented HID report layer
2026-08-29 15:39:03 +02:00
portersky 73c026218d docs: mark rumble TX verified on hardware
Rumble works from the Rumble button in the app; Phase 3 is complete.
Next up is Phase 4 (virtual HID gamepad).

Co-Authored-By: qwen3.8-27b@q3_k_xl: marked rumble verified
2026-08-29 15:22:16 +02:00
portersky 490b8af585 docs: mark rumble TX as implemented
Update PLAN.md and README.md current status: host to controller TX
(rumble) is implemented and pending hardware confirmation; the dongle
LED is driven at chip level, so no data path LED work remains.

Co-Authored-By: qwen3.8-27b@q3_k_xl: updated status docs
2026-08-29 15:19:45 +02:00
portersky 1bca6048a5 docs: bring PLAN.md in line with style guide
Replace em dashes with colons throughout, wrap prose and list lines at
80 columns (Goal, Phase 4 options, Known Challenges), refresh the
current status section now that pairing and the RX data path are done,
and add src/cli to the directory layout. Table alignment was also
normalized as a side effect of the file rewrite.

Co-Authored-By: qwen3.8-27b@q3_k_xl: reformatted PLAN.md per style guide
2026-08-29 14:30:02 +02:00
portersky baebcb73c2 fix: use upstream dongle firmware
Use the common xow_dongle.bin image from the upstream driver for the
GUI session instead of selecting the older 02E6-specific image. Update
the firmware download script and plan to document the same upstream flow.
Keep the extended RX diagnostics used to inspect controller discovery.

Co-Authored-By: openai/gpt-5.6-luna: traced firmware and pairing behavior
2026-08-29 13:36:54 +02:00
portersky dae51f085b feat: pair controllers and show them in the app
Port the MT76 client functions (send_wlan, associate_client,
pair_client, set_client_key, remove_client) and wire the RX dispatch
into the session: EP IN frames are parsed, ASSOC_REQ associates a
controller (WCID plus chip programming), PAIR_REQ replies with
PAIR_RESP, and DISASSOC or client-lost removes it. The C API exposes
connected controllers and the app lists them by MAC. Bumps
xone_cli/xone_app to C++23: they were falling back to the default
standard once mt76.hpp started using std::span. Adds a unit test pinning
the WCID regions, the 32-byte rxwi, and the new frame control values.

Co-Authored-By: qwen3.8-27b@q2_k_xl: client functions, RX dispatch, GUI list
2026-08-29 13:36:32 +02:00
portersky 95e958a7e8 docs: add AGENTS.md coding conventions
Adapt the refix AGENTS.md to this project: build commands, module
layout, C++/Swift/C-bridge style rules, and commit guidelines. C++
headers use .hpp and C headers use .h; the PLAN.md port table is
updated to match.

Co-Authored-By: qwen (qwen/qwen3.8-27b@q2_k_xl): wrote coding conventions
2026-08-17 14:18:06 +02:00
portersky 78f042ab84 Initial commit 2026-08-04 17:12:54 +02:00