2023-12-23 20:39:58 +00:00
# chuniio-yubideck
ChuniIO driver for YubiDeck FW 3.0.
Thanks to:
- [hlcm0 ](https://github.com/hlcm0/yubideck-io-firmware/blob/main/code/pico_yubideck_emu/report.h ) and [4yn ](https://github.com/4yn/slidershim/blob/main/src-slider_io/src/device/hid.rs#L257 )
for YubiDeck protocol information
2024-01-02 12:13:59 +00:00
- one_3 for testing
2023-12-23 20:39:58 +00:00
## Configuration
segatools.ini
```ini
[chuniio]
;; For Chunithm NEW or newer
path32=chuniio_yubideck_chusan.dll
path64=chuniio_yubideck_amdaemon.dll
;; For CHUNITHM PARADISE and older
path=chuniio_yubideck.dll
[io3]
test=0x31
service=0x32
coin=0x33
```
## USB Protocol
USB device: `1973:2001` , interface 0
- Endpoint IN Interrupt (0x81)
- Data length: 45 bytes
2024-01-02 12:13:59 +00:00
- `data[0]` : bits 0-5: beam {2, 1, 4, 3, 6, 5}
2023-12-23 20:39:58 +00:00
- `data[1]` : bits 0-2 for the 3 buttons (1 = pressed)
2024-01-02 12:13:59 +00:00
- `data[2..34]` : pressure of touch sensor 1-32 (counting from top -> bottom, left -> right)
2023-12-23 20:39:58 +00:00
- `data[34]` : Card type
- 0: No card
- 1: MIFARE Classic
- 2: FeliCa
- `data[35..45]` : Card IDm/Access Code
- Endpoint OUT Interrupt (0x02)
- Data length: 61 bytes
- `data[0]` : Packet type
- Packet type 1:
2024-01-02 12:13:59 +00:00
- `data[1..61]` : Slider LED for the first 20 sensors, GBR
2023-12-23 20:39:58 +00:00
- Packet type 2:
2024-01-02 12:13:59 +00:00
- `data[1..34]` : Slider LED for the last 11 sensors, GBR
2023-12-23 20:39:58 +00:00
- `data[34..37]` : Left air LED, RGB
- `data[37..40]` : Right air LED, RGB
- `data[40..43]` : Card reader LED, RGB
- `data[43..61]` : Empty padding
## Build instructions
```shell
# For CHUNITHM NEW
cargo build --features chusan --target i686-pc-windows-msvc --release
cargo build --features chusan --target x86_64-pc-windows-msvc --release
cp target/i686-pc-windows-msvc/release/chuniio_yubideck.dll chuniio_yubideck_chusan.dll
cp target/x86_64-pc-windows-msvc/release/chuniio_yubideck.dll chuniio_yubideck_amdaemon.dll
# For CHUNITHM
cargo build --target i686-pc-windows-msvc --release
cp target/i686-pc-windows-msvc/release/chuniio_yubideck.dll .
```