10 // |
10 // |
11 // Contributors: |
11 // Contributors: |
12 // |
12 // |
13 // Description: |
13 // Description: |
14 // Class declaration for CUsbMassStorageController. |
14 // Class declaration for CUsbMassStorageController. |
15 // |
15 // |
16 // |
16 // |
17 |
17 |
18 /** |
18 /** |
19 @file |
19 @file |
20 @internalTechnology |
20 @internalTechnology |
21 */ |
21 */ |
22 |
22 |
23 #ifndef __CUSBMASSSTORAGECONTROLLER_H__ |
23 #ifndef __CUSBMASSSTORAGECONTROLLER_H__ |
24 #define __CUSBMASSSTORAGECONTROLLER_H__ |
24 #define __CUSBMASSSTORAGECONTROLLER_H__ |
25 |
25 |
26 #include <e32base.h> |
26 |
27 #include <usbmsshared.h> |
27 class MTransportBase; |
28 #include "drivemanager.h" |
28 class MProtocolBase; |
29 #include "cusbmassstorageserver.h" |
29 class CUsbMassStorageServer; |
30 #include "protocol.h" |
|
31 |
30 |
32 /** |
31 /** |
33 Mass Storage Controller class. |
32 Mass Storage Controller class. |
34 Encapsulates the drive manager, transport and protocol for USB Mass Storage. |
33 Encapsulates the drive manager, transport and protocol for USB Mass Storage. |
35 Its main purpose is to instantiate and initialize these objects. |
34 Its main purpose is to instantiate and initialize these objects. |
36 */ |
35 */ |
37 class CUsbMassStorageController : public CBase |
36 class CUsbMassStorageController : public CBase |
38 { |
37 { |
39 public: |
38 public: |
40 ~CUsbMassStorageController(); |
39 ~CUsbMassStorageController(); |
41 void CreateL(RArray<TInt>& aDriveMapping); |
40 void CreateL(RArray<TInt>& aDriveMapping); |
42 CDriveManager& DriveManager(); |
41 CDriveManager& DriveManager(); |
43 TInt Start(TMassStorageConfig& aConfig); |
42 TInt Start(TMassStorageConfig& aConfig); |
44 TInt Stop(); |
43 TInt Stop(); |
45 void Reset(); |
44 void Reset(); |
46 void GetTransport(MTransportBase* &aTransport); |
45 void GetTransport(MTransportBase* &aTransport); |
47 enum TTransportldd {EUsbc = 1, EUsbcsc}; |
46 enum TTransportldd {EUsbc = 1, EUsbcsc}; |
48 |
47 |
49 private: |
48 private: |
50 CDriveManager* iDriveManager; |
49 CDriveManager* iDriveManager; |
51 MTransportBase* iTransport; |
50 MTransportBase* iTransport; |
52 MProtocolBase* iProtocol; |
51 MProtocolBase* iProtocol; |
53 CUsbMassStorageServer* iServer; |
52 CUsbMassStorageServer* iServer; |
54 TMassStorageConfig iConfig; |
53 TMassStorageConfig iConfig; |
55 TInt iMaxDrives; |
54 TInt iMaxDrives; |
56 TTransportldd iTransportLddFlag; |
55 TTransportldd iTransportLddFlag; |
57 }; |
56 }; |
58 |
57 |
59 #endif //__CUSBMASSSTORAGECONTROLLER_H__ |
58 #endif //__CUSBMASSSTORAGECONTROLLER_H__ |