|
From: Nyall D. <ny...@zo...> - 2009-09-10 22:37:27
|
Ok, with DEVICE_FLAG_BROKEN_MTPGETOBJPROPLIST, tracks can be transferred and things are looking good. One thing that confused me a lot was that I get an error if I try to transfer a track which already exists on the player... so I kept thinking things were still broken when they were actually working alright. Is this normal though? This is the error I receive: "Error sending track. Error 2: PTP Layer error a803: send_file_object_info():Could not send object property list. Error 2: (Look this up in ptp.h for an explanation.) Error 1: LIBMTP_Send_Track_From_File_Descriptor(): subcall to LIBMTP_Send_File_From_File_Descriptor failed. " As I said, it only happens if that track already exists on the player. I've attached a patch which adds the flag to the device. On Thu, Sep 10, 2009 at 8:15 AM, Richard Low <ri...@we...> wrote: > Hi, > > On 10 Sep 2009, at 00:39, Nyall Dawson wrote: > >> Ok, here's a log of sending a short sound file via mtp-sendtr, with >> the usb debug prints. > > This is interesting. Here's what I've found: > > 1. 0x2008 (invalid storage ID) errors > > These occur a few times after the big get object property list, for > example: > > REQUEST: 0x1008, Get object info > USB OUT==> > 0000: 1000 0000 0100 0810 1300 0000 0000 02dc ................ > GET DATA PHASE > Remaining size to read: 0x0200 bytes > Reading in 0x0200 bytes > Result of read: 0x000c > <==USB IN > 0000: 0c00 0000 0300 0820 1300 0000 ....... .... > > This is not even a valid return for this call (although it is for > 0x9805 (get object property list) which we get later). I don't know > what it could mean or what problems if any it is causing. > > 2. Get object property list is broken > > In the output below, no zero write is made which makes the output > impossible to parse. So we will need to use > DEVICE_FLAG_BROKEN_MTPGETOBJPROPLIST. > > REQUEST: 0x9805, Get object property list > USB OUT==> > 0000: 2000 0000 0100 0598 3b00 0000 9a00 0000 .......;....... > 0010: 0000 0000 ffff ffff 0000 0000 0000 0000 ................ > GET DATA PHASE > Remaining size to read: 0x0200 bytes > Reading in 0x0200 bytes > Result of read: 0x01a0 > <==USB IN > 0000: ffff ffff 0200 0598 3b00 0000 1c00 0000 ........;....... > 0010: 9a00 0000 01dc 0600 0100 0100 9a00 0000 ................ > 0020: 02dc 0400 0930 9a00 0000 03dc 0400 0000 .....0.......... > 0030: 9a00 0000 04dc 0800 79b1 0100 0000 0000 ........y....... > 0040: 9a00 0000 07dc ffff 0a70 0070 0061 0061 .........p.p.a.a > 0050: 0061 002e 006d 0070 0033 0000 009a 0000 .a...m.p.3...... > 0060: 0008 dcff ff01 0000 9a00 0000 0bdc 0600 ................ > 0070: 6800 0000 9a00 0000 41dc 0a00 2a02 0000 h.......A...*... > 0080: 2000 0000 0891 62d5 0000 0000 9a00 0000 .....b......... > 0090: 42dc ffff 0100 009a 0000 000d dc04 0000 B............... > 00a0: 009a 0000 004f dc02 0000 9a00 0000 9adc .....O.......... > 00b0: ffff 0100 009a 0000 0046 dcff ff01 0000 .........F...... > 00c0: 9a00 0000 9bdc ffff 009a 0000 0093 de06 ................ > 00d0: 0000 0000 009a 0000 0094 de04 0000 009a ................ > 00e0: 0000 009a de06 0000 0000 009a 0000 0044 ...............D > 00f0: dcff ff0a 7000 7000 6100 6100 6100 2e00 ....p.p.a.a.a... > 0100: 6d00 7000 3300 0000 9a00 0000 89dc 0600 m.p.3........... > 0110: 0000 0000 9a00 0000 99de 0600 0000 0000 ................ > 0120: 9a00 0000 09dc ffff 1732 0030 0030 0039 .........2.0.0.9 > 0130: 0030 0039 0030 0039 0054 0032 0030 0033 .0.9.0.9.T.2.0.3 > 0140: 0037 0031 0037 002e 0030 002d 0030 0033 .7.1.7...0.-.0.3 > 0150: 0030 0030 0000 009a 0000 008b dc04 0000 .0.0............ > 0160: 009a 0000 008c dcff ff01 0000 9a00 0000 ................ > 0170: 99dc ffff 009a 0000 0001 d902 0000 9a00 ................ > 0180: 0000 8adc 0400 0000 9a00 0000 91dc 0600 ................ > 0190: 0000 0000 9a00 0000 92dc 0600 0000 0000 ................ > Remaining size to read: 0x0200 bytes > Reading in 0x0200 bytes > Result of read: 0x000c > <==USB IN > 0000: 0c00 0000 0300 0120 3b00 0000 ....... ;... > RESPONSE: Remaining size to read: 0x0200 bytes > Reading in 0x0200 bytes > Result of read: 0xffffff92 > 02ff > > 3. Another strange get object property list call > > Although with the broken flag this won't appear any more, I'm confused > by this (which comes just before the close session command): > > REQUEST: 0x9805, Get object property list > USB OUT==> > 0000: 2000 0000 0100 0598 5700 0000 9400 0000 .......W....... > 0010: 0000 0000 ffff ffff 0000 0000 0000 0000 ................ > GET DATA PHASE > Remaining size to read: 0x0200 bytes > Reading in 0x0200 bytes > Result of read: 0x011a > <==USB IN > 0000: ffff ffff 0200 0598 5700 0000 1400 0000 ........W....... > 0010: 9400 0000 01dc 0600 0100 0100 9400 0000 ................ > 0020: 02dc 0400 03ba 9400 0000 03dc 0400 0000 ................ > 0030: 9400 0000 04dc 0800 0000 0000 0000 0000 ................ > 0040: 9400 0000 07dc ffff 0974 0065 0073 0074 .........t.e.s.t > 0050: 002e 0061 006c 0062 0000 0094 0000 0008 ...a.l.b........ > 0060: dcff ff01 0000 9400 0000 0bdc 0600 6800 ..............h. > 0070: 0000 9400 0000 41dc 0a00 2902 0000 a006 ......A...)..... > 0080: 0000 3449 82d5 0000 0000 9400 0000 42dc ..4I..........B. > 0090: ffff 0100 0094 0000 000d dc04 0000 0094 ................ > 00a0: 0000 004f dc02 0000 9400 0000 9bdc ffff ...O............ > 00b0: 0574 0065 0073 0074 0000 0094 0000 0044 .t.e.s.t.......D > 00c0: dcff ff05 7400 6500 7300 7400 0000 9400 ....t.e.s.t..... > 00d0: 0000 8cdc ffff 0574 0065 0073 0074 0000 .......t.e.s.t.. > 00e0: 0094 0000 0001 d902 0000 9400 0000 84dc ................ > 00f0: 0600 0000 0000 9400 0000 83dc 0600 0000 ................ > 0100: 0000 9400 0000 82dc 0600 0000 0000 9400 ................ > 0110: 0000 81dc 0400 0000 99de .......... > Remaining size to read: 0x0200 bytes > Reading in 0x0200 bytes > Result of read: 0x000c > <==USB IN > 0000: 0c00 0000 0300 0120 5700 0000 ....... W... > RESPONSE: Remaining size to read: 0x0200 bytes > Reading in 0x0200 bytes > Result of read: 0xffffff92 > 02ff > success! > > The last read should be treated as a response but isn't. In this > case, the response is valid (a short read so we know to stop > reading). But maybe this occurs because of a previous error. > > So in summary, you might find it all works simply by adding > DEVICE_FLAG_BROKEN_MTPGETOBJPROPLIST for this player. > > Richard. > > ------------------------------------------------------------------------------ > Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day > trial. Simplify your report design, integration and deployment - and focus on > what you do best, core application coding. Discover what's new with > Crystal Reports now. http://p.sf.net/sfu/bobj-july > _______________________________________________ > Libmtp-discuss mailing list > Lib...@li... > https://lists.sourceforge.net/lists/listinfo/libmtp-discuss > |