diff -r 89d6a7a84779 -r 25a17d01db0c Symbian3/PDK/Source/GUID-1D0301C5-52D8-4E4F-BEC3-52037BA2A003.dita --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/Symbian3/PDK/Source/GUID-1D0301C5-52D8-4E4F-BEC3-52037BA2A003.dita Fri Jan 22 18:26:19 2010 +0000 @@ -0,0 +1,61 @@ + + + + + +Enabling +MTP over USB using a user applicationThis section describes the steps to enable MTP over USB using a +user application. +

You can write your own application to enable MTP over USB. +The application must call the MTP Client API to start the MTP server (in the +MTP framework). The MTP Framework then loads the USB MTP Transport plug-in.

+
+ +The user application +must instantiate a service provider, RMTPClient, and connect +to the MTP Server. + +Once the session +is connected start communication with the PC by calling StartTransport(). +Pass the UID for the USB transport plug-in, 0x102827B2, to +this method. + + +RMTPClient mtp; +const TUid KUSBStillImage = { 0x102827B2 }; + +TInt err = mtp.Connect(); +if( err != KErrNone ) + { + // Error in starting the MTP Framework + } +else( err = mtp.StartTransport( KUSBStillImage ) ) + { + if( err != KErrNone ) + { + // Error in starting the USB transport. + } + } +... +err = mtp.StopTransport( KUSBstillImage ); +if( err != KErrNone ) + { + // Error in stopping the USB transport + } + +mtp.Close(); + +
+Enabling +MTP over USB +Symbian USB +Manager +USB Personalities + +
\ No newline at end of file