new USB_GetHIDDescriptor()
[libogc.git] / gc / ogc / conf.h
blob4cdf2962a7a50f2ea493136ba576f6223bb0fbfe
1 /*-------------------------------------------------------------
3 conf.h -- SYSCONF support
5 Copyright (C) 2008
6 Hector Martin (marcan)
8 This software is provided 'as-is', without any express or implied
9 warranty. In no event will the authors be held liable for any
10 damages arising from the use of this software.
12 Permission is granted to anyone to use this software for any
13 purpose, including commercial applications, and to alter it and
14 redistribute it freely, subject to the following restrictions:
16 1. The origin of this software must not be misrepresented; you
17 must not claim that you wrote the original software. If you use
18 this software in a product, an acknowledgment in the product
19 documentation would be appreciated but is not required.
21 2. Altered source versions must be plainly marked as such, and
22 must not be misrepresented as being the original software.
24 3. This notice may not be removed or altered from any source
25 distribution.
27 -------------------------------------------------------------*/
29 #ifndef __CONF_H__
30 #define __CONF_H__
32 #if defined(HW_RVL)
34 #include <gctypes.h>
35 #include <gcutil.h>
37 #define CONF_EBADFILE -0x6001
38 #define CONF_ENOENT -0x6002
39 #define CONF_ETOOBIG -0x6003
40 #define CONF_ENOTINIT -0x6004
41 #define CONF_ENOTIMPL -0x6005
42 #define CONF_EBADVALUE -0x6006
43 #define CONF_ENOMEM -0x6007
44 #define CONF_ERR_OK 0
46 #ifdef __cplusplus
47 extern "C" {
48 #endif /* __cplusplus */
50 enum {
51 CONF_BIGARRAY = 1,
52 CONF_SMALLARRAY,
53 CONF_BYTE,
54 CONF_SHORT,
55 CONF_LONG,
56 CONF_BOOL = 7
59 enum {
60 CONF_VIDEO_NTSC = 0,
61 CONF_VIDEO_PAL,
62 CONF_VIDEO_MPAL
65 enum {
66 CONF_REGION_JP = 0,
67 CONF_REGION_US = 1,
68 CONF_REGION_EU = 2,
69 CONF_REGION_KR = 4,
70 CONF_REGION_CN = 5
73 enum {
74 CONF_AREA_JPN = 0,
75 CONF_AREA_USA,
76 CONF_AREA_EUR,
77 CONF_AREA_AUS,
78 CONF_AREA_BRA,
79 CONF_AREA_TWN,
80 CONF_AREA_ROC,
81 CONF_AREA_KOR,
82 CONF_AREA_HKG,
83 CONF_AREA_ASI,
84 CONF_AREA_LTN,
85 CONF_AREA_SAF,
86 CONF_AREA_CHN
89 enum {
90 CONF_SHUTDOWN_STANDBY = 0,
91 CONF_SHUTDOWN_IDLE
94 enum {
95 CONF_LED_OFF = 0,
96 CONF_LED_DIM,
97 CONF_LED_BRIGHT
100 enum {
101 CONF_SOUND_MONO = 0,
102 CONF_SOUND_STEREO,
103 CONF_SOUND_SURROUND
106 enum {
107 CONF_LANG_JAPANESE = 0,
108 CONF_LANG_ENGLISH,
109 CONF_LANG_GERMAN,
110 CONF_LANG_FRENCH,
111 CONF_LANG_SPANISH,
112 CONF_LANG_ITALIAN,
113 CONF_LANG_DUTCH,
114 CONF_LANG_SIMP_CHINESE,
115 CONF_LANG_TRAD_CHINESE,
116 CONF_LANG_KOREAN
119 enum {
120 CONF_ASPECT_4_3 = 0,
121 CONF_ASPECT_16_9
124 enum {
125 CONF_SENSORBAR_BOTTOM = 0,
126 CONF_SENSORBAR_TOP
129 #define CONF_PAD_MAX_REGISTERED 10
130 #define CONF_PAD_MAX_ACTIVE 4
132 typedef struct _conf_pad_device conf_pad_device;
134 struct _conf_pad_device {
135 u8 bdaddr[6];
136 char name[0x40];
137 } ATTRIBUTE_PACKED;
139 typedef struct _conf_pads conf_pads;
141 struct _conf_pads {
142 u8 num_registered;
143 conf_pad_device registered[CONF_PAD_MAX_REGISTERED];
144 conf_pad_device active[CONF_PAD_MAX_ACTIVE];
145 conf_pad_device balance_board;
146 conf_pad_device unknown;
147 } ATTRIBUTE_PACKED;
149 s32 CONF_Init(void);
150 s32 CONF_GetLength(const char *name);
151 s32 CONF_GetType(const char *name);
152 s32 CONF_Get(const char *name, void *buffer, u32 length);
153 s32 CONF_GetShutdownMode(void);
154 s32 CONF_GetIdleLedMode(void);
155 s32 CONF_GetProgressiveScan(void);
156 s32 CONF_GetEuRGB60(void);
157 s32 CONF_GetIRSensitivity(void);
158 s32 CONF_GetSensorBarPosition(void);
159 s32 CONF_GetPadSpeakerVolume(void);
160 s32 CONF_GetPadMotorMode(void);
161 s32 CONF_GetSoundMode(void);
162 s32 CONF_GetLanguage(void);
163 s32 CONF_GetCounterBias(u32 *bias);
164 s32 CONF_GetScreenSaverMode(void);
165 s32 CONF_GetDisplayOffsetH(s8 *offset);
166 s32 CONF_GetPadDevices(conf_pads *pads);
167 s32 CONF_GetNickName(u8 *nickname);
168 s32 CONF_GetAspectRatio(void);
169 s32 CONF_GetEULA(void);
170 s32 CONF_GetParentalPassword(s8 *password);
171 s32 CONF_GetParentalAnswer(s8 *answer);
172 s32 CONF_GetWiiConnect24(void);
173 s32 CONF_GetRegion(void);
174 s32 CONF_GetArea(void);
175 s32 CONF_GetVideo(void);
177 #ifdef __cplusplus
179 #endif /* __cplusplus */
181 #endif
183 #endif