SDL_hid_bus_type(3type)
π SDL_hid_bus_type π
okay bestie, welcome to the SDL_hid_bus_type(3type) page β it's a datatype from the SDL3 manual, filed under SDL3 DATATYPES, and it's genuinely one of the cutest little enums you'll ever meet. no cap.
β¨ NAME β¨
SDL_hid_bus_type β HID underlying bus types. that's it, that's the whole vibe. it's the enum that tells you which bus a HID device is riding in on. π
πΈ SYNOPSIS πΈ
so here's the whole thing, verbatim, no edits, we do not touch the code:
#include <SDL3/SDL_hidapi.h>
typedef enum SDL_hid_bus_type {
/** Unknown bus type */
SDL_HID_API_BUS_UNKNOWN = 0x00,
/** USB bus
Specifications:
https://usb.org/hid */
SDL_HID_API_BUS_USB = 0x01,
/** Bluetooth or Bluetooth LE bus
Specifications:
https://www.bluetooth.com/specifications/specs/human-interface-device-profile-1-1-1/
https://www.bluetooth.com/specifications/specs/hid-service-1-0/
https://www.bluetooth.com/specifications/specs/hid-over-gatt-profile-1-0/ */
SDL_HID_API_BUS_BLUETOOTH = 0x02,
/** I2C bus
Specifications:
https://docs.microsoft.com/previous-versions/windows/hardware/design/dn642101(v=vs.85) */
SDL_HID_API_BUS_I2C = 0x03,
/** SPI bus
Specifications:
https://www.microsoft.com/download/details.aspx?id=103325 */
SDL_HID_API_BUS_SPI = 0x04
} SDL_hid_bus_type;
π DESCRIPTION π
okay so listen. this enum is literally just a list of buses β as in, the physical-ish way your HID device is talking to your computer. it's giving "which road did you take to get here" energy. and there are exactly five (5) options, so let's go through them one by one, bestie, no skipping. π
π¦ the members π¦
SDL_HID_API_BUS_UNKNOWN = 0x00β unknown bus type. the mystery era. we do not know how this thing is connected and honestly? we're at peace with that. πSDL_HID_API_BUS_USB = 0x01β the USB bus. classic. iconic. plugged in like a good little peripheral. π
Specifications:
SDL_HID_API_BUS_BLUETOOTH = 0x02β the Bluetooth or Bluetooth LE bus. wireless, unbothered, thriving, no cables in sight. π¦β¨
Specifications:
https://www.bluetooth.com/specifications/specs/human-interface-device-profile-1-1-1/https://www.bluetooth.com/specifications/specs/hid-service-1-0/https://www.bluetooth.com/specifications/specs/hid-over-gatt-profile-1-0/
SDL_HID_API_BUS_I2C = 0x03β the I2C bus. tiny wires, big feelings, usually hiding inside your laptop somewhere being mysterious and low-power. π
Specifications:
SDL_HID_API_BUS_SPI = 0x04β the SPI bus. fast, chatty, four wires and a dream. also the last member in the enum, so no trailing comma situation, we respect the formatting. β
Specifications:
ngl, if you're pattern-matching on these values: they're0x00through0x04, in that order, andSDL_HID_API_BUS_SPIis the last one. write that down. π
π AVAILABILITY π
this enum is available since SDL 3.2.0. so if you're on anything older, bestie, it's simply not going to be there. upgrade era. π
π«Ά SEE ALSO π«Ά
(this page doesn't list any SEE ALSO references β so it's just us here. main character energy. β¨)
okay that's the whole page, you ate it, you understood it, periodt. π this little love letter was brought to you by Simple Directmedia Layer, version SDL 3.4.18, for SDL_hid_bus_type(3type) β mwah, bye bestie ππΈπ¦
π¦ where this page comes from
- fedora 43: SDL3-devel 3.4.18-1.fc43 Β· Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 OR MIT)
- fedora 43: SDL3-devel 3.4.18-1.fc43 Β· Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 OR MIT)
- fedora 44: SDL3-devel 3.4.18-1.fc44 Β· Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 OR MIT)
- fedora 44: SDL3-devel 3.4.18-1.fc44 Β· Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 OR MIT)
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms