hid_types/id/usage/
arcade.rs1use num_enum::{IntoPrimitive, TryFromPrimitive};
4
5use crate::Ident;
6
7#[expect(missing_docs)]
12#[derive(Clone, Copy, Debug, Eq, PartialEq, TryFromPrimitive, IntoPrimitive)]
13#[repr(u16)]
14pub enum KnownUsage {
15 Undefined = 0,
16 GeneralPurposeIoCard = 0x01,
17 CoinDoor = 0x02,
18 WatchdogTimer = 0x03,
19 GeneralPurposeAnalogInputState = 0x30,
21 GeneralPurposeDigitalInputState = 0x31,
22 GeneralPurposeOpticalInputState = 0x32,
23 GeneralPurposeDigitalOutputState = 0x33,
24 NumberOfCoinDoors = 0x34,
25 CoinDrawerDropCount = 0x35,
26 CoinDrawerStart = 0x36,
27 CoinDrawerService = 0x37,
28 CoinDrawerTilt = 0x38,
29 CoinDoorTest = 0x39,
30 CoinDoorLockout = 0x40,
32 WatchdogTimeout = 0x41,
33 WatchdogAction = 0x42,
34 WatchdogReboot = 0x43,
35 WatchdogRestart = 0x44,
36 AlarmInput = 0x45,
37 CoinDoorCounter = 0x46,
38 IoDirectionMapping = 0x47,
39 SetIoDirectionMapping = 0x48,
40 ExtendedOpticalInputState = 0x49,
41 PinPadInputState = 0x4A,
42 PinPadStatus = 0x4B,
43 PinPadOutput = 0x4C,
44 PinPadCommand = 0x4D,
45 }
47
48pub type Usage = Ident<KnownUsage, u16>;