SyntekUSBVideoCamera
stk11xx-dev-6a51.c
Go to the documentation of this file.
1 
34 #include <linux/module.h>
35 #include <linux/init.h>
36 #include <linux/kernel.h>
37 #include <linux/version.h>
38 #include <linux/errno.h>
39 #include <linux/slab.h>
40 #include <linux/kref.h>
41 
42 #include <linux/usb.h>
43 #include <media/v4l2-common.h>
44 #include <media/v4l2-ioctl.h>
45 
46 #include "stk11xx.h"
47 #include "stk11xx-dev.h"
48 
49 
50 //=============================================================================
51 //
52 // STK-6A51 API
53 //
54 //=============================================================================
55 
56 
71 {
72  int i;
73  int value;
74 
75  STK_INFO("Initialize USB2.0 Syntek Camera\n");
76 
77  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
78  usb_stk11xx_write_registry(dev, 0x0002, 0x0078);
79  usb_stk11xx_write_registry(dev, 0x0003, 0x0080);
80 
81  usb_stk11xx_write_registry(dev, 0x0002, 0x007f);
82  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
83  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
84  usb_stk11xx_write_registry(dev, 0x0000, 0x0026);
85  usb_stk11xx_write_registry(dev, 0x0000, 0x0027);
86  usb_stk11xx_write_registry(dev, 0x0000, 0x0026);
87  usb_stk11xx_write_registry(dev, 0x0000, 0x0026);
88  usb_stk11xx_write_registry(dev, 0x0000, 0x0027);
89  usb_stk11xx_write_registry(dev, 0x0000, 0x0026);
90  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
91  usb_stk11xx_write_registry(dev, 0x0000, 0x0025);
92  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
93  usb_stk11xx_write_registry(dev, 0x0000, 0x0026);
94  usb_stk11xx_write_registry(dev, 0x0000, 0x0027);
95  usb_stk11xx_write_registry(dev, 0x0000, 0x0026);
96  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
97  usb_stk11xx_write_registry(dev, 0x0000, 0x0025);
98  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
99  usb_stk11xx_write_registry(dev, 0x0000, 0x0026);
100  usb_stk11xx_write_registry(dev, 0x0000, 0x0027);
101  usb_stk11xx_write_registry(dev, 0x0000, 0x0026);
102  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
103  usb_stk11xx_write_registry(dev, 0x0000, 0x0025);
104  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
105  usb_stk11xx_write_registry(dev, 0x0000, 0x0026);
106  usb_stk11xx_write_registry(dev, 0x0000, 0x0027);
107  usb_stk11xx_write_registry(dev, 0x0000, 0x0026);
108  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
109  usb_stk11xx_write_registry(dev, 0x0000, 0x0025);
110  usb_stk11xx_write_registry(dev, 0x0002, 0x007d);
111  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
112 
113  for (i=0; i<16; i++) {
114  usb_stk11xx_write_registry(dev, 0x0000, 0x0025);
115  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
116  usb_stk11xx_read_registry(dev, 0x0000, &value);
117 
118  STK_DEBUG("Loop 1 : Read 0x0000 = %02X\n", value);
119  }
120 
121  usb_stk11xx_write_registry(dev, 0x0000, 0x0025);
122  usb_stk11xx_write_registry(dev, 0x0000, 0x0020);
123 
124  usb_stk11xx_write_registry(dev, 0x0002, 0x007f);
125  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
126  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
127  usb_stk11xx_write_registry(dev, 0x0000, 0x0026);
128  usb_stk11xx_write_registry(dev, 0x0000, 0x0027);
129  usb_stk11xx_write_registry(dev, 0x0000, 0x0026);
130  usb_stk11xx_write_registry(dev, 0x0000, 0x0026);
131  usb_stk11xx_write_registry(dev, 0x0000, 0x0027);
132  usb_stk11xx_write_registry(dev, 0x0000, 0x0026);
133  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
134  usb_stk11xx_write_registry(dev, 0x0000, 0x0025);
135  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
136  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
137  usb_stk11xx_write_registry(dev, 0x0000, 0x0025);
138  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
139  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
140  usb_stk11xx_write_registry(dev, 0x0000, 0x0025);
141  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
142  usb_stk11xx_write_registry(dev, 0x0000, 0x0026);
143  usb_stk11xx_write_registry(dev, 0x0000, 0x0027);
144  usb_stk11xx_write_registry(dev, 0x0000, 0x0026);
145  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
146  usb_stk11xx_write_registry(dev, 0x0000, 0x0025);
147  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
148  usb_stk11xx_write_registry(dev, 0x0000, 0x0026);
149  usb_stk11xx_write_registry(dev, 0x0000, 0x0027);
150  usb_stk11xx_write_registry(dev, 0x0000, 0x0026);
151  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
152  usb_stk11xx_write_registry(dev, 0x0000, 0x0025);
153  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
154  usb_stk11xx_write_registry(dev, 0x0000, 0x0026);
155  usb_stk11xx_write_registry(dev, 0x0000, 0x0027);
156  usb_stk11xx_write_registry(dev, 0x0000, 0x0026);
157  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
158  usb_stk11xx_write_registry(dev, 0x0000, 0x0025);
159  usb_stk11xx_write_registry(dev, 0x0002, 0x007d);
160  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
161 
162  for (i=0; i<16; i++) {
163  usb_stk11xx_write_registry(dev, 0x0000, 0x0025);
164  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
165  usb_stk11xx_read_registry(dev, 0x0000, &value);
166 
167  STK_DEBUG("Loop 2 : Read 0x0000 = %02X\n", value);
168  }
169 
170  usb_stk11xx_write_registry(dev, 0x0000, 0x0025);
171  usb_stk11xx_write_registry(dev, 0x0000, 0x0020);
172 
173  usb_stk11xx_write_registry(dev, 0x0002, 0x007f);
174  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
175  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
176  usb_stk11xx_write_registry(dev, 0x0000, 0x0026);
177  usb_stk11xx_write_registry(dev, 0x0000, 0x0027);
178  usb_stk11xx_write_registry(dev, 0x0000, 0x0026);
179  usb_stk11xx_write_registry(dev, 0x0000, 0x0026);
180  usb_stk11xx_write_registry(dev, 0x0000, 0x0027);
181  usb_stk11xx_write_registry(dev, 0x0000, 0x0026);
182  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
183  usb_stk11xx_write_registry(dev, 0x0000, 0x0025);
184  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
185  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
186  usb_stk11xx_write_registry(dev, 0x0000, 0x0025);
187  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
188  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
189  usb_stk11xx_write_registry(dev, 0x0000, 0x0025);
190  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
191  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
192  usb_stk11xx_write_registry(dev, 0x0000, 0x0025);
193  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
194  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
195  usb_stk11xx_write_registry(dev, 0x0000, 0x0025);
196  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
197  usb_stk11xx_write_registry(dev, 0x0000, 0x0026);
198  usb_stk11xx_write_registry(dev, 0x0000, 0x0027);
199  usb_stk11xx_write_registry(dev, 0x0000, 0x0026);
200  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
201  usb_stk11xx_write_registry(dev, 0x0000, 0x0025);
202  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
203  usb_stk11xx_write_registry(dev, 0x0000, 0x0026);
204  usb_stk11xx_write_registry(dev, 0x0000, 0x0027);
205  usb_stk11xx_write_registry(dev, 0x0000, 0x0026);
206  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
207  usb_stk11xx_write_registry(dev, 0x0000, 0x0025);
208  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
209  usb_stk11xx_write_registry(dev, 0x0000, 0x0026);
210  usb_stk11xx_write_registry(dev, 0x0000, 0x0027);
211  usb_stk11xx_write_registry(dev, 0x0000, 0x0026);
212  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
213  usb_stk11xx_write_registry(dev, 0x0000, 0x0025);
214  usb_stk11xx_write_registry(dev, 0x0002, 0x007d);
215  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
216 
217  for (i=0; i<16; i++) {
218  usb_stk11xx_write_registry(dev, 0x0000, 0x0025);
219  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
220  usb_stk11xx_read_registry(dev, 0x0000, &value);
221 
222  STK_DEBUG("Loop 3 : Read 0x0000 = %02X\n", value);
223  }
224 
225  usb_stk11xx_write_registry(dev, 0x0000, 0x0025);
226  usb_stk11xx_write_registry(dev, 0x0000, 0x0020);
227  usb_stk11xx_write_registry(dev, 0x0002, 0x007f);
228  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
229  usb_stk11xx_write_registry(dev, 0x0000, 0x0020);
230 
231  usb_stk11xx_write_registry(dev, 0x0117, 0x0000);
232  usb_stk11xx_read_registry(dev, 0x0103, &value);
233  usb_stk11xx_write_registry(dev, 0x0103, 0x0001);
234  usb_stk11xx_read_registry(dev, 0x0103, &value);
235  usb_stk11xx_write_registry(dev, 0x0103, 0x0000);
236 
237  usb_stk11xx_write_registry(dev, 0x0000, 0x00e0);
238  usb_stk11xx_write_registry(dev, 0x0002, 0x00f8);
239  usb_stk11xx_write_registry(dev, 0x0002, 0x0078);
240  usb_stk11xx_write_registry(dev, 0x0000, 0x0020);
241 
243  dev_stk11xx_check_device(dev, 65);
244  usb_stk11xx_write_registry(dev, 0x0200, 0x0008);
245 
247  dev_stk11xx_check_device(dev, 65);
248  usb_stk11xx_write_registry(dev, 0x0200, 0x0008);
249 
251  dev_stk11xx_check_device(dev, 65);
252  usb_stk11xx_write_registry(dev, 0x0200, 0x0008);
253 
255  dev_stk11xx_check_device(dev, 65);
256  usb_stk11xx_write_registry(dev, 0x0200, 0x0008);
257 
259  dev_stk11xx_check_device(dev, 65);
260  usb_stk11xx_write_registry(dev, 0x0200, 0x0008);
261 
263  dev_stk11xx_check_device(dev, 65);
264  usb_stk11xx_write_registry(dev, 0x0200, 0x0008);
265 
267  dev_stk11xx_check_device(dev, 65);
268  usb_stk11xx_write_registry(dev, 0x0200, 0x0008);
269 
271  dev_stk11xx_check_device(dev, 65);
272  usb_stk11xx_write_registry(dev, 0x0200, 0x0008);
273 
275  dev_stk11xx_check_device(dev, 65);
276  usb_stk11xx_write_registry(dev, 0x0200, 0x0008);
277 
279  dev_stk11xx_check_device(dev, 65);
280  usb_stk11xx_write_registry(dev, 0x0200, 0x0008);
281 
283  dev_stk11xx_check_device(dev, 65);
284  usb_stk11xx_write_registry(dev, 0x0200, 0x0008);
285 
287  dev_stk11xx_check_device(dev, 65);
288  usb_stk11xx_write_registry(dev, 0x0200, 0x0008);
289 
291  dev_stk11xx_check_device(dev, 65);
292  usb_stk11xx_write_registry(dev, 0x0200, 0x0008);
293 
295 
297 
299  dev_stk11xx_check_device(dev, 65);
300  usb_stk11xx_write_registry(dev, 0x0200, 0x0008);
301 
303 
305 
306 
307 
308 
309 
311 
312  usb_stk11xx_set_feature(dev, 0);
313 
314  // Device is initialized and is ready !!!
315  STK_INFO("Syntek USB2.0 Camera is ready\n");
316 
317  return 0;
318 }
319 
320 
334 int dev_stk6a51_configure_device(struct usb_stk11xx *dev, int step)
335 {
336  int value;
337 
338  // 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19
339  static const int values_001B[] = {
340  0x0e, 0x03, 0x0e, 0x0e, 0x0e, 0x0e, 0x0e, 0x0e, 0x0e, 0x0e, 0x0e, 0x07, 0x07, 0x07, 0x07, 0x07, 0x0e, 0x0e, 0x0e, 0x0e
341  };
342  static const int values_001C[] = {
343  0x06, 0x02, 0x46, 0x46, 0x46, 0x46, 0x46, 0x46, 0x46, 0x46, 0x06, 0x06, 0x06, 0x06, 0x06, 0x06, 0x46, 0x46, 0x46, 0x46
344  };
345  static const int values_0202[] = {
346  0x1e, 0x0a, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x0a, 0x1e, 0x14, 0x1e, 0x1f, 0x0a, 0x0a, 0x0a, 0x0a
347  };
348  static const int values_0110[] = {
349  0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3e, 0x3e, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
350  };
351  static const int values_0112[] = {
352  0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x09, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01
353  };
354  static const int values_0114[] = {
355  0x87, 0x80, 0x80, 0x80, 0x80, 0x00, 0xbe, 0xbe, 0x80, 0x80, 0x84, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80
356  };
357  static const int values_0115[] = {
358  0x02, 0x02, 0x02, 0x02, 0x02, 0x05, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02
359  };
360  static const int values_0116[] = {
361  0xe7, 0xe0, 0xe0, 0xe0, 0xe0, 0xe0, 0xe9, 0xe9, 0xe0, 0xe0, 0xe4, 0xe0, 0xe0, 0xe0, 0xe0, 0xe0, 0xe1, 0xe1, 0xe1, 0xe1
362  };
363  static const int values_0117[] = {
364  0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x00, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01
365  };
366  static const int values_0100[] = {
367  0x20, 0x21, 0x21, 0x21, 0x21, 0x21, 0x21, 0x21, 0x21, 0x21, 0x23, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20
368  };
369 
370 
371  STK_DEBUG("dev_stk6a51_configure_device : %d\n", step);
372 
373  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
374  usb_stk11xx_write_registry(dev, 0x0002, 0x0078);
375  usb_stk11xx_write_registry(dev, 0x0003, 0x0080);
376  usb_stk11xx_write_registry(dev, 0x0005, 0x0000);
377 
378  usb_stk11xx_write_registry(dev, 0x0007, 0x0003);
379  usb_stk11xx_write_registry(dev, 0x000d, 0x0000);
380  usb_stk11xx_write_registry(dev, 0x000f, 0x0002);
381  usb_stk11xx_write_registry(dev, 0x0300, 0x0012);
382  usb_stk11xx_write_registry(dev, 0x0350, 0x0041);
383 
384  usb_stk11xx_write_registry(dev, 0x0351, 0x0000);
385  usb_stk11xx_write_registry(dev, 0x0352, 0x0000);
386  usb_stk11xx_write_registry(dev, 0x0353, 0x0000);
387  usb_stk11xx_write_registry(dev, 0x0018, 0x0010);
388  usb_stk11xx_write_registry(dev, 0x0019, 0x0000);
389 
390  usb_stk11xx_write_registry(dev, 0x001b, values_001B[step]);
391  usb_stk11xx_write_registry(dev, 0x001c, values_001C[step]);
392  usb_stk11xx_write_registry(dev, 0x0300, 0x0080);
393  usb_stk11xx_write_registry(dev, 0x001a, 0x0004);
394  usb_stk11xx_write_registry(dev, 0x0202, values_0202[step]);
395 
396  usb_stk11xx_write_registry(dev, 0x0110, values_0110[step]);
397  usb_stk11xx_write_registry(dev, 0x0111, 0x0000);
398  usb_stk11xx_write_registry(dev, 0x0112, values_0112[step]);
399  usb_stk11xx_write_registry(dev, 0x0113, 0x0000);
400  usb_stk11xx_write_registry(dev, 0x0114, values_0114[step]);
401 
402  usb_stk11xx_write_registry(dev, 0x0115, values_0115[step]);
403  usb_stk11xx_write_registry(dev, 0x0116, values_0116[step]);
404  usb_stk11xx_write_registry(dev, 0x0117, values_0117[step]);
405 
406  usb_stk11xx_read_registry(dev, 0x0100, &value);
407  usb_stk11xx_write_registry(dev, 0x0100, values_0100[step]);
408 
409 // usb_stk11xx_write_registry(dev, 0x0200, 0x0080);
410 // usb_stk11xx_write_registry(dev, 0x0200, 0x0000);
411  usb_stk11xx_write_registry(dev, 0x02ff, 0x0000);
412 
413 
414  switch (step) {
415  case 0:
416  usb_stk11xx_write_registry(dev, 0x0203, 0x0040);
417 
418  usb_stk11xx_write_registry(dev, 0x0204, 0x0041);
419  usb_stk11xx_write_registry(dev, 0x0205, 0x0001);
420  usb_stk11xx_write_registry(dev, 0x0204, 0x001c);
421  usb_stk11xx_write_registry(dev, 0x0205, 0x0002);
422 
423  usb_stk11xx_write_registry(dev, 0x0200, 0x0005);
424 
425  break;
426 
427  case 1:
428  usb_stk11xx_write_registry(dev, 0x0203, 0x0022);
429 
430  usb_stk11xx_write_registry(dev, 0x0204, 0x0027);
431  usb_stk11xx_write_registry(dev, 0x0205, 0x00a5);
432 
433  usb_stk11xx_write_registry(dev, 0x0200, 0x0005);
434 
435  break;
436 
437  case 2:
438  usb_stk11xx_write_registry(dev, 0x0203, 0x0060);
439 
440  usb_stk11xx_write_registry(dev, 0x0204, 0x0012);
441  usb_stk11xx_write_registry(dev, 0x0205, 0x0080);
442  usb_stk11xx_write_registry(dev, 0x0204, 0x0013);
443  usb_stk11xx_write_registry(dev, 0x0205, 0x00bf);
444 
445  usb_stk11xx_write_registry(dev, 0x0200, 0x0005);
446 
447  break;
448 
449  case 3:
450  usb_stk11xx_write_registry(dev, 0x0203, 0x0042);
451 
452  usb_stk11xx_write_registry(dev, 0x0204, 0x0012);
453  usb_stk11xx_write_registry(dev, 0x0205, 0x0080);
454  usb_stk11xx_write_registry(dev, 0x0204, 0x0024);
455  usb_stk11xx_write_registry(dev, 0x0205, 0x00a5);
456 
457  usb_stk11xx_write_registry(dev, 0x0200, 0x0005);
458 
459  break;
460 
461  case 4:
462  usb_stk11xx_write_registry(dev, 0x0203, 0x0042);
463 
464  usb_stk11xx_write_registry(dev, 0x0204, 0x0012);
465  usb_stk11xx_write_registry(dev, 0x0205, 0x0080);
466  usb_stk11xx_write_registry(dev, 0x0204, 0x0013);
467  usb_stk11xx_write_registry(dev, 0x0205, 0x00e0);
468  usb_stk11xx_write_registry(dev, 0x0204, 0x0024);
469  usb_stk11xx_write_registry(dev, 0x0205, 0x00a5);
470 
471  usb_stk11xx_write_registry(dev, 0x0200, 0x0005);
472 
473  break;
474 
475  case 5:
476  usb_stk11xx_write_registry(dev, 0x0203, 0x0042);
477 
478  usb_stk11xx_write_registry(dev, 0x0204, 0x0012);
479  usb_stk11xx_write_registry(dev, 0x0205, 0x0080);
480  usb_stk11xx_write_registry(dev, 0x0204, 0x0013);
481  usb_stk11xx_write_registry(dev, 0x0205, 0x00bf);
482 
483  usb_stk11xx_write_registry(dev, 0x0200, 0x0005);
484 
485  break;
486 
487  case 6:
488  usb_stk11xx_write_registry(dev, 0x0203, 0x0060);
489 
490  usb_stk11xx_write_registry(dev, 0x0204, 0x0012);
491  usb_stk11xx_write_registry(dev, 0x0205, 0x0080);
492  usb_stk11xx_write_registry(dev, 0x0204, 0x0013);
493  usb_stk11xx_write_registry(dev, 0x0205, 0x00ff);
494 
495  usb_stk11xx_write_registry(dev, 0x0200, 0x0005);
496 
497  break;
498 
499  case 7:
500  usb_stk11xx_write_registry(dev, 0x0203, 0x0060);
501 
502  usb_stk11xx_write_registry(dev, 0x0204, 0x0012);
503  usb_stk11xx_write_registry(dev, 0x0205, 0x0080);
504  usb_stk11xx_write_registry(dev, 0x0204, 0x0013);
505  usb_stk11xx_write_registry(dev, 0x0205, 0x00ff);
506 
507  usb_stk11xx_write_registry(dev, 0x0200, 0x0005);
508 
509  break;
510 
511  case 8:
512  usb_stk11xx_write_registry(dev, 0x0203, 0x0060);
513 
514  usb_stk11xx_write_registry(dev, 0x0204, 0x0012);
515  usb_stk11xx_write_registry(dev, 0x0205, 0x0080);
516  usb_stk11xx_write_registry(dev, 0x0204, 0x0013);
517  usb_stk11xx_write_registry(dev, 0x0205, 0x00b7);
518 
519  usb_stk11xx_write_registry(dev, 0x0200, 0x0005);
520 
521  break;
522 
523  case 9:
524  usb_stk11xx_write_registry(dev, 0x0203, 0x0060);
525 
526  usb_stk11xx_write_registry(dev, 0x0204, 0x0012);
527  usb_stk11xx_write_registry(dev, 0x0205, 0x0080);
528  usb_stk11xx_write_registry(dev, 0x0204, 0x0013);
529  usb_stk11xx_write_registry(dev, 0x0205, 0x00b7);
530 
531  usb_stk11xx_write_registry(dev, 0x0200, 0x0005);
532 
533  break;
534 
535  case 10:
536  usb_stk11xx_write_registry(dev, 0x0203, 0x0080);
537 
538  usb_stk11xx_write_registry(dev, 0x0204, 0x0012);
539  usb_stk11xx_write_registry(dev, 0x0205, 0x0080);
540  usb_stk11xx_write_registry(dev, 0x0204, 0x000a);
541  usb_stk11xx_write_registry(dev, 0x0205, 0x00ff);
542 
543  usb_stk11xx_write_registry(dev, 0x0200, 0x0005);
544 
545  break;
546 
547  case 11:
548  usb_stk11xx_write_registry(dev, 0x0203, 0x00dc);
549 
550  usb_stk11xx_write_registry(dev, 0x0204, 0x0015);
551  usb_stk11xx_write_registry(dev, 0x0205, 0x0080);
552 
553  usb_stk11xx_write_registry(dev, 0x0200, 0x0005);
554 
555  break;
556 
557  case 12:
558  usb_stk11xx_write_registry(dev, 0x0203, 0x00ec);
559 
560  usb_stk11xx_write_registry(dev, 0x0204, 0x0015);
561  usb_stk11xx_write_registry(dev, 0x0205, 0x0080);
562 
563  usb_stk11xx_write_registry(dev, 0x0200, 0x0005);
564 
565  break;
566 
567  case 13:
568  usb_stk11xx_write_registry(dev, 0x0203, 0x00ba);
569 
570  usb_stk11xx_read_registry(dev, 0x02ff, &value);
571  usb_stk11xx_write_registry(dev, 0x02ff, 0x0000);
572 
573  usb_stk11xx_write_registry(dev, 0x0208, 0x0020);
574  usb_stk11xx_write_registry(dev, 0x0200, 0x0020);
575  dev_stk11xx_check_device(dev, 500);
576  usb_stk11xx_read_registry(dev, 0x0209, &value);
577  usb_stk11xx_write_registry(dev, 0x02ff, 0x0000);
578 
579  break;
580 
581  case 14:
582  usb_stk11xx_write_registry(dev, 0x0203, 0x00ba);
583 
584  usb_stk11xx_read_registry(dev, 0x02ff, &value);
585  usb_stk11xx_write_registry(dev, 0x02ff, 0x0000);
586 
587  usb_stk11xx_write_registry(dev, 0x0208, 0x0000);
588  usb_stk11xx_write_registry(dev, 0x0200, 0x0020);
589  dev_stk11xx_check_device(dev, 500);
590  usb_stk11xx_read_registry(dev, 0x0209, &value);
591  usb_stk11xx_write_registry(dev, 0x02ff, 0x0000);
592  usb_stk11xx_read_registry(dev, 0x02ff, &value);
593  usb_stk11xx_write_registry(dev, 0x02ff, 0x0000);
594 
595  usb_stk11xx_write_registry(dev, 0x0208, 0x00f1);
596  usb_stk11xx_write_registry(dev, 0x0200, 0x0020);
597  dev_stk11xx_check_device(dev, 500);
598  usb_stk11xx_read_registry(dev, 0x0209, &value);
599  usb_stk11xx_write_registry(dev, 0x02ff, 0x0000);
600 
601  break;
602 
603  case 15:
604  usb_stk11xx_write_registry(dev, 0x0203, 0x00ba);
605 
606  usb_stk11xx_write_registry(dev, 0x0204, 0x0001);
607  usb_stk11xx_write_registry(dev, 0x0205, 0x0000);
608  usb_stk11xx_write_registry(dev, 0x0200, 0x0005);
609 
610  break;
611 
612  case 16:
613  usb_stk11xx_write_registry(dev, 0x0203, 0x007a);
614 
615  usb_stk11xx_read_registry(dev, 0x02ff, &value);
616  usb_stk11xx_write_registry(dev, 0x02ff, 0x0000);
617  usb_stk11xx_write_registry(dev, 0x0205, 0x0030);
618  usb_stk11xx_write_registry(dev, 0x0205, 0x0000);
619  usb_stk11xx_read_registry(dev, 0x0201, &value);
620  usb_stk11xx_read_registry(dev, 0x0201, &value);
621  usb_stk11xx_read_registry(dev, 0x0201, &value);
622  usb_stk11xx_read_registry(dev, 0x0209, &value);
623  usb_stk11xx_write_registry(dev, 0x0200, 0x0020);
624  usb_stk11xx_read_registry(dev, 0x0201, &value);
625  usb_stk11xx_read_registry(dev, 0x0209, &value);
626  usb_stk11xx_write_registry(dev, 0x02ff, 0x0001);
627  usb_stk11xx_write_registry(dev, 0x02ff, 0x0000);
628 
629  usb_stk11xx_write_registry(dev, 0x0002, 0x007f);
630  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
631  usb_stk11xx_write_registry(dev, 0x0002, 0x007d);
632  usb_stk11xx_write_registry(dev, 0x0000, 0x0024);
633  usb_stk11xx_write_registry(dev, 0x0000, 0x0025);
634  usb_stk11xx_write_registry(dev, 0x0000, 0x0020);
635 
636  break;
637 
638  case 17:
639  usb_stk11xx_write_registry(dev, 0x0203, 0x007a);
640 
642 
643  usb_stk11xx_read_registry(dev, 0x02ff, &value);
644  usb_stk11xx_write_registry(dev, 0x02ff, 0x0001);
645 
646  usb_stk11xx_write_registry(dev, 0x0205, 0x0033);
647  usb_stk11xx_write_registry(dev, 0x0205, 0x0090);
648  usb_stk11xx_write_registry(dev, 0x0200, 0x0061);
649  dev_stk11xx_check_device(dev, 500);
650  usb_stk11xx_read_registry(dev, 0x0209, &value);
651  usb_stk11xx_write_registry(dev, 0x0200, 0x0020);
652  dev_stk11xx_check_device(dev, 500);
653  usb_stk11xx_read_registry(dev, 0x0209, &value);
654  usb_stk11xx_write_registry(dev, 0x02ff, 0x0001);
655  usb_stk11xx_read_registry(dev, 0x0201, &value);
656  usb_stk11xx_write_registry(dev, 0x02ff, 0x0000);
657 
658  usb_stk11xx_write_registry(dev, 0x0200, 0x0080);
659  usb_stk11xx_write_registry(dev, 0x0200, 0x0000);
660  usb_stk11xx_write_registry(dev, 0x02ff, 0x0001);
661 
662  break;
663 
664  case 18:
665  usb_stk11xx_write_registry(dev, 0x0203, 0x007a);
666 
668 
669  usb_stk11xx_read_registry(dev, 0x02ff, &value);
670  usb_stk11xx_write_registry(dev, 0x02ff, 0x0001);
671 
672  usb_stk11xx_write_registry(dev, 0x0205, 0x0033);
673  usb_stk11xx_write_registry(dev, 0x0205, 0x0090);
674  usb_stk11xx_write_registry(dev, 0x0200, 0x0061);
675  dev_stk11xx_check_device(dev, 500);
676  usb_stk11xx_read_registry(dev, 0x0209, &value);
677  usb_stk11xx_write_registry(dev, 0x0200, 0x0020);
678  dev_stk11xx_check_device(dev, 500);
679  usb_stk11xx_read_registry(dev, 0x0209, &value);
680  usb_stk11xx_write_registry(dev, 0x02ff, 0x0000);
681  break;
682 
683  case 19:
684  usb_stk11xx_write_registry(dev, 0x0203, 0x007a);
685 
687 
688  usb_stk11xx_read_registry(dev, 0x02ff, &value);
689  usb_stk11xx_write_registry(dev, 0x02ff, 0x0001);
690 
691  usb_stk11xx_write_registry(dev, 0x0205, 0x0033);
692  usb_stk11xx_write_registry(dev, 0x0205, 0x0090);
693  usb_stk11xx_write_registry(dev, 0x0200, 0x0061);
694  dev_stk11xx_check_device(dev, 500);
695  usb_stk11xx_read_registry(dev, 0x0209, &value);
696  usb_stk11xx_write_registry(dev, 0x0200, 0x0020);
697  dev_stk11xx_check_device(dev, 500);
698  usb_stk11xx_read_registry(dev, 0x0209, &value);
699  usb_stk11xx_write_registry(dev, 0x02ff, 0x0000);
700  break;
701  }
702 
703  return 0;
704 }
705 
706 
717 {
718  int value;
719 
720  usb_stk11xx_write_registry(dev, 0x0203, 0x00a0);
721 
722  usb_stk11xx_read_registry(dev, 0x0104, &value);
723  usb_stk11xx_read_registry(dev, 0x0105, &value);
724  usb_stk11xx_read_registry(dev, 0x0106, &value);
725 
726  usb_stk11xx_write_registry(dev, 0x0100, 0x0021);
727  usb_stk11xx_write_registry(dev, 0x0116, 0x0000);
728  usb_stk11xx_write_registry(dev, 0x0117, 0x0000);
729  usb_stk11xx_write_registry(dev, 0x0018, 0x0000);
730 
731  usb_stk11xx_read_registry(dev, 0x0000, &value);
732  usb_stk11xx_write_registry(dev, 0x0000, 0x0049);
733 
734  return 0;
735 }
736 
737 
749 {
751 
752  usb_stk11xx_set_feature(dev, 0);
753 
755 
756  usb_stk11xx_write_registry(dev, 0x0000, 0x00e0);
757  usb_stk11xx_write_registry(dev, 0x0002, 0x00f8);
758  usb_stk11xx_write_registry(dev, 0x0002, 0x0078);
759  usb_stk11xx_write_registry(dev, 0x0000, 0x0020);
760 
762 
764 
765  return 0;
766 }
767 
768 
780 {
781  int i;
782  int value;
783 
784  int asize;
785 
786  static const int values_205[][4] = {
787  { 0x33, 0x86, 0x05, 0x01 },
788  { 0x33, 0x86, 0x05, 0x00 },
789  { 0x33, 0x8c, 0xa1, 0x04 },
790  { 0x33, 0x90, -1 },
791  { 0x30, 0x1a, 0x0a, 0xcc },
792  { 0x32, 0x02, 0x00, 0x08 },
793  { 0x33, 0xf4, 0x03, 0x1d },
794  { 0x33, 0x8c, 0xa1, 0x04 },
795  { 0x33, 0x90, -1 },
796  { 0x33, 0x8c, 0xa1, 0x04 },
797  { 0x33, 0x90, -1 },
798  { 0x34, 0x1e, 0x8f, 0x09 },
799  { 0x34, 0x1c, 0x02, 0x50 },
800  { 0x34, 0x1e, 0x8f, 0x09 },
801  { 0x34, 0x1e, 0x8f, 0x08 },
802  { 0x33, 0x8c, 0x04, 0x00 },
803  { 0x33, 0x90, 0x30, 0x8f },
804  { 0x33, 0x92, 0xc3, 0xff },
805  { 0x33, 0x94, 0xed, 0x8f },
806  { 0x33, 0x96, 0x35, 0x8f },
807  { 0x33, 0x98, 0x18, 0x8f },
808  { 0x33, 0x9a, 0x30, 0x8f },
809  { 0x33, 0x9c, 0xc3, 0x00 },
810  { 0x33, 0x9e, 0x15, 0x8f },
811  { 0x33, 0x8c, 0x04, 0x10 },
812  { 0x33, 0x90, 0xcc, 0x00 },
813  { 0x33, 0x92, 0x07, 0xbd },
814  { 0x33, 0x94, 0x04, 0xb5 },
815  { 0x33, 0x96, 0xbd, 0x9e },
816  { 0x33, 0x98, 0x9f, 0xf6 },
817  { 0x33, 0x9a, 0x03, 0x22 },
818  { 0x33, 0x9c, 0x30, 0xe7 },
819  { 0x33, 0x9e, 0x0a, 0xf6 },
820  { 0x33, 0x8c, 0x04, 0x20 },
821  { 0x33, 0x90, 0x02, 0x39 },
822  { 0x33, 0x92, 0xc1, 0x01 },
823  { 0x33, 0x94, 0x26, 0x05 },
824  { 0x33, 0x96, 0xf6, 0x03 },
825  { 0x33, 0x98, 0x23, 0xe7 },
826  { 0x33, 0x9a, 0x0a, 0x7d },
827  { 0x33, 0x9c, 0x03, 0x21 },
828  { 0x33, 0x9e, 0x27, 0x20 },
829  { 0x33, 0x8c, 0x04, 0x30 },
830  { 0x33, 0x90, 0xf6, 0x02 },
831  { 0x33, 0x92, 0x39, 0xe7 },
832  { 0x33, 0x94, 0x02, 0x8f },
833  { 0x33, 0x96, 0xc3, 0x00 },
834  { 0x33, 0x98, 0x0b, 0x30 },
835  { 0x33, 0x9a, 0xed, 0x00 },
836  { 0x33, 0x9c, 0xfe, 0x02 },
837  { 0x33, 0x9e, 0x37, 0xee },
838  { 0x33, 0x8c, 0x04, 0x40 },
839  { 0x33, 0x90, 0x04, 0x5f },
840  { 0x33, 0x92, 0xad, 0x00 },
841  { 0x33, 0x94, 0x30, 0xe6 },
842  { 0x33, 0x96, 0x0a, 0x4f },
843  { 0x33, 0x98, 0xed, 0x08 },
844  { 0x33, 0x9a, 0xec, 0x11 },
845  { 0x33, 0x9c, 0xa3, 0x08 },
846  { 0x33, 0x9e, 0xdd, 0x56 },
847  { 0x33, 0x8c, 0x04, 0x50 },
848  { 0x33, 0x90, 0x30, 0xc6 },
849  { 0x33, 0x92, 0x13, 0x3a },
850  { 0x33, 0x94, 0x35, 0x39 },
851  { 0x33, 0x96, 0x3c, 0x3c },
852  { 0x33, 0x98, 0x3c, 0xc6 },
853  { 0x33, 0x9a, 0x01, 0xf7 },
854  { 0x33, 0x9c, 0x03, 0x21 },
855  { 0x33, 0x9e, 0xc6, 0x0a },
856  { 0x33, 0x8c, 0x04, 0x60 },
857  { 0x33, 0x90, 0xf7, 0x03 },
858  { 0x33, 0x92, 0x22, 0xf7 },
859  { 0x33, 0x94, 0x03, 0x23 },
860  { 0x33, 0x96, 0xcc, 0x03 },
861  { 0x33, 0x98, 0x03, 0x30 },
862  { 0x33, 0x9a, 0xed, 0x02 },
863  { 0x33, 0x9c, 0xfe, 0x10 },
864  { 0x33, 0x9e, 0x50, 0xec },
865  { 0x33, 0x8c, 0x04, 0x70 },
866  { 0x33, 0x90, 0x04, 0xfd },
867  { 0x33, 0x92, 0x02, 0xff },
868  { 0x33, 0x94, 0xfe, 0x02 },
869  { 0x33, 0x96, 0xff, 0xec },
870  { 0x33, 0x98, 0x00, 0xfd },
871  { 0x33, 0x9a, 0x03, 0x01 },
872  { 0x33, 0x9c, 0x5f, 0x4f },
873  { 0x33, 0x9e, 0x30, 0xed },
874  { 0x33, 0x8c, 0x04, 0x80 },
875  { 0x33, 0x90, 0x04, 0xec },
876  { 0x33, 0x92, 0x04, 0x05 },
877  { 0x33, 0x94, 0xf3, 0x03 },
878  { 0x33, 0x96, 0x01, 0x8f },
879  { 0x33, 0x98, 0xec, 0x00 },
880  { 0x33, 0x9a, 0x30, 0xed },
881  { 0x33, 0x9c, 0x00, 0xec },
882  { 0x33, 0x9e, 0x04, 0x05 },
883  { 0x33, 0x8c, 0x04, 0x90 },
884  { 0x33, 0x90, 0xe3, 0x02 },
885  { 0x33, 0x92, 0x18, 0x8f },
886  { 0x33, 0x94, 0xec, 0x00 },
887  { 0x33, 0x96, 0x18, 0xed },
888  { 0x33, 0x98, 0x00, 0xec },
889  { 0x33, 0x9a, 0x04, 0xc3 },
890  { 0x33, 0x9c, 0x00, 0x01 },
891  { 0x33, 0x9e, 0xed, 0x04 },
892  { 0x33, 0x8c, 0x04, 0xa0 },
893  { 0x33, 0x90, 0x83, 0x00 },
894  { 0x33, 0x92, 0x0f, 0x25 },
895  { 0x33, 0x94, 0xdc, 0xee },
896  { 0x33, 0x96, 0x02, 0xcc },
897  { 0x33, 0x98, 0x04, 0x00 },
898  { 0x33, 0x9a, 0xed, 0x04 },
899  { 0x33, 0x9c, 0xcc, 0x03 },
900  { 0x33, 0x9e, 0x03, 0xdd },
901  { 0x33, 0x8c, 0x04, 0xb0 },
902  { 0x33, 0x90, 0x52, 0x38 },
903  { 0x33, 0x92, 0x38, 0x38 },
904  { 0x33, 0x94, 0x39, 0x37 },
905  { 0x33, 0x96, 0x36, 0x8f },
906  { 0x33, 0x98, 0x30, 0xe3 },
907  { 0x33, 0x9a, 0x00, 0x8f },
908  { 0x33, 0x9c, 0x18, 0x8f },
909  { 0x33, 0x9e, 0x18, 0x30 },
910  { 0x33, 0x8c, 0x04, 0xc0 },
911  { 0x33, 0x90, 0x18, 0xe3 },
912  { 0x33, 0x92, 0x00, 0x18 },
913  { 0x33, 0x94, 0x8f, 0x32 },
914  { 0x33, 0x96, 0x33, 0x36 },
915  { 0x33, 0x98, 0xa6, 0x00 },
916  { 0x33, 0x9a, 0x18, 0xa7 },
917  { 0x33, 0x9c, 0x00, 0x09 },
918  { 0x33, 0x9e, 0x18, 0x09 },
919  { 0x33, 0x8c, 0x04, 0xd0 },
920  { 0x33, 0x90, 0xc0, 0x01 },
921  { 0x33, 0x92, 0x24, 0xf4 },
922  { 0x33, 0x94, 0x32, 0x80 },
923  { 0x33, 0x96, 0x01, 0x24 },
924  { 0x33, 0x98, 0xee, 0x39 },
925  { 0x33, 0x8c, 0x20, 0x03 },
926  { 0x33, 0x90, 0x04, 0x56 },
927  { 0x33, 0x8c, 0xa0, 0x02 },
928  { 0x33, 0x90, 0x00, 0x01 },
929  { 0x33, 0x8c, 0xa1, 0x04 },
930  { 0x33, 0x90, -1 },
931  { 0x34, 0xce, 0x81, 0x60 },
932  { 0x34, 0xd0, 0x66, 0x33 },
933  { 0x34, 0xd2, 0x31, 0x9a },
934  { 0x34, 0xd4, 0x94, 0x63 },
935  { 0x34, 0xd6, 0x4b, 0x25 },
936  { 0x34, 0xd8, 0x26, 0x70 },
937  { 0x34, 0xda, 0x72, 0x4c },
938  { 0x34, 0xdc, 0xff, 0x04 },
939  { 0x34, 0xde, 0x00, 0xf4 },
940  { 0x34, 0xe6, 0x00, 0xcc },
941  { 0x34, 0xee, 0x0e, 0x42 },
942  { 0x34, 0xf6, 0x0d, 0xb5 },
943  { 0x35, 0x00, 0x0a, 0xfa },
944  { 0x35, 0x08, 0x0f, 0x10 },
945  { 0x35, 0x10, 0x11, 0x22 },
946  { 0x35, 0x18, 0x0c, 0x28 },
947  { 0x35, 0x20, 0x1c, 0x2c },
948  { 0x35, 0x28, 0x17, 0x40 },
949  { 0x35, 0x30, 0x08, 0xf2 },
950  { 0x35, 0x38, 0xfb, 0xd5 },
951  { 0x35, 0x4c, 0x05, 0xc7 },
952  { 0x35, 0x44, 0x04, 0xf9 },
953  { 0x35, 0x5c, 0x05, 0xd0 },
954  { 0x35, 0x54, 0x05, 0xf4 },
955  { 0x34, 0xe0, 0x01, 0x05 },
956  { 0x34, 0xe8, 0x00, 0xa0 },
957  { 0x34, 0xf0, 0x0e, 0xa1 },
958  { 0x34, 0xf8, 0x0e, 0x01 },
959  { 0x35, 0x02, 0x0f, 0xeb },
960  { 0x35, 0x0a, 0x09, 0x0a },
961  { 0x35, 0x12, 0x10, 0x1e },
962  { 0x35, 0x1a, 0x08, 0x23 },
963  { 0x35, 0x22, 0x1c, 0x22 },
964  { 0x35, 0x2a, 0x07, 0x22 },
965  { 0x35, 0x32, 0x0b, 0x06 },
966  { 0x35, 0x3a, 0xf9, 0x16 },
967  { 0x35, 0x4e, 0x05, 0x9f },
968  { 0x35, 0x46, 0x05, 0x30 },
969  { 0x35, 0x5e, 0x06, 0x75 },
970  { 0x35, 0x56, 0x06, 0x5c },
971  { 0x34, 0xe4, 0x00, 0xc5 },
972  { 0x34, 0xec, 0x00, 0x48 },
973  { 0x34, 0xf4, 0x0f, 0x66 },
974  { 0x34, 0xfc, 0x0e, 0x61 },
975  { 0x35, 0x06, 0x1b, 0xdb },
976  { 0x35, 0x0e, 0x04, 0x0a },
977  { 0x35, 0x16, 0x11, 0x13 },
978  { 0x35, 0x1e, 0x08, 0x1f },
979  { 0x35, 0x26, 0x11, 0x19 },
980  { 0x35, 0x2e, 0xf8, 0x1a },
981  { 0x35, 0x36, 0x04, 0x0c },
982  { 0x35, 0x3e, 0xfa, 0x00 },
983  { 0x35, 0x52, 0x06, 0xf1 },
984  { 0x35, 0x4a, 0x04, 0x0e },
985  { 0x35, 0x62, 0x06, 0xa1 },
986  { 0x35, 0x5a, 0x06, 0x91 },
987  { 0x34, 0xe2, 0x00, 0xd2 },
988  { 0x34, 0xea, 0x00, 0x72 },
989  { 0x34, 0xf2, 0x0e, 0x1d },
990  { 0x34, 0xfa, 0x0e, 0x06 },
991  { 0x35, 0x04, 0x13, 0x0e },
992  { 0x35, 0x0c, 0x0f, 0x0d },
993  { 0x35, 0x14, 0x13, 0x1c },
994  { 0x35, 0x1c, 0x13, 0x29 },
995  { 0x35, 0x24, 0x0d, 0x24 },
996  { 0x35, 0x2c, 0xfd, 0x29 },
997  { 0x35, 0x34, 0x07, 0xf4 },
998  { 0x35, 0x3c, 0xee, 0xe7 },
999  { 0x35, 0x50, 0x06, 0x50 },
1000  { 0x35, 0x48, 0x05, 0xc1 },
1001  { 0x35, 0x60, 0x06, 0x11 },
1002  { 0x35, 0x58, 0x06, 0x58 },
1003  { 0x35, 0x40, 0x00, 0x00 },
1004  { 0x35, 0x42, 0x00, 0x00 },
1005  { 0x32, 0x10, 0x01, 0xfc },
1006  { 0x33, 0x8c, 0xa3, 0x52 },
1007  { 0x33, 0x90, 0x00, 0x3c },
1008  { 0x33, 0x8c, 0xa1, 0x18 },
1009  { 0x33, 0x90, 0x00, 0x3c },
1010  { 0x33, 0x8c, 0xa1, 0x19 },
1011  { 0x33, 0x90, 0x00, 0x0a },
1012  { 0x33, 0x8c, 0xa7, 0x6d },
1013  { 0x33, 0x90, 0x00, 0x03 },
1014  { 0x33, 0x8c, 0xa7, 0x6e },
1015  { 0x33, 0x90, 0x00, 0x03 },
1016  { 0x33, 0x8c, 0xa7, 0x6f },
1017  { 0x33, 0x90, 0x00, 0x00 },
1018  { 0x33, 0x8c, 0xa7, 0x70 },
1019  { 0x33, 0x90, 0x00, 0x05 },
1020  { 0x33, 0x8c, 0xa7, 0x71 },
1021  { 0x33, 0x90, 0x00, 0x10 },
1022  { 0x33, 0x8c, 0xa7, 0x72 },
1023  { 0x33, 0x90, 0x00, 0x30 },
1024  { 0x33, 0x8c, 0xa7, 0x73 },
1025  { 0x33, 0x90, 0x00, 0x5b },
1026  { 0x33, 0x8c, 0xa7, 0x74 },
1027  { 0x33, 0x90, 0x00, 0x77 },
1028  { 0x33, 0x8c, 0xa7, 0x75 },
1029  { 0x33, 0x90, 0x00, 0x8e },
1030  { 0x33, 0x8c, 0xa7, 0x76 },
1031  { 0x33, 0x90, 0x00, 0xa0 },
1032  { 0x33, 0x8c, 0xa7, 0x77 },
1033  { 0x33, 0x90, 0x00, 0xaf },
1034  { 0x33, 0x8c, 0xa7, 0x78 },
1035  { 0x33, 0x90, 0x00, 0xbc },
1036  { 0x33, 0x8c, 0xa7, 0x79 },
1037  { 0x33, 0x90, 0x00, 0xc7 },
1038  { 0x33, 0x8c, 0xa7, 0x7a },
1039  { 0x33, 0x90, 0x00, 0xd0 },
1040  { 0x33, 0x8c, 0xa7, 0x7b },
1041  { 0x33, 0x90, 0x00, 0xd9 },
1042  { 0x33, 0x8c, 0xa7, 0x7c },
1043  { 0x33, 0x90, 0x00, 0xe0 },
1044  { 0x33, 0x8c, 0xa7, 0x7d },
1045  { 0x33, 0x90, 0x00, 0xe8 },
1046  { 0x33, 0x8c, 0xa7, 0x7e },
1047  { 0x33, 0x90, 0x00, 0xee },
1048  { 0x33, 0x8c, 0xa7, 0x7f },
1049  { 0x33, 0x90, 0x00, 0xf4 },
1050  { 0x33, 0x8c, 0xa7, 0x80 },
1051  { 0x33, 0x90, 0x00, 0xfa },
1052  { 0x33, 0x8c, 0xa7, 0x81 },
1053  { 0x33, 0x90, 0x00, 0xff },
1054  { 0x33, 0x8c, 0xa7, 0x82 },
1055  { 0x33, 0x90, 0x00, 0x00 },
1056  { 0x33, 0x8c, 0xa7, 0x83 },
1057  { 0x33, 0x90, 0x00, 0x05 },
1058  { 0x33, 0x8c, 0xa7, 0x84 },
1059  { 0x33, 0x90, 0x00, 0x10 },
1060  { 0x33, 0x8c, 0xa7, 0x85 },
1061  { 0x33, 0x90, 0x00, 0x30 },
1062  { 0x33, 0x8c, 0xa7, 0x86 },
1063  { 0x33, 0x90, 0x00, 0x5b },
1064  { 0x33, 0x8c, 0xa7, 0x87 },
1065  { 0x33, 0x90, 0x00, 0x77 },
1066  { 0x33, 0x8c, 0xa7, 0x88 },
1067  { 0x33, 0x90, 0x00, 0x8e },
1068  { 0x33, 0x8c, 0xa7, 0x89 },
1069  { 0x33, 0x90, 0x00, 0xa0 },
1070  { 0x33, 0x8c, 0xa7, 0x8a },
1071  { 0x33, 0x90, 0x00, 0xaf },
1072  { 0x33, 0x8c, 0xa7, 0x8b },
1073  { 0x33, 0x90, 0x00, 0xbc },
1074  { 0x33, 0x8c, 0xa7, 0x8c },
1075  { 0x33, 0x90, 0x00, 0xc7 },
1076  { 0x33, 0x8c, 0xa7, 0x8d },
1077  { 0x33, 0x90, 0x00, 0xd0 },
1078  { 0x33, 0x8c, 0xa7, 0x8e },
1079  { 0x33, 0x90, 0x00, 0xd9 },
1080  { 0x33, 0x8c, 0xa7, 0x8f },
1081  { 0x33, 0x90, 0x00, 0xe0 },
1082  { 0x33, 0x8c, 0xa7, 0x90 },
1083  { 0x33, 0x90, 0x00, 0xe8 },
1084  { 0x33, 0x8c, 0xa7, 0x91 },
1085  { 0x33, 0x90, 0x00, 0xee },
1086  { 0x33, 0x8c, 0xa7, 0x92 },
1087  { 0x33, 0x90, 0x00, 0xf4 },
1088  { 0x33, 0x8c, 0xa7, 0x93 },
1089  { 0x33, 0x90, 0x00, 0xfa },
1090  { 0x33, 0x8c, 0xa7, 0x94 },
1091  { 0x33, 0x90, 0x00, 0xff },
1092  { 0x33, 0x8c, 0xa1, 0x03 },
1093  { 0x33, 0x90, 0x00, 0x05 },
1094  { 0x33, 0x8c, 0xa1, 0x04 },
1095  { 0x33, 0x90, -1 },
1096  { 0x33, 0x8c, 0xa2, 0x06 },
1097  { 0x33, 0x90, 0x00, 0x50 },
1098  { 0x33, 0x8c, 0x27, 0x03 },
1099  { 0x33, 0x90, 0x02, 0x82 },
1100  { 0x33, 0x8c, 0x27, 0x05 },
1101  { 0x33, 0x90, 0x01, 0xe2 },
1102  { 0x33, 0x8c, 0x27, 0x07 },
1103  { 0x33, 0x90, 0x05, 0x02 },
1104  { 0x33, 0x8c, 0x27, 0x09 },
1105  { 0x33, 0x90, 0x04, 0x02 },
1106  { 0x33, 0x8c, 0x27, 0x0d },
1107  { 0x33, 0x90, 0x00, 0x00 },
1108  { 0x33, 0x8c, 0x27, 0x0f },
1109  { 0x33, 0x90, 0x00, 0x00 },
1110  { 0x33, 0x8c, 0x27, 0x11 },
1111  { 0x33, 0x90, 0x04, 0xbd },
1112  { 0x33, 0x8c, 0x27, 0x13 },
1113  { 0x33, 0x90, 0x06, 0x4d },
1114  { 0x33, 0x8c, 0x27, 0x15 },
1115  { 0x33, 0x90, 0x04, 0x00 },
1116  { 0x33, 0x8c, 0x27, 0x17 },
1117  { 0x33, 0x90, 0x21, 0x11 },
1118  { 0x33, 0x8c, 0x27, 0x19 },
1119  { 0x33, 0x90, 0x04, 0x6c },
1120  { 0x33, 0x8c, 0x27, 0x1b },
1121  { 0x33, 0x90, 0x02, 0x4f },
1122  { 0x33, 0x8c, 0x27, 0x1d },
1123  { 0x33, 0x90, 0x01, 0x02 },
1124  { 0x33, 0x8c, 0x27, 0x1f },
1125  { 0x33, 0x90, 0x02, 0x79 },
1126  { 0x33, 0x8c, 0x27, 0x21 },
1127  { 0x33, 0x90, 0x01, 0x55 },
1128  { 0x33, 0x8c, 0x27, 0x23 },
1129  { 0x33, 0x90, 0x03, 0x5b },
1130  { 0x33, 0x8c, 0x27, 0x25 },
1131  { 0x33, 0x90, 0x06, 0x0f },
1132  { 0x33, 0x8c, 0x27, 0x27 },
1133  { 0x33, 0x90, 0x20, 0x20 },
1134  { 0x33, 0x8c, 0x27, 0x29 },
1135  { 0x33, 0x90, 0x20, 0x20 },
1136  { 0x33, 0x8c, 0x27, 0x2b },
1137  { 0x33, 0x90, 0x10, 0x20 },
1138  { 0x33, 0x8c, 0x27, 0x2d },
1139  { 0x33, 0x90, 0x20, 0x07 },
1140  { 0x33, 0x8c, 0x27, 0x2f },
1141  { 0x33, 0x90, 0x00, 0x04 },
1142  { 0x33, 0x8c, 0x27, 0x31 },
1143  { 0x33, 0x90, 0x00, 0x04 },
1144  { 0x33, 0x8c, 0x27, 0x33 },
1145  { 0x33, 0x90, 0x04, 0xbb },
1146  { 0x33, 0x8c, 0x27, 0x35 },
1147  { 0x33, 0x90, 0x06, 0x4b },
1148  { 0x33, 0x8c, 0x27, 0x37 },
1149  { 0x33, 0x90, 0x04, 0xce },
1150  { 0x33, 0x8c, 0x27, 0x39 },
1151  { 0x33, 0x90, 0x21, 0x11 },
1152  { 0x33, 0x8c, 0x27, 0x3b },
1153  { 0x33, 0x90, 0x00, 0x24 },
1154  { 0x33, 0x8c, 0x27, 0x3d },
1155  { 0x33, 0x90, 0x01, 0x20 },
1156  { 0x33, 0x8c, 0x27, 0x41 },
1157  { 0x33, 0x90, 0x01, 0x69 },
1158  { 0x33, 0x8c, 0x27, 0x45 },
1159  { 0x33, 0x90, 0x04, 0xff },
1160  { 0x33, 0x8c, 0x27, 0x47 },
1161  { 0x33, 0x90, 0x08, 0x24 },
1162  { 0x33, 0x8c, 0x27, 0x51 },
1163  { 0x33, 0x90, 0x00, 0x00 },
1164  { 0x33, 0x8c, 0x27, 0x53 },
1165  { 0x33, 0x90, 0x03, 0x20 },
1166  { 0x33, 0x8c, 0x27, 0x55 },
1167  { 0x33, 0x90, 0x00, 0x00 },
1168  { 0x33, 0x8c, 0x27, 0x57 },
1169  { 0x33, 0x90, 0x02, 0x58 },
1170  { 0x33, 0x8c, 0x27, 0x5f },
1171  { 0x33, 0x90, 0x00, 0x00 },
1172  { 0x33, 0x8c, 0x27, 0x61 },
1173  { 0x33, 0x90, 0x06, 0x40 },
1174  { 0x33, 0x8c, 0x27, 0x63 },
1175  { 0x33, 0x90, 0x00, 0x00 },
1176  { 0x33, 0x8c, 0x27, 0x65 },
1177  { 0x33, 0x90, 0x04, 0xb0 },
1178  { 0x33, 0x8c, 0x22, 0x2e },
1179  { 0x33, 0x90, 0x00, 0xd7 },
1180  { 0x33, 0x8c, 0xa4, 0x08 },
1181  { 0x33, 0x90, 0x00, 0x2a },
1182  { 0x33, 0x8c, 0xa4, 0x09 },
1183  { 0x33, 0x90, 0x00, 0x2c },
1184  { 0x33, 0x8c, 0xa4, 0x0a },
1185  { 0x33, 0x90, 0x00, 0x32 },
1186  { 0x33, 0x8c, 0xa4, 0x0b },
1187  { 0x33, 0x90, 0x00, 0x34 },
1188  { 0x33, 0x8c, 0x24, 0x11 },
1189  { 0x33, 0x90, 0x00, 0xd7 },
1190  { 0x33, 0x8c, 0x24, 0x13 },
1191  { 0x33, 0x90, 0x01, 0x02 },
1192  { 0x33, 0x8c, 0x24, 0x15 },
1193  { 0x33, 0x90, 0x00, 0xa0 },
1194  { 0x33, 0x8c, 0x24, 0x17 },
1195  { 0x33, 0x90, 0x00, 0xc0 },
1196  { 0x33, 0x8c, 0x27, 0x99 },
1197  { 0x33, 0x90, 0x64, 0x08 },
1198  { 0x33, 0x8c, 0x27, 0x9b },
1199  { 0x33, 0x90, 0x64, 0x08 },
1200  { 0x33, 0x8c, 0xa2, 0x0c },
1201  { 0x33, 0x90, 0x00, 0x18 },
1202  { 0x33, 0x8c, 0xa2, 0x14 },
1203  { 0x33, 0x90, 0x00, 0x24 },
1204  { 0x33, 0x8c, 0xa2, 0x15 },
1205  { 0x33, 0x90, 0x00, 0x04 },
1206  { 0x33, 0x8c, 0xa2, 0x0d },
1207  { 0x33, 0x90, 0x00, 0x30 },
1208  { 0x33, 0x8c, 0xa2, 0x0e },
1209  { 0x33, 0x90, 0x00, 0x80 },
1210  { 0x33, 0x8c, 0xa1, 0x03 },
1211  { 0x33, 0x90, 0x00, 0x05 },
1212  { 0x33, 0x8c, 0xa1, 0x04 },
1213  { 0x33, 0x90, -1 },
1214  { 0x33, 0x8c, 0xa1, 0x03 },
1215  { 0x33, 0x90, 0x00, 0x06 },
1216  { 0x33, 0x8c, 0xa1, 0x04 },
1217  { 0x33, 0x90, -1 },
1218  { 0x33, 0x8c, 0xa1, 0x30 },
1219  { 0x33, 0x90, 0x00, 0x04 },
1220  { 0x33, 0x8c, 0xa1, 0x15 },
1221  { 0x33, 0x90, 0x00, 0xef },
1222  { 0x33, 0x8c, 0xa1, 0x16 },
1223  { 0x33, 0x90, 0x00, 0x30 },
1224  { 0x33, 0x8c, 0xa1, 0x17 },
1225  { 0x33, 0x90, 0x00, 0x55 },
1226  { 0x33, 0x8c, 0xa1, 0x18 },
1227  { 0x33, 0x90, 0x00, 0x5a },
1228  { 0x33, 0x8c, 0xa1, 0x19 },
1229  { 0x33, 0x90, 0x00, 0x28 },
1230  { 0x33, 0x8c, 0xa1, 0x1a },
1231  { 0x33, 0x90, 0x00, 0x08 },
1232  { 0x33, 0x8c, 0xa1, 0x1b },
1233  { 0x33, 0x90, 0x00, 0x1e },
1234  { 0x33, 0x8c, 0xa1, 0x1c },
1235  { 0x33, 0x90, 0x00, 0x02 },
1236  { 0x33, 0x8c, 0xa1, 0x1d },
1237  { 0x33, 0x90, 0x00, 0x00 },
1238  { 0x33, 0x8c, 0xa1, 0x1e },
1239  { 0x33, 0x90, 0x00, 0x00 },
1240  { 0x33, 0x8c, 0xa1, 0x1f },
1241  { 0x33, 0x90, 0x00, 0x04 },
1242  { 0x33, 0x8c, 0xab, 0x05 },
1243  { 0x33, 0x90, 0x00, 0x00 },
1244  { 0x33, 0x8c, 0xa7, 0x6d },
1245  { 0x33, 0x90, 0x00, 0x03 },
1246  { 0x33, 0x8c, 0xa7, 0x6e },
1247  { 0x33, 0x90, 0x00, 0x03 },
1248  { 0x33, 0x8c, 0xa7, 0x6f },
1249  { 0x33, 0x90, 0x00, 0x00 },
1250  { 0x33, 0x8c, 0xa7, 0x70 },
1251  { 0x33, 0x90, 0x00, 0x15 },
1252  { 0x33, 0x8c, 0xa7, 0x71 },
1253  { 0x33, 0x90, 0x00, 0x25 },
1254  { 0x33, 0x8c, 0xa7, 0x72 },
1255  { 0x33, 0x90, 0x00, 0x3f },
1256  { 0x33, 0x8c, 0xa7, 0x73 },
1257  { 0x33, 0x90, 0x00, 0x64 },
1258  { 0x33, 0x8c, 0xa7, 0x74 },
1259  { 0x33, 0x90, 0x00, 0x80 },
1260  { 0x33, 0x8c, 0xa7, 0x75 },
1261  { 0x33, 0x90, 0x00, 0x97 },
1262  { 0x33, 0x8c, 0xa7, 0x76 },
1263  { 0x33, 0x90, 0x00, 0xa9 },
1264  { 0x33, 0x8c, 0xa7, 0x77 },
1265  { 0x33, 0x90, 0x00, 0xba },
1266  { 0x33, 0x8c, 0xa7, 0x78 },
1267  { 0x33, 0x90, 0x00, 0xc7 },
1268  { 0x33, 0x8c, 0xa7, 0x79 },
1269  { 0x33, 0x90, 0x00, 0xd2 },
1270  { 0x33, 0x8c, 0xa7, 0x7a },
1271  { 0x33, 0x90, 0x00, 0xdc },
1272  { 0x33, 0x8c, 0xa7, 0x7b },
1273  { 0x33, 0x90, 0x00, 0xe4 },
1274  { 0x33, 0x8c, 0xa7, 0x7c },
1275  { 0x33, 0x90, 0x00, 0xea },
1276  { 0x33, 0x8c, 0xa7, 0x7d },
1277  { 0x33, 0x90, 0x00, 0xf0 },
1278  { 0x33, 0x8c, 0xa7, 0x7e },
1279  { 0x33, 0x90, 0x00, 0xf4 },
1280  { 0x33, 0x8c, 0xa7, 0x7f },
1281  { 0x33, 0x90, 0x00, 0xf8 },
1282  { 0x33, 0x8c, 0xa7, 0x80 },
1283  { 0x33, 0x90, 0x00, 0xfc },
1284  { 0x33, 0x8c, 0xa7, 0x81 },
1285  { 0x33, 0x90, 0x00, 0xff },
1286  { 0x33, 0x8c, 0xa7, 0x82 },
1287  { 0x33, 0x90, 0x00, 0x00 },
1288  { 0x33, 0x8c, 0xa7, 0x83 },
1289  { 0x33, 0x90, 0x00, 0x15 },
1290  { 0x33, 0x8c, 0xa7, 0x84 },
1291  { 0x33, 0x90, 0x00, 0x25 },
1292  { 0x33, 0x8c, 0xa7, 0x85 },
1293  { 0x33, 0x90, 0x00, 0x3f },
1294  { 0x33, 0x8c, 0xa7, 0x86 },
1295  { 0x33, 0x90, 0x00, 0x64 },
1296  { 0x33, 0x8c, 0xa7, 0x87 },
1297  { 0x33, 0x90, 0x00, 0x80 },
1298  { 0x33, 0x8c, 0xa7, 0x88 },
1299  { 0x33, 0x90, 0x00, 0x97 },
1300  { 0x33, 0x8c, 0xa7, 0x89 },
1301  { 0x33, 0x90, 0x00, 0xa9 },
1302  { 0x33, 0x8c, 0xa7, 0x8a },
1303  { 0x33, 0x90, 0x00, 0xba },
1304  { 0x33, 0x8c, 0xa7, 0x8b },
1305  { 0x33, 0x90, 0x00, 0xc7 },
1306  { 0x33, 0x8c, 0xa7, 0x8c },
1307  { 0x33, 0x90, 0x00, 0xd2 },
1308  { 0x33, 0x8c, 0xa7, 0x8d },
1309  { 0x33, 0x90, 0x00, 0xdc },
1310  { 0x33, 0x8c, 0xa7, 0x8e },
1311  { 0x33, 0x90, 0x00, 0xe4 },
1312  { 0x33, 0x8c, 0xa7, 0x8f },
1313  { 0x33, 0x90, 0x00, 0xea },
1314  { 0x33, 0x8c, 0xa7, 0x90 },
1315  { 0x33, 0x90, 0x00, 0xf0 },
1316  { 0x33, 0x8c, 0xa7, 0x91 },
1317  { 0x33, 0x90, 0x00, 0xf4 },
1318  { 0x33, 0x8c, 0xa7, 0x92 },
1319  { 0x33, 0x90, 0x00, 0xf8 },
1320  { 0x33, 0x8c, 0xa7, 0x93 },
1321  { 0x33, 0x90, 0x00, 0xfc },
1322  { 0x33, 0x8c, 0xa7, 0x94 },
1323  { 0x33, 0x90, 0x00, 0xff },
1324  { 0x33, 0x8c, 0xa1, 0x03 },
1325  { 0x33, 0x90, 0x00, 0x06 },
1326  { 0x33, 0x8c, 0xa1, 0x04 },
1327  { 0x33, 0x90, -1 },
1328  { 0x35, 0xa4, 0x05, 0x96 },
1329  { 0x33, 0x8c, 0xa1, 0x18 },
1330  { 0x33, 0x90, 0x00, 0x1e },
1331  { 0x33, 0x8c, 0xa1, 0x19 },
1332  { 0x33, 0x90, 0x00, 0x04 },
1333  { 0x33, 0x8c, 0xa1, 0x1a },
1334  { 0x33, 0x90, 0x00, 0x0a },
1335  { 0x33, 0x8c, 0xa1, 0x1b },
1336  { 0x33, 0x90, 0x00, 0x20 },
1337  { 0x33, 0x8c, 0xa1, 0x3e },
1338  { 0x33, 0x90, 0x00, 0x04 },
1339  { 0x33, 0x8c, 0xa1, 0x3f },
1340  { 0x33, 0x90, 0x00, 0x0e },
1341  { 0x33, 0x8c, 0xa1, 0x40 },
1342  { 0x33, 0x90, 0x00, 0x04 },
1343  { 0x33, 0x8c, 0xa1, 0x41 },
1344  { 0x33, 0x90, 0x00, 0x04 },
1345  { 0x33, 0x8c, 0xa1, 0x42 },
1346  { 0x33, 0x90, 0x00, 0x32 },
1347  { 0x33, 0x8c, 0xa1, 0x43 },
1348  { 0x33, 0x90, 0x00, 0x0f },
1349  { 0x33, 0x8c, 0xa1, 0x44 },
1350  { 0x33, 0x90, 0x00, 0x32 },
1351  { 0x33, 0x8c, 0xa1, 0x45 },
1352  { 0x33, 0x90, 0x00, 0x32 },
1353  { 0x33, 0x8c, 0xa1, 0x46 },
1354  { 0x33, 0x90, 0x00, 0x05 },
1355  { 0x33, 0x8c, 0xa1, 0x04 },
1356  { 0x33, 0x90, -1 },
1357  { 0x33, 0x8c, 0xa1, 0x47 },
1358  { 0x33, 0x90, 0x00, 0x3a },
1359  { 0x33, 0x8c, 0x27, 0x95 },
1360  { 0x33, 0x90, 0x01, 0x00 },
1361  { 0x33, 0x8c, 0xa1, 0x03 },
1362  { 0x33, 0x90, 0x00, 0x05 },
1363  { 0x33, 0x8c, 0xa1, 0x04 },
1364  { 0x33, 0x90, -1 },
1365  { 0x33, 0x8c, 0x27, 0x97 },
1366  { 0x33, 0x90, 0x01, 0x00 },
1367  { 0x33, 0x8c, 0xa1, 0x03 },
1368  { 0x33, 0x90, 0x00, 0x05 },
1369  { 0x33, 0x8c, 0xa1, 0x04 },
1370  { 0x33, 0x90, -1 },
1371  { 0x33, 0x8c, 0xa4, 0x04 },
1372  { 0x33, 0x90, 0x00, 0x80 },
1373  { 0x33, 0x8c, 0xa1, 0x03 },
1374  { 0x33, 0x90, 0x00, 0x05 },
1375  { 0x33, 0x8c, 0xa1, 0x04 },
1376  { 0x33, 0x90 }
1377  };
1378 
1379 
1380  asize = ARRAY_SIZE(values_205);
1381 
1382  for(i=0; i<asize; i++) {
1383  usb_stk11xx_read_registry(dev, 0x02ff, &value);
1384  usb_stk11xx_write_registry(dev, 0x02ff, 0x0001);
1385 
1386  usb_stk11xx_write_registry(dev, 0x0205, values_205[i][0]);
1387  usb_stk11xx_write_registry(dev, 0x0205, values_205[i][1]);
1388 
1389  if (values_205[i][2] == -1) {
1390  usb_stk11xx_write_registry(dev, 0x0200, 0x0061);
1391 
1392  dev_stk11xx_check_device(dev, 500);
1393 
1394  usb_stk11xx_read_registry(dev, 0x0209, &value);
1395  usb_stk11xx_write_registry(dev, 0x0200, 0x0020);
1396 
1397  dev_stk11xx_check_device(dev, 500);
1398 
1399  usb_stk11xx_read_registry(dev, 0x0209, &value);
1400  }
1401  else {
1402  usb_stk11xx_write_registry(dev, 0x0205, values_205[i][2]);
1403  usb_stk11xx_write_registry(dev, 0x0205, values_205[i][3]);
1404  usb_stk11xx_write_registry(dev, 0x0200, 0x0001);
1405 
1406  dev_stk11xx_check_device(dev, 500);
1407  }
1408 
1409  usb_stk11xx_write_registry(dev, 0x02ff, 0x0001);
1410  }
1411 
1412  return 0;
1413 }
1414 
1415 
1430 {
1431  return 0;
1432 }
1433 
1434 
1449 {
1450  int value;
1451 
1452  // Contrast register
1453  usb_stk11xx_read_registry(dev, 0x02ff, &value);
1454  usb_stk11xx_write_registry(dev, 0x02ff, 0x0000);
1455 
1456  usb_stk11xx_write_registry(dev, 0x0204, 0x00b3);
1457  usb_stk11xx_write_registry(dev, 0x0205, (dev->vsettings.contrast >> 8));
1458 
1459  usb_stk11xx_write_registry(dev, 0x0200, 0x0001);
1460  dev_stk11xx_check_device(dev, 500);
1461  usb_stk11xx_write_registry(dev, 0x02ff, 0x0000);
1462 
1463  STK_DEBUG("Set colour : %d\n", dev->vsettings.colour);
1464  STK_DEBUG("Set contrast : %d\n", dev->vsettings.contrast);
1465  STK_DEBUG("Set whiteness : %d\n", dev->vsettings.whiteness);
1466  STK_DEBUG("Set brightness : %d\n", dev->vsettings.brightness);
1467 
1468  return 0;
1469 }
1470 
1471 
1482 {
1483  return 0;
1484 }
1485 
1486 
1498 {
1499  int value;
1500  int value_116, value_117;
1501 
1502  usb_stk11xx_read_registry(dev, 0x0116, &value_116);
1503  usb_stk11xx_read_registry(dev, 0x0117, &value_117);
1504 
1505  usb_stk11xx_write_registry(dev, 0x0116, 0x0000);
1506  usb_stk11xx_write_registry(dev, 0x0117, 0x0000);
1507 
1508  usb_stk11xx_read_registry(dev, 0x0100, &value); // read 0x21
1509  usb_stk11xx_write_registry(dev, 0x0100, 0x00a0);
1510 
1511  usb_stk11xx_write_registry(dev, 0x0116, value_116);
1512  usb_stk11xx_write_registry(dev, 0x0117, value_117);
1513 
1514  return 0;
1515 }
1516 
1517 
1528 {
1530 
1532 
1533  return 0;
1534 }
1535 
1536 
1548 {
1549  return 0;
1550 }
1551 
int dev_stk11xx_camera_off(struct usb_stk11xx *dev)
This function switchs off the camera.
Definition: stk11xx-dev.c:280
int dev_stk6a51_stop_stream(struct usb_stk11xx *dev)
This function sets the device to stop the stream.
int dev_stk11xx_camera_settings(struct usb_stk11xx *dev)
This function permits to modify the settings of the camera.
Definition: stk11xx-dev.c:366
int whiteness
Definition: stk11xx.h:295
#define STK_DEBUG(str, args...)
Definition: stk11xx.h:158
int dev_stk6a51_configure_device(struct usb_stk11xx *dev, int step)
This function permits to configure the device.
struct stk11xx_video vsettings
Definition: stk11xx.h:336
int dev_stk6a51_initialize_device(struct usb_stk11xx *dev)
This function permits to initialize the device.
int dev_stk11xx_check_device(struct usb_stk11xx *dev, int nbr)
This function permits to check the device in reading the register 0x0201.
Definition: stk11xx-dev.c:186
int dev_stk6a51_reconf_camera(struct usb_stk11xx *dev)
Reconfigure the camera before the stream.
int dev_stk6a51_camera_settings(struct usb_stk11xx *dev)
This function permits to modify the settings of the camera.
int brightness
Definition: stk11xx.h:293
int dev_stk6a51_camera_asleep(struct usb_stk11xx *dev)
Wake-up the camera.
int dev_stk6a51_sensor_settings(struct usb_stk11xx *dev)
This function permits to set default sensor settings.
int dev_stk6a51_set_camera_quality(struct usb_stk11xx *dev)
This function permits to modify the settings of the camera.
int usb_stk11xx_set_feature(struct usb_stk11xx *dev, int index)
Send the message SET_FEATURE and choose the interface.
Definition: stk11xx-usb.c:492
int dev_stk6a51_start_stream(struct usb_stk11xx *dev)
This function sets the device to start the stream.
int dev_stk6a51_init_camera(struct usb_stk11xx *dev)
This function initializes the device for the stream.
#define STK_INFO(str, args...)
Definition: stk11xx.h:155
int usb_stk11xx_write_registry(struct usb_stk11xx *dev, __u16 index, __u16 value)
Write a 16-bits value to a 16-bits register.
Definition: stk11xx-usb.c:558
int usb_stk11xx_read_registry(struct usb_stk11xx *dev, __u16 index, int *value)
Read a 16-bits value from a 16-bits register.
Definition: stk11xx-usb.c:590
Driver for Syntek USB video camera.
Driver for Syntek USB video camera.
int contrast
Definition: stk11xx.h:294
int dev_stk6a51_set_camera_fps(struct usb_stk11xx *dev)
This function permits to modify the settings of the camera.