TinyUSB Library
TU_BIT
is only used within TinyUSB Library.
Symbol previews are coming soon...
Symbols
loading...
Files
loading...
Summary
Syntax
Arguments
Examples
References
Call Tree
Data Use
Class Tree
Override Tree
Implementations
Instances
Lifecycle
SourceVu
Raspberry Pi Pico SDK and Examples
TinyUSB Library
TU_BIT
TU_BIT macro
Syntax
Show:
Summary
Declaration
from
tusb_common.h:56
#define
TU_BIT
(
n
)
(
1UL
<
<
(
n
)
)
Arguments
Argument
n
Examples
References
from
examples
Code
Location
#define
TU_BIT
(
n
)
(
1UL
<
<
(
n
)
)
tusb_common.h:56
GAMEPAD_BUTTON_0
=
TU_BIT
(
0
)
,
hid.h:210
GAMEPAD_BUTTON_1
=
TU_BIT
(
1
)
,
hid.h:211
GAMEPAD_BUTTON_2
=
TU_BIT
(
2
)
,
hid.h:212
GAMEPAD_BUTTON_3
=
TU_BIT
(
3
)
,
hid.h:213
GAMEPAD_BUTTON_4
=
TU_BIT
(
4
)
,
hid.h:214
GAMEPAD_BUTTON_5
=
TU_BIT
(
5
)
,
hid.h:215
GAMEPAD_BUTTON_6
=
TU_BIT
(
6
)
,
hid.h:216
GAMEPAD_BUTTON_7
=
TU_BIT
(
7
)
,
hid.h:217
GAMEPAD_BUTTON_8
=
TU_BIT
(
8
)
,
hid.h:218
GAMEPAD_BUTTON_9
=
TU_BIT
(
9
)
,
hid.h:219
GAMEPAD_BUTTON_10
=
TU_BIT
(
10
)
,
hid.h:220
GAMEPAD_BUTTON_11
=
TU_BIT
(
11
)
,
hid.h:221
GAMEPAD_BUTTON_12
=
TU_BIT
(
12
)
,
hid.h:222
GAMEPAD_BUTTON_13
=
TU_BIT
(
13
)
,
hid.h:223
GAMEPAD_BUTTON_14
=
TU_BIT
(
14
)
,
hid.h:224
GAMEPAD_BUTTON_15
=
TU_BIT
(
15
)
,
hid.h:225
GAMEPAD_BUTTON_16
=
TU_BIT
(
16
)
,
hid.h:226
GAMEPAD_BUTTON_17
=
TU_BIT
(
17
)
,
hid.h:227
GAMEPAD_BUTTON_18
=
TU_BIT
(
18
)
,
hid.h:228
GAMEPAD_BUTTON_19
=
TU_BIT
(
19
)
,
hid.h:229
GAMEPAD_BUTTON_20
=
TU_BIT
(
20
)
,
hid.h:230
GAMEPAD_BUTTON_21
=
TU_BIT
(
21
)
,
hid.h:231
GAMEPAD_BUTTON_22
=
TU_BIT
(
22
)
,
hid.h:232
GAMEPAD_BUTTON_23
=
TU_BIT
(
23
)
,
hid.h:233
GAMEPAD_BUTTON_24
=
TU_BIT
(
24
)
,
hid.h:234
GAMEPAD_BUTTON_25
=
TU_BIT
(
25
)
,
hid.h:235
GAMEPAD_BUTTON_26
=
TU_BIT
(
26
)
,
hid.h:236
GAMEPAD_BUTTON_27
=
TU_BIT
(
27
)
,
hid.h:237
GAMEPAD_BUTTON_28
=
TU_BIT
(
28
)
,
hid.h:238
GAMEPAD_BUTTON_29
=
TU_BIT
(
29
)
,
hid.h:239
GAMEPAD_BUTTON_30
=
TU_BIT
(
30
)
,
hid.h:240
GAMEPAD_BUTTON_31
=
TU_BIT
(
31
)
,
hid.h:241
MOUSE_BUTTON_LEFT
=
TU_BIT
(
0
)
,
///< Left button
hid.h:319
MOUSE_BUTTON_RIGHT
=
TU_BIT
(
1
)
,
///< Right button
hid.h:320
MOUSE_BUTTON_MIDDLE
=
TU_BIT
(
2
)
,
///< Middle button
hid.h:321
MOUSE_BUTTON_BACKWARD
=
TU_BIT
(
3
)
,
///< Backward button,
hid.h:322
MOUSE_BUTTON_FORWARD
=
TU_BIT
(
4
)
,
///< Forward button,
hid.h:323
KEYBOARD_MODIFIER_LEFTCTRL
=
TU_BIT
(
0
)
,
///< Left Control
hid.h:345
KEYBOARD_MODIFIER_LEFTSHIFT
=
TU_BIT
(
1
)
,
///< Left Shift
hid.h:346
KEYBOARD_MODIFIER_LEFTALT
=
TU_BIT
(
2
)
,
///< Left Alt
hid.h:347
KEYBOARD_MODIFIER_LEFTGUI
=
TU_BIT
(
3
)
,
///< Left Window
hid.h:348
KEYBOARD_MODIFIER_RIGHTCTRL
=
TU_BIT
(
4
)
,
///< Right Control
hid.h:349
KEYBOARD_MODIFIER_RIGHTSHIFT
=
TU_BIT
(
5
)
,
///< Right Shift
hid.h:350
KEYBOARD_MODIFIER_RIGHTALT
=
TU_BIT
(
6
)
,
///< Right Alt
hid.h:351
KEYBOARD_MODIFIER_RIGHTGUI
=
TU_BIT
(
7
)
///< Right Window
hid.h:352
KEYBOARD_LED_NUMLOCK
=
TU_BIT
(
0
)
,
///< Num Lock LED
hid.h:357
KEYBOARD_LED_CAPSLOCK
=
TU_BIT
(
1
)
,
///< Caps Lock LED
hid.h:358
KEYBOARD_LED_SCROLLLOCK
=
TU_BIT
(
2
)
,
///< Scroll Lock LED
hid.h:359
KEYBOARD_LED_COMPOSE
=
TU_BIT
(
3
)
,
///< Composition Mode
hid.h:360
KEYBOARD_LED_KANA
=
TU_BIT
(
4
)
///< Kana mode
hid.h:361
TU_ATTR_ALWAYS_INLINE
static
inline
uint32_t
tu_bit_set
(
uint32_t
value
,
uint8_t
pos
)
{
return
value
|
TU_BIT
(
pos
)
;
}
tusb_common.h:145
TU_ATTR_ALWAYS_INLINE
static
inline
uint32_t
tu_bit_clear
(
uint32_t
value
,
uint8_t
pos
)
{
return
value
&
(
~
TU_BIT
(
pos
)
)
;
}
tusb_common.h:146
TU_ATTR_ALWAYS_INLINE
static
inline
bool
tu_bit_test
(
uint32_t
value
,
uint8_t
pos
)
{
return
(
value
&
TU_BIT
(
pos
)
)
?
true
:
false
;
}
tusb_common.h:147
9
,
TUSB_DESC_CONFIGURATION
,
U16_TO_U8S_LE
(
_total_len
)
,
_itfcount
,
config_num
,
_stridx
,
TU_BIT
(
7
)
|
_attribute
,
(
_power_ma
)
/
2
usbd.h:210
removing_hubs
|=
TU_BIT
(
dev_id
-
CFG_TUH_DEVICE_MAX
)
;
usbh.c:1231
removing_hubs
&=
~
TU_BIT
(
h_id
)
;
usbh.c:1258
Call Tree
from
examples
All items filtered out
All items filtered out
Data Use
from
examples
All items filtered out
All items filtered out
Class Tree
from
examples
All items filtered out
All items filtered out
Override Tree
from
examples
All items filtered out
All items filtered out
Implementations
from
examples
All items filtered out
All items filtered out
Instances
from
examples
Lifecycle
from
examples
All items filtered out
All items filtered out