1
2
3
4
5
6
7
8 #ifndef FW_TYPES_H
9 #define FW_TYPES_H
10 struct led_control {int led_num; int action; int brightness; int blink_count;};
11
12 #if !CAM_DRYOS_REL
13
14 struct __stat
15 {
16 unsigned long st_dev;
17 unsigned long st_ino;
18 unsigned short st_mode;
19 short st_nlink;
20 short st_uid;
21 short st_gid;
22 unsigned long st_rdev;
23 unsigned long st_size;
24 unsigned long st_atime;
25 unsigned long st_mtime;
26 unsigned long st_ctime;
27 long st_blksize;
28 long st_blocks;
29 unsigned char st_attrib;
30 int reserved1;
31 int reserved2;
32 int reserved3;
33 int reserved4;
34 int reserved5;
35 int reserved6;
36 };
37
38 #elif CAM_DRYOS_REL < 39
39 struct __stat
40 {
41 unsigned long st_dev;
42 unsigned long st_ino;
43 unsigned short st_mode;
44 short st_nlink;
45 short st_uid;
46 short st_gid;
47 unsigned long st_atime;
48 unsigned long st_mtime;
49 unsigned long st_ctime;
50 unsigned long st_size;
51 long st_blksize;
52 long st_blocks;
53 unsigned char st_attrib;
54 int reserved1;
55 int reserved2;
56 int reserved3;
57 int reserved4;
58 int reserved5;
59 int reserved6;
60 };
61
62 #elif CAM_DRYOS_REL < 59
63
64 struct __stat
65 {
66 unsigned long st_unknown_1;
67 unsigned long st_attrib;
68 unsigned long st_size;
69 unsigned long st_ctime;
70 unsigned long st_mtime;
71 unsigned long st_unknown_2;
72 };
73
74 #else
75
76 struct __stat
77 {
78 unsigned long st_unknown_1;
79 unsigned long st_attrib;
80 unsigned long st_size;
81 unsigned long st_unknown_2;
82 unsigned long st_ctime;
83 unsigned long st_mtime;
84 unsigned long st_unknown_3;
85 };
86
87 #endif
88
89
90 typedef struct {
91 int code;
92 int sess_id;
93 int trans_id;
94 int num_param;
95 int param1;
96 int param2;
97 int param3;
98 int param4;
99 int param5;
100 } PTPContainer;
101
102 typedef struct {
103 int handle;
104 int (*send_data)(int handle, const char *buf, int part_size, int total_size, int, int, int);
105 int (*recv_data)(int handle, char *buf, int size, int, int);
106 #ifdef VX_OLD_PTP
107 int (*send_resp)(int handle, PTPContainer *resp, int zero);
108 #else
109 int (*send_resp)(int handle, PTPContainer *resp);
110 #endif
111 int (*get_data_size)(int handle);
112 int (*send_err_resp)(int handle, PTPContainer *resp);
113 int unknown1;
114 int (*f2)();
115 int (*f3)();
116 int more[1];
117
118 } ptp_data;
119
120 typedef int (*ptp_handler)(int, ptp_data*, int, int, int, int, int, int, int, int);
121
122
123 typedef struct {
124 const char *name;
125 int (*func)();
126 } eventproc_table_entry;
127
128
129
130
131
132 typedef struct FILE_S {
133 int fd;
134 unsigned len;
135 int unk0;
136 unsigned pos;
137
138 int unk1;
139 int unk2;
140 char * io_buf;
141 int unk3;
142 char name[127];
143 } FILE;
144
145
146
147 typedef struct mzrm_context_s mzrm_context;
148 typedef struct mzrm_context_s {
149 int unk0;
150 int sem;
151 unsigned alloc_avail;
152 int unk1;
153 int index1;
154 int index2;
155 int unk2[3];
156 void (*maybe_wait_fn)(mzrm_context *ctx);
157 int unk3[2];
158 };
159
160 typedef struct mzrm_msg_s {
161 int msg_type;
162 int unk;
163 int payload_size;
164 int payload[16];
165 } mzrm_msg;
166 #endif
167