Contiki 2.5
msc-descriptors.c
1 #include "descriptors.h"
2 #include "usb-msc-bulk.h"
3 #include <usb-arch.h>
4 
5 const struct usb_st_device_descriptor device_descriptor =
6  {
7  sizeof(struct usb_st_device_descriptor),
8  DEVICE,
9  0x0210,
10  0,
11  0,
12  0,
13  CTRL_EP_SIZE,
14  0xffff,
15  0xffff,
16  0x0030,
17  2,
18  1,
19  3,
20  1
21  };
22 
23 const struct configuration_st {
24  struct usb_st_configuration_descriptor configuration;
25  struct usb_st_interface_descriptor massbulk;
26  struct usb_st_endpoint_descriptor ep_in;
27  struct usb_st_endpoint_descriptor ep_out;
28 } BYTE_ALIGNED configuration_block =
29  {
30  /* Configuration */
31  {
32  sizeof(configuration_block.configuration),
33  CONFIGURATION,
34  sizeof(configuration_block),
35  1,
36  1,
37  0,
38  0x80,
39  50
40  },
41  {
42  sizeof(configuration_block.massbulk),
43  INTERFACE,
44  0,
45  0,
46  2,
47  MASS_STORAGE,
48  MASS_RBC,
49  MASS_BULK_ONLY,
50  0
51  },
52  {
53  sizeof(configuration_block.ep_in),
54  ENDPOINT,
55  0x81,
56  0x02,
57  64,
58  0
59  },
60  {
61  sizeof(configuration_block.ep_out),
62  ENDPOINT,
63  0x02,
64  0x02,
65  64,
66  0
67  }
68 
69  };
70 
71 const struct usb_st_configuration_descriptor const *configuration_head =
72 (struct usb_st_configuration_descriptor const*)&configuration_block;