requesttype=0x1f
Command: 0x50 bytes
0000: 10 00 00 00 01 02 00 00 00 00 00 00 00 00 00 00 ................
0010: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
0020: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
0030: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
0040: 02 00 00 00 1f 00 00 12 10 00 00 00 78 56 34 12 ............xV4.
Reply is 0x384 bytes (PowerShot G2):
0000: 44 03 00 00 01 03 00 00 00 00 00 00 00 00 00 00 D...............
0010: aa 55 aa 55 aa 55 aa 55 aa 55 aa 55 aa 55 aa 55 .U.U.U.U.U.U.U.U
0020: aa 55 aa 55 aa 55 aa 55 aa 55 aa 55 aa 55 aa 55 .U.U.U.U.U.U.U.U
0030: aa 55 aa 55 aa 55 aa 55 aa 55 aa 55 aa 55 aa 55 .U.U.U.U.U.U.U.U
0040: 02 00 00 00 1f 00 00 22 44 03 00 00 78 56 34 12 ......."D...xV4.
0050: 00 00 00 00 30 03 00 00 10 01 50 6f 77 65 72 53 ....0.....PowerS
0060: 68 6f 74 20 47 32 00 00 00 14 00 00 80 28 00 00 hot G2.......(..
0070: 00 40 00 00 00 00 00 00 00 00 0d 00 00 00 4c 61 .@............La
0080: 72 67 65 3a 53 75 70 65 72 46 69 6e 65 00 00 00 rge:SuperFine...
0090: 00 00 a8 06 00 00 e0 08 00 00 01 00 00 00 4c 61 ..............La
00a0: 72 67 65 3a 46 69 6e 65 00 00 40 00 00 00 00 00 rge:Fine..@.....
00b0: 00 00 a8 06 00 00 e0 08 00 00 02 00 00 00 4c 61 ..............La
00c0: 72 67 65 3a 4e 6f 72 6d 61 6c 00 00 00 20 00 00 rge:Normal... ..
00d0: 00 00 a8 06 00 00 e0 08 00 00 03 00 00 00 4d 65 ..............Me
00e0: 64 69 75 6d 20 31 3a 53 75 70 65 72 46 69 6e 65 dium 1:SuperFine
00f0: 00 00 b0 04 00 00 40 06 00 00 01 00 00 00 4d 65 ......@.......Me
0100: 64 69 75 6d 20 31 3a 46 69 6e 65 00 00 00 00 00 dium 1:Fine.....
0110: 00 00 b0 04 00 00 40 06 00 00 02 00 00 00 4d 65 ......@.......Me
0120: 64 69 75 6d 20 31 3a 4e 6f 72 6d 61 6c 00 00 00 dium 1:Normal...
0130: 00 00 b0 04 00 00 40 06 00 00 03 00 00 00 4d 65 ......@.......Me
0140: 64 69 75 6d 20 32 3a 53 75 70 65 72 46 69 6e 65 dium 2:SuperFine
0150: 00 55 00 03 00 00 00 04 00 00 01 00 00 00 4d 65 .U............Me
0160: 64 69 75 6d 20 32 3a 46 69 6e 65 00 a8 71 aa 55 dium 2:Fine..q.U
0170: aa 55 00 03 00 00 00 04 00 00 02 00 00 00 4d 65 .U............Me
0180: 64 69 75 6d 20 32 3a 4e 6f 72 6d 61 6c 00 aa 55 dium 2:Normal..U
0190: ae 55 00 03 00 00 00 04 00 00 03 00 00 00 53 6d .U............Sm
01a0: 61 6c 6c 3a 53 75 70 65 72 46 69 6e 65 00 aa 55 all:SuperFine..U
01b0: aa 51 e0 01 00 00 80 02 00 00 01 00 00 00 53 6d .Q............Sm
01c0: 61 6c 6c 3a 46 69 6e 65 00 d5 aa 15 ab 55 aa 55 all:Fine.....U.U
01d0: aa 55 e0 01 00 00 80 02 00 00 02 00 00 00 53 6d .U............Sm
01e0: 61 6c 6c 3a 4e 6f 72 6d 61 6c 00 55 aa 55 aa 55 all:Normal.U.U.U
01f0: 2b 55 e0 01 00 00 80 02 00 00 03 00 00 00 43 52 +U............CR
0200: 57 00 aa 75 aa 15 aa 55 a8 54 aa 55 2a 57 aa 55 W..u...U.T.U*W.U
0210: 0a 75 a8 06 00 00 e0 08 00 00 04 00 00 00 aa 55 .u.............U
0220: aa d5 2a 54 aa 55 aa 55 aa c7 aa 55 aa 15 aa 55 ..*T.U.U...U...U
0230: ee 75 a2 55 a8 55 ff ff fe ff ff ff 7d f9 ff ff .u.U.U......}...
0240: ff af ff ff df ff ff ff ff ef ff ff fb ff ff ff ................
0250: be ff df ff fb fb ff ff ff ff ff ff fd ff ff ff ................
0260: 7d df bf f7 7f fe ff ff 3f ff be ff ff 57 ff ff }.......?....W..
0270: bf fb ff f7 ef 9f ff fb af ff ff ff ff ff 78 00 ..............x.
0280: 00 00 00 00 00 00 a0 00 00 00 00 00 00 00 14 00 ................
0290: 00 00 00 80 00 00 00 80 00 00 00 80 00 00 00 80 ................
02a0: 00 00 00 80 00 00 00 00 00 00 00 00 00 00 00 80 ................
02b0: 00 00 00 80 03 00 00 80 66 00 00 80 00 00 00 00 ........f.......
02c0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
02d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
02e0: 28 00 00 50 00 80 00 14 00 c0 00 00 00 80 00 00 (..P............
02f0: 00 80 00 00 00 80 00 00 00 80 00 00 00 80 00 00 ................
0300: 00 80 00 00 00 80 00 00 00 80 00 00 00 80 00 00 ................
0310: 00 c0 00 00 00 80 00 00 00 80 00 00 00 80 00 00 ................
0320: 00 00 00 00 00 00 00 00 00 80 00 00 00 80 00 00 ................
0330: 00 80 00 00 00 80 00 00 00 00 00 00 00 00 00 00 ................
0340: 00 00 00 00 00 00 00 00 00 00 00 00 00 f0 00 00 ................
0350: 00 80 00 00 00 80 00 00 00 80 00 00 00 80 00 50 ...............P
0360: 00 80 00 00 00 80 00 14 00 c0 00 00 00 00 00 00 ................
0370: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
0380: 00 00 55 aa ..U.
Table 3.6. Fields in camera photo abilities response
| offset | bytes | value |
|---|---|---|
| 0x50: | 4 | status code |
| 0x54: | 2 | size of structure (here 0x330=816 bytes) |
| 0x56: | 4 | Camera model identifier? (here 0x01100000). This will show up as the value of the image file tag 0x0010 (EXIF) or 0x5834 (CRW) |
| 0x5a: | 32 | camera identification (ASCII) |
| 0x7a: | 4 | Count n of number of entries in image-quality table |
| 0x7c: | n*32 | Table of image quality levels allowed |
The observed values at 0x56 are: 0x00000110 (G2) 0x000125 (A70), 0x00000127 (IXUS 400), 0x00000129 (G5), 0x00000134 (A80), 0x00000145 (A400), 0x00000157 (A510), 0x80000166 (D60), 0x80000170 (300D), 0x8003024a (Optura 20).
Each entry in the table seems to be
struct {
char imageType[20]; /* ASCII name of this image type */
long imageHeight, imageWidth;
long compressionType; /* 1: SuperFine 2:Fine 3:Normal 4:RAW */
} tableEntry;
So we can see that the PowerShot G2 can produce the following image types:
Table 3.7. PowerShot G2 image formats reported
| Height | Width | Compression | Name |
|---|---|---|---|
| 1704 | 2272 | JPEG superfine | Large: |
| 1704 | 2272 | JPEG fine | Large: |
| 1704 | 2272 | JPEG normal | Large: |
| 1200 | 1600 | JPEG superfine | Medium 1: |
| 1200 | 1600 | JPEG fine | Medium 1: |
| 1200 | 1600 | JPEG normal | Medium 1: |
| 768 | 1024 | JPEG superfine | Medium 2: |
| 768 | 1024 | JPEG fine | Medium 2: |
| 768 | 1024 | JPEG normal | Medium 2: |
| 480 | 640 | JPEG superfine | Small: |
| 480 | 640 | JPEG fine | Small: |
| 480 | 640 | JPEG normal | Small: |
| 1704 | 2272 | Raw | CRW |
I suspect that the remaining bytes after 0x21c are garbage.
Note: This command doesn't seem to be implemented on the EOS D30/D60 or the PowerShot S45 or G3. I suspect that it's being phased out, and new cameras from now on (February 2003) won't implement it. The new protocol uses a different code for what seems to be the same function.
Some recent models return responses of different length, so code must be ready for this and read the length from the first four bytes of the response. Cameras known to give different response lengths are