В основном я разрабатываю USB-устройство, которое будет использовать MTP для передачи файлов. Он прекрасно работает с Konqueror, и Dolphin I может успешно копировать файлы, также работает mtp-getfile (в Linux).
В Windows я вижу свое устройство и список файлов, но когда я пытаюсь скопировать любой из них, я получаю "Катастрофическая ошибка":
Я регистрирую все запросы от компьютера к устройству (коды операций и параметры), и во время ошибки нет ожидающих операций, поэтому я предполагаю, что это вызвано чем-то более ранним (например, отсутствует поддержка чего-то, что должно быть представлено в ответе DeviceInfo) ,
Я попытался посмотреть в Event Viewer, но никаких признаков этого сбоя нет, также сведения о устройстве в диспетчере устройств выглядят корректно. Вот дамп из mtp-Detected, запущенный на Linux:
libmtp version: 1.1.16
Listing raw device(s)
USB low-level info:
bcdUSB: 513
bDeviceClass: 0
bDeviceSubClass: 0
bDeviceProtocol: 0
idVendor: 0483
idProduct: 572b
IN endpoint maxpacket: 64 bytes
OUT endpoint maxpacket: 64 bytes
Raw device info:
Bus location: 1
Device number: 14
Device entry info:
Vendor: (null)
Vendor id: 0x0483
Product: (null)
Vendor id: 0x572b
Device flags: 0x00000000
Configuration 0, interface 0, altsetting 0:
Interface description contains the string "MTP"
Device recognized as MTP, no further probing.
Device info:
Manufacturer: test
Model: Testowy
Device version: 1.0
Serial number: 123454321
Vendor extension ID: 0x00000006
Vendor extension description: microsoft.com: 1.0;
Detected object size: 64 bits
Extensions:
microsoft.com: 1.0
Supported operations:
1001: Get device info
1002: Open session
1003: Close session
1004: Get storage IDs
1005: Get storage info
1006: Get number of objects
1007: Get object handles
1008: Get object info
1009: Get object
1014: Get device property description
1015: Get device property value
101b: Get partial object
9801: Get object properties supported
9802: Get object property description
9803: Get object property value
9805: Get object property list
100a: Get thumbnail
100b: Delete object
100c: Send object info
100d: Send object
1010: Reset device
1016: Set device property value
1017: Reset device property value
1019: Move object
101a: Copy object
Events supported:
0x4001: CancelTransaction
0x4002: ObjectAdded
0x4003: ObjectRemoved
0x4004: StoreAdded
0x4005: StoreRemoved
0x4006: DevicePropChanged
0x4007: ObjectInfoChanged
0x4008: DeviceInfoChanged
0x400a: StoreFull
0x400c: StorageInfoChanged
Device Properties Supported:
Playable File (Object) Types and Object Properties Supported:
3000: Undefined Type
dc01: Storage ID UINT32 data type ANY 32BIT VALUE form READ ONLY
dc02: Object Format UINT16 data type ANY 16BIT VALUE form READ ONLY
dc03: Protection Status UINT16 data type enumeration: READ ONLY
dc04: Object Size UINT64 data type READ ONLY
dc05: Association Type UINT16 data type enumeration: READ ONLY
dc06: Association Desc UINT16 data type ANY 16BIT VALUE form READ ONLY
dc07: Object File Name STRING data type READ ONLY
dc08: Date Created STRING data type READ ONLY
dc09: Date Modified STRING data type READ ONLY
dc0a: Keywords STRING data type READ ONLY
dc0b: Parent Object UINT32 data type ANY 32BIT VALUE form READ ONLY
3004: Text
dc01: Storage ID UINT32 data type ANY 32BIT VALUE form READ ONLY
dc02: Object Format UINT16 data type ANY 16BIT VALUE form READ ONLY
dc03: Protection Status UINT16 data type enumeration: READ ONLY
dc04: Object Size UINT64 data type READ ONLY
dc05: Association Type UINT16 data type enumeration: READ ONLY
dc06: Association Desc UINT16 data type ANY 16BIT VALUE form READ ONLY
dc07: Object File Name STRING data type READ ONLY
dc08: Date Created STRING data type READ ONLY
dc09: Date Modified STRING data type READ ONLY
dc0a: Keywords STRING data type READ ONLY
dc0b: Parent Object UINT32 data type ANY 32BIT VALUE form READ ONLY
3005: HTML
dc01: Storage ID UINT32 data type ANY 32BIT VALUE form READ ONLY
dc02: Object Format UINT16 data type ANY 16BIT VALUE form READ ONLY
dc03: Protection Status UINT16 data type enumeration: READ ONLY
dc04: Object Size UINT64 data type READ ONLY
dc05: Association Type UINT16 data type enumeration: READ ONLY
dc06: Association Desc UINT16 data type ANY 16BIT VALUE form READ ONLY
dc07: Object File Name STRING data type READ ONLY
dc08: Date Created STRING data type READ ONLY
dc09: Date Modified STRING data type READ ONLY
dc0a: Keywords STRING data type READ ONLY
dc0b: Parent Object UINT32 data type ANY 32BIT VALUE form READ ONLY
3001: Association/Directory
dc01: Storage ID UINT32 data type ANY 32BIT VALUE form READ ONLY
dc02: Object Format UINT16 data type ANY 16BIT VALUE form READ ONLY
dc03: Protection Status UINT16 data type enumeration: READ ONLY
dc04: Object Size UINT64 data type READ ONLY
dc05: Association Type UINT16 data type enumeration: READ ONLY
dc06: Association Desc UINT16 data type ANY 16BIT VALUE form READ ONLY
dc07: Object File Name STRING data type READ ONLY
dc08: Date Created STRING data type READ ONLY
dc09: Date Modified STRING data type READ ONLY
dc0a: Keywords STRING data type READ ONLY
dc0b: Parent Object UINT32 data type ANY 32BIT VALUE form READ ONLY
Storage Devices:
StorageID: 0x00010001
StorageType: 0x0003 fixed RAM storage
FilesystemType: 0x0002 generic hierarchical
AccessCapability: 0x0000 read/write
MaxCapacity: 16777214
FreeSpaceInBytes: 1048573
FreeSpaceInObjects: 4294967295
StorageDescription: Big_storage
VolumeIdentifier: 1111-2222-3333-4444
Special directories:
Default music folder: 0xffffffff
Default playlist folder: 0xffffffff
Default picture folder: 0xffffffff
Default video folder: 0xffffffff
Default organizer folder: 0xffffffff
Default zencast folder: 0xffffffff
Default album folder: 0xffffffff
Default text folder: 0xffffffff
MTP-specific device properties:
Friendly name: (NULL)
Synchronization partner: (NULL)
libmtp supported (playable) filetypes:
Text file
HTML file
Folder
Как я могу увидеть, что именно пошло не так или чего не хватает?