libnx  v4.8.0
hidsys.h
Go to the documentation of this file.
1 /**
2  * @file hidsys.h
3  * @brief hid:sys service IPC wrapper.
4  * @author exelix, yellows8, ndeadly
5  */
6 #pragma once
7 #include "../types.h"
8 #include "../kernel/event.h"
9 #include "../services/hid.h"
10 #include "../services/btdrv_types.h"
11 #include "../sf/service.h"
12 
13 /// Selects what button to map to.
14 typedef enum {
19  HidcfgDigitalButtonAssignment_StickL = 4, ///< Left Stick Button
20  HidcfgDigitalButtonAssignment_StickR = 5, ///< Right Stick Button
25  HidcfgDigitalButtonAssignment_Select = 10, ///< Select / Minus
26  HidcfgDigitalButtonAssignment_Start = 11, ///< Start / Plus
31  HidcfgDigitalButtonAssignment_LeftSL = 16, ///< SL on Left controller.
32  HidcfgDigitalButtonAssignment_LeftSR = 17, ///< SR on Left controller.
33  HidcfgDigitalButtonAssignment_RightSL = 18, ///< SL on Right controller.
34  HidcfgDigitalButtonAssignment_RightSR = 19, ///< SR on Right controller.
37  HidcfgDigitalButtonAssignment_Invalid = 22, ///< Invalid / Disabled
39 
40 /// AnalogStickRotation
41 typedef enum {
46 
47 /// UniquePadType
48 typedef enum {
49  HidsysUniquePadType_Embedded = 0, ///< Embedded
50  HidsysUniquePadType_FullKeyController = 1, ///< FullKeyController
51  HidsysUniquePadType_RightController = 2, ///< RightController
52  HidsysUniquePadType_LeftController = 3, ///< LeftController
53  HidsysUniquePadType_DebugPadController = 4, ///< DebugPadController
55 
56 /// UniquePadId for a controller.
57 typedef struct {
58  u64 id; ///< UniquePadId
60 
61 /// UniquePadSerialNumber
62 typedef struct {
63  char serial_number[0x10]; ///< SerialNumber
65 
66 /// Mini Cycle struct for \ref HidsysNotificationLedPattern.
67 typedef struct {
68  u8 ledIntensity; ///< Mini Cycle X LED Intensity.
69  u8 transitionSteps; ///< Fading Transition Steps to Mini Cycle X (Uses PWM). Value 0x0: Instant. Each step duration is based on HidsysNotificationLedPattern::baseMiniCycleDuration.
70  u8 finalStepDuration; ///< Final Step Duration Multiplier of Mini Cycle X. Value 0x0: 12.5ms, 0x1 - xF: 1x - 15x. Value is a Multiplier of HidsysNotificationLedPattern::baseMiniCycleDuration.
71  u8 pad;
73 
74 /// Structure for \ref hidsysSetNotificationLedPattern.
75 /// See also: https://switchbrew.org/wiki/HID_services#NotificationLedPattern
76 /// Only the low 4bits of each used byte in this struct is used.
77 typedef struct {
78  u8 baseMiniCycleDuration; ///< Mini Cycle Base Duration. Value 0x1-0xF: 12.5ms - 187.5ms. Value 0x0 = 0ms/OFF.
79  u8 totalMiniCycles; ///< Number of Mini Cycles + 1. Value 0x0-0xF: 1 - 16 mini cycles.
80  u8 totalFullCycles; ///< Number of Full Cycles. Value 0x1-0xF: 1 - 15 full cycles. Value 0x0 is repeat forever, but if baseMiniCycleDuration is set to 0x0, it does the 1st Mini Cycle with a 12.5ms step duration and then the LED stays on with startIntensity.
81  u8 startIntensity; ///< LED Start Intensity. Value 0x0=0% - 0xF=100%.
82 
83  HidsysNotificationLedPatternCycle miniCycles[16]; ///< Mini Cycles
84 
85  u8 unk_x44[0x2]; ///< Unknown
86  u8 pad_x46[0x2]; ///< Padding
88 
89 /// ButtonConfigEmbedded
90 typedef struct {
91  u8 unk_x0[0x2C8];
93 
94 /// ButtonConfigFull
95 typedef struct {
96  u8 unk_x0[0x2C8];
98 
99 /// ButtonConfigLeft
100 typedef struct {
101  u8 unk_x0[0x1C8];
103 
104 /// ButtonConfigRight
105 typedef struct {
106  u8 unk_x0[0x1A0];
108 
109 /// AnalogStickAssignment
110 typedef struct {
111  u32 rotation; ///< \ref HidcfgAnalogStickRotation
112  u8 is_paired_stick_assigned; ///< IsPairedStickAssigned
113  u8 reserved[3]; ///< Reserved
115 
116 /// ButtonConfigEmbedded
117 typedef struct {
118  u32 hardware_button_left; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonLeft
119  u32 hardware_button_up; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonUp
120  u32 hardware_button_right; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonRight
121  u32 hardware_button_down; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonDown
122  u32 hardware_button_a; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonA
123  u32 hardware_button_b; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonB
124  u32 hardware_button_x; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonX
125  u32 hardware_button_y; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonY
126  u32 hardware_button_stick_l; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonStickL
127  u32 hardware_button_stick_r; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonStickR
128  u32 hardware_button_l; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonL
129  u32 hardware_button_r; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonR
130  u32 hardware_button_zl; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonZL
131  u32 hardware_button_zr; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonZR
132  u32 hardware_button_select; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonSelect
133  u32 hardware_button_start; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonStart
134  u32 hardware_button_capture; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonCapture
138 
139 /// ButtonConfigFull
140 typedef struct {
141  u32 hardware_button_left; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonLeft
142  u32 hardware_button_up; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonUp
143  u32 hardware_button_right; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonRight
144  u32 hardware_button_down; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonDown
145  u32 hardware_button_a; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonA
146  u32 hardware_button_b; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonB
147  u32 hardware_button_x; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonX
148  u32 hardware_button_y; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonY
149  u32 hardware_button_stick_l; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonStickL
150  u32 hardware_button_stick_r; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonStickR
151  u32 hardware_button_l; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonL
152  u32 hardware_button_r; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonR
153  u32 hardware_button_zl; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonZL
154  u32 hardware_button_zr; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonZR
155  u32 hardware_button_select; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonSelect
156  u32 hardware_button_start; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonStart
157  u32 hardware_button_capture; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonCapture
161 
162 /// ButtonConfigLeft
163 typedef struct {
164  u32 hardware_button_left; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonLeft
165  u32 hardware_button_up; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonUp
166  u32 hardware_button_right; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonRight
167  u32 hardware_button_down; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonDown
168  u32 hardware_button_stick_l; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonStickL
169  u32 hardware_button_l; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonL
170  u32 hardware_button_zl; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonZL
171  u32 hardware_button_select; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonSelect
172  u32 hardware_button_left_sl; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonLeftSL
173  u32 hardware_button_left_sr; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonLeftSR
174  u32 hardware_button_capture; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonCapture
177 
178 /// ButtonConfigRight
179 typedef struct {
180  u32 hardware_button_a; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonA
181  u32 hardware_button_b; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonB
182  u32 hardware_button_x; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonX
183  u32 hardware_button_y; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonY
184  u32 hardware_button_stick_r; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonStickR
185  u32 hardware_button_r; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonR
186  u32 hardware_button_zr; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonZR
187  u32 hardware_button_start; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonStart
188  u32 hardware_button_right_sl; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonRightSL
189  u32 hardware_button_right_sr; ///< \ref HidcfgDigitalButtonAssignment HardwareButtonRightSR
192 
193 /// StorageName
194 typedef struct {
195  u8 name[0x81]; ///< UTF-8 NUL-terminated name string.
197 
198 /// Initialize hidsys.
200 
201 /// Exit hidsys.
202 void hidsysExit(void);
203 
204 /// Gets the Service object for the actual hidsys service session.
206 
207 /**
208  * @brief SendKeyboardLockKeyEvent
209  * @param[in] events Bitfield of \ref HidKeyboardLockKeyEvent.
210  */
212 
213 /**
214  * @brief Gets an Event which is signaled when HidHomeButtonState is updated.
215  * @note The Event must be closed by the user once finished with it.
216  * @note This generally shouldn't be used, since AM-sysmodule uses it internally.
217  * @param[out] out_event Output Event.
218  * @param[in] Event autoclear.
219 **/
220 Result hidsysAcquireHomeButtonEventHandle(Event* out_event, bool autoclear);
221 
222 /**
223  * @brief Activates the HomeButton sharedmem.
224  * @note This generally shouldn't be used, since AM-sysmodule uses it internally.
225 **/
227 
228 /**
229  * @brief Gets an Event which is signaled when HidSleepButtonState is updated.
230  * @note The Event must be closed by the user once finished with it.
231  * @note This generally shouldn't be used, since AM-sysmodule uses it internally.
232  * @param[out] out_event Output Event.
233  * @param[in] Event autoclear.
234 **/
236 
237 /**
238  * @brief Activates the SleepButton sharedmem.
239  * @note This generally shouldn't be used, since AM-sysmodule uses it internally.
240 **/
242 
243 /**
244  * @brief Gets an Event which is signaled when HidCaptureButtonState is updated.
245  * @note The Event must be closed by the user once finished with it.
246  * @note This generally shouldn't be used, since AM-sysmodule uses it internally.
247  * @param[out] out_event Output Event.
248  * @param[in] Event autoclear.
249 **/
251 
252 /**
253  * @brief Activates the CaptureButton sharedmem.
254  * @note This generally shouldn't be used, since AM-sysmodule uses it internally.
255 **/
257 
258 /**
259  * @brief Applies npad system common policy.
260  */
262 
263 /**
264  * @brief Gets the npad id type of the last controller that was active.
265  * @param[out] out of \ref HidNpadIdType.
266  */
268 
269 /**
270  * @brief Gets the SupportedNpadStyleSet for the CallerApplet. applet must be initialized in order to use this (uses \ref appletGetAppletResourceUserIdOfCallerApplet).
271  * @note Only available on [6.0.0+].
272  * @param[out] out Bitmask of \ref HidNpadStyleTag.
273  */
275 
276 /**
277  * @brief Gets the \ref HidNpadInterfaceType for the specified controller.
278  * @note Only available on [10.0.0+].
279  * @param[in] id \ref HidNpadIdType
280  * @param[out] out \ref HidNpadInterfaceType
281  */
283 
284 /**
285  * @brief GetNpadLeftRightInterfaceType
286  * @note Only available on [10.0.0+].
287  * @param[in] id \ref HidNpadIdType
288  * @param[out] out0 \ref HidNpadInterfaceType
289  * @param[out] out1 \ref HidNpadInterfaceType
290  */
292 
293 /**
294  * @brief HasBattery
295  * @note Only available on [10.0.0+].
296  * @param[in] id \ref HidNpadIdType
297  * @param[out] out Output flag.
298  */
300 
301 /**
302  * @brief HasLeftRightBattery
303  * @note Only available on [10.0.0+].
304  * @param[in] id \ref HidNpadIdType
305  * @param[out] out0 Output flag.
306  * @param[out] out1 Output flag.
307  */
308 Result hidsysHasLeftRightBattery(HidNpadIdType id, bool *out0, bool *out1);
309 
310 /**
311  * @brief Gets the UniquePadIds for the specified controller.
312  * @note Only available on [3.0.0+].
313  * @param[in] id \ref HidNpadIdType
314  * @param[out] unique_pad_ids Output array of \ref HidsysUniquePadId.
315  * @param[in] count Max number of entries for the unique_pad_ids array.
316  * @param[out] total_out Total output array entries. Optional, can be NULL.
317  */
319 
320 /**
321  * @brief EnableAppletToGetInput
322  * @param[in] enable Input flag.
323 **/
325 
326 /**
327  * @brief AcquireUniquePadConnectionEventHandle
328  * @param[out] out_event Output Event.
329  */
331 
332 /**
333  * @brief Gets a list of all UniquePadIds.
334  * @param[out] unique_pad_ids Output array of \ref HidsysUniquePadId.
335  * @param[in] count Max number of entries for the unique_pad_ids array.
336  * @param[out] total_out Total output array entries. Optional, can be NULL.
337  */
338 Result hidsysGetUniquePadIds(HidsysUniquePadId *unique_pad_ids, s32 count, s32 *total_out);
339 
340 /**
341  * @brief AcquireJoyDetachOnBluetoothOffEventHandle
342  * @param[out] out_event Output Event.
343  * @param[in] Event autoclear.
344  */
346 
347 /**
348  * @brief GetUniquePadBluetoothAddress
349  * @note Only available on [3.0.0+].
350  * @param[in] unique_pad_id \ref HidsysUniquePadId
351  * @param[out] address \ref BtdrvAddress
352  */
354 
355 /**
356  * @brief DisconnectUniquePad
357  * @note Only available on [3.0.0+].
358  * @param[in] unique_pad_id \ref HidsysUniquePadId
359  */
361 
362 /**
363  * @brief GetUniquePadType
364  * @note Only available on [5.0.0+].
365  * @param[in] unique_pad_id \ref HidsysUniquePadId
366  * @param[out] pad_type \ref HidsysUniquePadType
367  */
369 
370 /**
371  * @brief GetUniquePadInterface
372  * @note Only available on [5.0.0+].
373  * @param[in] unique_pad_id \ref HidsysUniquePadId
374  * @param[out] interface \ref HidNpadInterfaceType
375  */
377 
378 /**
379  * @brief Gets the \ref HidsysUniquePadSerialNumber.
380  * @note Only available on [5.0.0+].
381  * @param[in] unique_pad_id \ref HidsysUniquePadId
382  * @param[out] serial \ref HidsysUniquePadSerialNumber
383  */
385 
386 /**
387  * @brief GetUniquePadControllerNumber
388  * @note Only available on [5.0.0+].
389  * @param[in] unique_pad_id \ref HidsysUniquePadId
390  * @param[out] number Controller number.
391  */
393 
394 /**
395  * @brief Sets the HOME-button notification LED pattern, for the specified controller.
396  * @note Generally this should only be used if \ref hidsysSetNotificationLedPatternWithTimeout is not usable.
397  * @note Only available on [7.0.0+].
398  * @param[in] pattern \ref HidsysNotificationLedPattern
399  * @param[in] unique_pad_id \ref HidsysUniquePadId
400  */
402 
403 /**
404  * @brief Sets the HOME-button notification LED pattern, for the specified controller. The LED will automatically be disabled once the specified timeout occurs.
405  * @note Only available on [9.0.0+], and with controllers which have the [9.0.0+] firmware installed.
406  * @param[in] pattern \ref HidsysNotificationLedPattern
407  * @param[in] unique_pad_id \ref HidsysUniquePadId
408  * @param[in] timeout Timeout in nanoseconds.
409  */
411 
412 /**
413  * @brief IsUsbFullKeyControllerEnabled
414  * @note Only available on [3.0.0+].
415  * @param[out] out Output flag.
416  */
418 
419 /**
420  * @brief EnableUsbFullKeyController
421  * @note Only available on [3.0.0+].
422  * @param[in] flag Flag
423  */
425 
426 /**
427  * @brief IsUsbConnected
428  * @note Only available on [3.0.0+].
429  * @param[in] unique_pad_id \ref HidsysUniquePadId
430  * @param[out] out Output flag.
431  */
433 
434 /**
435  * @brief GetTouchScreenDefaultConfiguration
436  * @note Only available on [9.0.0+].
437  * @param[out] touch_screen_configuration \ref HidTouchScreenConfigurationForNx.
438  */
440 
441 /**
442  * @brief IsFirmwareUpdateNeededForNotification
443  * @note Only available on [9.0.0+].
444  * @param[in] unique_pad_id \ref HidsysUniquePadId
445  * @param[out] out Output flag.
446  */
448 
449 /**
450  * @brief Legacy IsButtonConfigSupported.
451  * @note Only available on [10.0.0-10.2.0]. On [11.0.0-17.0.1], use \ref hidsysIsButtonConfigSupported instead.
452  * @param[in] unique_pad_id \ref HidsysUniquePadId
453  * @param[out] out Output bool flag.
454  */
456 
457 /**
458  * @brief IsButtonConfigSupported
459  * @note Only available on [11.0.0-17.0.1]. On [10.0.0-10.2.0], use \ref hidsysLegacyIsButtonConfigSupported instead.
460  * @param[in] addr \ref BtdrvAddress
461  * @param[out] out Output bool flag.
462  */
464 
465 /**
466  * @brief IsButtonConfigEmbeddedSupported
467  * @note Only available on [11.0.0-17.0.1].
468  * @param[out] out Output bool flag.
469  */
471 
472 /**
473  * @brief Legacy DeleteButtonConfig.
474  * @note Only available on [10.0.0-10.2.0]. On [11.0.0-17.0.1], use \ref hidsysDeleteButtonConfig instead.
475  * @param[in] unique_pad_id \ref HidsysUniquePadId
476  */
478 
479 /**
480  * @brief DeleteButtonConfig
481  * @note Only available on [11.0.0-17.0.1]. On [10.0.0-10.2.0], use \ref hidsysLegacyDeleteButtonConfig instead.
482  * @param[in] addr \ref BtdrvAddress
483  */
485 
486 /**
487  * @brief DeleteButtonConfigEmbedded
488  * @note Only available on [11.0.0-17.0.1].
489  */
491 
492 /**
493  * @brief Legacy SetButtonConfigEnabled.
494  * @note Only available on [10.0.0-10.2.0]. On [11.0.0-17.0.1], use \ref hidsysSetButtonConfigEnabled instead.
495  * @param[in] unique_pad_id \ref HidsysUniquePadId
496  * @param[in] flag Input flag.
497  */
499 
500 /**
501  * @brief SetButtonConfigEnabled
502  * @note Only available on [11.0.0-17.0.1]. On [10.0.0-10.2.0], use \ref hidsysLegacySetButtonConfigEnabled instead.
503  * @param[in] addr \ref BtdrvAddress
504  * @param[in] flag Input flag.
505  */
507 
508 /**
509  * @brief SetButtonConfigEmbeddedEnabled
510  * @note Only available on [11.0.0-17.0.1].
511  * @param[in] flag Input flag.
512  */
514 
515 /**
516  * @brief Legacy IsButtonConfigEnabled.
517  * @note Only available on [10.0.0-10.2.0]. On [11.0.0-17.0.1], use \ref hidsysIsButtonConfigEnabled instead.
518  * @param[in] unique_pad_id \ref HidsysUniquePadId
519  * @param[out] out Output bool flag.
520  */
522 
523 /**
524  * @brief IsButtonConfigEnabled
525  * @note Only available on [11.0.0-17.0.1]. On [10.0.0-10.2.0], use \ref hidsysLegacyIsButtonConfigEnabled instead.
526  * @param[in] addr \ref BtdrvAddress
527  * @param[in] out Output bool flag.
528  */
530 
531 /**
532  * @brief IsButtonConfigEmbeddedEnabled
533  * @note Only available on [11.0.0-17.0.1].
534  * @param[out] out Output bool flag.
535  */
537 
538 /**
539  * @brief Legacy SetButtonConfigEmbedded.
540  * @note Only available on [10.0.0-10.2.0]. On [11.0.0-17.0.1], use \ref hidsysSetButtonConfigEmbedded instead.
541  * @param[in] unique_pad_id \ref HidsysUniquePadId
542  * @param[in] config \ref HidsysButtonConfigEmbedded
543  */
545 
546 /**
547  * @brief SetButtonConfigEmbedded
548  * @note Only available on [11.0.0-17.0.1]. On [10.0.0-10.2.0], use \ref hidsysLegacySetButtonConfigEmbedded instead.
549  * @param[in] config \ref HidsysButtonConfigEmbedded
550  */
552 
553 /**
554  * @brief Legacy SetButtonConfigFull.
555  * @note Only available on [10.0.0-10.2.0]. On [11.0.0-17.0.1], use \ref hidsysSetButtonConfigFull instead.
556  * @param[in] unique_pad_id \ref HidsysUniquePadId
557  * @param[in] config \ref HidsysButtonConfigFull
558  */
560 
561 /**
562  * @brief SetButtonConfigFull
563  * @note Only available on [11.0.0-17.0.1]. On [10.0.0-10.2.0], use \ref hidsysLegacySetButtonConfigFull instead.
564  * @param[in] addr \ref BtdrvAddress
565  * @param[in] config \ref HidsysButtonConfigFull
566  */
568 
569 /**
570  * @brief Legacy SetButtonConfigLeft.
571  * @note Only available on [10.0.0-10.2.0]. On [11.0.0-17.0.1], use \ref hidsysSetButtonConfigLeft instead.
572  * @param[in] unique_pad_id \ref HidsysUniquePadId
573  * @param[in] config \ref HidsysButtonConfigLeft
574  */
576 
577 /**
578  * @brief SetButtonConfigLeft
579  * @note Only available on [11.0.0-17.0.1]. On [10.0.0-10.2.0], use \ref hidsysLegacySetButtonConfigLeft instead.
580  * @param[in] addr \ref BtdrvAddress
581  * @param[in] config \ref HidsysButtonConfigLeft
582  */
584 
585 /**
586  * @brief Legacy SetButtonConfigRight.
587  * @note Only available on [10.0.0-10.2.0]. On [11.0.0-17.0.1], use \ref hidsysSetButtonConfigRight instead.
588  * @param[in] unique_pad_id \ref HidsysUniquePadId
589  * @param[in] config \ref HidsysButtonConfigRight
590  */
592 
593 /**
594  * @brief SetButtonConfigRight
595  * @note Only available on [11.0.0-17.0.1]. On [10.0.0-10.2.0], use \ref hidsysLegacySetButtonConfigRight instead.
596  * @param[in] addr \ref BtdrvAddress
597  * @param[in] config \ref HidsysButtonConfigRight
598  */
600 
601 /**
602  * @brief Legacy GetButtonConfigEmbedded.
603  * @note Only available on [10.0.0-10.2.0]. On [11.0.0-17.0.1], use \ref hidsysGetButtonConfigEmbedded instead.
604  * @param[in] unique_pad_id \ref HidsysUniquePadId
605  * @param[out] config \ref HidsysButtonConfigEmbedded
606  */
608 
609 /**
610  * @brief GetButtonConfigEmbedded
611  * @note Only available on [11.0.0-17.0.1]. On [10.0.0-10.2.0], use \ref hidsysLegacyGetButtonConfigEmbedded instead.
612  * @param[out] config \ref HidsysButtonConfigEmbedded
613  */
615 
616 /**
617  * @brief Legacy GetButtonConfigFull.
618  * @note Only available on [10.0.0-10.2.0]. On [11.0.0-17.0.1], use \ref hidsysGetButtonConfigFull instead.
619  * @param[in] unique_pad_id \ref HidsysUniquePadId
620  * @param[out] config \ref HidsysButtonConfigFull
621  */
623 
624 /**
625  * @brief GetButtonConfigFull
626  * @note Only available on [11.0.0-17.0.1]. On [10.0.0-10.2.0], use \ref hidsysLegacyGetButtonConfigFull instead.
627  * @param[in] addr \ref BtdrvAddress
628  * @param[out] config \ref HidsysButtonConfigFull
629  */
631 
632 /**
633  * @brief Legacy GetButtonConfigLeft.
634  * @note Only available on [10.0.0-10.2.0]. On [11.0.0-17.0.1], use \ref hidsysGetButtonConfigLeft instead.
635  * @param[in] unique_pad_id \ref HidsysUniquePadId
636  * @param[out] config \ref HidsysButtonConfigLeft
637  */
639 
640 /**
641  * @brief GetButtonConfigLeft
642  * @note Only available on [11.0.0-17.0.1]. On [10.0.0-10.2.0], use \ref hidsysLegacyGetButtonConfigLeft instead.
643  * @param[in] addr \ref BtdrvAddress
644  * @param[out] config \ref HidsysButtonConfigLeft
645  */
647 
648 /**
649  * @brief Legacy GetButtonConfigRight.
650  * @note Only available on [10.0.0-10.2.0]. On [11.0.0-17.0.1], use \ref hidsysGetButtonConfigRight instead.
651  * @param[in] unique_pad_id \ref HidsysUniquePadId
652  * @param[out] config \ref HidsysButtonConfigRight
653  */
655 
656 /**
657  * @brief GetButtonConfigRight
658  * @note Only available on [11.0.0-17.0.1]. On [10.0.0-10.2.0], use \ref hidsysLegacyGetButtonConfigRight instead.
659  * @param[in] addr \ref BtdrvAddress
660  * @param[out] config \ref HidsysButtonConfigRight
661  */
663 
664 /**
665  * @brief IsCustomButtonConfigSupported
666  * @note Only available on [10.0.0+].
667  * @param[in] unique_pad_id \ref HidsysUniquePadId
668  * @param[out] out Output bool flag.
669  */
671 
672 /**
673  * @brief IsDefaultButtonConfigEmbedded
674  * @note Only available on [10.0.0+].
675  * @param[in] config \ref HidcfgButtonConfigEmbedded
676  * @param[out] out Output bool flag.
677  */
679 
680 /**
681  * @brief IsDefaultButtonConfigFull
682  * @note Only available on [10.0.0+].
683  * @param[in] config \ref HidcfgButtonConfigFull
684  * @param[out] out Output bool flag.
685  */
687 
688 /**
689  * @brief IsDefaultButtonConfigLeft
690  * @note Only available on [10.0.0+].
691  * @param[in] config \ref HidcfgButtonConfigLeft
692  * @param[out] out Output bool flag.
693  */
695 
696 /**
697  * @brief IsDefaultButtonConfigRight
698  * @note Only available on [10.0.0+].
699  * @param[in] config \ref HidcfgButtonConfigRight
700  * @param[out] out Output bool flag.
701  */
703 
704 /**
705  * @brief IsButtonConfigStorageEmbeddedEmpty
706  * @note Only available on [10.0.0+].
707  * @param[in] index Array index, should be 0-4.
708  * @param[out] out Output bool flag.
709  */
711 
712 /**
713  * @brief IsButtonConfigStorageFullEmpty
714  * @note Only available on [10.0.0+].
715  * @param[in] index Array index, should be 0-4.
716  * @param[out] out Output bool flag.
717  */
719 
720 /**
721  * @brief IsButtonConfigStorageLeftEmpty
722  * @note Only available on [10.0.0+].
723  * @param[in] index Array index, should be 0-4.
724  * @param[out] out Output bool flag.
725  */
727 
728 /**
729  * @brief IsButtonConfigStorageRightEmpty
730  * @note Only available on [10.0.0+].
731  * @param[in] index Array index, should be 0-4.
732  * @param[out] out Output bool flag.
733  */
735 
736 /**
737  * @brief GetButtonConfigStorageEmbeddedDeprecated
738  * @note Only available on [10.0.0-12.1.0].
739  * @param[in] index Array index, should be 0-4.
740  * @param[out] config \ref HidcfgButtonConfigEmbedded
741  */
743 
744 /**
745  * @brief GetButtonConfigStorageFullDeprecated
746  * @note Only available on [10.0.0-12.1.0].
747  * @param[in] index Array index, should be 0-4.
748  * @param[out] config \ref HidcfgButtonConfigFull
749  */
751 
752 /**
753  * @brief GetButtonConfigStorageLeftDeprecated
754  * @note Only available on [10.0.0-12.1.0].
755  * @param[in] index Array index, should be 0-4.
756  * @param[out] config \ref HidcfgButtonConfigLeft
757  */
759 
760 /**
761  * @brief GetButtonConfigStorageRightDeprecated
762  * @note Only available on [10.0.0-12.1.0].
763  * @param[in] index Array index, should be 0-4.
764  * @param[out] config \ref HidcfgButtonConfigRight
765  */
767 
768 /**
769  * @brief SetButtonConfigStorageEmbeddedDeprecated
770  * @note Only available on [10.0.0-12.1.0].
771  * @param[in] index Array index, should be 0-4.
772  * @param[in] config \ref HidcfgButtonConfigEmbedded
773  */
775 
776 /**
777  * @brief SetButtonConfigStorageFullDeprecated
778  * @note Only available on [10.0.0-12.1.0].
779  * @param[in] index Array index, should be 0-4.
780  * @param[in] config \ref HidcfgButtonConfigFull
781  */
783 
784 /**
785  * @brief SetButtonConfigStorageLeftDeprecated
786  * @note Only available on [10.0.0-12.1.0].
787  * @param[in] index Array index, should be 0-4.
788  * @param[in] config \ref HidcfgButtonConfigLeft
789  */
791 
792 /**
793  * @brief SetButtonConfigStorageRightDeprecated
794  * @note Only available on [10.0.0-12.1.0].
795  * @param[in] index Array index, should be 0-4.
796  * @param[in] config \ref HidcfgButtonConfigRight
797  */
799 
800 /**
801  * @brief DeleteButtonConfigStorageEmbedded
802  * @note Only available on [10.0.0+].
803  * @param[in] index Array index, should be 0-4.
804  */
806 
807 /**
808  * @brief DeleteButtonConfigStorageFull
809  * @note Only available on [10.0.0+].
810  * @param[in] index Array index, should be 0-4.
811  */
813 
814 /**
815  * @brief DeleteButtonConfigStorageLeft
816  * @note Only available on [10.0.0+].
817  * @param[in] index Array index, should be 0-4.
818  */
820 
821 /**
822  * @brief DeleteButtonConfigStorageRight
823  * @note Only available on [10.0.0+].
824  * @param[in] index Array index, should be 0-4.
825  */
827 
828 /**
829  * @brief IsUsingCustomButtonConfig
830  * @note Only available on [10.0.0+].
831  * @param[in] unique_pad_id \ref HidsysUniquePadId
832  * @param[out] out Output bool flag.
833  */
835 
836 /**
837  * @brief IsAnyCustomButtonConfigEnabled
838  * @note Only available on [10.0.0+].
839  * @param[out] out Output bool flag.
840  */
842 
843 /**
844  * @brief SetAllCustomButtonConfigEnabled
845  * @note Only available on [10.0.0+].
846  * @param[in] AppletResourceUserId AppletResourceUserId
847  * @param[in] flag Input bool flag.
848  */
849 Result hidsysSetAllCustomButtonConfigEnabled(u64 AppletResourceUserId, bool flag);
850 
851 /**
852  * @brief SetAllDefaultButtonConfig
853  * @note Only available on [10.0.0+].
854  */
856 
857 /**
858  * @brief SetHidButtonConfigEmbedded
859  * @note Only available on [10.0.0+].
860  * @param[in] unique_pad_id \ref HidsysUniquePadId
861  * @param[in] config \ref HidcfgButtonConfigEmbedded
862  */
864 
865 /**
866  * @brief SetHidButtonConfigFull
867  * @note Only available on [10.0.0+].
868  * @param[in] unique_pad_id \ref HidsysUniquePadId
869  * @param[in] config \ref HidcfgButtonConfigFull
870  */
872 
873 /**
874  * @brief SetHidButtonConfigLeft
875  * @note Only available on [10.0.0+].
876  * @param[in] unique_pad_id \ref HidsysUniquePadId
877  * @param[in] config \ref HidcfgButtonConfigLeft
878  */
880 
881 /**
882  * @brief SetHidButtonConfigRight
883  * @note Only available on [10.0.0+].
884  * @param[in] unique_pad_id \ref HidsysUniquePadId
885  * @param[in] config \ref HidcfgButtonConfigRight
886  */
888 
889 /**
890  * @brief GetHidButtonConfigEmbedded
891  * @note Only available on [10.0.0+].
892  * @param[in] unique_pad_id \ref HidsysUniquePadId
893  * @param[out] config \ref HidcfgButtonConfigEmbedded
894  */
896 
897 /**
898  * @brief GetHidButtonConfigFull
899  * @note Only available on [10.0.0+].
900  * @param[in] unique_pad_id \ref HidsysUniquePadId
901  * @param[out] config \ref HidcfgButtonConfigFull
902  */
904 
905 /**
906  * @brief GetHidButtonConfigLeft
907  * @note Only available on [10.0.0+].
908  * @param[in] unique_pad_id \ref HidsysUniquePadId
909  * @param[out] config \ref HidcfgButtonConfigLeft
910  */
912 
913 /**
914  * @brief GetHidButtonConfigRight
915  * @note Only available on [10.0.0+].
916  * @param[in] unique_pad_id \ref HidsysUniquePadId
917  * @param[out] config \ref HidcfgButtonConfigRight
918  */
920 
921 /**
922  * @brief GetButtonConfigStorageEmbedded
923  * @note Only available on [11.0.0+].
924  * @param[in] index Array index, should be 0-4.
925  * @param[out] config \ref HidcfgButtonConfigEmbedded
926  * @param[out] name \ref HidcfgStorageName
927  */
929 
930 /**
931  * @brief GetButtonConfigStorageFull
932  * @note Only available on [11.0.0+].
933  * @param[in] index Array index, should be 0-4.
934  * @param[out] config \ref HidcfgButtonConfigFull
935  * @param[out] name \ref HidcfgStorageName
936  */
938 
939 /**
940  * @brief GetButtonConfigStorageLeft
941  * @note Only available on [11.0.0+].
942  * @param[in] index Array index, should be 0-4.
943  * @param[out] config \ref HidcfgButtonConfigLeft
944  * @param[out] name \ref HidcfgStorageName
945  */
947 
948 /**
949  * @brief GetButtonConfigStorageRight
950  * @note Only available on [11.0.0+].
951  * @param[in] index Array index, should be 0-4.
952  * @param[out] config \ref HidcfgButtonConfigRight
953  * @param[out] name \ref HidcfgStorageName
954  */
956 
957 /**
958  * @brief SetButtonConfigStorageEmbedded
959  * @note Only available on [11.0.0+].
960  * @param[in] index Array index, should be 0-4.
961  * @param[in] config \ref HidcfgButtonConfigEmbedded
962  * @param[in] name \ref HidcfgStorageName
963  */
965 
966 /**
967  * @brief SetButtonConfigStorageFull
968  * @note Only available on [11.0.0+].
969  * @param[in] index Array index, should be 0-4.
970  * @param[in] config \ref HidcfgButtonConfigFull
971  * @param[in] name \ref HidcfgStorageName
972  */
974 
975 /**
976  * @brief SetButtonConfigStorageLeft
977  * @note Only available on [11.0.0+].
978  * @param[in] index Array index, should be 0-4.
979  * @param[in] config \ref HidcfgButtonConfigLeft
980  * @param[in] name \ref HidcfgStorageName
981  */
983 
984 /**
985  * @brief SetButtonConfigStorageRight
986  * @note Only available on [11.0.0+].
987  * @param[in] index Array index, should be 0-4.
988  * @param[in] config \ref HidcfgButtonConfigRight
989  * @param[in] name \ref HidcfgStorageName
990  */
HidNpadInterfaceType
NpadInterfaceType (system)
Definition: hid.h:477
HidNpadIdType
HID controller IDs.
Definition: hid.h:214
Result hidsysLegacyDeleteButtonConfig(HidsysUniquePadId unique_pad_id)
Legacy DeleteButtonConfig.
Result hidsysSetButtonConfigStorageLeftDeprecated(s32 index, const HidcfgButtonConfigLeft *config)
SetButtonConfigStorageLeftDeprecated.
Result hidsysIsButtonConfigStorageEmbeddedEmpty(s32 index, bool *out)
IsButtonConfigStorageEmbeddedEmpty.
Result hidsysInitialize(void)
Initialize hidsys.
Result hidsysDeleteButtonConfigStorageEmbedded(s32 index)
DeleteButtonConfigStorageEmbedded.
Result hidsysGetButtonConfigStorageFull(s32 index, HidcfgButtonConfigFull *config, HidcfgStorageName *name)
GetButtonConfigStorageFull.
Result hidsysLegacyIsButtonConfigSupported(HidsysUniquePadId unique_pad_id, bool *out)
Legacy IsButtonConfigSupported.
Result hidsysEnableAppletToGetInput(bool enable)
EnableAppletToGetInput.
Result hidsysIsButtonConfigStorageRightEmpty(s32 index, bool *out)
IsButtonConfigStorageRightEmpty.
Result hidsysGetHidButtonConfigEmbedded(HidsysUniquePadId unique_pad_id, HidcfgButtonConfigEmbedded *config)
GetHidButtonConfigEmbedded.
Result hidsysLegacySetButtonConfigFull(HidsysUniquePadId unique_pad_id, const HidsysButtonConfigFull *config)
Legacy SetButtonConfigFull.
Result hidsysLegacySetButtonConfigEmbedded(HidsysUniquePadId unique_pad_id, const HidsysButtonConfigEmbedded *config)
Legacy SetButtonConfigEmbedded.
Result hidsysSendKeyboardLockKeyEvent(u32 events)
SendKeyboardLockKeyEvent.
Result hidsysGetUniquePadIds(HidsysUniquePadId *unique_pad_ids, s32 count, s32 *total_out)
Gets a list of all UniquePadIds.
Result hidsysGetButtonConfigStorageRightDeprecated(s32 index, HidcfgButtonConfigRight *config)
GetButtonConfigStorageRightDeprecated.
Result hidsysGetNpadInterfaceType(HidNpadIdType id, u8 *out)
Gets the HidNpadInterfaceType for the specified controller.
Result hidsysLegacySetButtonConfigEnabled(HidsysUniquePadId unique_pad_id, bool flag)
Legacy SetButtonConfigEnabled.
Result hidsysIsFirmwareUpdateNeededForNotification(HidsysUniquePadId unique_pad_id, bool *out)
IsFirmwareUpdateNeededForNotification.
Result hidsysDeleteButtonConfigStorageFull(s32 index)
DeleteButtonConfigStorageFull.
Result hidsysGetButtonConfigEmbedded(HidsysButtonConfigEmbedded *config)
GetButtonConfigEmbedded.
Result hidsysSetButtonConfigStorageLeft(s32 index, const HidcfgButtonConfigLeft *config, const HidcfgStorageName *name)
SetButtonConfigStorageLeft.
Result hidsysSetNotificationLedPatternWithTimeout(const HidsysNotificationLedPattern *pattern, HidsysUniquePadId unique_pad_id, u64 timeout)
Sets the HOME-button notification LED pattern, for the specified controller.
Result hidsysSetButtonConfigLeft(BtdrvAddress addr, const HidsysButtonConfigLeft *config)
SetButtonConfigLeft.
Result hidsysSetButtonConfigStorageRight(s32 index, const HidcfgButtonConfigRight *config, const HidcfgStorageName *name)
SetButtonConfigStorageRight.
void hidsysExit(void)
Exit hidsys.
Result hidsysIsUsingCustomButtonConfig(HidsysUniquePadId unique_pad_id, bool *out)
IsUsingCustomButtonConfig.
Result hidsysIsButtonConfigEmbeddedSupported(bool *out)
IsButtonConfigEmbeddedSupported.
Result hidsysSetButtonConfigEnabled(BtdrvAddress addr, bool flag)
SetButtonConfigEnabled.
Result hidsysSetButtonConfigStorageFullDeprecated(s32 index, const HidcfgButtonConfigFull *config)
SetButtonConfigStorageFullDeprecated.
Result hidsysActivateSleepButton(void)
Activates the SleepButton sharedmem.
Result hidsysGetSupportedNpadStyleSetOfCallerApplet(u32 *out)
Gets the SupportedNpadStyleSet for the CallerApplet.
HidcfgAnalogStickRotation
AnalogStickRotation.
Definition: hidsys.h:41
@ HidcfgAnalogStickRotation_Anticlockwise90
Anticlockwise90.
Definition: hidsys.h:44
@ HidcfgAnalogStickRotation_None
None.
Definition: hidsys.h:42
@ HidcfgAnalogStickRotation_Clockwise90
Clockwise90.
Definition: hidsys.h:43
Result hidsysSetAllCustomButtonConfigEnabled(u64 AppletResourceUserId, bool flag)
SetAllCustomButtonConfigEnabled.
Result hidsysLegacyGetButtonConfigRight(HidsysUniquePadId unique_pad_id, HidsysButtonConfigRight *config)
Legacy GetButtonConfigRight.
Result hidsysIsButtonConfigEnabled(BtdrvAddress addr, bool *out)
IsButtonConfigEnabled.
Result hidsysGetButtonConfigStorageRight(s32 index, HidcfgButtonConfigRight *config, HidcfgStorageName *name)
GetButtonConfigStorageRight.
Result hidsysGetButtonConfigRight(BtdrvAddress addr, HidsysButtonConfigRight *config)
GetButtonConfigRight.
Result hidsysSetButtonConfigStorageRightDeprecated(s32 index, const HidcfgButtonConfigRight *config)
SetButtonConfigStorageRightDeprecated.
Result hidsysDeleteButtonConfigStorageLeft(s32 index)
DeleteButtonConfigStorageLeft.
Result hidsysSetButtonConfigStorageEmbedded(s32 index, const HidcfgButtonConfigEmbedded *config, const HidcfgStorageName *name)
SetButtonConfigStorageEmbedded.
Result hidsysGetNpadLeftRightInterfaceType(HidNpadIdType id, u8 *out0, u8 *out1)
GetNpadLeftRightInterfaceType.
Result hidsysIsUsbFullKeyControllerEnabled(bool *out)
IsUsbFullKeyControllerEnabled.
Result hidsysEnableUsbFullKeyController(bool flag)
EnableUsbFullKeyController.
Result hidsysActivateCaptureButton(void)
Activates the CaptureButton sharedmem.
Result hidsysDisconnectUniquePad(HidsysUniquePadId unique_pad_id)
DisconnectUniquePad.
Result hidsysSetHidButtonConfigLeft(HidsysUniquePadId unique_pad_id, const HidcfgButtonConfigLeft *config)
SetHidButtonConfigLeft.
Result hidsysGetButtonConfigStorageFullDeprecated(s32 index, HidcfgButtonConfigFull *config)
GetButtonConfigStorageFullDeprecated.
Result hidsysIsAnyCustomButtonConfigEnabled(bool *out)
IsAnyCustomButtonConfigEnabled.
Result hidsysAcquireHomeButtonEventHandle(Event *out_event, bool autoclear)
Gets an Event which is signaled when HidHomeButtonState is updated.
Result hidsysSetButtonConfigStorageEmbeddedDeprecated(s32 index, const HidcfgButtonConfigEmbedded *config)
SetButtonConfigStorageEmbeddedDeprecated.
Result hidsysActivateHomeButton(void)
Activates the HomeButton sharedmem.
Result hidsysGetButtonConfigLeft(BtdrvAddress addr, HidsysButtonConfigLeft *config)
GetButtonConfigLeft.
Result hidsysAcquireUniquePadConnectionEventHandle(Event *out_event)
AcquireUniquePadConnectionEventHandle.
Result hidsysGetUniquePadBluetoothAddress(HidsysUniquePadId unique_pad_id, BtdrvAddress *address)
GetUniquePadBluetoothAddress.
Result hidsysLegacySetButtonConfigLeft(HidsysUniquePadId unique_pad_id, const HidsysButtonConfigLeft *config)
Legacy SetButtonConfigLeft.
Result hidsysIsButtonConfigStorageFullEmpty(s32 index, bool *out)
IsButtonConfigStorageFullEmpty.
Result hidsysGetUniquePadsFromNpad(HidNpadIdType id, HidsysUniquePadId *unique_pad_ids, s32 count, s32 *total_out)
Gets the UniquePadIds for the specified controller.
Result hidsysDeleteButtonConfigStorageRight(s32 index)
DeleteButtonConfigStorageRight.
Result hidsysHasLeftRightBattery(HidNpadIdType id, bool *out0, bool *out1)
HasLeftRightBattery.
Result hidsysSetButtonConfigStorageFull(s32 index, const HidcfgButtonConfigFull *config, const HidcfgStorageName *name)
SetButtonConfigStorageFull.
Result hidsysAcquireSleepButtonEventHandle(Event *out_event, bool autoclear)
Gets an Event which is signaled when HidSleepButtonState is updated.
Result hidsysIsCustomButtonConfigSupported(HidsysUniquePadId unique_pad_id, bool *out)
IsCustomButtonConfigSupported.
Result hidsysSetNotificationLedPattern(const HidsysNotificationLedPattern *pattern, HidsysUniquePadId unique_pad_id)
Sets the HOME-button notification LED pattern, for the specified controller.
Result hidsysSetAllDefaultButtonConfig(void)
SetAllDefaultButtonConfig.
Result hidsysGetButtonConfigStorageEmbeddedDeprecated(s32 index, HidcfgButtonConfigEmbedded *config)
GetButtonConfigStorageEmbeddedDeprecated.
Result hidsysGetTouchScreenDefaultConfiguration(HidTouchScreenConfigurationForNx *touch_screen_configuration)
GetTouchScreenDefaultConfiguration.
Result hidsysSetButtonConfigEmbeddedEnabled(bool flag)
SetButtonConfigEmbeddedEnabled.
HidsysUniquePadType
UniquePadType.
Definition: hidsys.h:48
@ HidsysUniquePadType_Embedded
Embedded.
Definition: hidsys.h:49
@ HidsysUniquePadType_FullKeyController
FullKeyController.
Definition: hidsys.h:50
@ HidsysUniquePadType_LeftController
LeftController.
Definition: hidsys.h:52
@ HidsysUniquePadType_RightController
RightController.
Definition: hidsys.h:51
@ HidsysUniquePadType_DebugPadController
DebugPadController.
Definition: hidsys.h:53
Result hidsysGetUniquePadInterface(HidsysUniquePadId unique_pad_id, HidNpadInterfaceType *interface)
GetUniquePadInterface.
Result hidsysGetUniquePadType(HidsysUniquePadId unique_pad_id, HidsysUniquePadType *pad_type)
GetUniquePadType.
Result hidsysIsUsbConnected(HidsysUniquePadId unique_pad_id, bool *out)
IsUsbConnected.
Result hidsysGetHidButtonConfigFull(HidsysUniquePadId unique_pad_id, HidcfgButtonConfigFull *config)
GetHidButtonConfigFull.
Result hidsysIsDefaultButtonConfigFull(const HidcfgButtonConfigFull *config, bool *out)
IsDefaultButtonConfigFull.
Result hidsysHasBattery(HidNpadIdType id, bool *out)
HasBattery.
Result hidsysIsDefaultButtonConfigLeft(const HidcfgButtonConfigLeft *config, bool *out)
IsDefaultButtonConfigLeft.
Result hidsysLegacySetButtonConfigRight(HidsysUniquePadId unique_pad_id, const HidsysButtonConfigRight *config)
Legacy SetButtonConfigRight.
Result hidsysDeleteButtonConfigEmbedded(void)
DeleteButtonConfigEmbedded.
Result hidsysGetHidButtonConfigLeft(HidsysUniquePadId unique_pad_id, HidcfgButtonConfigLeft *config)
GetHidButtonConfigLeft.
HidcfgDigitalButtonAssignment
Selects what button to map to.
Definition: hidsys.h:14
@ HidcfgDigitalButtonAssignment_StickL
Left Stick Button.
Definition: hidsys.h:19
@ HidcfgDigitalButtonAssignment_RightSR
SR on Right controller.
Definition: hidsys.h:34
@ HidcfgDigitalButtonAssignment_HomeButton
HomeButton.
Definition: hidsys.h:35
@ HidcfgDigitalButtonAssignment_Y
Y.
Definition: hidsys.h:18
@ HidcfgDigitalButtonAssignment_Down
Down.
Definition: hidsys.h:30
@ HidcfgDigitalButtonAssignment_X
X.
Definition: hidsys.h:17
@ HidcfgDigitalButtonAssignment_Up
Up.
Definition: hidsys.h:28
@ HidcfgDigitalButtonAssignment_LeftSR
SR on Left controller.
Definition: hidsys.h:32
@ HidcfgDigitalButtonAssignment_B
B.
Definition: hidsys.h:16
@ HidcfgDigitalButtonAssignment_CaptureButton
CaptureButton.
Definition: hidsys.h:36
@ HidcfgDigitalButtonAssignment_L
L.
Definition: hidsys.h:21
@ HidcfgDigitalButtonAssignment_ZL
ZL.
Definition: hidsys.h:23
@ HidcfgDigitalButtonAssignment_Start
Start / Plus.
Definition: hidsys.h:26
@ HidcfgDigitalButtonAssignment_LeftSL
SL on Left controller.
Definition: hidsys.h:31
@ HidcfgDigitalButtonAssignment_A
A.
Definition: hidsys.h:15
@ HidcfgDigitalButtonAssignment_RightSL
SL on Right controller.
Definition: hidsys.h:33
@ HidcfgDigitalButtonAssignment_StickR
Right Stick Button.
Definition: hidsys.h:20
@ HidcfgDigitalButtonAssignment_Invalid
Invalid / Disabled.
Definition: hidsys.h:37
@ HidcfgDigitalButtonAssignment_Left
Left.
Definition: hidsys.h:27
@ HidcfgDigitalButtonAssignment_Select
Select / Minus.
Definition: hidsys.h:25
@ HidcfgDigitalButtonAssignment_Right
Right.
Definition: hidsys.h:29
@ HidcfgDigitalButtonAssignment_R
R.
Definition: hidsys.h:22
@ HidcfgDigitalButtonAssignment_ZR
ZR.
Definition: hidsys.h:24
Result hidsysAcquireCaptureButtonEventHandle(Event *out_event, bool autoclear)
Gets an Event which is signaled when HidCaptureButtonState is updated.
Result hidsysSetHidButtonConfigRight(HidsysUniquePadId unique_pad_id, const HidcfgButtonConfigRight *config)
SetHidButtonConfigRight.
Result hidsysAcquireJoyDetachOnBluetoothOffEventHandle(Event *out_event, bool autoclear)
AcquireJoyDetachOnBluetoothOffEventHandle.
Result hidsysGetButtonConfigStorageEmbedded(s32 index, HidcfgButtonConfigEmbedded *config, HidcfgStorageName *name)
GetButtonConfigStorageEmbedded.
Result hidsysSetButtonConfigRight(BtdrvAddress addr, const HidsysButtonConfigRight *config)
SetButtonConfigRight.
Result hidsysIsDefaultButtonConfigRight(const HidcfgButtonConfigRight *config, bool *out)
IsDefaultButtonConfigRight.
Result hidsysDeleteButtonConfig(BtdrvAddress addr)
DeleteButtonConfig.
Result hidsysIsButtonConfigStorageLeftEmpty(s32 index, bool *out)
IsButtonConfigStorageLeftEmpty.
Service * hidsysGetServiceSession(void)
Gets the Service object for the actual hidsys service session.
Result hidsysApplyNpadSystemCommonPolicy(void)
Applies npad system common policy.
Result hidsysLegacyIsButtonConfigEnabled(HidsysUniquePadId unique_pad_id, bool *out)
Legacy IsButtonConfigEnabled.
Result hidsysGetHidButtonConfigRight(HidsysUniquePadId unique_pad_id, HidcfgButtonConfigRight *config)
GetHidButtonConfigRight.
Result hidsysSetButtonConfigFull(BtdrvAddress addr, const HidsysButtonConfigFull *config)
SetButtonConfigFull.
Result hidsysLegacyGetButtonConfigEmbedded(HidsysUniquePadId unique_pad_id, HidsysButtonConfigEmbedded *config)
Legacy GetButtonConfigEmbedded.
Result hidsysLegacyGetButtonConfigLeft(HidsysUniquePadId unique_pad_id, HidsysButtonConfigLeft *config)
Legacy GetButtonConfigLeft.
Result hidsysGetButtonConfigStorageLeftDeprecated(s32 index, HidcfgButtonConfigLeft *config)
GetButtonConfigStorageLeftDeprecated.
Result hidsysGetButtonConfigFull(BtdrvAddress addr, HidsysButtonConfigFull *config)
GetButtonConfigFull.
Result hidsysSetHidButtonConfigEmbedded(HidsysUniquePadId unique_pad_id, const HidcfgButtonConfigEmbedded *config)
SetHidButtonConfigEmbedded.
Result hidsysLegacyGetButtonConfigFull(HidsysUniquePadId unique_pad_id, HidsysButtonConfigFull *config)
Legacy GetButtonConfigFull.
Result hidsysIsButtonConfigSupported(BtdrvAddress addr, bool *out)
IsButtonConfigSupported.
Result hidsysIsDefaultButtonConfigEmbedded(const HidcfgButtonConfigEmbedded *config, bool *out)
IsDefaultButtonConfigEmbedded.
Result hidsysGetUniquePadControllerNumber(HidsysUniquePadId unique_pad_id, u64 *number)
GetUniquePadControllerNumber.
Result hidsysSetButtonConfigEmbedded(const HidsysButtonConfigEmbedded *config)
SetButtonConfigEmbedded.
Result hidsysSetHidButtonConfigFull(HidsysUniquePadId unique_pad_id, const HidcfgButtonConfigFull *config)
SetHidButtonConfigFull.
Result hidsysGetButtonConfigStorageLeft(s32 index, HidcfgButtonConfigLeft *config, HidcfgStorageName *name)
GetButtonConfigStorageLeft.
Result hidsysGetUniquePadSerialNumber(HidsysUniquePadId unique_pad_id, HidsysUniquePadSerialNumber *serial)
Gets the HidsysUniquePadSerialNumber.
Result hidsysIsButtonConfigEmbeddedEnabled(bool *out)
IsButtonConfigEmbeddedEnabled.
Result hidsysGetLastActiveNpad(u32 *out)
Gets the npad id type of the last controller that was active.
Address.
Definition: btdrv_types.h:214
Kernel-mode event structure.
Definition: event.h:13
HidTouchScreenConfigurationForNx.
Definition: hid.h:687
AnalogStickAssignment.
Definition: hidsys.h:110
u32 rotation
HidcfgAnalogStickRotation
Definition: hidsys.h:111
u8 is_paired_stick_assigned
IsPairedStickAssigned.
Definition: hidsys.h:112
ButtonConfigEmbedded.
Definition: hidsys.h:117
u32 hardware_button_zr
HidcfgDigitalButtonAssignment HardwareButtonZR
Definition: hidsys.h:131
u32 hardware_button_up
HidcfgDigitalButtonAssignment HardwareButtonUp
Definition: hidsys.h:119
u32 hardware_button_l
HidcfgDigitalButtonAssignment HardwareButtonL
Definition: hidsys.h:128
u32 hardware_button_select
HidcfgDigitalButtonAssignment HardwareButtonSelect
Definition: hidsys.h:132
u32 hardware_button_b
HidcfgDigitalButtonAssignment HardwareButtonB
Definition: hidsys.h:123
u32 hardware_button_y
HidcfgDigitalButtonAssignment HardwareButtonY
Definition: hidsys.h:125
HidcfgAnalogStickAssignment hardware_stick_l
HardwareStickL.
Definition: hidsys.h:135
u32 hardware_button_down
HidcfgDigitalButtonAssignment HardwareButtonDown
Definition: hidsys.h:121
u32 hardware_button_left
HidcfgDigitalButtonAssignment HardwareButtonLeft
Definition: hidsys.h:118
u32 hardware_button_a
HidcfgDigitalButtonAssignment HardwareButtonA
Definition: hidsys.h:122
u32 hardware_button_stick_r
HidcfgDigitalButtonAssignment HardwareButtonStickR
Definition: hidsys.h:127
u32 hardware_button_capture
HidcfgDigitalButtonAssignment HardwareButtonCapture
Definition: hidsys.h:134
u32 hardware_button_r
HidcfgDigitalButtonAssignment HardwareButtonR
Definition: hidsys.h:129
u32 hardware_button_x
HidcfgDigitalButtonAssignment HardwareButtonX
Definition: hidsys.h:124
u32 hardware_button_start
HidcfgDigitalButtonAssignment HardwareButtonStart
Definition: hidsys.h:133
u32 hardware_button_right
HidcfgDigitalButtonAssignment HardwareButtonRight
Definition: hidsys.h:120
u32 hardware_button_zl
HidcfgDigitalButtonAssignment HardwareButtonZL
Definition: hidsys.h:130
u32 hardware_button_stick_l
HidcfgDigitalButtonAssignment HardwareButtonStickL
Definition: hidsys.h:126
HidcfgAnalogStickAssignment hardware_stick_r
HardwareStickR.
Definition: hidsys.h:136
ButtonConfigFull.
Definition: hidsys.h:140
u32 hardware_button_stick_r
HidcfgDigitalButtonAssignment HardwareButtonStickR
Definition: hidsys.h:150
u32 hardware_button_l
HidcfgDigitalButtonAssignment HardwareButtonL
Definition: hidsys.h:151
HidcfgAnalogStickAssignment hardware_stick_l
HardwareStickL.
Definition: hidsys.h:158
u32 hardware_button_zl
HidcfgDigitalButtonAssignment HardwareButtonZL
Definition: hidsys.h:153
u32 hardware_button_x
HidcfgDigitalButtonAssignment HardwareButtonX
Definition: hidsys.h:147
u32 hardware_button_r
HidcfgDigitalButtonAssignment HardwareButtonR
Definition: hidsys.h:152
u32 hardware_button_capture
HidcfgDigitalButtonAssignment HardwareButtonCapture
Definition: hidsys.h:157
u32 hardware_button_up
HidcfgDigitalButtonAssignment HardwareButtonUp
Definition: hidsys.h:142
u32 hardware_button_select
HidcfgDigitalButtonAssignment HardwareButtonSelect
Definition: hidsys.h:155
u32 hardware_button_stick_l
HidcfgDigitalButtonAssignment HardwareButtonStickL
Definition: hidsys.h:149
u32 hardware_button_b
HidcfgDigitalButtonAssignment HardwareButtonB
Definition: hidsys.h:146
u32 hardware_button_right
HidcfgDigitalButtonAssignment HardwareButtonRight
Definition: hidsys.h:143
u32 hardware_button_down
HidcfgDigitalButtonAssignment HardwareButtonDown
Definition: hidsys.h:144
u32 hardware_button_left
HidcfgDigitalButtonAssignment HardwareButtonLeft
Definition: hidsys.h:141
u32 hardware_button_zr
HidcfgDigitalButtonAssignment HardwareButtonZR
Definition: hidsys.h:154
HidcfgAnalogStickAssignment hardware_stick_r
HardwareStickR.
Definition: hidsys.h:159
u32 hardware_button_a
HidcfgDigitalButtonAssignment HardwareButtonA
Definition: hidsys.h:145
u32 hardware_button_y
HidcfgDigitalButtonAssignment HardwareButtonY
Definition: hidsys.h:148
u32 hardware_button_start
HidcfgDigitalButtonAssignment HardwareButtonStart
Definition: hidsys.h:156
ButtonConfigLeft.
Definition: hidsys.h:163
u32 hardware_button_left
HidcfgDigitalButtonAssignment HardwareButtonLeft
Definition: hidsys.h:164
u32 hardware_button_l
HidcfgDigitalButtonAssignment HardwareButtonL
Definition: hidsys.h:169
HidcfgAnalogStickAssignment hardware_stick_l
HardwareStickL.
Definition: hidsys.h:175
u32 hardware_button_down
HidcfgDigitalButtonAssignment HardwareButtonDown
Definition: hidsys.h:167
u32 hardware_button_left_sl
HidcfgDigitalButtonAssignment HardwareButtonLeftSL
Definition: hidsys.h:172
u32 hardware_button_up
HidcfgDigitalButtonAssignment HardwareButtonUp
Definition: hidsys.h:165
u32 hardware_button_stick_l
HidcfgDigitalButtonAssignment HardwareButtonStickL
Definition: hidsys.h:168
u32 hardware_button_select
HidcfgDigitalButtonAssignment HardwareButtonSelect
Definition: hidsys.h:171
u32 hardware_button_left_sr
HidcfgDigitalButtonAssignment HardwareButtonLeftSR
Definition: hidsys.h:173
u32 hardware_button_capture
HidcfgDigitalButtonAssignment HardwareButtonCapture
Definition: hidsys.h:174
u32 hardware_button_zl
HidcfgDigitalButtonAssignment HardwareButtonZL
Definition: hidsys.h:170
u32 hardware_button_right
HidcfgDigitalButtonAssignment HardwareButtonRight
Definition: hidsys.h:166
ButtonConfigRight.
Definition: hidsys.h:179
u32 hardware_button_r
HidcfgDigitalButtonAssignment HardwareButtonR
Definition: hidsys.h:185
u32 hardware_button_right_sl
HidcfgDigitalButtonAssignment HardwareButtonRightSL
Definition: hidsys.h:188
u32 hardware_button_start
HidcfgDigitalButtonAssignment HardwareButtonStart
Definition: hidsys.h:187
u32 hardware_button_a
HidcfgDigitalButtonAssignment HardwareButtonA
Definition: hidsys.h:180
u32 hardware_button_stick_r
HidcfgDigitalButtonAssignment HardwareButtonStickR
Definition: hidsys.h:184
u32 hardware_button_x
HidcfgDigitalButtonAssignment HardwareButtonX
Definition: hidsys.h:182
u32 hardware_button_y
HidcfgDigitalButtonAssignment HardwareButtonY
Definition: hidsys.h:183
u32 hardware_button_b
HidcfgDigitalButtonAssignment HardwareButtonB
Definition: hidsys.h:181
u32 hardware_button_right_sr
HidcfgDigitalButtonAssignment HardwareButtonRightSR
Definition: hidsys.h:189
u32 hardware_button_zr
HidcfgDigitalButtonAssignment HardwareButtonZR
Definition: hidsys.h:186
HidcfgAnalogStickAssignment hardware_stick_r
HardwareStickR.
Definition: hidsys.h:190
StorageName.
Definition: hidsys.h:194
ButtonConfigEmbedded.
Definition: hidsys.h:90
ButtonConfigFull.
Definition: hidsys.h:95
ButtonConfigLeft.
Definition: hidsys.h:100
ButtonConfigRight.
Definition: hidsys.h:105
Mini Cycle struct for HidsysNotificationLedPattern.
Definition: hidsys.h:67
u8 transitionSteps
Fading Transition Steps to Mini Cycle X (Uses PWM). Value 0x0: Instant. Each step duration is based o...
Definition: hidsys.h:69
u8 finalStepDuration
Final Step Duration Multiplier of Mini Cycle X. Value 0x0: 12.5ms, 0x1 - xF: 1x - 15x....
Definition: hidsys.h:70
u8 ledIntensity
Mini Cycle X LED Intensity.
Definition: hidsys.h:68
Structure for hidsysSetNotificationLedPattern.
Definition: hidsys.h:77
u8 totalFullCycles
Number of Full Cycles. Value 0x1-0xF: 1 - 15 full cycles. Value 0x0 is repeat forever,...
Definition: hidsys.h:80
u8 startIntensity
LED Start Intensity. Value 0x0=0% - 0xF=100%.
Definition: hidsys.h:81
u8 totalMiniCycles
Number of Mini Cycles + 1. Value 0x0-0xF: 1 - 16 mini cycles.
Definition: hidsys.h:79
u8 baseMiniCycleDuration
Mini Cycle Base Duration. Value 0x1-0xF: 12.5ms - 187.5ms. Value 0x0 = 0ms/OFF.
Definition: hidsys.h:78
UniquePadId for a controller.
Definition: hidsys.h:57
u64 id
UniquePadId.
Definition: hidsys.h:58
UniquePadSerialNumber.
Definition: hidsys.h:62
Service object structure.
Definition: service.h:14
uint64_t u64
64-bit unsigned integer.
Definition: types.h:22
uint8_t u8
8-bit unsigned integer.
Definition: types.h:19
u32 Result
Function error code result type.
Definition: types.h:44
int32_t s32
32-bit signed integer.
Definition: types.h:27
uint32_t u32
32-bit unsigned integer.
Definition: types.h:21