INSTALLATION & C++
Start using Vdevice.
Install the driver, then create and control virtual USB devices from your application.
Windows 10 / 11 x64 · C++17 · Administrator rights
Inside your company ZIP
Download the ZIP after purchase and extract it before using the files. The package includes everything needed to install the driver and build the C++ example.
| File | How to use it |
|---|---|
Installers/VdeviceReleaseSetupConsole.exe | Console installer for /install and /uninstall, including integration into your own setup. |
Installers/VdeviceReleaseSetup.exe | Graphical installer with installation state, device information and diagnostics. |
SDK/Vdevice.hSDK/Vdevice.cpp | The complete C++ SDK. Include the header and compile the CPP once with your application. |
VdeviceActivation.exe | Ready-to-use console activation tool. Enter your key without writing or compiling code. |
activation.cpp | Small SDK activation example with a fictional key. Its helper returns an empty string on success or a detailed English error. |
CMakeLists.txt | Builds activation.cpp together with the SDK, with C++17, x64 and the administrator manifest configured. |
README.mdLICENSE-SDK | Package instructions and SDK licensing terms. |
SHA256SUMS.txt | Reference SHA-256 hashes for checking the packaged files. |
The driver and verification agent are embedded in the installers. No separate SYS installation or SDK DLL is needed. Use the installers, activation tool and SDK from the same package.
1 Install the driver
Choose either installer below. Both install the same Release driver and its verification agent.
Console installer
- Open PowerShell as administrator.
- Go to the extracted ZIP folder and run:
.\Installers\VdeviceReleaseSetupConsole.exe /installRead the result in the console. Restart Windows if requested. To remove the driver, use VdeviceReleaseSetupConsole.exe /uninstall from the same folder.
UI installer
- Open
Installers/VdeviceReleaseSetup.exeand accept the administrator prompt. - Choose Install / reinstall and wait for completion.
- If setup asks for a restart, use its Restart button or restart Windows normally.
Use this same application to check the installation state, inspect devices, run diagnostics or uninstall.
Use the Vdevice package and key for this virtual USB edition. Installing the driver and activating your key are separate steps.
2 Verifications
Authorize the installed driver with your customer key. Choose the SDK method for your software, or use the supplied EXE for a quick check without compiling anything.
C++ SDK activation
The ZIP includes this activation.cpp. Replace the fictional key with your customer key, then compile it with the supplied CMake project using the build commands in step 3.
#include "SDK/Vdevice.h"
#include <iostream>
// An empty string means success; otherwise the string explains the failure.
std::string ActivateDriver(const std::string& key) {
const auto result = Vdevice::Verification(key);
if (result) return {};
return "Stage: " + result.stage + "; reason: " + result.reason + "; " +
result.message + " (Windows error " + std::to_string(result.error) + ")";
}
int main() {
const std::string error = ActivateDriver("YOUR-VDEVICE-CUSTOMER-KEY");
std::cout << (error.empty() ? "Driver activated." : "Activation failed: " + error) << '\n';
return error.empty() ? 0 : 1;
}
Verification(key) returns activated, error, stage, reason and an English message. Test the result as a boolean: success means the driver confirmed activation. Otherwise, keep all diagnostic fields to identify the failed operation.
Activation EXE
- Open
VdeviceActivation.exefrom the extracted ZIP and accept the administrator prompt. - Paste your key with Ctrl+V, then press Enter.
- Read the activation result. On failure, the console shows Stage, Reason and Detail, followed by local diagnostics.
- Press Enter again to close the console.
You can also launch the interactive tool from PowerShell in the extracted folder:
.\VdeviceActivation.exeFor automation, use VdeviceActivation.exe "YOUR-CUSTOMER-ACTIVATION-KEY". Argument mode exits without waiting: exit code 0 means success; a nonzero code reports an error. Use --help for usage, or --diagnose for a local read-only check without activation.
Both methods require Internet access and administrator rights. Authorization belongs to the currently loaded driver, so other applications can use it afterwards. Verify again after a Windows restart or driver reload. Your own application can simply call Verification() once at startup, as in the complete example below; the separate activation EXE is optional.
3 Create, control, remove
Replace activation.cpp in the company ZIP with this complete virtual HID mouse example. Keep the supplied SDK and CMake project in place. It defines the exact USB/HID descriptors, creates the device, sends a neutral report without movement and removes the device.
Windows configures new devices asynchronously. Wait for the virtual mouse to appear before pressing Enter. The VID/PID values in this development example are placeholders; choose appropriate identifiers for your distributed product.
#include "SDK/Vdevice.h"
#include <iostream>
#include <utility>
namespace MouseExample {
Vdevice::Descriptor Text(std::uint32_t index, const std::u16string& text) {
Vdevice::Descriptor result;
result.index = index; result.language = 0x0409;
result.data = {static_cast<std::uint8_t>(2 + 2 * text.size()), 3};
for (const auto unit : text) {
result.data.push_back(static_cast<std::uint8_t>(unit));
result.data.push_back(static_cast<std::uint8_t>(unit >> 8));
}
return result;
}
Vdevice::Device_Config Make_Config(const std::string& serial) {
Vdevice::Device_Config config;
Vdevice::Descriptor device;
// USB 2.0, class on interface, 64-byte EP0, VID FFFF, PID 0002, revision 1.00.
// Strings 1/2/3 are manufacturer/product/serial; exactly one configuration.
device.data = {18,1,0x00,0x02,0,0,0,64,0xFF,0xFF,2,0,0,1,1,2,3,1};
Vdevice::Descriptor report;
report.kind = Vdevice::Descriptor_Kind::Report;
// Five buttons + padding; signed 16-bit X/Y; signed 8-bit wheel and AC Pan.
report.data = {
0x05,0x01,0x09,0x02,0xA1,0x01,0x09,0x01,0xA1,0x00,
0x05,0x09,0x19,0x01,0x29,0x05,0x15,0x00,0x25,0x01,
0x95,0x05,0x75,0x01,0x81,0x02,
0x95,0x01,0x75,0x03,0x81,0x01,
0x05,0x01,0x09,0x30,0x09,0x31,0x16,0x00,0x80,0x26,0xFF,0x7F,
0x75,0x10,0x95,0x02,0x81,0x06,
0x09,0x38,0x15,0x81,0x25,0x7F,0x75,0x08,0x95,0x01,0x81,0x06,
0x05,0x0C,0x0A,0x38,0x02,0x95,0x01,0x81,0x06,0xC0,0xC0
};
Vdevice::Descriptor configuration;
configuration.data = {
9,2,34,0,1,1,0,0x80,50, // 34 total bytes, 100 mA, bus powered.
9,4,0,0,1,3,0,0,0, // Interface 0, HID class.
9,0x21,0x11,0x01,0,1,0x22,
static_cast<std::uint8_t>(report.data.size()),
static_cast<std::uint8_t>(report.data.size() >> 8),
7,5,0x81,3,7,0,1 // Interrupt IN, 1 ms descriptor interval.
};
Vdevice::Descriptor languages; languages.data = {4,3,0x09,0x04};
config.descriptors = {
std::move(device),std::move(configuration),std::move(report),std::move(languages),
Text(1,u"Vdevice examples"),Text(2,u"Raw USB mouse"),Text(3,std::u16string(serial.begin(),serial.end()))
};
return config;
}
}
int main() {
const auto activation = Vdevice::Verification("YOUR-CUSTOMER-KEY");
if (!activation) {
std::cerr << activation.stage << " / " << activation.reason << ": "
<< activation.message << " (Windows error "
<< activation.error << ")\n";
return 1;
}
const auto config = MouseExample::Make_Config("DOCS-MOUSE-001");
const auto valid = Vdevice::Validate_Device(config);
if (!valid) {
std::cerr << valid.message << " (Windows error " << valid.error << ")\n";
return 1;
}
auto device = Vdevice::Create_Device(config);
if (!device) {
std::cerr << device.message << " (Windows error " << device.error << ")\n";
return 1;
}
std::cout << "Virtual mouse created. Wait for Windows to configure it,\n"
"then press Enter to send a neutral report.\n";
std::cin.get();
// Exact report layout: buttons, 16-bit X/Y, wheel and horizontal pan.
// All-zero input releases buttons and causes no movement.
const auto sent = Vdevice::Send_Input(device, 0x81, {0,0,0,0,0,0,0});
if (!sent) {
std::cerr << sent.message << " (Windows error " << sent.error << ")\n";
return 1;
}
std::cout << "Press Enter to remove this virtual device.\n";
std::cin.get();
const auto removed = Vdevice::Delete_Device(device);
if (!removed) {
std::cerr << removed.message << " (Windows error " << removed.error << ")\n";
return 1;
}
return 0;
}
Keep the move-only Device alive while the virtual device is in use. Validate_Device() is an offline configuration check. Create_Device() creates the device; it does not guarantee Windows has finished enumeration. Inspect Get_Info().devices for configuration state and counters. Successful Send_Input() means the driver accepted the report, not that a host application consumed it.
Build and run
With Visual Studio 2022 C++ tools and CMake installed, these commands build either the original activation-only example or the replacement SDK example. Run them from the extracted folder:
cmake -S . -B build -G "Visual Studio 17 2022" -A x64
cmake --build build --config ReleaseOpen build/Release/activation.exe and accept the administrator prompt. This is the program you just compiled, separate from the ready-made VdeviceActivation.exe in the ZIP. Keep the example open while testing; close it to end the session.
In your own application, compile Vdevice.cpp alongside your source and keep the compiler, linker and elevation settings from the supplied CMake project. Including the header alone is not enough. Keep access keys out of public source code.
Useful SDK calls
All public application operations in the supplied SDK belong to the Vdevice namespace.
| Call | What it does and returns |
|---|---|
Verification(key) | Authorize the loaded driver online. Returns Verification_Result with activation and detailed error fields. |
Validate_Device(config) | Check USB/HID descriptors, endpoints and rules offline. Returns Result; no driver activation or network call. |
Get_Info() | Return capabilities, license state and a snapshot of this SDK session?s devices and their counters. |
Create_Device(config) | Create a virtual USB device. Returns a move-only Device with its identity or an error. Keep it alive while in use. |
Delete_Device(device) | Remove the device and release its ownership. Returns Result. Device destruction also performs cleanup. |
Send_Input(device, endpoint, data) | Queue a report for an IN endpoint declared by the descriptors. Returns Result. Match the declared report size and format. |
Get_Output(timeout = Infinite) | Receive host output, delegated controls or device-state events as Output. Check timed_out and the result error. |
Respond_Output(output, data = {}, stall = false) | Answer a delegated control request with data or a stall. Returns Result. Only reply to requests owned by this session. |
Configure raw USB descriptors, strings, interfaces, endpoints and report layouts with Device_Config. Use Control_Rule for supported fixed responses, or delegate supported controls and answer them with Respond_Output(). Compatibility depends on the descriptors, protocol and Windows stack; this framework does not emulate every hardware bus.
If something fails
Read the complete error printed by the example. A Windows error number alone does not identify the cause.
- Driver or verification agent missing
- Run the matching installer again and restart if requested. Use the driver, SDK and activation tools from the same package.
- Access denied / error 5
- Run as administrator, then check the reported stage, reason and message.
- Network failure or blocked key
- Verification needs Internet access. A blocked key cannot activate a new driver session; contact titancsa on Discord.
- Device does not enumerate or accept reports
- Check Validate_Device(), exact descriptors, endpoint and report size. Inspect Get_Info() and Windows Device Manager. Creation and host configuration are separate stages.
To check activation without writing code, open VdeviceActivation.exe as administrator, paste your key and press Enter. It reports the full result.
Activation and compatibility
Release has no demo timer. Activation lasts until the driver unloads or reloads, or Windows restarts. Call Verification() again for the new driver session. Closing your app does not cancel activation.
Internet is used during verification, not for each input report. No TPM or hardware fingerprint is required. Blocking a key prevents future verification; a driver already authorized continues until reload or restart.
Test your virtual device protocol, Windows version and applications before deployment. Microsoft signing does not guarantee compatibility with every device or game.