TRIKILibrary 0.1.0
dotnet add package TRIKILibrary --version 0.1.0
NuGet\Install-Package TRIKILibrary -Version 0.1.0
<PackageReference Include="TRIKILibrary" Version="0.1.0" />
<PackageVersion Include="TRIKILibrary" Version="0.1.0" />
<PackageReference Include="TRIKILibrary" />
paket add TRIKILibrary --version 0.1.0
#r "nuget: TRIKILibrary, 0.1.0"
#:package TRIKILibrary@0.1.0
#addin nuget:?package=TRIKILibrary&version=0.1.0
#tool nuget:?package=TRIKILibrary&version=0.1.0
TRIKI Library
A C# (.NET) library for the integrating TRIKI motion controller (made by Caps Apps) into your projects.
This library is still in development. Some things may change slightly.
What is TRIKI?
TRIKI is a Bluetooth Low Energy (BLE) motion controller that has the shape and size of a bottle cap. It is produced by Caps Apps (also known as HOPX) and sold by 'Żabka', a convenience store franchise.
It was designed to be used in mini-games which are on the store's loyalty app.
Why I made this library
I wanted to make this library to give everyone a way to integrate this niche controller into their own games, experiments and other C# projects.
Features
- Scan for TRIKI controllers
- Connect to TRIKI controller
- Get battery level
- Get FW version
- Get IMU data from the controller
- Get state of the built-in button
- Control built-in LED
Platforms
For now, this library only works on Windows.
Installation
dotnet add package TRIKILibrary
Usage
// Import the library
using TRIKILibrary;
// Scan for TRIKI controllers
TRIKIScanner scanner = new TRIKIScanner();
await scanner.ScanAsync();
List<TRIKIDevice> devices = scanner.ScannedDevices;
devices[0].name; // Get device name
devices[0].address; // Get device BT address
// Connect to the controller
TRIKIController controller = new TRIKIController(devices[0]);
await controller.ConnectAsync();
controller.IsConnected; // Check if device is connected
controller.BatteryLevel; // Get battery level
device.FirmwareVersion; // Get FW version
controller.SpinX; // Get X Spin
controller.SpinY; // Get Y Spin
controller.TurnZ; // Get Z Turn
controller.TiltX; // Get X Tilt
controller.TiltY; // Get Y Tilt
controller.FlipZ; // Get Z Flip
controller.ButtonPressed; // Check if built-in button is pressed
// Turn on LED
await controller.ToggleLedAsync(true);
// Turn off LED
await controller.ToggleLedAsync(false);
// Loop
while (controller.IsConnected)
{
// Do stuff
}
// IMPORTANT: disconnect from the controller when you're done with it!
await controller.DisconnectAsync();
Examples can be found here.
Credits
Library made by Woofter_Wolf
Special thanks to Wojciech "Koksny" Górny for doing the hard work of documenting this device (look here for communication documentation): Link
Copyright
"TRIKI" and "Żabka" are trademarks of Żabka Polska sp. z o.o. "HOPX" is a trademark of Caps Apps sp. z o.o.
This library is an independent, open-source project. It is NOT affiliated, endorsed or sponsored by these companies. This library ships with no software, images or any assets belonging to these companies.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0-windows10.0.19041 is compatible. |
-
net10.0-windows10.0.19041
- InTheHand.BluetoothLE (>= 4.0.44)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 0.1.0 | 121 | 7/8/2026 |