Skip to content

Lib viiper - #13

Merged
Alia5 merged 10 commits into
mainfrom
libVIIPER
Apr 28, 2026
Merged

Lib viiper#13
Alia5 merged 10 commits into
mainfrom
libVIIPER

Conversation

@Alia5

@Alia5 Alia5 commented Apr 28, 2026

Copy link
Copy Markdown
Owner

No description provided.

Copilot AI review requested due to automatic review settings April 28, 2026 17:34
@codecov

codecov Bot commented Apr 28, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 0% with 531 lines in your changes missing coverage. Please review.
✅ Project coverage is 38.21%. Comparing base (ee448d8) to head (6a4d1c4).
⚠️ Report is 10 commits behind head on main.

Files with missing lines Patch % Lines
lib/viiper/dualshock4.go 0.00% 112 Missing ⚠️
lib/viiper/xbox360.go 0.00% 104 Missing ⚠️
lib/viiper/keyboard.go 0.00% 97 Missing ⚠️
lib/viiper/mouse.go 0.00% 74 Missing ⚠️
lib/viiper/server.go 0.00% 62 Missing ⚠️
lib/viiper/postbuild/main.go 0.00% 38 Missing ⚠️
lib/viiper/bus.go 0.00% 32 Missing ⚠️
lib/viiper/viiper.go 0.00% 12 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main      #13      +/-   ##
==========================================
- Coverage   42.93%   38.21%   -4.73%     
==========================================
  Files          63       71       +8     
  Lines        4297     4828     +531     
==========================================
  Hits         1845     1845              
- Misses       2216     2747     +531     
  Partials      236      236              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR introduces libVIIPER, a CGO-based shared library build of VIIPER with a C ABI for embedding the USB/USBIP stack into other applications, alongside updated docs, build tooling, and examples.

Changes:

  • Add libVIIPER C-shared build target (DLL/SO), version resources, and a postbuild step to inject exported-function docs into the generated header.
  • Implement a C-exported API for server/bus lifecycle and virtual devices (Xbox360, DualShock4, keyboard, mouse) including optional localhost auto-attach and output callbacks.
  • Update documentation site/nav and examples (C and C#), and bump C# generator/examples to newer .NET target.

Reviewed changes

Copilot reviewed 35 out of 35 changed files in this pull request and generated 28 comments.

Show a summary per file
File Description
versioninfo.json Update copyright year range for executable metadata.
scripts/install.ps1 Change Windows USBIP driver detection/install logic to versioned installer flow.
mkdocs.yml Update docs navigation and MkDocs theme config (currently broken indentation).
lib/viiper/viiper.go Core types/helpers for c-shared package (currently missing cgo preamble for import "C").
lib/viiper/server.go Exported USB server lifecycle + log callback plumbing.
lib/viiper/bus.go Exported bus create/remove functions for libVIIPER.
lib/viiper/xbox360.go Exported Xbox 360 device API + rumble callback.
lib/viiper/dualshock4.go Exported DualShock 4 device API + output callback.
lib/viiper/keyboard.go Exported HID keyboard API + LED callback.
lib/viiper/mouse.go Exported HID mouse API.
lib/viiper/versioninfo.json Windows resource metadata for libVIIPER DLL.
lib/viiper/postbuild/main.go Postbuild tool that injects Go export comments into generated C header docs.
internal/server/api/handler/bus_create.go Minor comment cleanup.
internal/codegen/generator/csharp/project.go Update generated C# client TargetFramework.
examples/libVIIPER/C/CMakeLists.txt Add C example build (currently has incorrect dist path and likely missing libm link).
examples/libVIIPER/C/main.c Add C example usage of libVIIPER (currently not portable due to _sleep and has uintptr_t printf issue).
examples/libVIIPER/csharp/libVIIPER_example.csproj Add C# example project consuming libVIIPER artifacts.
examples/libVIIPER/csharp/Program.cs Add C# P/Invoke example for libVIIPER.
examples/libVIIPER/csharp/.gitignore Ignore build outputs for new example.
examples/csharp/virtual_x360_pad/VirtualX360Pad.csproj Bump TargetFramework.
examples/csharp/virtual_mouse/VirtualMouse.csproj Bump TargetFramework.
examples/csharp/virtual_keyboard/VirtualKeyboard.csproj Bump TargetFramework.
docs/libviiper/overview.md Add libVIIPER overview docs and examples.
docs/index.md Update landing page to present server vs libVIIPER options.
docs/getting-started/installation.md Split installation docs by “VIIPER Server” vs “libVIIPER”.
docs/devices/xbox360.md Add libVIIPER API section (currently contains ABI/constant-name mismatches).
docs/devices/dualshock4.md Add libVIIPER API section.
docs/devices/keyboard.md Add libVIIPER API section.
docs/devices/mouse.md Add libVIIPER API section (currently constant-name mismatches).
docs/clients/csharp.md Update stated .NET target.
README.md Update top-level readme to include libVIIPER and new FAQ wording (typos present).
Makefile Add libVIIPER build target and resource cleanup paths.
.vscode/settings.json Set CGO_ENABLED=1 for Go tools in VS Code.
.github/workflows/generate-changelog.yml Minor cleanup in changelog workflow script block.
.github/scripts/generate-changelog.sh Remove changelog title line from generated output.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread lib/viiper/viiper.go
Comment thread examples/libVIIPER/csharp/Program.cs Outdated
Comment thread lib/viiper/xbox360.go
Comment thread lib/viiper/mouse.go
Comment thread README.md Outdated
Comment thread lib/viiper/server.go
Comment thread lib/viiper/xbox360.go
Comment thread examples/libVIIPER/C/main.c
Comment thread lib/viiper/postbuild/main.go
Comment thread docs/devices/xbox360.md Outdated
@Alia5
Alia5 force-pushed the libVIIPER branch 2 times, most recently from 6a6d797 to 22269c3 Compare April 28, 2026 18:03
@Alia5
Alia5 merged commit feb16d4 into main Apr 28, 2026
13 of 14 checks passed
@Alia5
Alia5 deleted the libVIIPER branch April 28, 2026 18:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants