File Coverage

blib/lib/Image/ExifTool/NikonCustom.pm
Criterion Covered Total %
statement 6 6 100.0
branch n/a
condition n/a
subroutine 2 2 100.0
pod n/a
total 8 8 100.0


line stmt bran cond sub pod time code
1             #------------------------------------------------------------------------------
2             # File: NikonCustom.pm
3             #
4             # Description: Read and write Nikon Custom settings
5             #
6             # Revisions: 2009/11/25 - P. Harvey Created
7             #
8             # References: 1) Warren Hatch private communication (D3 and Z9 with SB-800 and SB-900)
9             # 2) Anonymous contribution 2011/05/25 (D700, D7000)
10             # JD) Jens Duttke private communication
11             #------------------------------------------------------------------------------
12              
13             package Image::ExifTool::NikonCustom;
14              
15 3     3   25 use strict;
  3         7  
  3         145  
16 3     3   22 use vars qw($VERSION);
  3         7  
  3         50097  
17              
18             $VERSION = '1.22';
19              
20             my %buttonsZ9= (
21             SeparateTable => 'ButtonsZ9',
22             PrintConv => {
23             0 => 'None',
24             1 => 'Preview',
25             3 => 'FV Lock',
26             4 => 'AE/AF Lock',
27             5 => 'AE Lock Only',
28             6 => 'AE Lock (reset on release)',
29             7 => 'AE Lock (hold)',
30             8 => 'AF Lock Only',
31             9 => 'AF-On',
32             10 => 'Flash Disable/Enable',
33             11 => 'Bracketing Burst',
34             12 => '+NEF(RAW)',
35             18 => 'Virtual Horizon',
36             19 => 'Synchronized Release',
37             20 => 'My Menu',
38             21 => 'My Menu Top Item',
39             22 => 'Playback',
40             23 => 'Rating',
41             24 => 'Protect',
42             25 => 'Zoom',
43             26 => 'Focus Peaking',
44             28 => 'Image Area',
45             30 => 'Non-CPU Lens',
46             31 => 'Active-D Lighting',
47             33 => '1 Stop Speed/Aperture',
48             34 => 'White Balance',
49             35 => 'Metering',
50             36 => 'Auto Bracketing',
51             37 => 'Multiple Exposure',
52             38 => 'HDR Overlay',
53             39 => 'Picture Control',
54             40 => 'Quality',
55             41 => 'Focus Mode/AF AreaMode',
56             42 => 'Select Center Focus Point',
57             44 => 'Record Movie',
58             47 => 'Choose Folder',
59             48 => 'Power Aperture (Open)',
60             49 => 'Power Aperture (Close)',
61             52 => 'Microphone Sensitivity',
62             57 => 'Preset Focus Point',
63             58 => 'AE/AWB Lock (hold)',
64             59 => 'AF-AreaMode',
65             60 => 'AF-AreaMode + AF-On',
66             61 => 'Recall Shooting Functions',
67             64 => 'Filtered Playback',
68             65 => 'Same as AF-On',
69             66 => 'Voice Memo',
70             70 => 'Photo Shooting Bank',
71             71 => 'ISO',
72             73 => 'Exposure Compensation',
73             76 => 'Silent Mode',
74             78 => 'LiveView Information',
75             79 => 'AWB Lock (hold)',
76             80 => 'Grid Display',
77             81 => 'Starlight View',
78             82 => 'Select To Send (PC)',
79             83 => 'Select To Send (FTP)',
80             84 => 'Pattern Tone Range',
81             85 => 'Control Lock',
82             86 => 'Save Focus Position',
83             87 => 'Recall Focus Position',
84             88 => 'Recall Shooting Functions (Hold)',
85             97 => 'High Frequency Flicker Reduction',
86             98 => 'Switch FX/DX',
87             99 => 'View Mode (Photo LV)',
88             100 => 'Photo Flicker Reduction',
89             101 => 'Filtered Playback (Select Criteria)',
90             103 => 'Start Series Playback',
91             104 => 'View Assist',
92             105 => 'Hi-Res Zoom+',
93             106 => 'Hi-Res Zoom-',
94             108 => 'Override Other Cameras',
95             109 => 'DISP - Cycle Information Display (shooting)', # Shooting Mode
96             110 => 'DISP - Cycle Information Display (playback)', # Playback mode
97             111 => 'Resume Shooting',
98             },
99             );
100             my %dialsZ9 = (
101             0 => '1 Frame',
102             1 => '10 Frames',
103             2 => '50 Frames',
104             3 => 'Folder',
105             4 => 'Protect',
106             5 => 'Photos Only',
107             6 => 'Videos Only',
108             7 => 'Rating',
109             8 => 'Page',
110             );
111             my %evfGridsZ9 = (
112             0 => '3x3',
113             1 => '4x4',
114             2 => '2.35:1',
115             3 => '1.85:1',
116             4 => '5:4',
117             5 => '4:3',
118             6 => '1:1',
119             7 => '16:9',
120             8 => '90%',
121             );
122             my %flicksZ9 = (
123             0 => 'Rating',
124             1 => 'Select To Send (PC)',
125             2 => 'Select To Send (FTP)',
126             3 => 'Protect',
127             4 => 'Voice Memo',
128             5 => 'None',
129             );
130             my %focusModeRestrictionsZ9 = (
131             0 => 'AF-S',
132             1 => 'AF-C',
133             2 => 'Full-time AF',
134             3 => 'Manual',
135             4 => 'No Restrictions',
136             );
137             my %powerOffDelayTimesZ9 = (
138             SeparateTable => 'DelaysZ9',
139             PrintConv => {
140             0 => '2 s',
141             1 => '4 s',
142             3 => '10 s',
143             4 => '20 s',
144             5 => '30 s',
145             6 => '1 min',
146             7 => '5 min',
147             8 => '10 min',
148             11 => '30 min',
149             12 => 'No Limit',
150             },
151             );
152             my %thirdHalfFull = (
153             0 => '1/3 EV',
154             1 => '1/2 EV',
155             2 => '1 EV',
156             );
157              
158             my %limitNolimit = ( 0 => 'Limit', 1 => 'No Limit' );
159             my %offOn = ( 0 => 'Off', 1 => 'On' );
160             my %onOff = ( 0 => 'On', 1 => 'Off' );
161             my %noYes = ( 0 => 'No', 1 => 'Yes' );
162              
163             # custom settings for the D80 (encrypted) - ref JD
164             %Image::ExifTool::NikonCustom::SettingsD80 = (
165             PROCESS_PROC => \&Image::ExifTool::ProcessBinaryData,
166             WRITE_PROC => \&Image::ExifTool::WriteBinaryData,
167             CHECK_PROC => \&Image::ExifTool::CheckBinaryData,
168             WRITABLE => 1,
169             FIRST_ENTRY => 0,
170             GROUPS => { 0 => 'MakerNotes', 2 => 'Camera' },
171             NOTES => 'Custom settings for the Nikon D80.',
172             0.1 => { # CS1
173             Name => 'Beep',
174             Mask => 0x80,
175             PrintConv => \%onOff,
176             },
177             0.2 => { # CS4
178             Name => 'AFAssist',
179             Mask => 0x40,
180             PrintConv => \%onOff,
181             },
182             0.3 => { # CS5
183             Name => 'NoMemoryCard',
184             Mask => 0x20,
185             PrintConv => {
186             0 => 'Release Locked',
187             1 => 'Enable Release',
188             },
189             },
190             0.4 => { # CS6
191             Name => 'ImageReview',
192             Mask => 0x10,
193             PrintConv => \%onOff,
194             },
195             0.5 => { # CS17
196             Name => 'Illumination',
197             Mask => 0x08,
198             PrintConv => \%offOn,
199             },
200             0.6 => { # CS11
201             Name => 'MainDialExposureComp',
202             Mask => 0x04,
203             PrintConv => \%offOn,
204             },
205             0.7 => { # CS10
206             Name => 'EVStepSize',
207             Mask => 0x01,
208             PrintConv => {
209             0 => '1/3 EV',
210             1 => '1/2 EV',
211             },
212             },
213             1.1 => { # CS7
214             Name => 'AutoISO',
215             Mask => 0x40,
216             PrintConv => \%offOn,
217             },
218             1.2 => { # CS7-a
219             Name => 'AutoISOMax',
220             Mask => 0x30,
221             PrintConv => {
222             0 => 200,
223             1 => 400,
224             2 => 800,
225             3 => 1600,
226             },
227             },
228             1.3 => { # CS7-b
229             Name => 'AutoISOMinShutterSpeed',
230             Mask => 0x0f,
231             PrintConvColumns => 2,
232             PrintConv => {
233             0 => '1/125 s',
234             1 => '1/100 s',
235             2 => '1/80 s',
236             3 => '1/60 s',
237             4 => '1/40 s',
238             5 => '1/30 s',
239             6 => '1/15 s',
240             7 => '1/8 s',
241             8 => '1/4 s',
242             9 => '1/2 s',
243             10 => '1 s',
244             },
245             },
246             2.1 => { # CS13
247             Name => 'AutoBracketSet',
248             Mask => 0xc0,
249             PrintConv => {
250             0 => 'AE & Flash',
251             1 => 'AE Only',
252             2 => 'Flash Only',
253             3 => 'WB Bracketing',
254             },
255             },
256             2.2 => { # CS14
257             Name => 'AutoBracketOrder',
258             Mask => 0x20,
259             PrintConv => {
260             0 => '0,-,+',
261             1 => '-,0,+',
262             },
263             },
264             3.1 => { # CS27
265             Name => 'MonitorOffTime',
266             Mask => 0xe0,
267             PrintConv => {
268             0 => '5 s',
269             1 => '10 s',
270             2 => '20 s',
271             3 => '1 min',
272             4 => '5 min',
273             5 => '10 min',
274             },
275             },
276             3.2 => { # CS28
277             Name => 'MeteringTime',
278             Mask => 0x1c,
279             PrintConv => {
280             0 => '4 s',
281             1 => '6 s',
282             2 => '8 s',
283             3 => '16 s',
284             4 => '30 s',
285             5 => '30 min',
286             },
287             },
288             3.3 => { # CS29
289             Name => 'SelfTimerTime',
290             Mask => 0x03,
291             PrintConv => {
292             0 => '2 s',
293             1 => '5 s',
294             2 => '10 s',
295             3 => '20 s',
296             },
297             },
298             4.1 => { # CS18
299             Name => 'AELockButton',
300             Mask => 0x1e,
301             PrintConv => {
302             0 => 'AE/AF Lock',
303             1 => 'AE Lock Only',
304             2 => 'AF Lock Only',
305             3 => 'AE Lock (hold)',
306             4 => 'AF-ON',
307             5 => 'FV Lock',
308             6 => 'Focus Area Selection',
309             7 => 'AE-L/AF-L/AF Area',
310             8 => 'AE-L/AF Area',
311             9 => 'AF-L/AF Area',
312             10 => 'AF-ON/AF Area',
313             },
314             },
315             4.2 => { # CS19
316             Name => 'AELock',
317             Mask => 0x01,
318             PrintConv => \%offOn,
319             },
320             4.3 => { # CS30
321             Name => 'RemoteOnDuration',
322             Mask => 0xc0,
323             PrintConv => {
324             0 => '1 min',
325             1 => '5 min',
326             2 => '10 min',
327             3 => '15 min',
328             },
329             },
330             5.1 => { # CS15
331             Name => 'CommandDials',
332             Mask => 0x80,
333             PrintConv => {
334             0 => 'Standard (Main Shutter, Sub Aperture)',
335             1 => 'Reversed (Main Aperture, Sub Shutter)',
336             },
337             },
338             5.2 => { # CS16
339             Name => 'FunctionButton',
340             Mask => 0x78,
341             PrintConv => {
342             0 => 'ISO Display',
343             1 => 'Framing Grid',
344             2 => 'AF-area Mode',
345             3 => 'Center AF Area',
346             4 => 'FV Lock',
347             5 => 'Flash Off',
348             6 => 'Matrix Metering',
349             7 => 'Center-weighted',
350             8 => 'Spot Metering',
351             },
352             },
353             6.1 => { # CS8
354             Name => 'GridDisplay',
355             Mask => 0x80,
356             PrintConv => \%offOn,
357             },
358             6.2 => { # CS9
359             Name => 'ViewfinderWarning',
360             Mask => 0x40,
361             PrintConv => \%onOff,
362             },
363             6.3 => { # CS12
364             Name => 'CenterWeightedAreaSize',
365             Mask => 0x0c,
366             PrintConv => {
367             0 => '6 mm',
368             1 => '8 mm',
369             2 => '10 mm',
370             },
371             },
372             6.4 => { # CS31
373             Name => 'ExposureDelayMode',
374             Mask => 0x20,
375             PrintConv => \%offOn,
376             },
377             6.5 => { # CS32
378             Name => 'MB-D80Batteries',
379             Mask => 0x03,
380             PrintConv => {
381             0 => 'LR6 (AA Alkaline)',
382             1 => 'HR6 (AA Ni-MH)',
383             2 => 'FR6 (AA Lithium)',
384             3 => 'ZR6 (AA Ni-Mg)',
385             },
386             },
387             7.1 => { # CS23
388             Name => 'FlashWarning',
389             Mask => 0x80,
390             PrintConv => \%onOff,
391             },
392             7.2 => { # CS24
393             Name => 'FlashShutterSpeed',
394             Mask => 0x78,
395             ValueConv => '2 ** ($val - 6)',
396             ValueConvInv => '$val>0 ? int(log($val)/log(2)+6+0.5) : 0',
397             PrintConv => 'Image::ExifTool::Exif::PrintExposureTime($val)',
398             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
399             },
400             7.3 => { # CS25
401             Name => 'AutoFP',
402             Mask => 0x04,
403             PrintConv => \%offOn,
404             },
405             7.4 => { # CS26
406             Name => 'ModelingFlash',
407             Mask => 0x02,
408             PrintConv => \%offOn,
409             },
410             8.1 => { # CS22
411             Name => 'InternalFlash',
412             Mask => 0xc0,
413             PrintConv => {
414             0 => 'TTL',
415             1 => 'Manual',
416             2 => 'Repeating Flash',
417             3 => 'Commander Mode',
418             },
419             },
420             8.2 => { # CS22-a
421             Name => 'ManualFlashOutput',
422             Mask => 0x07,
423             ValueConv => '2 ** (-$val)',
424             ValueConvInv => '$val > 0 ? -log($val)/log(2) : 0',
425             PrintConv => q{
426             return 'Full' if $val > 0.99;
427             Image::ExifTool::Exif::PrintExposureTime($val);
428             },
429             PrintConvInv => '$val=~/F/i ? 1 : Image::ExifTool::Exif::ConvertFraction($val)',
430             },
431             9.1 => { # CS22-b
432             Name => 'RepeatingFlashOutput',
433             Mask => 0x70,
434             ValueConv => '2 ** (-$val-2)',
435             ValueConvInv => '$val > 0 ? int(-log($val)/log(2)-2+0.5) : 0',
436             PrintConv => 'Image::ExifTool::Exif::PrintExposureTime($val)',
437             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
438             },
439             9.2 => { # CS22-c
440             Name => 'RepeatingFlashCount',
441             Mask => 0x0f,
442             ValueConv => '$val < 10 ? $val + 1 : 5 * ($val - 7)',
443             ValueConvInv => '$val <= 10 ? $val - 1 : $val / 5 + 7',
444             },
445             10.1 => { # CS22-d
446             Name => 'RepeatingFlashRate',
447             Mask => 0xf0,
448             ValueConv => '$val < 10 ? $val + 1 : 10 * ($val - 8)',
449             ValueConvInv => 'int(($val <= 10 ? $val - 1 : $val / 10 + 8) + 0.5)',
450             PrintConv => '"$val Hz"',
451             PrintConvInv => '$val=~/(\d+)/; $1 || 0',
452             },
453             10.2 => { # CS22-n
454             Name => 'CommanderChannel',
455             Mask => 0x03,
456             ValueConv => '$val + 1',
457             ValueConvInv => '$val - 1',
458             },
459             11.1 => { # CS22-e
460             Name => 'CommanderInternalFlash',
461             Mask => 0xc0,
462             PrintConv => {
463             0 => 'TTL',
464             1 => 'Manual',
465             2 => 'Off',
466             },
467             },
468             11.2 => { # CS22-h
469             Name => 'CommanderGroupAMode',
470             Mask => 0x30,
471             PrintConv => {
472             0 => 'TTL',
473             1 => 'Auto Aperture',
474             2 => 'Manual',
475             3 => 'Off',
476             },
477             },
478             11.3 => { # CS22-k
479             Name => 'CommanderGroupBMode',
480             Mask => 0x0c,
481             PrintConv => {
482             0 => 'TTL',
483             1 => 'Auto Aperture',
484             2 => 'Manual',
485             3 => 'Off',
486             },
487             },
488             12.1 => { # CS22-f
489             Name => 'CommanderInternalTTLComp',
490             Mask => 0x1f,
491             ValueConv => '($val - 9) / 3',
492             ValueConvInv => '$val * 3 + 9',
493             PrintConv => '$val ? sprintf("%+.1f",$val) : 0',
494             PrintConvInv => '$val',
495             },
496             12.2 => { # CS22-g
497             Name => 'CommanderInternalManualOutput',
498             Mask => 0xe0,
499             ValueConv => '2 ** (-$val)',
500             ValueConvInv => '$val > 0 ? int(-log($val)/log(2)+0.5) : 0',
501             PrintConv => q{
502             return 'Full' if $val > 0.99;
503             Image::ExifTool::Exif::PrintExposureTime($val);
504             },
505             PrintConvInv => '$val=~/F/i ? 1 : Image::ExifTool::Exif::ConvertFraction($val)',
506             },
507             13.1 => { # CS22-i
508             Name => 'CommanderGroupA_TTL-AAComp',
509             Mask => 0x1f,
510             ValueConv => '($val - 9) / 3',
511             ValueConvInv => '$val * 3 + 9',
512             PrintConv => '$val ? sprintf("%+.1f",$val) : 0',
513             PrintConvInv => '$val',
514             },
515             13.2 => { # CS22-j
516             Name => 'CommanderGroupAManualOutput',
517             Mask => 0xe0,
518             ValueConv => '2 ** (-$val)',
519             ValueConvInv => '$val > 0 ? int(-log($val)/log(2)+0.5) : 0',
520             PrintConv => q{
521             return 'Full' if $val > 0.99;
522             Image::ExifTool::Exif::PrintExposureTime($val);
523             },
524             PrintConvInv => '$val=~/F/i ? 1 : Image::ExifTool::Exif::ConvertFraction($val)',
525             },
526             14.1 => { # CS22-l
527             Name => 'CommanderGroupB_TTL-AAComp',
528             Mask => 0x1f,
529             ValueConv => '($val - 9) / 3',
530             ValueConvInv => '$val * 3 + 9',
531             PrintConv => '$val ? sprintf("%+.1f",$val) : 0',
532             PrintConvInv => '$val',
533             },
534             14.2 => { # CS22-m
535             Name => 'CommanderGroupBManualOutput',
536             Mask => 0xe0,
537             ValueConv => '2 ** (-$val)',
538             ValueConvInv => '$val > 0 ? int(-log($val)/log(2)+0.5) : 0',
539             PrintConv => q{
540             return 'Full' if $val > 0.99;
541             Image::ExifTool::Exif::PrintExposureTime($val);
542             },
543             PrintConvInv => '$val=~/F/i ? 1 : Image::ExifTool::Exif::ConvertFraction($val)',
544             },
545             15.1 => { # CS3
546             Name => 'CenterAFArea',
547             Mask => 0x80,
548             PrintConv => {
549             0 => 'Normal Zone',
550             1 => 'Wide Zone',
551             },
552             },
553             15.2 => { # CS20
554             Name => 'FocusAreaSelection',
555             Mask => 0x04,
556             PrintConv => {
557             0 => 'No Wrap',
558             1 => 'Wrap',
559             },
560             },
561             15.3 => { # CS21
562             Name => 'AFAreaIllumination',
563             Mask => 0x03,
564             PrintConv => {
565             0 => 'Auto',
566             1 => 'Off',
567             2 => 'On',
568             },
569             },
570             16.1 => { # CS2
571             Name => 'AFAreaModeSetting',
572             Mask => 0xc0,
573             PrintConv => {
574             0 => 'Single Area',
575             1 => 'Dynamic Area',
576             2 => 'Auto-area',
577             },
578             },
579             );
580              
581             # custom settings for the D40 (encrypted) - ref JD
582             %Image::ExifTool::NikonCustom::SettingsD40 = (
583             PROCESS_PROC => \&Image::ExifTool::ProcessBinaryData,
584             WRITE_PROC => \&Image::ExifTool::WriteBinaryData,
585             CHECK_PROC => \&Image::ExifTool::CheckBinaryData,
586             WRITABLE => 1,
587             FIRST_ENTRY => 0,
588             GROUPS => { 0 => 'MakerNotes', 2 => 'Camera' },
589             NOTES => 'Custom settings for the Nikon D40.',
590             0.1 => { # CS1
591             Name => 'Beep',
592             Mask => 0x80,
593             PrintConv => \%onOff,
594             },
595             0.2 => { # CS9
596             Name => 'AFAssist',
597             Mask => 0x40,
598             PrintConv => \%onOff,
599             },
600             0.3 => { # CS6
601             Name => 'NoMemoryCard',
602             Mask => 0x20,
603             PrintConv => {
604             0 => 'Release Locked',
605             1 => 'Enable Release',
606             },
607             },
608             0.4 => { # CS7
609             Name => 'ImageReview',
610             Mask => 0x10,
611             PrintConv => \%onOff,
612             },
613             1.1 => { # CS10-a
614             Name => 'AutoISO',
615             Mask => 0x80,
616             PrintConv => \%offOn,
617             },
618             1.2 => { # CS10-b
619             Name => 'AutoISOMax',
620             Mask => 0x30,
621             PrintConv => {
622             1 => 400,
623             2 => 800,
624             3 => 1600,
625             },
626             },
627             1.3 => { # CS10-c
628             Name => 'AutoISOMinShutterSpeed',
629             Mask => 0x07,
630             PrintConvColumns => 2,
631             PrintConv => {
632             0 => '1/125 s',
633             1 => '1/60 s',
634             2 => '1/30 s',
635             3 => '1/15 s',
636             4 => '1/8 s',
637             5 => '1/4 s',
638             6 => '1/2 s',
639             7 => '1 s',
640             },
641             },
642             2.1 => { # CS15-b
643             Name => 'ImageReviewTime',
644             Mask => 0x07,
645             PrintConv => {
646             0 => '4 s',
647             1 => '8 s',
648             2 => '20 s',
649             3 => '1 min',
650             4 => '10 min',
651             },
652             },
653             3.1 => { # CS15-a
654             Name => 'MonitorOffTime',
655             Mask => 0xe0,
656             PrintConv => {
657             0 => '4 s',
658             1 => '8 s',
659             2 => '20 s',
660             3 => '1 min',
661             4 => '10 min',
662             },
663             },
664             3.2 => { # CS15-c
665             Name => 'MeteringTime',
666             Mask => 0x1c,
667             PrintConv => {
668             0 => '4 s',
669             1 => '8 s',
670             2 => '20 s',
671             3 => '1 min',
672             4 => '30 min',
673             },
674             },
675             3.3 => { # CS16
676             Name => 'SelfTimerTime',
677             Mask => 0x03,
678             PrintConv => {
679             0 => '2 s',
680             1 => '5 s',
681             2 => '10 s',
682             3 => '20 s',
683             },
684             },
685             3.4 => { # CS17
686             Name => 'RemoteOnDuration',
687             Mask => 0xc0,
688             PrintConv => {
689             0 => '1 min',
690             1 => '5 min',
691             2 => '10 min',
692             3 => '15 min',
693             },
694             },
695             4.1 => { # CS12
696             Name => 'AELockButton',
697             Mask => 0x0e,
698             PrintConv => {
699             0 => 'AE/AF Lock',
700             1 => 'AE Lock Only',
701             2 => 'AF Lock Only',
702             3 => 'AE Lock (hold)',
703             4 => 'AF-ON',
704             },
705             },
706             4.2 => { # CS13
707             Name => 'AELock',
708             Mask => 0x01,
709             PrintConv => \%offOn,
710             },
711             5.1 => { # CS4
712             Name => 'ShootingModeSetting',
713             Mask => 0x70,
714             PrintConv => {
715             0 => 'Single Frame',
716             1 => 'Continuous',
717             2 => 'Self-timer',
718             3 => 'Delayed Remote',
719             4 => 'Quick-response Remote',
720             },
721             },
722             5.2 => { # CS11
723             Name => 'TimerFunctionButton',
724             Mask => 0x07,
725             PrintConv => {
726             0 => 'Shooting Mode',
727             1 => 'Image Quality/Size',
728             2 => 'ISO',
729             3 => 'White Balance',
730             4 => 'Self-timer',
731             },
732             },
733             6.1 => { # CS5
734             Name => 'Metering',
735             Mask => 0x03,
736             PrintConv => {
737             0 => 'Matrix',
738             1 => 'Center-weighted',
739             2 => 'Spot',
740             },
741             },
742             8.1 => { # CS14-a
743             Name => 'InternalFlash',
744             Mask => 0x10,
745             PrintConv => {
746             0 => 'TTL',
747             1 => 'Manual',
748             },
749             },
750             8.2 => { # CS14-b
751             Name => 'ManualFlashOutput',
752             Mask => 0x07,
753             ValueConv => '2 ** (-$val)',
754             ValueConvInv => '$val > 0 ? -log($val)/log(2) : 0',
755             PrintConv => q{
756             return 'Full' if $val > 0.99;
757             Image::ExifTool::Exif::PrintExposureTime($val);
758             },
759             PrintConvInv => '$val=~/F/i ? 1 : Image::ExifTool::Exif::ConvertFraction($val)',
760             },
761             9 => { # CS8
762             Name => 'FlashLevel',
763             Format => 'int8s',
764             ValueConv => '$val / 6',
765             ValueConvInv => '$val * 6',
766             PrintConv => 'sprintf("%+.1f",$val)',
767             PrintConvInv => '$val',
768             },
769             10.1 => { # CS2
770             Name => 'FocusModeSetting',
771             # (may differ from FocusMode if lens switch is set to Manual)
772             Mask => 0xc0,
773             PrintConv => {
774             0 => 'Manual',
775             1 => 'AF-S',
776             2 => 'AF-C',
777             3 => 'AF-A',
778             },
779             },
780             11.1 => { # CS3
781             Name => 'AFAreaModeSetting',
782             # (may differ from AFAreaMode for Manual focus)
783             Mask => 0x30,
784             PrintConv => {
785             0 => 'Single Area',
786             1 => 'Dynamic Area',
787             2 => 'Closest Subject',
788             },
789             }
790             );
791              
792             # D90 custom settings (ref PH)
793             %Image::ExifTool::NikonCustom::SettingsD90 = (
794             PROCESS_PROC => \&Image::ExifTool::ProcessBinaryData,
795             WRITE_PROC => \&Image::ExifTool::WriteBinaryData,
796             CHECK_PROC => \&Image::ExifTool::CheckBinaryData,
797             WRITABLE => 1,
798             FIRST_ENTRY => 0,
799             GROUPS => { 0 => 'MakerNotes', 2 => 'Camera' },
800             NOTES => 'Custom settings for the D90.',
801             # Missing:
802             # CSe2 RepeatingFlashRate (needs verification)
803             # CommanderInternalFlash, CommanderGroupAMode, CommanderGroupBMode,
804             # CommanderChannel, CommanderInternalManualOutput,
805             # CommanderGroupAManualOutput, CommanderGroupBManualOutput
806             # CommanderGroupA_TTL-AAComp, CommanderGroupB_TTL-AAComp,
807             # CSe4 AutoBracketSet (some values need verification)
808             # CSf2 OKButton ("Not Used" value needs verification)
809             # CSf5-b CommandDialsChangeMainSub
810             # CSf5-c CommandDialsMenuAndPlayback
811             0.1 => { # CSf1
812             Name => 'LightSwitch',
813             Mask => 0x08,
814             PrintConv => {
815             0 => 'LCD Backlight',
816             1 => 'LCD Backlight and Shooting Information',
817             },
818             },
819             2.1 => { # CSa1
820             Name => 'AFAreaModeSetting',
821             Mask => 0x60,
822             PrintConv => {
823             0 => 'Single Area',
824             1 => 'Dynamic Area',
825             2 => 'Auto-area',
826             3 => '3D-tracking (11 points)',
827             },
828             },
829             2.2 => { # CSa2
830             Name => 'CenterFocusPoint',
831             Mask => 0x10,
832             PrintConv => {
833             0 => 'Normal Zone',
834             1 => 'Wide Zone',
835             },
836             },
837             2.3 => { # CSa3
838             Name => 'AFAssist',
839             Mask => 0x01,
840             PrintConv => \%onOff,
841             },
842             2.4 => { # CSa4
843             Name => 'AFPointIllumination',
844             Mask => 0x06,
845             PrintConv => {
846             0 => 'Auto',
847             1 => 'On',
848             2 => 'Off',
849             },
850             },
851             2.5 => { # CSa5
852             Name => 'FocusPointWrap',
853             Mask => 0x08,
854             PrintConv => {
855             0 => 'No Wrap',
856             1 => 'Wrap',
857             },
858             },
859             3.1 => { # CSa6
860             Name => 'AELockForMB-D80',
861             Mask => 0x1c,
862             PrintConv => {
863             0 => 'AE Lock Only',
864             1 => 'AF Lock Only',
865             2 => 'AE Lock (hold)',
866             3 => 'AF-On',
867             4 => 'FV Lock',
868             5 => 'Focus Point Selection',
869             7 => 'AE/AF Lock',
870             },
871             },
872             3.2 => { # CSd12
873             Name => 'MB-D80BatteryType',
874             Mask => 0x03,
875             PrintConv => {
876             0 => 'LR6 (AA alkaline)',
877             1 => 'HR6 (AA Ni-MH)',
878             2 => 'FR6 (AA lithium)',
879             3 => 'ZR6 (AA Ni-Mn)',
880             },
881             },
882             4.1 => { # CSd1
883             Name => 'Beep',
884             Mask => 0x40,
885             PrintConv => \%offOn,
886             },
887             4.2 => { # CSd2
888             Name => 'GridDisplay',
889             Mask => 0x02,
890             PrintConv => \%offOn,
891             },
892             4.3 => { # CSd3
893             Name => 'ISODisplay',
894             Mask => 0x0c,
895             PrintConv => {
896             0 => 'Show ISO/Easy ISO',
897             1 => 'Show ISO Sensitivity',
898             3 => 'Show Frame Count',
899             },
900             },
901             4.4 => { # CSd4
902             Name => 'ViewfinderWarning',
903             Mask => 0x01,
904             PrintConv => \%onOff,
905             },
906             4.5 => { # CSf6
907             Name => 'NoMemoryCard',
908             Mask => 0x20,
909             PrintConv => {
910             0 => 'Release Locked',
911             1 => 'Enable Release',
912             },
913             },
914             5.1 => { # CSd5
915             Name => 'ScreenTips',
916             Mask => 0x04,
917             PrintConv => \%offOn,
918             },
919             5.2 => { # CSd7
920             Name => 'FileNumberSequence',
921             Mask => 0x08,
922             PrintConv => \%onOff,
923             },
924             5.3 => { # CSd8
925             Name => 'ShootingInfoDisplay',
926             Mask => 0xc0,
927             PrintConv => {
928             0 => 'Auto',
929             2 => 'Manual (dark on light)',
930             3 => 'Manual (light on dark)',
931             },
932             },
933             5.4 => { # CSd9
934             Name => 'LCDIllumination',
935             Mask => 0x20,
936             PrintConv => \%offOn,
937             },
938             6.1 => { # CSb2
939             Name => 'EasyExposureComp',
940             Mask => 0x01,
941             PrintConv => \%offOn,
942             },
943             6.2 => { # CSf7
944             Name => 'ReverseIndicators',
945             Mask => 0x80,
946             PrintConv => {
947             0 => '+ 0 -',
948             1 => '- 0 +',
949             },
950             },
951             7.1 => { # CSb1
952             Name => 'ExposureControlStepSize',
953             Mask => 0x40,
954             PrintConv => {
955             0 => '1/3 EV',
956             1 => '1/2 EV',
957             },
958             },
959             8.1 => { # CSb3
960             Name => 'CenterWeightedAreaSize',
961             Mask => 0x60,
962             PrintConv => {
963             0 => '6 mm',
964             1 => '8 mm',
965             2 => '10 mm',
966             },
967             },
968             8.2 => { # CSb4-a
969             Name => 'FineTuneOptMatrixMetering',
970             Mask => 0x0f,
971             ValueConv => '($val > 0x7 ? $val - 0x10 : $val) / 6',
972             ValueConvInv => 'int($val*6+($val>0?0.5:-0.5))',
973             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
974             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
975             },
976             9.1 => { # CSb4-b
977             Name => 'FineTuneOptCenterWeighted',
978             Mask => 0xf0,
979             ValueConv => '($val > 0x7 ? $val - 0x10 : $val) / 6',
980             ValueConvInv => 'int($val*6+($val>0?0.5:-0.5))',
981             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
982             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
983             },
984             9.2 => { # CSb4-c
985             Name => 'FineTuneOptSpotMetering',
986             Mask => 0x0f,
987             ValueConv => '($val > 0x7 ? $val - 0x10 : $val) / 6',
988             ValueConvInv => 'int($val*6+($val>0?0.5:-0.5))',
989             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
990             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
991             },
992             11.1 => { # CSd6
993             Name => 'CLModeShootingSpeed',
994             Mask => 0x07,
995             PrintConv => '"$val fps"',
996             PrintConvInv => '$val=~s/\s*fps//i; $val',
997             },
998             11.2 => { # CSd10
999             Name => 'ExposureDelayMode',
1000             Mask => 0x40,
1001             PrintConv => \%offOn,
1002             },
1003             13.1 => { # CSe4
1004             Name => 'AutoBracketSet',
1005             Mask => 0xe0, #(NC)
1006             PrintConv => {
1007             0 => 'AE & Flash', # default
1008             1 => 'AE Only',
1009             2 => 'Flash Only', #(NC)
1010             3 => 'WB Bracketing', #(NC)
1011             4 => 'Active D-Lighting', #(NC)
1012             },
1013             },
1014             13.2 => { # CSe6
1015             Name => 'AutoBracketOrder',
1016             Mask => 0x10,
1017             PrintConv => {
1018             0 => '0,-,+',
1019             1 => '-,0,+',
1020             },
1021             },
1022             14.1 => { # CSf3
1023             Name => 'FuncButton',
1024             Mask => 0x78,
1025             PrintConv => {
1026             1 => 'Framing Grid',
1027             2 => 'AF-area Mode',
1028             3 => 'Center Focus Point',
1029             4 => 'FV Lock', # default
1030             5 => 'Flash Off',
1031             6 => 'Matrix Metering',
1032             7 => 'Center-weighted Metering',
1033             8 => 'Spot Metering',
1034             9 => 'My Menu Top',
1035             10 => '+ NEF (RAW)',
1036             },
1037             },
1038             16.1 => { # CSf2
1039             Name => 'OKButton',
1040             Mask => 0x18,
1041             PrintConv => {
1042             1 => 'Select Center Focus Point',
1043             2 => 'Highlight Active Focus Point',
1044             3 => 'Not Used', #(NC)
1045             0 => 'Not Used', #(NC)
1046             },
1047             },
1048             17.1 => { # CSf4
1049             Name => 'AELockButton',
1050             Mask => 0x38,
1051             PrintConv => {
1052             0 => 'AE/AF Lock',
1053             1 => 'AE Lock Only',
1054             2 => 'AF Lock Only', #(NC)
1055             3 => 'AE Lock (hold)', #(NC)
1056             4 => 'AF-ON', #(NC)
1057             5 => 'FV Lock', #(NC)
1058             },
1059             },
1060             18.1 => { # CSf5-a
1061             Name => 'CommandDialsReverseRotation',
1062             Mask => 0x80,
1063             PrintConv => \%noYes,
1064             },
1065             18.2 => { # CSc1
1066             Name => 'ShutterReleaseButtonAE-L',
1067             Mask => 0x02,
1068             PrintConv => \%offOn,
1069             },
1070             19.1 => { # CSc2
1071             Name => 'MeteringTime',
1072             Mask => 0xf0,
1073             PrintConvColumns => 2,
1074             PrintConv => {
1075             0 => '4 s',
1076             1 => '6 s', # default
1077             2 => '8 s',
1078             3 => '16 s',
1079             4 => '30 s',
1080             5 => '1 min',
1081             6 => '5 min',
1082             7 => '10 min',
1083             8 => '30 min',
1084             },
1085             },
1086             19.2 => { # CSc5
1087             Name => 'RemoteOnDuration',
1088             Mask => 0x03,
1089             PrintConv => {
1090             0 => '1 min',
1091             1 => '5 min',
1092             2 => '10 min',
1093             3 => '15 min',
1094             },
1095             },
1096             20.1 => { # CSc3-a
1097             Name => 'SelfTimerTime',
1098             Mask => 0xc0,
1099             PrintConv => {
1100             0 => '2 s',
1101             1 => '5 s',
1102             2 => '10 s', # default
1103             3 => '20 s',
1104             },
1105             },
1106             20.2 => { # CSc3-b
1107             Name => 'SelfTimerShotCount',
1108             Mask => 0x1e,
1109             },
1110             21.1 => { # CSc4-a
1111             Name => 'PlaybackMonitorOffTime',
1112             Mask => 0x1c,
1113             PrintConv => {
1114             0 => '4 s',
1115             1 => '10 s', # default
1116             2 => '20 s',
1117             3 => '1 min',
1118             4 => '5 min',
1119             5 => '10 min',
1120             },
1121             },
1122             21.2 => { # CSc4-d
1123             Name => 'ImageReviewTime',
1124             Mask => 0xe0,
1125             PrintConv => {
1126             0 => '4 s', # default
1127             1 => '10 s',
1128             2 => '20 s',
1129             3 => '1 min',
1130             4 => '5 min',
1131             5 => '10 min',
1132             },
1133             },
1134             22.1 => { # CSc4-b
1135             Name => 'MenuMonitorOffTime',
1136             Mask => 0xe0,
1137             PrintConv => {
1138             0 => '4 s',
1139             1 => '10 s',
1140             2 => '20 s', # default
1141             3 => '1 min',
1142             4 => '5 min',
1143             5 => '10 min',
1144             },
1145             },
1146             22.2 => { # CSc4-c
1147             Name => 'ShootingInfoMonitorOffTime',
1148             Mask => 0x1c,
1149             PrintConv => {
1150             0 => '4 s',
1151             1 => '10 s', # default
1152             2 => '20 s',
1153             3 => '1 min',
1154             4 => '5 min',
1155             5 => '10 min',
1156             },
1157             },
1158             23.1 => { # CSe1
1159             Name => 'FlashShutterSpeed',
1160             Mask => 0x0f,
1161             PrintConvColumns => 2,
1162             PrintConv => {
1163             0 => '1/60 s', # default
1164             1 => '1/30 s',
1165             2 => '1/15 s',
1166             3 => '1/8 s',
1167             4 => '1/4 s',
1168             5 => '1/2 s',
1169             6 => '1 s',
1170             7 => '2 s',
1171             8 => '4 s',
1172             9 => '8 s',
1173             10 => '15 s',
1174             11 => '30 s',
1175             },
1176             },
1177             24.1 => { # CSe2-a
1178             Name => 'InternalFlash',
1179             Mask => 0xc0,
1180             PrintConv => {
1181             0 => 'TTL',
1182             1 => 'Manual',
1183             2 => 'Repeating Flash',
1184             3 => 'Commander Mode',
1185             },
1186             },
1187             24.2 => { # CSe2-b
1188             Name => 'ManualFlashOutput',
1189             Mask => 0x1f,
1190             ValueConv => '2 ** (-$val/3)',
1191             ValueConvInv => '$val > 0 ? -3*log($val)/log(2) : 0',
1192             PrintConv => q{
1193             return 'Full' if $val > 0.99;
1194             Image::ExifTool::Exif::PrintExposureTime($val);
1195             },
1196             PrintConvInv => '$val=~/F/i ? 1 : Image::ExifTool::Exif::ConvertFraction($val)',
1197             },
1198             25.1 => { # CSe2-ca
1199             Name => 'RepeatingFlashOutput',
1200             Mask => 0x70,
1201             ValueConv => '2 ** (-$val-2)',
1202             ValueConvInv => '$val > 0 ? int(-log($val)/log(2)-2+0.5) : 0',
1203             PrintConv => 'Image::ExifTool::Exif::PrintExposureTime($val)',
1204             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
1205             },
1206             25.2 => { # CSe2-cb
1207             Name => 'RepeatingFlashCount',
1208             Mask => 0x0f,
1209             ValueConv => '$val < 10 ? $val + 1 : 5 * ($val - 7)',
1210             ValueConvInv => '$val <= 10 ? $val - 1 : $val / 5 + 7',
1211             },
1212             26.1 => { # CSe2-cc (NC)
1213             Name => 'RepeatingFlashRate',
1214             Mask => 0xf0,
1215             ValueConv => '$val < 10 ? $val + 1 : 10 * ($val - 8)',
1216             ValueConvInv => 'int(($val <= 10 ? $val - 1 : $val / 10 + 8) + 0.5)',
1217             PrintConv => '"$val Hz"',
1218             PrintConvInv => '$val=~/(\d+)/; $1 || 0',
1219             },
1220             31.1 => { # CSd11
1221             Name => 'FlashWarning',
1222             Mask => 0x80,
1223             PrintConv => \%onOff,
1224             },
1225             31.2 => { # CSe2-ea
1226             Name => 'CommanderInternalTTLComp',
1227             Mask => 0x1f,
1228             ValueConv => '($val - 9) / 3',
1229             ValueConvInv => '$val * 3 + 9',
1230             PrintConv => '$val ? sprintf("%+.1f",$val) : 0',
1231             PrintConvInv => '$val',
1232             },
1233             31.3 => { # CSe3
1234             Name => 'ModelingFlash',
1235             Mask => 0x20,
1236             PrintConv => \%onOff,
1237             },
1238             31.4 => { # CSe5
1239             Name => 'AutoFP',
1240             Mask => 0x40,
1241             PrintConv => \%offOn,
1242             },
1243             32.1 => { # CSe2-eb
1244             Name => 'CommanderGroupA_TTLComp',
1245             Mask => 0x1f,
1246             ValueConv => '($val - 9) / 3',
1247             ValueConvInv => '$val * 3 + 9',
1248             PrintConv => '$val ? sprintf("%+.1f",$val) : 0',
1249             PrintConvInv => '$val',
1250             },
1251             33.1 => { # CSe2-ec
1252             Name => 'CommanderGroupB_TTLComp',
1253             Mask => 0x1f,
1254             ValueConv => '($val - 9) / 3',
1255             ValueConvInv => '$val * 3 + 9',
1256             PrintConv => '$val ? sprintf("%+.1f",$val) : 0',
1257             PrintConvInv => '$val',
1258             },
1259             34.1 => { # CSa7
1260             Name => 'LiveViewAF',
1261             Mask => 0xc0,
1262             PrintConv => {
1263             0 => 'Face Priority', #(NC)
1264             1 => 'Wide Area',
1265             2 => 'Normal Area',
1266             },
1267             },
1268             );
1269              
1270             # D300 (ref JD) and D3 (ref 1/PH) custom settings
1271             %Image::ExifTool::NikonCustom::SettingsD3 = (
1272             PROCESS_PROC => \&Image::ExifTool::ProcessBinaryData,
1273             WRITE_PROC => \&Image::ExifTool::WriteBinaryData,
1274             CHECK_PROC => \&Image::ExifTool::CheckBinaryData,
1275             WRITABLE => 1,
1276             FIRST_ENTRY => 0,
1277             GROUPS => { 0 => 'MakerNotes', 2 => 'Camera' },
1278             NOTES => 'Custom settings for the D3, D3S, D3X, D300 and D300S.',
1279             # these settings have been decoded using the D3 and D300, and
1280             # extrapolated to the other models, but these haven't yet been
1281             # verified, and the following custom settings are missing:
1282             # CSf1-d (D3X,D3S) MultiSelectorLiveView
1283             # CSf1 (D300S) LightSwitch
1284             0.1 => { #1
1285             Name => 'CustomSettingsBank',
1286             Mask => 0x03,
1287             PrintConv => {
1288             0 => 'A',
1289             1 => 'B',
1290             2 => 'C',
1291             3 => 'D',
1292             },
1293             },
1294             0.2 => { #1
1295             Name => 'CustomSettingsAllDefault',
1296             Notes => '"No" if any custom setting for this bank was changed from the default',
1297             Mask => 0x80,
1298             PrintConv => { 0 => 'Yes', 1 => 'No' },
1299             },
1300             1.1 => { # CSa1
1301             Name => 'AF-CPrioritySelection',
1302             Mask => 0xc0,
1303             PrintConv => {
1304             0 => 'Release',
1305             1 => 'Release + Focus',
1306             2 => 'Focus',
1307             },
1308             },
1309             1.2 => { # CSa2
1310             Name => 'AF-SPrioritySelection',
1311             Mask => 0x20,
1312             PrintConv => {
1313             0 => 'Focus',
1314             1 => 'Release',
1315             },
1316             },
1317             1.3 => { # CSa8
1318             Name => 'AFPointSelection',
1319             Mask => 0x10,
1320             PrintConv => {
1321             0 => '51 Points',
1322             1 => '11 Points',
1323             },
1324             },
1325             1.4 => { # CSa3
1326             Name => 'DynamicAFArea',
1327             Mask => 0x0c,
1328             PrintConv => {
1329             0 => '9 Points',
1330             1 => '21 Points',
1331             2 => '51 Points',
1332             3 => '51 Points (3D-tracking)',
1333             },
1334             },
1335             1.5 => { # CSa4
1336             Name => 'FocusTrackingLockOn',
1337             Condition => '$$self{Model} !~ /D3S\b/',
1338             Notes => 'not D3S',
1339             Mask => 0x03,
1340             PrintConv => {
1341             0 => 'Long',
1342             1 => 'Normal',
1343             2 => 'Short',
1344             3 => 'Off',
1345             },
1346             },
1347             2.1 => { # CSa5
1348             Name => 'AFActivation',
1349             Mask => 0x80,
1350             PrintConv => {
1351             0 => 'Shutter/AF-On',
1352             1 => 'AF-On Only',
1353             },
1354             },
1355             2.2 => { # CSa7
1356             Name => 'FocusPointWrap',
1357             Mask => 0x08,
1358             PrintConv => {
1359             0 => 'No Wrap',
1360             1 => 'Wrap',
1361             },
1362             },
1363             2.3 => [ # CSa6
1364             {
1365             Name => 'AFPointIllumination',
1366             Condition => '$$self{Model} =~ /D3[SX]?\b/',
1367             Notes => 'D3',
1368             Mask => 0x60,
1369             PrintConv => {
1370             0 => 'On in Continuous Shooting and Manual Focusing',
1371             1 => 'On During Manual Focusing',
1372             2 => 'On in Continuous Shooting Modes',
1373             3 => 'Off',
1374             },
1375             },
1376             {
1377             Name => 'AFPointIllumination',
1378             Notes => 'D300',
1379             Mask => 0x06,
1380             PrintConv => {
1381             0 => 'Auto',
1382             1 => 'Off',
1383             2 => 'On',
1384             },
1385             },
1386             ],
1387             2.4 => { # CSa6-b (D3, added by firmware update)
1388             Name => 'AFPointBrightness',
1389             Condition => '$$self{Model} =~ /D3[SX]?\b/',
1390             Notes => 'D3 only',
1391             Mask => 0x06,
1392             PrintConv => {
1393             0 => 'Low',
1394             1 => 'Normal',
1395             2 => 'High',
1396             3 => 'Extra High',
1397             },
1398             },
1399             2.5 => { # CSa9 (D300)
1400             Name => 'AFAssist',
1401             Condition => '$$self{Model} =~ /D300S?\b/',
1402             Notes => 'D300 only',
1403             Mask => 0x01,
1404             PrintConv => \%onOff,
1405             },
1406             3.1 => { # CSa9 (D3)
1407             Name => 'AFOnButton',
1408             Condition => '$$self{Model} =~ /D3[SX]?\b/',
1409             Notes => 'D3 only',
1410             Mask => 0x07,
1411             PrintConv => {
1412             0 => 'AF On',
1413             1 => 'AE/AF Lock',
1414             2 => 'AE Lock Only',
1415             3 => 'AE Lock (reset on release)',
1416             4 => 'AE Lock (hold)',
1417             5 => 'AF Lock Only',
1418             },
1419             },
1420             3.2 => { # CSa10 (D3)
1421             Name => 'VerticalAFOnButton',
1422             Condition => '$$self{Model} =~ /D3[SX]?\b/',
1423             Notes => 'D3 only',
1424             Mask => 0x70,
1425             PrintConv => {
1426             0 => 'AF On',
1427             1 => 'AE/AF Lock',
1428             2 => 'AE Lock Only',
1429             3 => 'AE Lock (reset on release)',
1430             4 => 'AE Lock (hold)',
1431             5 => 'AF Lock Only',
1432             7 => 'Same as AF On',
1433             },
1434             },
1435             3.3 => { # CSa10 (D300)
1436             Name => 'AF-OnForMB-D10',
1437             Condition => '$$self{Model} =~ /D300S?\b/',
1438             Notes => 'D300 only',
1439             Mask => 0x70,
1440             PrintConv => {
1441             0 => 'AF-On',
1442             1 => 'AE/AF Lock',
1443             2 => 'AE Lock Only',
1444             3 => 'AE Lock (reset on release)',
1445             4 => 'AE Lock (hold)',
1446             5 => 'AF Lock Only',
1447             6 => 'Same as FUNC Button',
1448             },
1449             },
1450             4.1 => { # CSa4 (D3S)
1451             Name => 'FocusTrackingLockOn',
1452             Condition => '$$self{Model} =~ /D3S\b/',
1453             Notes => 'D3S only',
1454             Mask => 0x07,
1455             PrintConv => {
1456             0 => '5 (Long)',
1457             1 => '4',
1458             2 => '3 (Normal)',
1459             3 => '2',
1460             4 => '1 (Short)',
1461             5 => 'Off',
1462             },
1463             },
1464             4.2 => { # CSf7 (D3S)
1465             Name => 'AssignBktButton',
1466             Condition => '$$self{Model} =~ /D3S\b/',
1467             Notes => 'D3S only',
1468             Mask => 0x08,
1469             PrintConv => {
1470             0 => 'Auto Bracketing',
1471             1 => 'Multiple Exposure',
1472             },
1473             },
1474             4.3 => { # CSf1-c (D3S) (ref 1)
1475             Name => 'MultiSelectorLiveView',
1476             Condition => '$$self{Model} =~ /D3S\b/',
1477             Notes => 'D3S only',
1478             Mask => 0xc0,
1479             PrintConv => {
1480             0 => 'Reset',
1481             1 => 'Zoom On/Off',
1482             2 => 'Start Movie Recording',
1483             3 => 'Not Used',
1484             },
1485             },
1486             4.4 => { # CSf1-c2 (D3S) (ref 1)
1487             Name => 'InitialZoomLiveView',
1488             Condition => '$$self{Model} =~ /D3S\b/',
1489             Notes => 'D3S only',
1490             Mask => 0x30,
1491             PrintConv => {
1492             0 => 'Low Magnification',
1493             1 => 'Medium Magnification',
1494             2 => 'High Magnification',
1495             },
1496             },
1497             6.1 => { # CSb1
1498             Name => 'ISOStepSize',
1499             Mask => 0xc0,
1500             PrintConv => {
1501             0 => '1/3 EV',
1502             1 => '1/2 EV',
1503             2 => '1 EV',
1504             },
1505             },
1506             6.2 => { # CSb2
1507             Name => 'ExposureControlStepSize',
1508             Mask => 0x30,
1509             PrintConv => {
1510             0 => '1/3 EV',
1511             1 => '1/2 EV',
1512             2 => '1 EV',
1513             },
1514             },
1515             6.3 => { # CSb3
1516             Name => 'ExposureCompStepSize',
1517             Mask => 0x0c,
1518             PrintConv => {
1519             0 => '1/3 EV',
1520             1 => '1/2 EV',
1521             2 => '1 EV',
1522             },
1523             },
1524             6.4 => { # CSb4
1525             Name => 'EasyExposureCompensation',
1526             Mask => 0x03,
1527             PrintConv => {
1528             0 => 'Off',
1529             1 => 'On',
1530             2 => 'On (auto reset)',
1531             },
1532             },
1533             7.1 => [ # CSb5
1534             {
1535             Name => 'CenterWeightedAreaSize',
1536             Condition => '$$self{Model} =~ /D3[SX]?\b/',
1537             Notes => 'D3',
1538             Mask => 0xe0,
1539             PrintConv => {
1540             0 => '8 mm',
1541             1 => '12 mm',
1542             2 => '15 mm',
1543             3 => '20 mm',
1544             4 => 'Average',
1545             },
1546             },
1547             {
1548             Name => 'CenterWeightedAreaSize',
1549             Notes => 'D300',
1550             Mask => 0xe0,
1551             PrintConv => {
1552             0 => '6 mm',
1553             1 => '8 mm',
1554             2 => '10 mm',
1555             3 => '13 mm',
1556             4 => 'Average',
1557             },
1558             },
1559             ],
1560             7.2 => { # CSb6-b
1561             Name => 'FineTuneOptCenterWeighted',
1562             Mask => 0x0f,
1563             ValueConv => '($val > 0x7 ? $val - 0x10 : $val) / 6',
1564             ValueConvInv => 'int($val*6+($val>0?0.5:-0.5))',
1565             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
1566             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
1567             },
1568             8.1 => { # CSb6-a
1569             Name => 'FineTuneOptMatrixMetering',
1570             Mask => 0xf0,
1571             ValueConv => '($val > 0x7 ? $val - 0x10 : $val) / 6',
1572             ValueConvInv => 'int($val*6+($val>0?0.5:-0.5))',
1573             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
1574             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
1575             },
1576             8.2 => { # CSb6-c
1577             Name => 'FineTuneOptSpotMetering',
1578             Mask => 0x0f,
1579             ValueConv => '($val > 0x7 ? $val - 0x10 : $val) / 6',
1580             ValueConvInv => 'int($val*6+($val>0?0.5:-0.5))',
1581             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
1582             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
1583             },
1584             9.1 => { # CSf1-a, CSf2-a (D300S)
1585             Name => 'MultiSelectorShootMode',
1586             Mask => 0xc0,
1587             PrintConv => {
1588             0 => 'Select Center Focus Point',
1589             1 => 'Highlight Active Focus Point',
1590             2 => 'Not Used',
1591             },
1592             },
1593             9.2 => { # CSf1-b, CSf2-b (D300S)
1594             Name => 'MultiSelectorPlaybackMode',
1595             Condition => '$$self{Model} !~ /D3S\b/',
1596             Notes => 'all models except D3S', # (not confirmed for D3X)
1597             Mask => 0x30,
1598             PrintConv => {
1599             0 => 'Thumbnail On/Off',
1600             1 => 'View Histograms',
1601             2 => 'Zoom On/Off',
1602             3 => 'Choose Folder',
1603             },
1604             },
1605             9.3 => [ # CSf1-b2, CSf2-b2 (D300S)
1606             {
1607             Name => 'InitialZoomSetting',
1608             Condition => '$$self{Model} =~ /D3[SX]?\b/',
1609             Notes => 'D3',
1610             Mask => 0x0c,
1611             PrintConv => { #1
1612             0 => 'High Magnification',
1613             1 => 'Medium Magnification',
1614             2 => 'Low Magnification',
1615             },
1616             },
1617             {
1618             Name => 'InitialZoomSetting',
1619             Notes => 'D300',
1620             Mask => 0x0c,
1621             PrintConv => { #JD
1622             0 => 'Low Magnification',
1623             1 => 'Medium Magnification',
1624             2 => 'High Magnification',
1625             },
1626             },
1627             ],
1628             9.4 => { # CSf2 (D300,D3), CSf3 (D300S)
1629             Name => 'MultiSelector',
1630             Mask => 0x01,
1631             PrintConv => {
1632             0 => 'Do Nothing',
1633             1 => 'Reset Meter-off Delay',
1634             },
1635             },
1636             10.1 => { # CSd9 (D300,D3S), CSd10 (D300S), CSd8 (D3)
1637             Name => 'ExposureDelayMode',
1638             Mask => 0x40,
1639             PrintConv => \%offOn,
1640             },
1641             10.2 => { # CSd4 (D300), CDs5 (D300S), CSd2-a (D3)
1642             Name => 'CLModeShootingSpeed',
1643             Mask => 0x07,
1644             PrintConv => '"$val fps"',
1645             PrintConvInv => '$val=~s/\s*fps//i; $val',
1646             },
1647             10.3 => { # (D3 CSd2-b)
1648             Name => 'CHModeShootingSpeed',
1649             Condition => '$$self{Model} =~ /D3[SX]?\b/',
1650             Notes => 'D3 only',
1651             Mask => 0x30,
1652             PrintConv => {
1653             0 => '9 fps',
1654             1 => '10 fps',
1655             2 => '11 fps',
1656             },
1657             },
1658             11 => { # CSd5 (D300), CSd6 (D300S), CSd3 (D3)
1659             Name => 'MaxContinuousRelease',
1660             # values: 1-100 (D300), 1-130 (D3)
1661             },
1662             12.1 => { # CSf10, CSf11 (D3S,D300S)
1663             Name => 'ReverseIndicators',
1664             Mask => 0x20,
1665             PrintConv => {
1666             0 => '+ 0 -',
1667             1 => '- 0 +',
1668             },
1669             },
1670             12.2 => [ # CSd6 (D300), CSd7 (D300S), CSd4 (D3)
1671             {
1672             Name => 'FileNumberSequence',
1673             Condition => '$$self{Model} =~ /D3[SX]?\b/',
1674             Notes => 'D3',
1675             Mask => 0x02,
1676             PrintConv => \%onOff,
1677             },
1678             {
1679             Name => 'FileNumberSequence',
1680             Notes => 'D300',
1681             Mask => 0x08,
1682             PrintConv => \%onOff,
1683             },
1684             ],
1685             12.3 => { # CSd5-a (D3)
1686             Name => 'RearDisplay',
1687             Condition => '$$self{Model} =~ /D3[SX]?\b/',
1688             Notes => 'D3 only',
1689             Mask => 0x80,
1690             PrintConv => {
1691             0 => 'ISO',
1692             1 => 'Exposures Remaining',
1693             },
1694             },
1695             12.4 => { # CSd5-b (D3)
1696             Name => 'ViewfinderDisplay',
1697             Condition => '$$self{Model} =~ /D3[SX]?\b/',
1698             Notes => 'D3 only',
1699             Mask => 0x40,
1700             PrintConv => {
1701             0 => 'Frame Count',
1702             1 => 'Exposures Remaining',
1703             },
1704             },
1705             12.5 => { # CSd11 (D300), CSd12 (D300S)
1706             Name => 'BatteryOrder',
1707             Condition => '$$self{Model} =~ /D300S?\b/',
1708             Notes => 'D300 only',
1709             Mask => 0x04,
1710             PrintConv => {
1711             0 => 'MB-D10 First',
1712             1 => 'Camera Battery First',
1713             },
1714             },
1715             12.6 => { # CSd10 (D300), CSd11 (D300S)
1716             Name => 'MB-D10Batteries',
1717             Condition => '$$self{Model} =~ /D300S?\b/',
1718             Notes => 'D300 only',
1719             Mask => 0x03,
1720             PrintConv => {
1721             0 => 'LR6 (AA alkaline)',
1722             1 => 'HR6 (AA Ni-MH)',
1723             2 => 'FR6 (AA lithium)',
1724             3 => 'ZR6 (AA Ni-Mn)',
1725             },
1726             },
1727             12.7 => { # CSd7 (D3S), CSd4, (D300S)
1728             Name => 'ScreenTips',
1729             Condition => '$$self{Model} =~ /(D3S|D300S)\b/',
1730             Mask => 0x10,
1731             PrintConv => \%onOff,
1732             },
1733             13.1 => { # CSd1
1734             Name => 'Beep',
1735             Mask => 0xc0,
1736             PrintConv => {
1737             0 => 'High',
1738             1 => 'Low',
1739             2 => 'Off',
1740             },
1741             },
1742             13.2 => { # CSd7 (D300), CSd8 (D300S), CSd6 (D3)
1743             Name => 'ShootingInfoDisplay',
1744             Mask => 0x30,
1745             PrintConv => {
1746             0 => 'Auto', #JD (D300)
1747             1 => 'Auto', #1 (D3)
1748             2 => 'Manual (dark on light)',
1749             3 => 'Manual (light on dark)',
1750             },
1751             },
1752             13.3 => { # CSd2 (D300)
1753             Name => 'GridDisplay',
1754             Condition => '$$self{Model} =~ /D300S?\b/',
1755             Notes => 'D300 only',
1756             Mask => 0x02,
1757             PrintConv => \%offOn,
1758             },
1759             13.4 => { # CSd3 (D300)
1760             Name => 'ViewfinderWarning',
1761             Condition => '$$self{Model} =~ /D300S?\b/',
1762             Notes => 'D300 only',
1763             Mask => 0x01,
1764             PrintConv => \%onOff,
1765             },
1766             13.5 => { # CSf1-b (D3S) (ref 1)
1767             Name => 'MultiSelectorPlaybackMode',
1768             Condition => '$$self{Model} =~ /D3S\b/',
1769             Notes => 'D3S only',
1770             Mask => 0x03,
1771             PrintConv => {
1772             0 => 'Thumbnail On/Off',
1773             1 => 'View Histograms',
1774             2 => 'Zoom On/Off',
1775             },
1776             },
1777             14.1 => [ # CSf5-a (ref 1), CSf6-a (D300S)
1778             {
1779             Name => 'PreviewButton',
1780             Condition => '$$self{Model} =~ /D3[SX]?\b/',
1781             Notes => 'D3',
1782             Mask => 0xf8,
1783             PrintConv => {
1784             0 => 'None',
1785             1 => 'Preview',
1786             2 => 'FV Lock',
1787             3 => 'AE/AF Lock',
1788             4 => 'AE Lock Only',
1789             5 => 'AE Lock (reset on release)',
1790             6 => 'AE Lock (hold)',
1791             7 => 'AF Lock Only',
1792             8 => 'Flash Off',
1793             9 => 'Bracketing Burst',
1794             10 => 'Matrix Metering',
1795             11 => 'Center-weighted Metering',
1796             12 => 'Spot Metering',
1797             13 => 'Virtual Horizon',
1798             # 14 not used
1799             15 => 'Playback',
1800             16 => 'My Menu Top',
1801             },
1802             },
1803             { #PH
1804             Name => 'FuncButton',
1805             Notes => 'D300',
1806             Mask => 0xf8,
1807             PrintConv => {
1808             0 => 'None',
1809             1 => 'Preview',
1810             2 => 'FV Lock',
1811             3 => 'AE/AF Lock',
1812             4 => 'AE Lock Only',
1813             5 => 'AE Lock (reset on release)',
1814             6 => 'AE Lock (hold)',
1815             7 => 'AF Lock Only',
1816             # 8 not used
1817             9 => 'Flash Off',
1818             10 => 'Bracketing Burst',
1819             11 => 'Matrix Metering',
1820             12 => 'Center-weighted Metering',
1821             13 => 'Spot Metering',
1822             14 => 'Playback', #PH (guess)
1823             15 => 'My Menu Top', #PH (guess)
1824             16 => '+ NEF (RAW)', #PH (guess)
1825             },
1826             },
1827             ],
1828             14.2 => [ # CSf5-b (PH,NC), CSf6-b (D300S)
1829             {
1830             Name => 'PreviewButtonPlusDials',
1831             Condition => '$$self{Model} =~ /D3[SX]?\b/',
1832             Notes => 'D3',
1833             Mask => 0x07,
1834             PrintConv => {
1835             0 => 'None',
1836             1 => 'Choose Image Area (FX/DX/5:4)',
1837             2 => 'One Step Speed/Aperture',
1838             3 => 'Choose Non-CPU Lens Number',
1839             # n/a 4 => 'Focus Point Selection',
1840             5 => 'Choose Image Area (FX/DX)',
1841             6 => 'Shooting Bank Menu',
1842             7 => 'Dynamic AF Area', #PH (D3S,D3X,NC)
1843             },
1844             },
1845             { #PH
1846             Name => 'FuncButtonPlusDials',
1847             Notes => 'D300',
1848             Mask => 0x07,
1849             PrintConv => {
1850             0 => 'None',
1851             2 => 'One Step Speed/Aperture',
1852             3 => 'Choose Non-CPU Lens Number',
1853             5 => 'Auto Bracketing',
1854             6 => 'Dynamic AF Area',
1855             },
1856             },
1857             ],
1858             15.1 => [ # CSf4-a (ref 1), CSf5-a (D300S)
1859             {
1860             Name => 'FuncButton',
1861             Condition => '$$self{Model} =~ /D3[SX]?\b/',
1862             Notes => 'D3',
1863             Mask => 0xf8,
1864             PrintConv => {
1865             0 => 'None',
1866             1 => 'Preview',
1867             2 => 'FV Lock',
1868             3 => 'AE/AF Lock',
1869             4 => 'AE Lock Only',
1870             5 => 'AE Lock (reset on release)',
1871             6 => 'AE Lock (hold)',
1872             7 => 'AF Lock Only',
1873             8 => 'Flash Off',
1874             9 => 'Bracketing Burst',
1875             10 => 'Matrix Metering',
1876             11 => 'Center-weighted Metering',
1877             12 => 'Spot Metering',
1878             13 => 'Virtual Horizon',
1879             # 14 not used
1880             15 => 'Playback',
1881             16 => 'My Menu Top',
1882             },
1883             },
1884             { #PH
1885             Name => 'PreviewButton',
1886             Notes => 'D300',
1887             Mask => 0xf8,
1888             PrintConv => {
1889             0 => 'None',
1890             1 => 'Preview',
1891             2 => 'FV Lock',
1892             3 => 'AE/AF Lock',
1893             4 => 'AE Lock Only',
1894             5 => 'AE Lock (reset on release)',
1895             6 => 'AE Lock (hold)',
1896             7 => 'AF Lock Only',
1897             # 8 not used
1898             9 => 'Flash Off',
1899             10 => 'Bracketing Burst',
1900             11 => 'Matrix Metering',
1901             12 => 'Center-weighted Metering',
1902             13 => 'Spot Metering',
1903             14 => 'Playback', #PH (guess)
1904             15 => 'My Menu Top', #PH (guess)
1905             16 => '+ NEF (RAW)', #PH (guess)
1906             },
1907             },
1908             ],
1909             15.2 => [ # CSf4-b (ref 1), CSf5-b (D300S)
1910             {
1911             Name => 'FuncButtonPlusDials',
1912             Condition => '$$self{Model} =~ /D3[SX]?\b/',
1913             Notes => 'D3',
1914             Mask => 0x07,
1915             PrintConv => {
1916             0 => 'None',
1917             1 => 'Choose Image Area (FX/DX/5:4)',
1918             2 => 'One Step Speed/Aperture',
1919             3 => 'Choose Non-CPU Lens Number',
1920             4 => 'Focus Point Selection', #(NC)
1921             5 => 'Choose Image Area (FX/DX)',
1922             6 => 'Shooting Bank Menu',
1923             7 => 'Dynamic AF Area', #PH (D3S,D3X,NC)
1924             },
1925             },
1926             { #PH
1927             Name => 'PreviewButtonPlusDials',
1928             Notes => 'D300',
1929             Mask => 0x07,
1930             PrintConv => {
1931             0 => 'None',
1932             2 => 'One Step Speed/Aperture',
1933             3 => 'Choose Non-CPU Lens Number',
1934             5 => 'Auto Bracketing',
1935             6 => 'Dynamic AF Area',
1936             },
1937             },
1938             ],
1939             16.1 => [ # CSf6-a (ref 1), CSf7-a (D300S)
1940             {
1941             Name => 'AELockButton',
1942             Condition => '$$self{Model} =~ /D3[SX]?\b/',
1943             Notes => 'D3',
1944             Mask => 0xf8,
1945             PrintConv => {
1946             0 => 'None',
1947             1 => 'Preview',
1948             2 => 'FV Lock',
1949             3 => 'AE/AF Lock',
1950             4 => 'AE Lock Only',
1951             5 => 'AE Lock (reset on release)',
1952             6 => 'AE Lock (hold)',
1953             7 => 'AF Lock Only',
1954             8 => 'Flash Off',
1955             9 => 'Bracketing Burst',
1956             10 => 'Matrix Metering',
1957             11 => 'Center-weighted Metering',
1958             12 => 'Spot Metering',
1959             13 => 'Virtual Horizon',
1960             14 => 'AF On', # (AE-L/AF-L button only)
1961             15 => 'Playback',
1962             16 => 'My Menu Top',
1963             },
1964             },
1965             { #PH
1966             Name => 'AELockButton',
1967             Notes => 'D300',
1968             Mask => 0xf8,
1969             PrintConv => {
1970             0 => 'None',
1971             1 => 'Preview',
1972             2 => 'FV Lock',
1973             3 => 'AE/AF Lock',
1974             4 => 'AE Lock Only',
1975             5 => 'AE Lock (reset on release)',
1976             6 => 'AE Lock (hold)',
1977             7 => 'AF Lock Only',
1978             8 => 'AF On', # (AE-L/AF-L button only)
1979             9 => 'Flash Off',
1980             10 => 'Bracketing Burst',
1981             11 => 'Matrix Metering',
1982             12 => 'Center-weighted Metering',
1983             13 => 'Spot Metering',
1984             14 => 'Playback', #PH (guess)
1985             15 => 'My Menu Top', #PH (guess)
1986             16 => '+ NEF (RAW)', #PH (guess)
1987             },
1988             },
1989             ],
1990             16.2 => [ # CSf6-b (ref 1), CSf7-b (D300S)
1991             {
1992             Name => 'AELockButtonPlusDials',
1993             Condition => '$$self{Model} =~ /D3[SX]?\b/',
1994             Notes => 'D3',
1995             Mask => 0x07,
1996             PrintConv => {
1997             0 => 'None',
1998             1 => 'Choose Image Area (FX/DX/5:4)',
1999             2 => 'One Step Speed/Aperture',
2000             3 => 'Choose Non-CPU Lens Number',
2001             # n/c 4 => 'Focus Point Selection', #(NC)
2002             5 => 'Choose Image Area (FX/DX)',
2003             6 => 'Shooting Bank Menu',
2004             7 => 'Dynamic AF Area', #PH (D3S,D3X,NC)
2005             },
2006             },
2007             { #PH
2008             Name => 'AELockButtonPlusDials',
2009             Notes => 'D300',
2010             Mask => 0x07,
2011             PrintConv => {
2012             0 => 'None',
2013             # n/a 2 => 'One Step Speed/Aperture',
2014             3 => 'Choose Non-CPU Lens Number',
2015             5 => 'Auto Bracketing', #(NC)
2016             6 => 'Dynamic AF Area',
2017             },
2018             },
2019             ],
2020             17.1 => { # CSf7-a, CSf8-a (D3S,D300S)
2021             Name => 'CommandDialsReverseRotation',
2022             Mask => 0x80,
2023             PrintConv => \%noYes,
2024             },
2025             17.2 => { # CSf7-b, CSf8-b (D3S,D300S)
2026             Name => 'CommandDialsChangeMainSub',
2027             Mask => 0x40,
2028             PrintConv => \%offOn,
2029             },
2030             17.3 => { # CSf7-c, CSf8-c (D3S,D300S)
2031             Name => 'CommandDialsApertureSetting',
2032             Mask => 0x20,
2033             PrintConv => {
2034             0 => 'Sub-command Dial',
2035             1 => 'Aperture Ring',
2036             },
2037             },
2038             17.4 => { # CSf7-d, CSf8-d (D3S,D300S)
2039             Name => 'CommandDialsMenuAndPlayback',
2040             Mask => 0x10,
2041             PrintConv => \%offOn,
2042             },
2043             17.5 => { # CSd8 (D300,D3S), CSd9 (D300S), CSd7 (D3)
2044             Name => 'LCDIllumination',
2045             Mask => 0x08,
2046             PrintConv => \%offOn,
2047             },
2048             17.6 => { # CSf3, CSf4 (D300S)
2049             Name => 'PhotoInfoPlayback',
2050             Mask => 0x04,
2051             PrintConv => {
2052             0 => 'Info Up-down, Playback Left-right',
2053             1 => 'Info Left-right, Playback Up-down',
2054             },
2055             },
2056             17.7 => { # CSc1
2057             Name => 'ShutterReleaseButtonAE-L',
2058             Mask => 0x02,
2059             PrintConv => \%offOn,
2060             },
2061             17.8 => { # CSf8, CSf9 (D3S,D300S)
2062             Name => 'ReleaseButtonToUseDial',
2063             Mask => 0x01,
2064             PrintConv => \%noYes,
2065             },
2066             18.1 => { # CSc3
2067             Name => 'SelfTimerTime',
2068             Mask => 0x18,
2069             PrintConv => {
2070             0 => '2 s',
2071             1 => '5 s',
2072             2 => '10 s',
2073             3 => '20 s',
2074             },
2075             },
2076             18.2 => { # CSc4
2077             Name => 'MonitorOffTime',
2078             # NOTE: The D3S and D300S have separate settings for Playback,
2079             # Image Review, Menus, and Information Display times
2080             Mask => 0x07,
2081             PrintConv => {
2082             0 => '10 s',
2083             1 => '20 s',
2084             2 => '1 min',
2085             3 => '5 min',
2086             4 => '10 min',
2087             },
2088             },
2089             20.1 => [ # CSe1
2090             {
2091             Name => 'FlashSyncSpeed',
2092             Condition => '$$self{Model} =~ /D3[SX]?\b/',
2093             Notes => 'D3',
2094             Mask => 0xe0,
2095             PrintConv => {
2096             0 => '1/250 s (auto FP)',
2097             1 => '1/250 s',
2098             2 => '1/200 s',
2099             3 => '1/160 s',
2100             4 => '1/125 s',
2101             5 => '1/100 s',
2102             6 => '1/80 s',
2103             7 => '1/60 s',
2104             },
2105             },
2106             {
2107             Name => 'FlashSyncSpeed',
2108             Notes => 'D300',
2109             Mask => 0xf0,
2110             PrintConv => {
2111             0 => '1/320 s (auto FP)',
2112             1 => '1/250 s (auto FP)',
2113             2 => '1/250 s',
2114             3 => '1/200 s',
2115             4 => '1/160 s',
2116             5 => '1/125 s',
2117             6 => '1/100 s',
2118             7 => '1/80 s',
2119             8 => '1/60 s',
2120             },
2121             },
2122             ],
2123             20.2 => { # CSe2
2124             Name => 'FlashShutterSpeed',
2125             Mask => 0x0f,
2126             PrintConvColumns => 2,
2127             PrintConv => {
2128             0 => '1/60 s',
2129             1 => '1/30 s',
2130             2 => '1/15 s',
2131             3 => '1/8 s',
2132             4 => '1/4 s',
2133             5 => '1/2 s',
2134             6 => '1 s',
2135             7 => '2 s',
2136             8 => '4 s',
2137             9 => '8 s',
2138             10 => '15 s',
2139             11 => '30 s',
2140             },
2141             },
2142             21.1 => [{ # CSe5 (D300), CSe4 (D3)
2143             Name => 'AutoBracketSet',
2144             Condition => '$$self{Model} !~ /(D3S|D300S)\b/',
2145             Notes => 'D3 and D300',
2146             Mask => 0xc0,
2147             PrintConv => {
2148             0 => 'AE & Flash',
2149             1 => 'AE Only',
2150             2 => 'Flash Only',
2151             3 => 'WB Bracketing',
2152             },
2153             },{ # CSe4 (D3S) (NC for D300S)
2154             Name => 'AutoBracketSet',
2155             Notes => 'D3S and D300S',
2156             Mask => 0xe0,
2157             PrintConv => {
2158             0 => 'AE & Flash',
2159             1 => 'AE Only',
2160             2 => 'Flash Only',
2161             3 => 'WB Bracketing',
2162             # D3S/D300S have an "ADL Bracketing" setting - PH
2163             4 => 'ADL Bracketing',
2164             },
2165             }],
2166             21.2 => [{ # CSe6 (D300), CSe5 (D3)
2167             Name => 'AutoBracketModeM',
2168             Condition => '$$self{Model} !~ /(D3S|D300S)\b/',
2169             Notes => 'D3 and D300',
2170             Mask => 0x30,
2171             PrintConv => {
2172             0 => 'Flash/Speed',
2173             1 => 'Flash/Speed/Aperture',
2174             2 => 'Flash/Aperture',
2175             3 => 'Flash Only',
2176             },
2177             },{ # CSe5 (D3S)
2178             Name => 'AutoBracketModeM',
2179             Notes => 'D3S and D300S',
2180             Mask => 0x18,
2181             PrintConv => {
2182             0 => 'Flash/Speed',
2183             1 => 'Flash/Speed/Aperture',
2184             2 => 'Flash/Aperture',
2185             3 => 'Flash Only',
2186             },
2187             }],
2188             21.3 => [{ # CSe7 (D300), CSe6 (D3)
2189             Name => 'AutoBracketOrder',
2190             Condition => '$$self{Model} !~ /(D3S|D300S)\b/',
2191             Notes => 'D3 and D300',
2192             Mask => 0x08,
2193             PrintConv => {
2194             0 => '0,-,+',
2195             1 => '-,0,+',
2196             },
2197             },{ # CSe6 (D3S)
2198             Name => 'AutoBracketOrder',
2199             Notes => 'D3S and D300S',
2200             Mask => 0x04,
2201             PrintConv => {
2202             0 => '0,-,+',
2203             1 => '-,0,+',
2204             },
2205             }],
2206             21.4 => { # CSe4 (D300), CSe3 (D3)
2207             Name => 'ModelingFlash',
2208             Mask => 0x01,
2209             PrintConv => \%onOff,
2210             },
2211             22.1 => { # CSf9, CSf10 (D3S,D300S)
2212             Name => 'NoMemoryCard',
2213             Mask => 0x80,
2214             PrintConv => {
2215             0 => 'Release Locked',
2216             1 => 'Enable Release',
2217             },
2218             },
2219             22.2 => { # CSc2
2220             Name => 'MeteringTime',
2221             Mask => 0x0f,
2222             PrintConvColumns => 2,
2223             PrintConv => {
2224             0 => '4 s',
2225             1 => '6 s',
2226             2 => '8 s',
2227             3 => '16 s',
2228             4 => '30 s',
2229             5 => '1 min',
2230             6 => '5 min',
2231             7 => '10 min',
2232             8 => '30 min',
2233             9 => 'No Limit',
2234             },
2235             },
2236             23.1 => { # CSe3
2237             Name => 'InternalFlash',
2238             Mask => 0xc0,
2239             PrintConv => {
2240             0 => 'TTL',
2241             1 => 'Manual',
2242             2 => 'Repeating Flash',
2243             3 => 'Commander Mode',
2244             },
2245             },
2246             25.1 => { #1 CSc4-d (D3S)
2247             Name => 'ImageReviewTime',
2248             Mask => 0xe0,
2249             PrintConv => {
2250             0 => '4 s',
2251             1 => '10 s',
2252             2 => '20 s',
2253             3 => '1 min',
2254             4 => '5 min',
2255             5 => '10 min',
2256             },
2257             },
2258             25.2 => { #1 CSc4-a (D3S)
2259             Name => 'PlaybackMonitorOffTime',
2260             Mask => 0x1c,
2261             PrintConv => {
2262             0 => '4 s',
2263             1 => '10 s',
2264             2 => '20 s',
2265             3 => '1 min',
2266             4 => '5 min',
2267             5 => '10 min',
2268             },
2269             },
2270             26.1 => { #1 CSc4-b (D3S)
2271             Name => 'MenuMonitorOffTime',
2272             Mask => 0xe0,
2273             PrintConv => {
2274             0 => '4 s',
2275             1 => '10 s',
2276             2 => '20 s',
2277             3 => '1 min',
2278             4 => '5 min',
2279             5 => '10 min',
2280             },
2281             },
2282             26.2 => { #1 CSc4-c (D3S)
2283             Name => 'ShootingInfoMonitorOffTime',
2284             Mask => 0x1c,
2285             PrintConv => {
2286             0 => '4 s',
2287             1 => '10 s',
2288             2 => '20 s',
2289             3 => '1 min',
2290             4 => '5 min',
2291             5 => '10 min',
2292             },
2293             },
2294             );
2295              
2296             # D700 custom settings (ref 2)
2297             %Image::ExifTool::NikonCustom::SettingsD700 = (
2298             PROCESS_PROC => \&Image::ExifTool::ProcessBinaryData,
2299             WRITE_PROC => \&Image::ExifTool::WriteBinaryData,
2300             CHECK_PROC => \&Image::ExifTool::CheckBinaryData,
2301             WRITABLE => 1,
2302             FIRST_ENTRY => 0,
2303             DATAMEMBER => [ 16.1 ],
2304             GROUPS => { 0 => 'MakerNotes', 2 => 'Camera' },
2305             NOTES => 'Custom settings for the D700.',
2306             0.1 => { #1
2307             Name => 'CustomSettingsBank',
2308             Mask => 0x03,
2309             PrintConv => {
2310             0 => 'A',
2311             1 => 'B',
2312             2 => 'C',
2313             3 => 'D',
2314             },
2315             },
2316             0.2 => { #1
2317             Name => 'CustomSettingsAllDefault',
2318             Notes => '"No" if any custom setting for this bank was changed from the default',
2319             Mask => 0x80,
2320             PrintConv => { 0 => 'Yes', 1 => 'No' },
2321             },
2322             1.1 => { # CSa1
2323             Name => 'AF-CPrioritySelection',
2324             Mask => 0xc0,
2325             PrintConv => {
2326             0 => 'Release',
2327             1 => 'Release + Focus',
2328             2 => 'Focus',
2329             },
2330             },
2331             1.2 => { # CSa2
2332             Name => 'AF-SPrioritySelection',
2333             Mask => 0x20,
2334             PrintConv => {
2335             0 => 'Focus',
2336             1 => 'Release',
2337             },
2338             },
2339             1.3 => { # CSa8
2340             Name => 'AFPointSelection',
2341             Mask => 0x10,
2342             PrintConv => {
2343             0 => '51 Points',
2344             1 => '11 Points',
2345             },
2346             },
2347             1.4 => { # CSa3
2348             Name => 'DynamicAFArea',
2349             Mask => 0x0c,
2350             PrintConv => {
2351             0 => '9 Points',
2352             1 => '21 Points',
2353             2 => '51 Points',
2354             3 => '51 Points (3D-tracking)',
2355             },
2356             },
2357             2.1 => { # CSa5
2358             Name => 'AFActivation',
2359             Mask => 0x80,
2360             PrintConv => {
2361             0 => 'Shutter/AF-On',
2362             1 => 'AF-On Only',
2363             },
2364             },
2365             2.2 => { # CSa7
2366             Name => 'FocusPointWrap',
2367             Mask => 0x08,
2368             PrintConv => {
2369             0 => 'No Wrap',
2370             1 => 'Wrap',
2371             },
2372             },
2373             2.3 => { # CSa6
2374             Name => 'AFPointIllumination',
2375             Mask => 0x06,
2376             PrintConv => {
2377             0 => 'Auto',
2378             1 => 'Off',
2379             2 => 'On',
2380             },
2381             },
2382             2.4 => { # CSa9
2383             Name => 'AFAssist',
2384             Mask => 0x01,
2385             PrintConv => \%onOff,
2386             },
2387             3.1 => { # CSa4
2388             Name => 'FocusTrackingLockOn',
2389             Mask => 0x07,
2390             PrintConv => {
2391             0 => '3 Normal',
2392             1 => '4',
2393             2 => '5 Long',
2394             3 => '2',
2395             4 => '1 Short',
2396             5 => 'Off',
2397             },
2398             },
2399             3.2 => { # CSa10
2400             Name => 'AF-OnForMB-D10',
2401             Mask => 0x70,
2402             PrintConv => {
2403             0 => 'AF-On',
2404             1 => 'AE/AF Lock',
2405             2 => 'AE Lock Only',
2406             3 => 'AE Lock (reset on release)',
2407             4 => 'AE Lock (hold)',
2408             5 => 'AF Lock Only',
2409             6 => 'Same as FUNC Button',
2410             },
2411             },
2412             4.1 => { # CSb1
2413             Name => 'ISOStepSize',
2414             Mask => 0xc0,
2415             PrintConv => {
2416             0 => '1/3 EV',
2417             1 => '1/2 EV',
2418             2 => '1 EV',
2419             },
2420             },
2421             4.2 => { # CSb2
2422             Name => 'ExposureControlStepSize',
2423             Mask => 0x30,
2424             PrintConv => {
2425             0 => '1/3 EV',
2426             1 => '1/2 EV',
2427             2 => '1 EV',
2428             },
2429             },
2430             4.3 => { # CSb3
2431             Name => 'ExposureCompStepSize',
2432             Mask => 0x0c,
2433             PrintConv => {
2434             0 => '1/3 EV',
2435             1 => '1/2 EV',
2436             2 => '1 EV',
2437             },
2438             },
2439             4.4 => { # CSb4
2440             Name => 'EasyExposureCompensation',
2441             Mask => 0x03,
2442             PrintConv => {
2443             0 => 'Off',
2444             1 => 'On',
2445             2 => 'On (auto reset)',
2446             },
2447             },
2448             5.1 => { # CSb5
2449             Name => 'CenterWeightedAreaSize',
2450             Mask => 0x70,
2451             PrintConv => {
2452             0 => '8 mm',
2453             1 => '12 mm',
2454             2 => '15 mm',
2455             3 => '20 mm',
2456             4 => 'Average',
2457             },
2458             },
2459             6.1 => { # CSb6-a
2460             Name => 'FineTuneOptMatrixMetering',
2461             Mask => 0xf0,
2462             ValueConv => '($val > 0x7 ? $val - 0x10 : $val) / 6',
2463             ValueConvInv => 'int($val*6+($val>0?0.5:-0.5))',
2464             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
2465             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
2466             },
2467             6.2 => { # CSb6-c
2468             Name => 'FineTuneOptSpotMetering',
2469             Mask => 0x0f,
2470             ValueConv => '($val > 0x7 ? $val - 0x10 : $val) / 6',
2471             ValueConvInv => 'int($val*6+($val>0?0.5:-0.5))',
2472             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
2473             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
2474             },
2475             7.1 => { # CSc1
2476             Name => 'ShutterReleaseButtonAE-L',
2477             Mask => 0x80,
2478             PrintConv => \%offOn,
2479             },
2480             7.2 => { # CSc3
2481             Name => 'SelfTimerTime',
2482             Mask => 0x30,
2483             PrintConv => {
2484             0 => '2 s',
2485             1 => '5 s',
2486             2 => '10 s',
2487             3 => '20 s',
2488             },
2489             },
2490             7.3 => { # CSc2
2491             Name => 'MeteringTime',
2492             Mask => 0x0f,
2493             PrintConvColumns => 2,
2494             PrintConv => {
2495             0 => '4 s',
2496             1 => '6 s',
2497             2 => '8 s',
2498             3 => '16 s',
2499             4 => '30 s',
2500             5 => '1 min',
2501             6 => '5 min',
2502             7 => '10 min',
2503             8 => '30 min',
2504             9 => 'No Limit',
2505             },
2506             },
2507             8.1 => { # CSc4-a
2508             Name => 'PlaybackMonitorOffTime',
2509             Mask => 0x38,
2510             PrintConv => {
2511             0 => '4 s',
2512             1 => '10 s',
2513             2 => '20 s',
2514             3 => '1 min',
2515             4 => '5 min',
2516             5 => '10 min',
2517             },
2518             },
2519             8.2 => { # CSc4-b
2520             Name => 'MenuMonitorOffTime',
2521             Mask => 0x07,
2522             PrintConv => {
2523             0 => '4 s',
2524             1 => '10 s',
2525             2 => '20 s',
2526             3 => '1 min',
2527             4 => '5 min',
2528             5 => '10 min',
2529             },
2530             },
2531             9.1 => { # CSc4-c
2532             Name => 'ShootingInfoMonitorOffTime',
2533             Mask => 0x38,
2534             PrintConv => {
2535             0 => '4 s',
2536             1 => '10 s',
2537             2 => '20 s',
2538             3 => '1 min',
2539             4 => '5 min',
2540             5 => '10 min',
2541             },
2542             },
2543             9.2 => { # CSc4-d
2544             Name => 'ImageReviewTime',
2545             Mask => 0x07,
2546             PrintConv => {
2547             0 => '4 s',
2548             1 => '10 s',
2549             2 => '20 s',
2550             3 => '1 min',
2551             4 => '5 min',
2552             5 => '10 min',
2553             },
2554             },
2555             10.1 => { # CSd1
2556             Name => 'Beep',
2557             Mask => 0xc0,
2558             PrintConv => {
2559             0 => 'High',
2560             1 => 'Low',
2561             2 => 'Off',
2562             },
2563             },
2564             10.2 => { # CSd7
2565             Name => 'ShootingInfoDisplay',
2566             Mask => 0x30,
2567             PrintConv => {
2568             0 => 'Auto', #JD (D300)
2569             1 => 'Auto', #1 (D3)
2570             2 => 'Manual (dark on light)',
2571             3 => 'Manual (light on dark)',
2572             },
2573             },
2574             10.3 => { # CSd8
2575             Name => 'LCDIllumination',
2576             Mask => 0x08,
2577             PrintConv => \%offOn,
2578             },
2579             10.4 => { # CSd9
2580             Name => 'ExposureDelayMode',
2581             Mask => 0x04,
2582             PrintConv => \%offOn,
2583             },
2584             10.5 => { # CSd2
2585             Name => 'GridDisplay',
2586             Mask => 0x02,
2587             PrintConv => \%offOn,
2588             },
2589             11.1 => { # CSd6
2590             Name => 'FileNumberSequence',
2591             Mask => 0x40,
2592             PrintConv => \%onOff,
2593             },
2594             11.2 => { # CSd4
2595             Name => 'CLModeShootingSpeed',
2596             Mask => 0x07,
2597             PrintConv => '"$val fps"',
2598             PrintConvInv => '$val=~s/\s*fps//i; $val',
2599             },
2600             12 => { # CSd5
2601             Name => 'MaxContinuousRelease',
2602             # values: 1-100
2603             },
2604             13.1 => { # CSd3
2605             Name => 'ScreenTips',
2606             Mask => 0x08,
2607             PrintConv => \%onOff,
2608             },
2609             13.2 => { # CSd11
2610             Name => 'BatteryOrder',
2611             Mask => 0x04,
2612             PrintConv => {
2613             0 => 'MB-D10 First',
2614             1 => 'Camera Battery First',
2615             },
2616             },
2617             13.3 => { # CSd10
2618             Name => 'MB-D10BatteryType',
2619             Mask => 0x03,
2620             PrintConv => {
2621             0 => 'LR6 (AA alkaline)',
2622             1 => 'HR6 (AA Ni-MH)',
2623             2 => 'FR6 (AA lithium)',
2624             3 => 'ZR6 (AA Ni-Mn)',
2625             },
2626             },
2627             15.1 => { # CSe1
2628             Name => 'FlashSyncSpeed',
2629             Mask => 0xf0,
2630             PrintConv => {
2631             0 => '1/320 s (auto FP)',
2632             1 => '1/250 s (auto FP)',
2633             2 => '1/250 s',
2634             3 => '1/200 s',
2635             4 => '1/160 s',
2636             5 => '1/125 s',
2637             6 => '1/100 s',
2638             7 => '1/80 s',
2639             8 => '1/60 s',
2640             },
2641             },
2642             15.2 => { # CSe2
2643             Name => 'FlashShutterSpeed',
2644             Mask => 0x0f,
2645             PrintConvColumns => 2,
2646             PrintConv => {
2647             0 => '1/60 s',
2648             1 => '1/30 s',
2649             2 => '1/15 s',
2650             3 => '1/8 s',
2651             4 => '1/4 s',
2652             5 => '1/2 s',
2653             6 => '1 s',
2654             7 => '2 s',
2655             8 => '4 s',
2656             9 => '8 s',
2657             10 => '15 s',
2658             11 => '30 s',
2659             },
2660             },
2661             16.1 => { # CSe3
2662             Name => 'FlashControlBuilt-in',
2663             # Note If set the Manual, Repeating Flash, Commander Mode
2664             # does not decode the detail settings.
2665             Mask => 0xc0,
2666             RawConv => '$$self{FlashControlBuiltin} = $val',
2667             PrintConv => {
2668             0 => 'TTL',
2669             1 => 'Manual',
2670             2 => 'Repeating Flash',
2671             3 => 'Commander Mode',
2672             },
2673             },
2674             16.2 => { # CSe3-b
2675             Name => 'ManualFlashOutput',
2676             Condition => '$$self{FlashControlBuiltin} == 1',
2677             Mask => 0x1f,
2678             ValueConv => '2 ** (-$val/3)',
2679             ValueConvInv => '$val > 0 ? -3*log($val)/log(2) : 0',
2680             PrintConv => q{
2681             return 'Full' if $val > 0.99;
2682             Image::ExifTool::Exif::PrintExposureTime($val);
2683             },
2684             PrintConvInv => '$val=~/F/i ? 1 : Image::ExifTool::Exif::ConvertFraction($val)',
2685             },
2686             17.1 => { # CSe3-ca
2687             Name => 'RepeatingFlashOutput',
2688             Condition => '$$self{FlashControlBuiltin} == 2',
2689             Mask => 0x70,
2690             ValueConv => '2 ** (-$val-2)',
2691             ValueConvInv => '$val > 0 ? int(-log($val)/log(2)-2+0.5) : 0',
2692             PrintConv => 'Image::ExifTool::Exif::PrintExposureTime($val)',
2693             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
2694             },
2695             17.2 => { # CSe3-cb
2696             Name => 'RepeatingFlashCount',
2697             Condition => '$$self{FlashControlBuiltin} == 2',
2698             Mask => 0x0f,
2699             ValueConv => '$val < 10 ? $val + 1 : 5 * ($val - 7)',
2700             ValueConvInv => '$val <= 10 ? $val - 1 : $val / 5 + 7',
2701             },
2702             18.1 => { # CSe3-cc (NC)
2703             Name => 'RepeatingFlashRate',
2704             Condition => '$$self{FlashControlBuiltin} == 2',
2705             Mask => 0xf0,
2706             ValueConv => '$val < 10 ? $val + 1 : 10 * ($val - 8)',
2707             ValueConvInv => 'int(($val <= 10 ? $val - 1 : $val / 10 + 8) + 0.5)',
2708             PrintConv => '"$val Hz"',
2709             PrintConvInv => '$val=~/(\d+)/; $1 || 0',
2710             },
2711             18.2 => { # CSe3-dd
2712             Name => 'CommanderInternalTTLChannel',
2713             Condition => '$$self{FlashControlBuiltin} == 3',
2714             Mask => 0x03,
2715             PrintConv => {
2716             0 => '1 ch',
2717             1 => '2 ch',
2718             2 => '3 ch',
2719             3 => '4 ch',
2720             },
2721             },
2722             20.1 => { # CSe3-da
2723             Name => 'CommanderInternalTTLCompBuiltin',
2724             Condition => '$$self{FlashControlBuiltin} == 3',
2725             Mask => 0x1f,
2726             ValueConv => '($val - 9) / 3',
2727             ValueConvInv => '$val * 3 + 9',
2728             PrintConv => '$val ? sprintf("%+.1f",$val) : 0',
2729             PrintConvInv => '$val',
2730             },
2731             21.1 => { # CSe3-db
2732             Name => 'CommanderInternalTTLCompGroupA',
2733             Condition => '$$self{FlashControlBuiltin} == 3',
2734             Mask => 0x1f,
2735             ValueConv => '($val - 9) / 3',
2736             ValueConvInv => '$val * 3 + 9',
2737             PrintConv => '$val ? sprintf("%+.1f",$val) : 0',
2738             PrintConvInv => '$val',
2739             },
2740             22.1 => { # CSe3-dc
2741             Name => 'CommanderInternalTTLCompGroupB',
2742             Condition => '$$self{FlashControlBuiltin} == 3',
2743             Mask => 0x1f,
2744             ValueConv => '($val - 9) / 3',
2745             ValueConvInv => '$val * 3 + 9',
2746             PrintConv => '$val ? sprintf("%+.1f",$val) : 0',
2747             PrintConvInv => '$val',
2748             },
2749             26.1 => { # CSe5
2750             Name => 'AutoBracketSet',
2751             Mask => 0xc0,
2752             PrintConv => {
2753             0 => 'AE & Flash',
2754             1 => 'AE Only',
2755             2 => 'Flash Only',
2756             3 => 'WB Bracketing',
2757             },
2758             },
2759             26.2 => { # CSe6
2760             Name => 'AutoBracketModeM',
2761             Mask => 0x30,
2762             PrintConv => {
2763             0 => 'Flash/Speed',
2764             1 => 'Flash/Speed/Aperture',
2765             2 => 'Flash/Aperture',
2766             3 => 'Flash Only',
2767             },
2768             },
2769             26.3 => { # CSe7
2770             Name => 'AutoBracketOrder',
2771             Mask => 0x08,
2772             PrintConv => {
2773             0 => '0,-,+',
2774             1 => '-,0,+',
2775             },
2776             },
2777             26.4 => { # CSe4
2778             Name => 'ModelingFlash',
2779             Mask => 0x01,
2780             PrintConv => \%onOff,
2781             },
2782             27.1 => { # CSf2-a
2783             Name => 'MultiSelectorShootMode',
2784             Mask => 0xc0,
2785             PrintConv => {
2786             0 => 'Select Center Focus Point',
2787             1 => 'Highlight Active Focus Point',
2788             2 => 'Not Used',
2789             },
2790             },
2791             27.2 => { # CSf2-b
2792             Name => 'MultiSelectorPlaybackMode',
2793             Mask => 0x30,
2794             PrintConv => {
2795             0 => 'Thumbnail On/Off',
2796             1 => 'View Histograms',
2797             2 => 'Zoom On/Off',
2798             3 => 'Choose Folder',
2799             },
2800             },
2801             27.3 => { # CSf2-b2
2802             Name => 'InitialZoomSetting',
2803             Mask => 0x0c,
2804             PrintConv => { #1
2805             0 => 'Low Magnification',
2806             1 => 'Medium Magnification',
2807             2 => 'High Magnification',
2808             },
2809             },
2810             27.4 => { # CSf3
2811             Name => 'MultiSelector',
2812             Mask => 0x01,
2813             PrintConv => {
2814             0 => 'Do Nothing',
2815             1 => 'Reset Meter-off Delay',
2816             },
2817             },
2818             28.1 => { # CSf5-a
2819             Name => 'FuncButton',
2820             Mask => 0xf8,
2821             PrintConv => {
2822             0 => 'None',
2823             1 => 'Preview',
2824             2 => 'FV Lock',
2825             3 => 'AE/AF Lock',
2826             4 => 'AE Lock Only',
2827             5 => 'AE Lock (reset on release)',
2828             6 => 'AE Lock (hold)',
2829             7 => 'AF Lock Only',
2830             # 8 not used
2831             9 => 'Flash Off',
2832             10 => 'Bracketing Burst',
2833             11 => 'Matrix Metering',
2834             12 => 'Center-weighted Metering',
2835             13 => 'Spot Metering',
2836             14 => 'My Menu Top',
2837             15 => 'Live View',
2838             16 => '+ NEF (RAW)',
2839             17 => 'Virtual Horizon',
2840             },
2841             },
2842             29.1 => { # CSf6-a
2843             Name => 'PreviewButton',
2844             Mask => 0xf8,
2845             PrintConv => {
2846             0 => 'None',
2847             1 => 'Preview',
2848             2 => 'FV Lock',
2849             3 => 'AE/AF Lock',
2850             4 => 'AE Lock Only',
2851             5 => 'AE Lock (reset on release)',
2852             6 => 'AE Lock (hold)',
2853             7 => 'AF Lock Only',
2854             8 => 'AF-ON',
2855             9 => 'Flash Off',
2856             10 => 'Bracketing Burst',
2857             11 => 'Matrix Metering',
2858             12 => 'Center-weighted Metering',
2859             13 => 'Spot Metering',
2860             14 => 'My Menu Top',
2861             15 => 'Live View',
2862             16 => '+ NEF (RAW)',
2863             17 => 'Virtual Horizon',
2864             },
2865             },
2866             30.1 => { # CSf7-a
2867             Name => 'AELockButton',
2868             Notes => 'D300',
2869             Mask => 0xf8,
2870             PrintConv => {
2871             0 => 'None',
2872             1 => 'Preview',
2873             2 => 'FV Lock',
2874             3 => 'AE/AF Lock',
2875             4 => 'AE Lock Only',
2876             5 => 'AE Lock (reset on release)',
2877             6 => 'AE Lock (hold)',
2878             7 => 'AF Lock Only',
2879             8 => 'AF-ON',
2880             9 => 'Flash Off',
2881             10 => 'Bracketing Burst',
2882             11 => 'Matrix Metering',
2883             12 => 'Center-weighted Metering',
2884             13 => 'Spot Metering',
2885             14 => 'My Menu Top',
2886             15 => 'Live View',
2887             16 => '+ NEF (RAW)',
2888             17 => 'Virtual Horizon',
2889             },
2890             },
2891             31.1 => { # CSf5-b
2892             Name => 'FuncButtonPlusDials',
2893             Mask => 0x70,
2894             PrintConv => {
2895             0 => 'None',
2896             1 => 'Choose Image Area',
2897             2 => 'One Step Speed/Aperture',
2898             3 => 'Choose Non-CPU Lens Number',
2899             # n/a 4 => 'Focus Point Selection',
2900             5 => 'Auto bracketing',
2901             6 => 'Dynamic AF Area',
2902             7 => 'Shutter speed & Aperture lock',
2903             },
2904             },
2905             31.2 => { # CSf6-b
2906             Name => 'PreviewButtonPlusDials',
2907             Mask => 0x07,
2908             PrintConv => {
2909             0 => 'None',
2910             1 => 'Choose Image Area',
2911             2 => 'One Step Speed/Aperture',
2912             3 => 'Choose Non-CPU Lens Number',
2913             # n/a 4 => 'Focus Point Selection',
2914             5 => 'Auto bracketing',
2915             6 => 'Dynamic AF Area',
2916             7 => 'Shutter speed & Aperture lock',
2917             },
2918             },
2919             32.1 => { # CSf7-b
2920             Name => 'AELockButtonPlusDials',
2921             Mask => 0x70,
2922             Prinonv => {
2923             0 => 'None',
2924             1 => 'Choose Image Area',
2925             2 => 'One Step Speed/Aperture',
2926             3 => 'Choose Non-CPU Lens Number',
2927             # n/a 4 => 'Focus Point Selection',
2928             5 => 'Auto bracketing',
2929             6 => 'Dynamic AF Area',
2930             7 => 'Shutter speed & Aperture lock',
2931             },
2932             },
2933             33.1 => { # CSf9-a
2934             Name => 'CommandDialsReverseRotation',
2935             Mask => 0x80,
2936             PrintConv => \%noYes,
2937             },
2938             33.2 => { # CSf9-b
2939             Name => 'CommandDialsChangeMainSub',
2940             Mask => 0x40,
2941             PrintConv => \%offOn,
2942             },
2943             33.3 => { # CSf9-c
2944             Name => 'CommandDialsApertureSetting',
2945             Mask => 0x20,
2946             PrintConv => {
2947             0 => 'Sub-command Dial',
2948             1 => 'Aperture Ring',
2949             },
2950             },
2951             33.4 => { # CSf9-d
2952             Name => 'CommandDialsMenuAndPlayback',
2953             Mask => 0x10,
2954             PrintConv => \%offOn,
2955             },
2956             33.5 => { # CSf12
2957             Name => 'ReverseIndicators',
2958             Mask => 0x08,
2959             PrintConv => {
2960             0 => '+ 0 -',
2961             1 => '- 0 +',
2962             },
2963             },
2964             33.6 => { # CSf4
2965             Name => 'PhotoInfoPlayback',
2966             Mask => 0x04,
2967             PrintConv => \%offOn,
2968             },
2969             33.7 => { # CSf11
2970             Name => 'NoMemoryCard',
2971             Mask => 0x02,
2972             PrintConv => {
2973             0 => 'Release Locked',
2974             1 => 'Enable Release',
2975             },
2976             },
2977             33.8 => { # CSf10
2978             Name => 'ReleaseButtonToUseDial',
2979             Mask => 0x01,
2980             PrintConv => \%noYes,
2981             },
2982             );
2983              
2984             # D800 custom settings (ref PH)
2985             %Image::ExifTool::NikonCustom::SettingsD800 = (
2986             PROCESS_PROC => \&Image::ExifTool::ProcessBinaryData,
2987             WRITE_PROC => \&Image::ExifTool::WriteBinaryData,
2988             CHECK_PROC => \&Image::ExifTool::CheckBinaryData,
2989             WRITABLE => 1,
2990             FIRST_ENTRY => 0,
2991             DATAMEMBER => [ 23.1 ],
2992             GROUPS => { 0 => 'MakerNotes', 2 => 'Camera' },
2993             NOTES => 'Custom settings for the D800 and D800E.',
2994             12.1 => { # CSe5
2995             Name => 'AutoBracketingSet',
2996             Mask => 0xe0, #(NC)
2997             PrintConv => {
2998             0 => 'AE & Flash', # default
2999             1 => 'AE Only', #(NC)
3000             2 => 'Flash Only',
3001             3 => 'WB Bracketing', #(NC)
3002             4 => 'Active D-Lighting', #(NC)
3003             },
3004             },
3005             12.2 => { # CSe7
3006             Name => 'AutoBracketOrder',
3007             Mask => 0x10,
3008             PrintConv => {
3009             0 => '0,-,+',
3010             1 => '-,0,+',
3011             },
3012             },
3013             12.3 => { # CSe6
3014             Name => 'AutoBracketingMode',
3015             Mask => 0x0c,
3016             PrintConv => {
3017             0 => 'Flash/Speed',
3018             1 => 'Flash/Speed/Aperture',
3019             2 => 'Flash/Aperture',
3020             3 => 'Flash Only',
3021             },
3022             },
3023             # 21 - 100 (MaxContinuousRelease?)
3024             22.1 => { # CSe1
3025             Name => 'FlashSyncSpeed',
3026             Mask => 0xf0,
3027             PrintConv => {
3028             0 => '1/320 s (auto FP)',
3029             1 => '1/250 s (auto FP)',
3030             2 => '1/250 s',
3031             3 => '1/200 s',
3032             4 => '1/160 s',
3033             5 => '1/125 s',
3034             6 => '1/100 s',
3035             7 => '1/80 s',
3036             8 => '1/60 s',
3037             },
3038             },
3039             22.2 => { # CSe2
3040             Name => 'FlashShutterSpeed',
3041             Mask => 0x0f,
3042             PrintConvColumns => 2,
3043             PrintConv => {
3044             0 => '1/60 s',
3045             1 => '1/30 s',
3046             2 => '1/15 s',
3047             3 => '1/8 s',
3048             4 => '1/4 s',
3049             5 => '1/2 s',
3050             6 => '1 s',
3051             7 => '2 s',
3052             8 => '4 s',
3053             9 => '8 s',
3054             10 => '15 s',
3055             11 => '30 s',
3056             },
3057             },
3058             23.1 => { # CSe3
3059             Name => 'FlashControlBuilt-in',
3060             Mask => 0xc0,
3061             RawConv => '$$self{FlashControlBuiltin} = $val',
3062             PrintConv => {
3063             0 => 'TTL',
3064             1 => 'Manual',
3065             2 => 'Repeating Flash',
3066             3 => 'Commander Mode',
3067             },
3068             },
3069             23.2 => { # CSe3-b
3070             Name => 'ManualFlashOutput',
3071             Condition => '$$self{FlashControlBuiltin} == 1',
3072             Mask => 0x1f,
3073             ValueConv => '2 ** (-$val/3)',
3074             ValueConvInv => '$val > 0 ? -3*log($val)/log(2) : 0',
3075             PrintConv => q{
3076             return 'Full' if $val > 0.99;
3077             Image::ExifTool::Exif::PrintExposureTime($val);
3078             },
3079             PrintConvInv => '$val=~/F/i ? 1 : Image::ExifTool::Exif::ConvertFraction($val)',
3080             },
3081             24.1 => { # CSe3-ca
3082             Name => 'RepeatingFlashOutput',
3083             Condition => '$$self{FlashControlBuiltin} == 2',
3084             Mask => 0x70,
3085             ValueConv => '2 ** (-$val-2)',
3086             ValueConvInv => '$val > 0 ? int(-log($val)/log(2)-2+0.5) : 0',
3087             PrintConv => 'Image::ExifTool::Exif::PrintExposureTime($val)',
3088             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
3089             },
3090             24.2 => { # CSe3-cb
3091             Name => 'RepeatingFlashCount',
3092             Condition => '$$self{FlashControlBuiltin} == 2',
3093             Mask => 0x0f,
3094             ValueConv => '$val < 10 ? $val + 1 : 5 * ($val - 7)',
3095             ValueConvInv => '$val <= 10 ? $val - 1 : $val / 5 + 7',
3096             },
3097             25.1 => { # CSe3-cc
3098             Name => 'RepeatingFlashRate',
3099             Condition => '$$self{FlashControlBuiltin} == 2',
3100             Mask => 0xf0,
3101             ValueConv => '$val < 10 ? $val + 1 : 10 * ($val - 8)',
3102             ValueConvInv => 'int(($val <= 10 ? $val - 1 : $val / 10 + 8) + 0.5)',
3103             PrintConv => '"$val Hz"',
3104             PrintConvInv => '$val=~/(\d+)/; $1 || 0',
3105             },
3106             25.2 => { # CSe3
3107             Name => 'CommanderChannel',
3108             Mask => 0x03,
3109             ValueConv => '$val + 1',
3110             ValueConvInv => '$val - 1',
3111             },
3112             27.1 => { # CSe3
3113             Name => 'CommanderInternalFlash',
3114             Mask => 0xc0,
3115             PrintConv => {
3116             0 => 'TTL',
3117             1 => 'Manual',
3118             2 => 'Off',
3119             },
3120             },
3121             27.2 => { # CSe3
3122             Name => 'CommanderInternalManualOutput',
3123             Mask => 0x1f,
3124             ValueConv => '2 ** (-$val/3)',
3125             ValueConvInv => '$val > 0 ? int(-log($val)/log(2) * 3 + 0.5): 0',
3126             PrintConv => q{
3127             return 'Full' if $val > 0.99;
3128             Image::ExifTool::Exif::PrintExposureTime($val);
3129             },
3130             PrintConvInv => '$val=~/F/i ? 1 : Image::ExifTool::Exif::ConvertFraction($val)',
3131             },
3132             28.1 => { # CSe3
3133             Name => 'CommanderGroupAMode',
3134             Mask => 0xc0,
3135             PrintConv => {
3136             0 => 'TTL',
3137             1 => 'Auto Aperture',
3138             2 => 'Manual',
3139             3 => 'Off',
3140             },
3141             },
3142             28.2 => { # CSe3
3143             Name => 'CommanderGroupAManualOutput',
3144             Mask => 0x1f,
3145             ValueConv => '2 ** (-$val/3)',
3146             ValueConvInv => '$val > 0 ? int(-log($val)/log(2) * 3 + 0.5): 0',
3147             PrintConv => q{
3148             return 'Full' if $val > 0.99;
3149             Image::ExifTool::Exif::PrintExposureTime($val);
3150             },
3151             PrintConvInv => '$val=~/F/i ? 1 : Image::ExifTool::Exif::ConvertFraction($val)',
3152             },
3153             29.1 => { # CSe3
3154             Name => 'CommanderGroupBMode',
3155             Mask => 0xc0,
3156             PrintConv => {
3157             0 => 'TTL',
3158             1 => 'Auto Aperture',
3159             2 => 'Manual',
3160             3 => 'Off',
3161             },
3162             },
3163             29.2 => { # CSe3
3164             Name => 'CommanderGroupBManualOutput',
3165             Mask => 0x1f,
3166             ValueConv => '2 ** (-$val/3)',
3167             ValueConvInv => '$val > 0 ? int(-log($val)/log(2) * 3 + 0.5): 0',
3168             PrintConv => q{
3169             return 'Full' if $val > 0.99;
3170             Image::ExifTool::Exif::PrintExposureTime($val);
3171             },
3172             PrintConvInv => '$val=~/F/i ? 1 : Image::ExifTool::Exif::ConvertFraction($val)',
3173             },
3174             30.1 => { # CSe4
3175             Name => 'ModelingFlash',
3176             Mask => 0x20,
3177             PrintConv => \%onOff,
3178             },
3179             30.2 => { # CSe3
3180             Name => 'CommanderInternalTTLComp',
3181             Mask => 0x1f,
3182             ValueConv => '($val - 9) / 3',
3183             ValueConvInv => '$val * 3 + 9',
3184             PrintConv => '$val ? sprintf("%+.1f",$val) : 0',
3185             PrintConvInv => '$val',
3186             },
3187             31.1 => { # CSe3
3188             Name => 'CommanderGroupA_TTL-AAComp',
3189             Mask => 0x1f,
3190             ValueConv => '($val - 9) / 3',
3191             ValueConvInv => '$val * 3 + 9',
3192             PrintConv => '$val ? sprintf("%+.1f",$val) : 0',
3193             PrintConvInv => '$val',
3194             },
3195             32.1 => { # CSe3
3196             Name => 'CommanderGroupB_TTL-AAComp',
3197             Mask => 0x1f,
3198             ValueConv => '($val - 9) / 3',
3199             ValueConvInv => '$val * 3 + 9',
3200             PrintConv => '$val ? sprintf("%+.1f",$val) : 0',
3201             PrintConvInv => '$val',
3202             },
3203             # 47 - related to flash
3204             );
3205              
3206             # D5 custom settings (ref 1)
3207             %Image::ExifTool::NikonCustom::SettingsD5 = (
3208             PROCESS_PROC => \&Image::ExifTool::ProcessBinaryData,
3209             WRITE_PROC => \&Image::ExifTool::WriteBinaryData,
3210             CHECK_PROC => \&Image::ExifTool::CheckBinaryData,
3211             WRITABLE => 1,
3212             FIRST_ENTRY => 0,
3213             GROUPS => { 0 => 'MakerNotes', 2 => 'Camera' },
3214             NOTES => 'Custom settings for the D5.',
3215             0.1 => {
3216             Name => 'CustomSettingsBank',
3217             Mask => 0x03,
3218             PrintConv => {
3219             0 => 'A',
3220             1 => 'B',
3221             2 => 'C',
3222             3 => 'D',
3223             },
3224             },
3225             1.1 => { # CSa1
3226             Name => 'AF-CPrioritySelection',
3227             Mask => 0xc0,
3228             PrintConv => {
3229             0 => 'Release',
3230             1 => 'Release + Focus',
3231             2 => 'Focus',
3232             3 => 'Focus + Release',
3233             },
3234             },
3235             1.2 => { # CSa2
3236             Name => 'AF-SPrioritySelection',
3237             Mask => 0x20,
3238             PrintConv => {
3239             0 => 'Focus',
3240             1 => 'Release',
3241             },
3242             },
3243             1.3 => { # CSa6
3244             Name => 'NumberOfFocusPoints',
3245             Mask => 0x10,
3246             PrintConv => {
3247             0 => '55 Points',
3248             1 => '15 Points',
3249             },
3250             },
3251             1.4 => { # CSa4
3252             Name => 'Three-DTrackingFaceDetection',
3253             Mask => 0x08,
3254             PrintConv => {
3255             0 => 'Off',
3256             1 => 'On',
3257             },
3258             },
3259             1.5 => { # CSa3-a
3260             Name => 'BlockShotAFResponse',
3261             Mask => 0x07,
3262             #values 1-5
3263             },
3264             2.1 => { # CSa11
3265             Name => 'FocusPointWrap',
3266             Mask => 0x08,
3267             PrintConv => {
3268             0 => 'No Wrap',
3269             1 => 'Wrap',
3270             },
3271             },
3272             2.2 => { # CSa12-d
3273             Name => 'AFPointBrightness',
3274             Mask => 0x06,
3275             PrintConv => {
3276             0 => 'Auto',
3277             1 => 'On',
3278             2 => 'Off',
3279             },
3280             },
3281             4.1 => { # CSd3
3282             Name => 'ISODisplay',
3283             Mask => 0x08,
3284             PrintConv => {
3285             0 => 'Show ISO Sensitivity',
3286             1 => 'Show Frame Count',
3287             },
3288             },
3289             4.2 => { # CSd8
3290             Name => 'GridDisplay',
3291             Mask => 0x02,
3292             PrintConv => \%onOff,
3293             },
3294             5.1 => { # CSd9
3295             Name => 'LCDIllumination',
3296             Mask => 0x20,
3297             PrintConv => \%offOn,
3298             },
3299             5.2 => { # CSd6
3300             Name => 'ElectronicFront-CurtainShutter',
3301             Mask => 0x08,
3302             PrintConv => \%offOn,
3303             },
3304             6.1 => { # CSf7
3305             Name => 'ReverseIndicators',
3306             Mask => 0x80,
3307             PrintConv => {
3308             0 => '+ 0 -',
3309             1 => '- 0 +',
3310             },
3311             },
3312             6.2 => { # CSf4-a
3313             Name => 'CommandDialsReverseRotation',
3314             Mask => 0x18,
3315             PrintConv => {
3316             0 => 'No',
3317             1 => 'Shutter Speed & Aperture',
3318             2 => 'Exposure Compensation',
3319             3 => 'Exposure Compensation, Shutter Speed & Aperture',
3320             },
3321             },
3322             6.3 => { # CSb4
3323             Name => 'EasyExposureCompensation',
3324             Mask => 0x03,
3325             PrintConv => {
3326             0 => 'Off',
3327             1 => 'On',
3328             2 => 'On (auto reset)',
3329             },
3330             },
3331             7.1 => { # CSb2
3332             Name => 'ExposureControlStepSize',
3333             Mask => 0xc0,
3334             PrintConv => {
3335             0 => '1/3 EV',
3336             1 => '1/2 EV',
3337             2 => '1 EV',
3338             },
3339             },
3340             7.2 => { # CSb1
3341             Name => 'ISOStepSize',
3342             Mask => 0x30,
3343             PrintConv => {
3344             0 => '1/3 EV',
3345             1 => '1/2 EV',
3346             2 => '1 EV',
3347             },
3348             },
3349             7.3 => { # CSb3
3350             Name => 'ExposureCompStepSize',
3351             Mask => 0x0c,
3352             PrintConv => {
3353             0 => '1/3 EV',
3354             1 => '1/2 EV',
3355             2 => '1 EV',
3356             },
3357             },
3358             8.1 => { # CSb6
3359             Name => 'CenterWeightedAreaSize',
3360             Mask => 0xe0,
3361             PrintConv => {
3362             0 => '8 mm',
3363             1 => '12 mm',
3364             2 => '15 mm',
3365             3 => '20 mm',
3366             4 => 'Average',
3367             },
3368             },
3369             8.2 => { # CSb7-a
3370             Name => 'FineTuneOptMatrixMetering',
3371             Mask => 0x0f,
3372             ValueConv => '($val > 0x7 ? $val - 0x10 : $val) / 6',
3373             ValueConvInv => 'int($val*6+($val>0?0.5:-0.5))',
3374             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
3375             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
3376             },
3377             9.1 => { # CSb7-b
3378             Name => 'FineTuneOptCenterWeighted',
3379             Mask => 0xf0,
3380             ValueConv => '($val > 0x7 ? $val - 0x10 : $val) / 6',
3381             ValueConvInv => 'int($val*6+($val>0?0.5:-0.5))',
3382             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
3383             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
3384             },
3385             9.2 => { # CSb7-c
3386             Name => 'FineTuneOptSpotMetering',
3387             Mask => 0x0f,
3388             ValueConv => '($val > 0x7 ? $val - 0x10 : $val) / 6',
3389             ValueConvInv => 'int($val*6+($val>0?0.5:-0.5))',
3390             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
3391             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
3392             },
3393             10.1 => { # CSf2-a
3394             Name => 'MultiSelectorShootMode',
3395             Mask => 0xe0,
3396             PrintConv => {
3397             0 => 'Select Center Focus Point (Reset)',
3398             1 => 'Zoom On/Off', # this is the documented (and actual) default value, but the choice does not appear on the camera menu
3399             2 => 'Preset Focus Point (Pre)',
3400             4 => 'Not Used (None)',
3401             },
3402             },
3403             # 10.2 => { # CSf2-b # moved from the D500 position to Nikon_ShotInfoD5_0x0ab1 with the Mask and PrintConv as specified below. Further research required.
3404             # Name => 'MultiSelectorPlaybackMode',
3405             # Mask => 0x70,
3406             # PrintConv => {
3407             # 0 => 'Zoom On/Off',
3408             # 1 => 'Choose Folder',
3409             # 6 => 'Thumbnail On/Off',
3410             # 7 => 'View Histograms',
3411             # },
3412             # },
3413             10.3 => { # CSf5
3414             Name => 'MultiSelector',
3415             Mask => 0x01,
3416             PrintConv => {
3417             0 => 'Do Nothing',
3418             1 => 'Reset Meter-off Delay',
3419             },
3420             },
3421             11.1 => { # CSd5
3422             Name => 'ExposureDelayMode',
3423             Mask => 0xc0,
3424             PrintConv => {
3425             0 => 'Off',
3426             1 => '1 s',
3427             2 => '2 s',
3428             3 => '3 s',
3429             },
3430             },
3431             11.2 => { # CSd1
3432             Name => 'CLModeShootingSpeed',
3433             Mask => 0x0f,
3434             PrintConv => '"$val fps"',
3435             PrintConvInv => '$val=~s/\s*fps//i; $val',
3436             },
3437             12.1 => { # CSd2
3438             Name => 'MaxContinuousRelease',
3439             # values: 1-100
3440             },
3441             13.1 => { # CSe7
3442             Name => 'AutoBracketOrder',
3443             Mask => 0x10,
3444             PrintConv => {
3445             0 => '0,-,+',
3446             1 => '-,0,+',
3447             },
3448             },
3449             13.2 => { # CSe6
3450             Name => 'AutoBracketModeM',
3451             Mask => 0x0c,
3452             PrintConv => {
3453             0 => 'Flash/Speed',
3454             1 => 'Flash/Speed/Aperture',
3455             2 => 'Flash/Aperture',
3456             3 => 'Flash Only',
3457             },
3458             },
3459             14.1 => { # CSf1-c
3460             Name => 'Func1Button',
3461             Mask => 0x3f,
3462             PrintConv => {
3463             0 => 'None',
3464             1 => 'Preview',
3465             2 => 'FV Lock',
3466             3 => 'AE/AF Lock',
3467             4 => 'AE Lock Only',
3468             5 => 'AE Lock (reset on release)',
3469             6 => 'AE Lock (hold)',
3470             7 => 'AF Lock Only',
3471             8 => 'AF-On',
3472             10 => 'Bracketing Burst',
3473             11 => 'Matrix Metering',
3474             12 => 'Center-weighted Metering',
3475             13 => 'Spot Metering',
3476             14 => 'Playback',
3477             15 => 'My Menu Top Item',
3478             16 => '+NEF(RAW)',
3479             17 => 'Virtual Horizon',
3480             19 => 'Grid Display',
3481             20 => 'My Menu',
3482             21 => 'Disable Synchronized Release',
3483             22 => 'Remote Release Only',
3484             26 => 'Flash Disable/Enable',
3485             27 => 'Highlight-weighted Metering',
3486             36 => 'AF-Area Mode (Single)',
3487             37 => 'AF-Area Mode (Dynamic Area 25 Points)',
3488             38 => 'AF-Area Mode (Dynamic Area 72 Points)',
3489             39 => 'AF-Area Mode (Dynamic Area 152 Points)',
3490             40 => 'AF-Area Mode (Group Area AF)',
3491             41 => 'AF-Area Mode (Auto Area AF)',
3492             42 => 'AF-Area Mode + AF-On (Single)',
3493             43 => 'AF-Area Mode + AF-On (Dynamic Area 25 Points)',
3494             44 => 'AF-Area Mode + AF-On (Dynamic Area 72 Points)',
3495             45 => 'AF-Area Mode + AF-On (Dynamic Area 152 Points)',
3496             46 => 'AF-Area Mode + AF-On (Group Area AF)',
3497             47 => 'AF-Area Mode + AF-On (Auto Area AF)',
3498             49 => 'Sync Release (Master Only)',
3499             50 => 'Sync Release (Remote Only)',
3500             58 => 'AF-Area Mode + AF-On (Group Area AF - HL)',
3501             59 => 'AF-Area Mode + AF-On (Group Area AF - VL)',
3502             },
3503             },
3504             15.1 => { # CSf1-a
3505             Name => 'PreviewButton',
3506             Mask => 0x3f,
3507             PrintConv => {
3508             0 => 'None',
3509             1 => 'Preview',
3510             2 => 'FV Lock',
3511             3 => 'AE/AF Lock',
3512             4 => 'AE Lock Only',
3513             5 => 'AE Lock (reset on release)',
3514             6 => 'AE Lock (hold)',
3515             7 => 'AF Lock Only',
3516             8 => 'AF-On',
3517             10 => 'Bracketing Burst',
3518             11 => 'Matrix Metering',
3519             12 => 'Center-weighted Metering',
3520             13 => 'Spot Metering',
3521             14 => 'Playback',
3522             15 => 'My Menu Top Item',
3523             16 => '+NEF(RAW)',
3524             17 => 'Virtual Horizon',
3525             19 => 'Grid Display',
3526             20 => 'My Menu',
3527             21 => 'Disable Synchronized Release',
3528             22 => 'Remote Release Only',
3529             26 => 'Flash Disable/Enable',
3530             27 => 'Highlight-weighted Metering',
3531             36 => 'AF-Area Mode (Single)',
3532             37 => 'AF-Area Mode (Dynamic Area 25 Points)',
3533             38 => 'AF-Area Mode (Dynamic Area 72 Points)',
3534             39 => 'AF-Area Mode (Dynamic Area 152 Points)',
3535             40 => 'AF-Area Mode (Group Area AF)',
3536             41 => 'AF-Area Mode (Auto Area AF)',
3537             42 => 'AF-Area Mode + AF-On (Single)',
3538             43 => 'AF-Area Mode + AF-On (Dynamic Area 25 Points)',
3539             44 => 'AF-Area Mode + AF-On (Dynamic Area 72 Points)',
3540             45 => 'AF-Area Mode + AF-On (Dynamic Area 152 Points)',
3541             46 => 'AF-Area Mode + AF-On (Group Area AF)',
3542             47 => 'AF-Area Mode + AF-On (Auto Area AF)',
3543             49 => 'Sync Release (Master Only)',
3544             50 => 'Sync Release (Remote Only)',
3545             58 => 'AF-Area Mode + AF-On (Group Area AF - HL)',
3546             59 => 'AF-Area Mode + AF-On (Group Area AF - VL)',
3547             },
3548             },
3549             16.1 => { # CSf1-p
3550             Name => 'AssignBktButton',
3551             Mask => 0x07,
3552             PrintConv => {
3553             0 => 'Auto Bracketing',
3554             1 => 'Multiple Exposure',
3555             2 => 'HDR (high dynamic range)',
3556             3 => 'None',
3557             },
3558             },
3559             18.1 => { # CSf4-b
3560             Name => 'CommandDialsChangeMainSub',
3561             Mask => 0xe0,
3562             PrintConv => {
3563             0 => 'Autofocus Off, Exposure Off',
3564             1 => 'Autofocus Off, Exposure On',
3565             2 => 'Autofocus Off, Exposure On (Mode A)',
3566             4 => 'Autofocus On, Exposure Off',
3567             5 => 'Autofocus On, Exposure On',
3568             6 => 'Autofocus On, Exposure On (Mode A)',
3569             },
3570             },
3571             18.2 => { # CSf4-d
3572             Name => 'CommandDialsMenuAndPlayback',
3573             Mask => 0x18,
3574             PrintConv => {
3575             0 => 'On',
3576             1 => 'Off',
3577             2 => 'On (Image Review Excluded)',
3578             },
3579             },
3580             18.3 => { # CSf4-c
3581             Name => 'CommandDialsApertureSetting',
3582             Mask => 0x04,
3583             PrintConv => {
3584             0 => 'Sub-command Dial',
3585             1 => 'Aperture Ring',
3586             },
3587             },
3588             18.4 => { # CSf6
3589             Name => 'ReleaseButtonToUseDial',
3590             Mask => 0x01,
3591             PrintConv => \%noYes,
3592             },
3593             19.1 => { # CSc2
3594             Name => 'StandbyTimer',
3595             Mask => 0xf0,
3596             PrintConv => {
3597             0 => '4 s',
3598             1 => '6 s',
3599             3 => '10 s',
3600             5 => '30 s',
3601             6 => '1 min',
3602             7 => '5 min',
3603             8 => '10 min',
3604             9 => '30 min',
3605             10 => 'No Limit',
3606             },
3607             },
3608             20.1 => { # CSc3-a
3609             Name => 'SelfTimerTime',
3610             Mask => 0xc0,
3611             PrintConv => {
3612             0 => '2 s',
3613             1 => '5 s',
3614             2 => '10 s',
3615             3 => '20 s',
3616             },
3617             },
3618             20.2 => { # CSc3-c
3619             Name => 'SelfTimerShotInterval',
3620             Mask => 0x30,
3621             PrintConv => {
3622             0 => '0.5 s',
3623             1 => '1 s',
3624             2 => '2 s',
3625             3 => '3 s',
3626             },
3627             },
3628             20.3 => { # CSc3-b
3629             Name => 'SelfTimerShotCount',
3630             Mask => 0x0f,
3631             },
3632             21.1 => { # CSc4-d
3633             Name => 'ImageReviewMonitorOffTime',
3634             Mask => 0xe0,
3635             PrintConv => {
3636             0 => '2 s',
3637             1 => '4 s',
3638             3 => '10 s',
3639             4 => '20 s',
3640             5 => '1 min',
3641             6 => '5 min',
3642             7 => '10 min',
3643             },
3644             },
3645             21.2 => { # CSc4-e
3646             Name => 'LiveViewMonitorOffTime',
3647             Mask => 0x1c,
3648             PrintConv => {
3649             1 => '5 min',
3650             2 => '10 min',
3651             3 => '15 min',
3652             4 => '20 min',
3653             5 => '30 min',
3654             6 => 'No Limit',
3655             },
3656             },
3657             22.1 => { # CSc4-b
3658             Name => 'MenuMonitorOffTime',
3659             Mask => 0xe0,
3660             PrintConv => {
3661             0 => '4 s',
3662             2 => '10 s',
3663             4 => '20 s',
3664             5 => '1 min',
3665             6 => '5 min',
3666             7 => '10 min',
3667             },
3668             },
3669             22.2 => { # CSc4-c
3670             Name => 'ShootingInfoMonitorOffTime',
3671             Mask => 0x1c,
3672             PrintConv => {
3673             0 => '4 s',
3674             2 => '10 s',
3675             4 => '20 s',
3676             5 => '1 min',
3677             6 => '5 min',
3678             7 => '10 min',
3679             },
3680             },
3681             23.1 => { # CSe1
3682             Name => 'FlashSyncSpeed',
3683             Mask => 0xf0,
3684             PrintConv => {
3685             2 => '1/250 s (auto FP)',
3686             3 => '1/250 s',
3687             5 => '1/200 s',
3688             6 => '1/160 s',
3689             7 => '1/125 s',
3690             8 => '1/100 s',
3691             9 => '1/80 s',
3692             10 => '1/60 s',
3693             },
3694             },
3695             23.2 => { # CSe2
3696             Name => 'FlashShutterSpeed',
3697             Mask => 0x0f,
3698             PrintConvColumns => 2,
3699             PrintConv => {
3700             0 => '1/60 s',
3701             1 => '1/30 s',
3702             2 => '1/15 s',
3703             3 => '1/8 s',
3704             4 => '1/4 s',
3705             5 => '1/2 s',
3706             6 => '1 s',
3707             7 => '2 s',
3708             8 => '4 s',
3709             9 => '8 s',
3710             10 => '15 s',
3711             11 => '30 s',
3712             },
3713             },
3714             31.1 => { # CSe5
3715             Name => 'ModelingFlash',
3716             Mask => 0x20,
3717             PrintConv => \%onOff,
3718             },
3719             36.1 => { # CSc4-a
3720             Name => 'PlaybackMonitorOffTime',
3721             Mask => 0xe0,
3722             PrintConv => {
3723             0 => '4 s',
3724             1 => '10 s',
3725             2 => '20 s',
3726             3 => '1 min',
3727             4 => '5 min',
3728             5 => '10 min',
3729             },
3730             },
3731             37.1 => { # CSf2-c
3732             Name => 'MultiSelectorLiveView',
3733             Mask => 0xc0,
3734             PrintConv => {
3735             0 => 'Reset',
3736             1 => 'Zoom',
3737             3 => 'Not Used',
3738             },
3739             },
3740             38.1 => { # CSf3-a
3741             Name => 'ShutterSpeedLock',
3742             Mask => 0x80,
3743             PrintConv => \%offOn,
3744             },
3745             38.2 => { # CSf3-b
3746             Name => 'ApertureLock',
3747             Mask => 0x40,
3748             PrintConv => \%offOn,
3749             },
3750             38.3 => { # CSg1-h
3751             Name => 'MovieShutterButton',
3752             Mask => 0x10,
3753             PrintConv => {
3754             0 => 'Take Photo',
3755             1 => 'Record Movies',
3756             },
3757             },
3758             38.4 => { # CSe3
3759             Name => 'FlashExposureCompArea',
3760             Mask => 0x04,
3761             PrintConv => {
3762             0 => 'Entire Frame',
3763             1 => 'Background Only',
3764             },
3765             },
3766             38.5 => { # CSe4
3767             Name => 'AutoFlashISOSensitivity',
3768             Mask => 0x02,
3769             PrintConv => {
3770             0 => 'Subject and Background',
3771             1 => 'Subject Only',
3772             },
3773             },
3774             41.1 => { # CSg1-c
3775             Name => 'MovieFunc1Button',
3776             Mask => 0xf0,
3777             PrintConv => {
3778             0 => 'None',
3779             2 => 'Power Aperture (close)',
3780             3 => 'Index Marking',
3781             4 => 'View Photo Shooting Info',
3782             11 => 'Exposure Compensation -',
3783             },
3784             },
3785             41.2 => { # CSg1-a
3786             Name => 'MoviePreviewButton',
3787             Mask => 0x0f,
3788             PrintConv => {
3789             0 => 'None',
3790             1 => 'Power Aperture (open)',
3791             3 => 'Index Marking',
3792             4 => 'View Photo Shooting Info',
3793             10 => 'Exposure Compensation +',
3794             },
3795             },
3796             42.1 => { # CSf1-d
3797             Name => 'Func1ButtonPlusDials',
3798             Mask => 0x0f,
3799             PrintConv => {
3800             0 => 'None',
3801             1 => 'Choose Image Area',
3802             2 => 'Shutter Speed & Aperture Lock',
3803             3 => 'One Step Speed / Aperture',
3804             4 => 'Choose Non-CPU Lens Number',
3805             5 => 'Active D-Lighting',
3806             7 => 'Photo Shooting Menu Bank',
3807             8 => 'Exposure Delay Mode',
3808             },
3809             },
3810             43.1 => { # CSf1-b
3811             Name => 'PreviewButtonPlusDials',
3812             Mask => 0x0f,
3813             PrintConv => {
3814             0 => 'None',
3815             1 => 'Choose Image Area',
3816             2 => 'Shutter Speed & Aperture Lock',
3817             3 => 'One Step Speed / Aperture',
3818             4 => 'Choose Non-CPU Lens Number',
3819             5 => 'Active D-Lighting',
3820             7 => 'Photo Shooting Menu Bank', # new with D500
3821             8 => 'Exposure Delay Mode',
3822             },
3823             },
3824             45.1 => { # CSf1-q
3825             Name => 'AssignMovieRecordButtonPlusDials',
3826             Mask => 0x0f,
3827             PrintConv => {
3828             0 => 'None',
3829             1 => 'Choose Image Area',
3830             2 => 'Shutter Speed & Aperture Lock',
3831             7 => 'Photo Shooting Menu Bank',
3832             11 => 'Exposure Mode',
3833             },
3834             },
3835             46.1 => { # CSb7-d
3836             Name => 'FineTuneOptHighlightWeighted',
3837             Mask => 0x0f,
3838             ValueConv => '($val > 0x7 ? $val - 0x10 : $val) / 6',
3839             ValueConvInv => 'int($val*6+($val>0?0.5:-0.5))',
3840             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
3841             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
3842             },
3843             47.1 => { # CSa12-b
3844             Name => 'DynamicAreaAFDisplay',
3845             Mask => 0x80,
3846             PrintConv => \%offOn,
3847             },
3848             47.2 => { # CSa12-a
3849             Name => 'AFPointIllumination',
3850             Mask => 0x40,
3851             PrintConv => {
3852             0 => 'Off',
3853             1 => 'On During Manual Focusing',
3854             },
3855             },
3856             47.3 => { # CSa7
3857             Name => 'StoreByOrientation',
3858             Mask => 0x18,
3859             PrintConv => {
3860             0 => 'Off',
3861             1 => 'Focus Point',
3862             2 => 'Focus Point and AF-area Mode',
3863             },
3864             },
3865             48.1 => { # CSb5
3866             Name => 'MatrixMetering',
3867             Mask => 0x80,
3868             PrintConv => {
3869             0 => 'Face Detection On',
3870             1 => 'Face Detection Off',
3871             },
3872             },
3873             48.2 => { # CSf8
3874             Name => 'LiveViewButtonOptions',
3875             Mask => 0x30,
3876             PrintConv => {
3877             0 => 'Enable',
3878             1 => 'Enable (Standby Timer Active)', # new with D500
3879             2 => 'Disable',
3880             },
3881             },
3882             48.3 => { # CSa10
3883             Name => 'AFModeRestrictions',
3884             Mask => 0x03,
3885             PrintConv => {
3886             0 => 'No Restrictions',
3887             1 => 'AF-C',
3888             2 => 'AF-S',
3889             },
3890             },
3891             49.1 => { # CSa9
3892             Name => 'LimitAFAreaModeSelection',
3893             Mask => 0x7e,
3894             PrintConv => {
3895             0 => 'No Restrictions',
3896             BITMASK => {
3897             0 => 'Auto-area',
3898             1 => 'Group-area',
3899             2 => '3D-tracking',
3900             3 => 'Dynamic area (153 points)',
3901             4 => 'Dynamic area (72 points)',
3902             5 => 'Dynamic area (25 points)',
3903             },
3904             },
3905             },
3906             52.1 => { # CSf1-r
3907             Name => 'LensFocusFunctionButtons',
3908             Mask => 0x3f,
3909             PrintConv => {
3910             3 => 'AE/AF Lock',
3911             4 => 'AE Lock Only',
3912             7 => 'AF Lock Only',
3913             8 => 'AF-On',
3914             24 => 'Preset Focus Point',
3915             26 => 'Flash Disable/Enable',
3916             36 => 'AF-Area Mode (Single)',
3917             37 => 'AF-Area Mode (Dynamic Area 25 Points)',
3918             38 => 'AF-Area Mode (Dynamic Area 72 Points)',
3919             39 => 'AF-Area Mode (Dynamic Area 152 Points)',
3920             40 => 'AF-Area Mode (Group Area AF)',
3921             41 => 'AF-Area Mode (Auto Area AF)',
3922             42 => 'AF-Area Mode + AF-On (Single)',
3923             43 => 'AF-Area Mode + AF-On (Dynamic Area 25 Points)',
3924             44 => 'AF-Area Mode + AF-On (Dynamic Area 72 Points)',
3925             45 => 'AF-Area Mode + AF-On (Dynamic Area 152 Points)',
3926             46 => 'AF-Area Mode + AF-On (Group Area AF)',
3927             47 => 'AF-Area Mode + AF-On (Auto Area AF)',
3928             49 => 'Sync Release (Master Only)',
3929             50 => 'Sync Release (Remote Only)',
3930             },
3931             },
3932             66.1 => { # CSf1-o
3933             Name => 'VerticalMultiSelector',
3934             Mask => 0xff,
3935             PrintHex => 1,
3936             PrintConv => {
3937             0x00 => 'Same as Multi-Selector with Info(U/D) & Playback(R/L)',
3938             0x08 => 'Same as Multi-Selector with Info(R/L) & Playback(U/D)',
3939             0x80 => 'Focus Point Selection',
3940             },
3941             },
3942             67.1 => { # CSf1-g
3943             Name => 'VerticalFuncButton',
3944             Mask => 0x3f,
3945             PrintConv => {
3946             0 => 'None',
3947             1 => 'Preview',
3948             2 => 'FV Lock',
3949             3 => 'AE/AF Lock',
3950             4 => 'AE Lock Only',
3951             5 => 'AE Lock (reset on release)',
3952             6 => 'AE Lock (hold)',
3953             7 => 'AF Lock Only',
3954             8 => 'AF-On',
3955             10 => 'Bracketing Burst',
3956             11 => 'Matrix Metering',
3957             12 => 'Center-weighted Metering',
3958             13 => 'Spot Metering',
3959             14 => 'Playback',
3960             15 => 'My Menu Top Item',
3961             16 => '+NEF(RAW)',
3962             17 => 'Virtual Horizon',
3963             18 => 'Reset Focus Point',
3964             19 => 'Grid Display',
3965             20 => 'My Menu',
3966             22 => 'Remote Release Only',
3967             23 => 'Preset Focus Point',
3968             26 => 'Flash Disable/Enable',
3969             27 => 'Highlight-weighted Metering',
3970             36 => 'AF-Area Mode (Single)',
3971             37 => 'AF-Area Mode (Dynamic Area 25 Points)',
3972             38 => 'AF-Area Mode (Dynamic Area 72 Points)',
3973             39 => 'AF-Area Mode (Dynamic Area 152 Points)',
3974             40 => 'AF-Area Mode (Group Area AF)',
3975             41 => 'AF-Area Mode (Auto Area AF)',
3976             42 => 'AF-Area Mode + AF-On (Single)',
3977             43 => 'AF-Area Mode + AF-On (Dynamic Area 25 Points)',
3978             44 => 'AF-Area Mode + AF-On (Dynamic Area 72 Points)',
3979             45 => 'AF-Area Mode + AF-On (Dynamic Area 152 Points)',
3980             46 => 'AF-Area Mode + AF-On (Group Area AF)',
3981             47 => 'AF-Area Mode + AF-On (Auto Area AF)',
3982             49 => 'Sync Release (Master Only)',
3983             50 => 'Sync Release (Remote Only)',
3984             54 => 'Highlight Active Focus Point',
3985             },
3986             },
3987             68.1 => { # CSf1-h
3988             Name => 'VerticalFuncPlusDials',
3989             Mask => 0x0f,
3990             PrintConv => {
3991             0 => 'None',
3992             1 => 'Choose Image Area',
3993             2 => 'Shutter Speed & Aperture Lock',
3994             3 => 'One Step Speed / Aperture',
3995             4 => 'Choose Non-CPU Lens Number',
3996             5 => 'Active D-Lighting',
3997             7 => 'Photo Shooting Menu Bank',
3998             8 => 'Exposure Delay Mode',
3999             10 => 'ISO Sensitivity',
4000             11 => 'Exposure Mode',
4001             12 => 'Exposure Compensation',
4002             13 => 'Metering',
4003             },
4004             },
4005             70.1 => { # CSf1-j
4006             Name => 'AF-OnButton',
4007             Mask => 0x3f,
4008             PrintConv => {
4009             0 => 'None',
4010             3 => 'AE/AF Lock',
4011             4 => 'AE Lock Only',
4012             5 => 'AE Lock (reset on release)',
4013             6 => 'AE Lock (hold)',
4014             7 => 'AF Lock Only',
4015             8 => 'AF-On',
4016             36 => 'AF-Area Mode (Single)',
4017             37 => 'AF-Area Mode (Dynamic Area 25 Points)',
4018             38 => 'AF-Area Mode (Dynamic Area 72 Points)',
4019             39 => 'AF-Area Mode (Dynamic Area 152 Points)',
4020             40 => 'AF-Area Mode (Group Area AF)',
4021             41 => 'AF-Area Mode (Auto Area AF)',
4022             42 => 'AF-Area Mode + AF-On (Single)',
4023             43 => 'AF-Area Mode + AF-On (Dynamic Area 25 Points)',
4024             44 => 'AF-Area Mode + AF-On (Dynamic Area 72 Points)',
4025             45 => 'AF-Area Mode + AF-On (Dynamic Area 152 Points)',
4026             46 => 'AF-Area Mode + AF-On (Group Area AF)',
4027             47 => 'AF-Area Mode + AF-On (Auto Area AF)',
4028             },
4029             },
4030             71.1 => { # CSf1-k
4031             Name => 'SubSelector',
4032             Mask => 0x80,
4033             PrintConv => {
4034             0 => 'Focus Point Selection',
4035             1 => 'Same as MultiSelector',
4036             },
4037             },
4038             72.1 => { # CSf1-l
4039             Name => 'SubSelectorCenter',
4040             Mask => 0x3f,
4041             PrintConv => {
4042             0 => 'None',
4043             1 => 'Preview',
4044             2 => 'FV Lock',
4045             3 => 'AE/AF Lock',
4046             4 => 'AE Lock Only',
4047             5 => 'AE Lock (reset on release)',
4048             6 => 'AE Lock (hold)',
4049             7 => 'AF Lock Only',
4050             8 => 'AF-On',
4051             10 => 'Bracketing Burst',
4052             11 => 'Matrix Metering',
4053             12 => 'Center-weighted Metering',
4054             13 => 'Spot Metering',
4055             14 => 'Playback',
4056             15 => 'My Menu Top Item',
4057             16 => '+NEF(RAW)',
4058             17 => 'Virtual Horizon',
4059             18 => 'Reset Focus Point',
4060             19 => 'Grid Display',
4061             20 => 'My Menu',
4062             22 => 'Remote Release Only',
4063             23 => 'Preset Focus Point',
4064             26 => 'Flash Disable/Enable',
4065             27 => 'Highlight-weighted Metering',
4066             36 => 'AF-Area Mode (Single)',
4067             37 => 'AF-Area Mode (Dynamic Area 25 Points)',
4068             38 => 'AF-Area Mode (Dynamic Area 72 Points)',
4069             39 => 'AF-Area Mode (Dynamic Area 152 Points)',
4070             40 => 'AF-Area Mode (Group Area AF)',
4071             41 => 'AF-Area Mode (Auto Area AF)',
4072             42 => 'AF-Area Mode + AF-On (Single)',
4073             43 => 'AF-Area Mode + AF-On (Dynamic Area 25 Points)',
4074             44 => 'AF-Area Mode + AF-On (Dynamic Area 72 Points)',
4075             45 => 'AF-Area Mode + AF-On (Dynamic Area 152 Points)',
4076             46 => 'AF-Area Mode + AF-On (Group Area AF)',
4077             47 => 'AF-Area Mode + AF-On (Auto Area AF)',
4078             49 => 'Sync Release (Master Only)',
4079             50 => 'Sync Release (Remote Only)',
4080             54 => 'Highlight Active Focus Point',
4081             },
4082             },
4083             73.1 => { # CSf1-m
4084             Name => 'SubSelectorPlusDials',
4085             Mask => 0x0f,
4086             PrintConv => {
4087             0 => 'None',
4088             1 => 'Choose Image Area',
4089             2 => 'Shutter Speed & Aperture Lock',
4090             4 => 'Choose Non-CPU Lens Number',
4091             7 => 'Photo Shooting Menu Bank',
4092             },
4093             },
4094             74.1 => { # CSg1-f
4095             Name => 'AssignMovieSubselector',
4096             Mask => 0xf0,
4097             PrintConv => {
4098             0 => 'None',
4099             3 => 'Index Marking',
4100             4 => 'View Photo Shooting Info',
4101             5 => 'AE/AF Lock',
4102             6 => 'AE Lock (Only)',
4103             7 => 'AE Lock (Hold)',
4104             8 => 'AF Lock (Only)',
4105             },
4106             },
4107             75.1 => { # CSg1-d
4108             Name => 'AssignMovieFunc1ButtonPlusDials',
4109             Mask => 0x10,
4110             PrintConv => {
4111             0 => 'None',
4112             1 => 'Choose Image Area',
4113             },
4114             },
4115             75.2 => { # CSg1-b
4116             Name => 'AssignMoviePreviewButtonPlusDials',
4117             Mask => 0x01,
4118             PrintConv => {
4119             0 => 'None',
4120             1 => 'Choose Image Area (DX/1.3x)',
4121             },
4122             },
4123             76.1 => { # CSg1-g
4124             Name => 'AssignMovieSubselectorPlusDials',
4125             Mask => 0x10,
4126             PrintConv => {
4127             0 => 'None',
4128             1 => 'Choose Image Area',
4129             },
4130             },
4131             77.1 => { # CSd4
4132             Name => 'SyncReleaseMode', # new with D500
4133             Mask => 0x80,
4134             PrintConv => {
4135             0 => 'No Sync',
4136             1 => 'Sync',
4137             },
4138             },
4139             78.1 => { # CSa5
4140             Name => 'Three-DTrackingWatchArea', # new with D500
4141             Mask => 0x80,
4142             PrintConv => {
4143             0 => 'Wide',
4144             1 => 'Normal',
4145             },
4146             },
4147             78.2 => { # CSa3-b
4148             Name => 'SubjectMotion',
4149             Mask => 0x60,
4150             PrintConv => {
4151             0 => 'Steady',
4152             1 => 'Middle',
4153             2 => 'Erratic',
4154             },
4155             },
4156             78.3 => { # CSa8
4157             Name => 'AFActivation',
4158             Mask => 0x08,
4159             PrintConv => {
4160             0 => 'Shutter/AF-On',
4161             1 => 'AF-On Only',
4162             },
4163             },
4164             78.4 => { # CSc1
4165             Name => 'ShutterReleaseButtonAE-L',
4166             Mask => 0x03,
4167             PrintConv => {
4168             0 => 'Off',
4169             1 => 'On (Half Press)',
4170             2 => 'On (Burst Mode)'
4171             },
4172             },
4173             79.1 => { # CSf1-n
4174             Name => 'VerticalAFOnButton',
4175             Mask => 0x7f,
4176             PrintConv => {
4177             0 => 'None',
4178             3 => 'AE/AF Lock',
4179             4 => 'AE Lock Only',
4180             5 => 'AE Lock (reset on release)',
4181             6 => 'AE Lock (hold)',
4182             7 => 'AF Lock Only',
4183             8 => 'AF-On',
4184             36 => 'AF-Area Mode (Single)',
4185             37 => 'AF-Area Mode (Dynamic Area 25 Points)',
4186             38 => 'AF-Area Mode (Dynamic Area 72 Points)',
4187             39 => 'AF-Area Mode (Dynamic Area 152 Points)',
4188             40 => 'AF-Area Mode (Group Area AF)',
4189             41 => 'AF-Area Mode (Auto Area AF)',
4190             42 => 'AF-Area Mode + AF-On (Single)',
4191             43 => 'AF-Area Mode + AF-On (Dynamic Area 25 Points)',
4192             44 => 'AF-Area Mode + AF-On (Dynamic Area 72 Points)',
4193             45 => 'AF-Area Mode + AF-On (Dynamic Area 152 Points)',
4194             46 => 'AF-Area Mode + AF-On (Group Area AF)',
4195             47 => 'AF-Area Mode + AF-On (Auto Area AF)',
4196             100 => 'Same as AF-On',
4197             },
4198             },
4199             80.1 => { # CSf1-e
4200             Name => 'Func2Button',
4201             Mask => 0x3f,
4202             PrintConv => {
4203             0 => 'None',
4204             1 => 'Preview',
4205             2 => 'FV Lock',
4206             3 => 'AE/AF Lock',
4207             4 => 'AE Lock Only',
4208             5 => 'AE Lock (reset on release)',
4209             6 => 'AE Lock (hold)',
4210             7 => 'AF Lock Only',
4211             8 => 'AF-On',
4212             10 => 'Bracketing Burst',
4213             11 => 'Matrix Metering',
4214             12 => 'Center-weighted Metering',
4215             13 => 'Spot Metering',
4216             14 => 'Playback',
4217             15 => 'My Menu Top Item',
4218             16 => '+NEF(RAW)',
4219             17 => 'Virtual Horizon',
4220             19 => 'Grid Display',
4221             20 => 'My Menu',
4222             21 => 'Disable Synchronized Release',
4223             22 => 'Remote Release Only',
4224             26 => 'Flash Disable/Enable',
4225             27 => 'Highlight-weighted Metering',
4226             36 => 'AF-Area Mode (Single)',
4227             37 => 'AF-Area Mode (Dynamic Area 25 Points)',
4228             38 => 'AF-Area Mode (Dynamic Area 72 Points)',
4229             39 => 'AF-Area Mode (Dynamic Area 152 Points)',
4230             40 => 'AF-Area Mode (Group Area AF)',
4231             41 => 'AF-Area Mode (Auto Area AF)',
4232             42 => 'AF-Area Mode + AF-On (Single)',
4233             43 => 'AF-Area Mode + AF-On (Dynamic Area 25 Points)',
4234             44 => 'AF-Area Mode + AF-On (Dynamic Area 72 Points)',
4235             45 => 'AF-Area Mode + AF-On (Dynamic Area 152 Points)',
4236             46 => 'AF-Area Mode + AF-On (Group Area AF)',
4237             47 => 'AF-Area Mode + AF-On (Auto Area AF)',
4238             49 => 'Sync Release (Master Only)',
4239             50 => 'Sync Release (Remote Only)',
4240             },
4241             },
4242             81.1 => { # CSf1-f
4243             Name => 'Func2ButtonPlusDials',
4244             Mask => 0x0f,
4245             PrintConv => {
4246             0 => 'None',
4247             1 => 'Choose Image Area',
4248             2 => 'Shutter Speed & Aperture Lock',
4249             3 => 'One Step Speed / Aperture',
4250             4 => 'Choose Non-CPU Lens Number',
4251             5 => 'Active D-Lighting',
4252             7 => 'Photo Shooting Menu Bank',
4253             8 => 'Exposure Delay Mode',
4254             },
4255             },
4256             82.1 => { # CSg1-e
4257             Name => 'AssignMovieFunc2Button',
4258             Mask => 0x70,
4259             PrintConv => {
4260             0 => 'None',
4261             3 => 'Index Marking',
4262             4 => 'View Photo Shooting Info',
4263             },
4264             },
4265             83.1 => { # CSf1-i
4266             Name => 'Func3Button',
4267             Mask => 0x03,
4268             PrintConv => {
4269             0 => 'None',
4270             1 => 'Voice Memo',
4271             2 => 'Rating',
4272             3 => 'Connect To Network',
4273             },
4274             },
4275             );
4276              
4277             # D500 custom settings (ref 1)
4278             %Image::ExifTool::NikonCustom::SettingsD500 = (
4279             PROCESS_PROC => \&Image::ExifTool::ProcessBinaryData,
4280             WRITE_PROC => \&Image::ExifTool::WriteBinaryData,
4281             CHECK_PROC => \&Image::ExifTool::CheckBinaryData,
4282             WRITABLE => 1,
4283             FIRST_ENTRY => 0,
4284             GROUPS => { 0 => 'MakerNotes', 2 => 'Camera' },
4285             NOTES => 'Custom settings for the D500.',
4286             0.1 => {
4287             Name => 'CustomSettingsBank',
4288             Mask => 0x03,
4289             PrintConv => {
4290             0 => 'A',
4291             1 => 'B',
4292             2 => 'C',
4293             3 => 'D',
4294             },
4295             },
4296             1.1 => { # CSa1
4297             Name => 'AF-CPrioritySelection',
4298             Mask => 0xc0,
4299             PrintConv => {
4300             0 => 'Release',
4301             1 => 'Release + Focus',
4302             2 => 'Focus',
4303             3 => 'Focus + Release',
4304             },
4305             },
4306             1.2 => { # CSa2
4307             Name => 'AF-SPrioritySelection',
4308             Mask => 0x20,
4309             PrintConv => {
4310             0 => 'Focus',
4311             1 => 'Release',
4312             },
4313             },
4314             1.3 => { # CSa6
4315             Name => 'NumberOfFocusPoints',
4316             Mask => 0x10,
4317             PrintConv => {
4318             0 => '55 Points',
4319             1 => '15 Points',
4320             },
4321             },
4322             1.4 => { # CSa4
4323             Name => 'Three-DTrackingFaceDetection',
4324             Mask => 0x08,
4325             PrintConv => \%offOn,
4326             },
4327             1.5 => { # CSa3-a
4328             Name => 'BlockShotAFResponse',
4329             Mask => 0x07,
4330             #values 1-5
4331             },
4332             2.1 => { # CSa11
4333             Name => 'FocusPointWrap',
4334             Mask => 0x08,
4335             PrintConv => {
4336             0 => 'No Wrap',
4337             1 => 'Wrap',
4338             },
4339             },
4340             2.2 => { # CSa12-c
4341             Name => 'AFPointBrightness',
4342             Mask => 0x06,
4343             PrintConv => {
4344             0 => 'Auto',
4345             1 => 'On',
4346             2 => 'Off',
4347             },
4348             },
4349             4.1 => { # CSd3
4350             Name => 'ISODisplay',
4351             Mask => 0x08,
4352             PrintConv => {
4353             0 => 'Show ISO Sensitivity',
4354             1 => 'Show Frame Count',
4355             },
4356             },
4357             4.2 => { # CSd8
4358             Name => 'GridDisplay',
4359             Mask => 0x02,
4360             PrintConv => \%onOff,
4361             },
4362             5.1 => { # CSd9
4363             Name => 'LCDIllumination',
4364             Mask => 0x20,
4365             PrintConv => \%offOn,
4366             },
4367             5.2 => { # CSd6
4368             Name => 'ElectronicFront-CurtainShutter',
4369             Mask => 0x08,
4370             PrintConv => \%offOn,
4371             },
4372             6.1 => { # CSf7
4373             Name => 'ReverseIndicators',
4374             Mask => 0x80,
4375             PrintConv => {
4376             0 => '+ 0 -',
4377             1 => '- 0 +',
4378             },
4379             },
4380             6.2 => { # CSf4-a
4381             Name => 'CommandDialsReverseRotation',
4382             Mask => 0x18,
4383             PrintConv => {
4384             0 => 'No',
4385             1 => 'Shutter Speed & Aperture',
4386             2 => 'Exposure Compensation',
4387             3 => 'Exposure Compensation, Shutter Speed & Aperture',
4388             },
4389             },
4390             6.3 => { # CSb4
4391             Name => 'EasyExposureCompensation',
4392             Mask => 0x03,
4393             PrintConv => {
4394             0 => 'Off',
4395             1 => 'On',
4396             2 => 'On (auto reset)',
4397             },
4398             },
4399             7.1 => { # CSb2
4400             Name => 'ExposureControlStepSize',
4401             Mask => 0xc0,
4402             PrintConv => {
4403             0 => '1/3 EV',
4404             1 => '1/2 EV',
4405             2 => '1 EV',
4406             },
4407             },
4408             7.2 => { # CSb1
4409             Name => 'ISOStepSize',
4410             Mask => 0x30,
4411             PrintConv => {
4412             0 => '1/3 EV',
4413             1 => '1/2 EV',
4414             2 => '1 EV',
4415             },
4416             },
4417             7.3 => { # CSb3
4418             Name => 'ExposureCompStepSize',
4419             Mask => 0x0c,
4420             PrintConv => {
4421             0 => '1/3 EV',
4422             1 => '1/2 EV',
4423             2 => '1 EV',
4424             },
4425             },
4426             8.1 => { # CSb6
4427             Name => 'CenterWeightedAreaSize',
4428             Mask => 0xe0,
4429             PrintConv => {
4430             0 => '6 mm',
4431             1 => '8 mm',
4432             2 => '10 mm',
4433             3 => '13 mm',
4434             4 => 'Average',
4435             },
4436             },
4437             8.2 => { # CSb7-a
4438             Name => 'FineTuneOptMatrixMetering',
4439             Mask => 0x0f,
4440             ValueConv => '($val > 0x7 ? $val - 0x10 : $val) / 6',
4441             ValueConvInv => 'int($val*6+($val>0?0.5:-0.5))',
4442             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
4443             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
4444             },
4445             9.1 => { # CSb7-b
4446             Name => 'FineTuneOptCenterWeighted',
4447             Mask => 0xf0,
4448             ValueConv => '($val > 0x7 ? $val - 0x10 : $val) / 6',
4449             ValueConvInv => 'int($val*6+($val>0?0.5:-0.5))',
4450             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
4451             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
4452             },
4453             9.2 => { # CSb7-c
4454             Name => 'FineTuneOptSpotMetering',
4455             Mask => 0x0f,
4456             ValueConv => '($val > 0x7 ? $val - 0x10 : $val) / 6',
4457             ValueConvInv => 'int($val*6+($val>0?0.5:-0.5))',
4458             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
4459             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
4460             },
4461             10.1 => { # CSf2-a
4462             Name => 'MultiSelectorShootMode',
4463             Mask => 0xe0, #same offset and settings as D810 but with a different decoding
4464             PrintConv => {
4465             0 => 'Select Center Focus Point (Reset)',
4466             2 => 'Preset Focus Point (Pre)',
4467             3 => 'Highlight Active Focus Point',
4468             4 => 'Not Used (None)',
4469             },
4470             },
4471             10.2 => { # CSf2-b #same offset and settings as D810 but with a different decoding
4472             Name => 'MultiSelectorPlaybackMode',
4473             Mask => 0x0c,
4474             PrintConv => {
4475             0 => 'Thumbnail On/Off',
4476             1 => 'View Histograms',
4477             2 => 'Zoom On/Off',
4478             3 => 'Choose Folder',
4479             },
4480             },
4481             10.3 => { # CSf5
4482             Name => 'MultiSelector',
4483             Mask => 0x01,
4484             PrintConv => {
4485             0 => 'Do Nothing',
4486             1 => 'Reset Meter-off Delay',
4487             },
4488             },
4489             11.1 => { # CSd5
4490             Name => 'ExposureDelayMode',
4491             Mask => 0xc0,
4492             PrintConv => {
4493             0 => 'Off',
4494             1 => '1 s',
4495             2 => '2 s',
4496             3 => '3 s',
4497             },
4498             },
4499             11.2 => { # CSd1
4500             Name => 'CLModeShootingSpeed',
4501             Mask => 0x0f,
4502             PrintConv => '"$val fps"',
4503             PrintConvInv => '$val=~s/\s*fps//i; $val',
4504             },
4505             12.1 => { # CSd2
4506             Name => 'MaxContinuousRelease',
4507             # values: 1-100
4508             },
4509             13.1 => { # CSe7
4510             Name => 'AutoBracketOrder',
4511             Mask => 0x10,
4512             PrintConv => {
4513             0 => '0,-,+',
4514             1 => '-,0,+',
4515             },
4516             },
4517             13.2 => { # CSe6
4518             Name => 'AutoBracketModeM',
4519             Mask => 0x0c,
4520             PrintConv => {
4521             0 => 'Flash/Speed',
4522             1 => 'Flash/Speed/Aperture',
4523             2 => 'Flash/Aperture',
4524             3 => 'Flash Only',
4525             },
4526             },
4527             14.1 => { # CSf1-c
4528             Name => 'Func1Button',
4529             Mask => 0x3f,
4530             PrintConv => {
4531             0 => 'None',
4532             1 => 'Preview',
4533             2 => 'FV Lock',
4534             3 => 'AE/AF Lock',
4535             4 => 'AE Lock Only',
4536             5 => 'AE Lock (reset on release)',
4537             6 => 'AE Lock (hold)',
4538             7 => 'AF Lock Only',
4539             8 => 'AF-On',
4540             10 => 'Bracketing Burst',
4541             11 => 'Matrix Metering',
4542             12 => 'Center-weighted Metering',
4543             13 => 'Spot Metering',
4544             14 => 'Playback',
4545             15 => 'My Menu Top Item',
4546             16 => '+NEF(RAW)',
4547             17 => 'Virtual Horizon',
4548             19 => 'Grid Display',
4549             20 => 'My Menu',
4550             22 => 'Remote Release Only',
4551             26 => 'Flash Disable/Enable',
4552             27 => 'Highlight-weighted Metering',
4553             36 => 'AF-Area Mode (Single)',
4554             37 => 'AF-Area Mode (Dynamic Area 25 Points)',
4555             38 => 'AF-Area Mode (Dynamic Area 72 Points)',
4556             39 => 'AF-Area Mode (Dynamic Area 152 Points)',
4557             40 => 'AF-Area Mode (Group Area AF)',
4558             41 => 'AF-Area Mode (Auto Area AF)',
4559             42 => 'AF-Area Mode + AF-On (Single)',
4560             43 => 'AF-Area Mode + AF-On (Dynamic Area 25 Points)',
4561             44 => 'AF-Area Mode + AF-On (Dynamic Area 72 Points)',
4562             45 => 'AF-Area Mode + AF-On (Dynamic Area 152 Points)',
4563             46 => 'AF-Area Mode + AF-On (Group Area AF)',
4564             47 => 'AF-Area Mode + AF-On (Auto Area AF)',
4565             49 => 'Sync Release (Master Only)',
4566             50 => 'Sync Release (Remote Only)',
4567             },
4568             },
4569             15.1 => { # CSf1-a
4570             Name => 'PreviewButton',
4571             Mask => 0x3f,
4572             PrintConv => {
4573             0 => 'None',
4574             1 => 'Preview',
4575             2 => 'FV Lock',
4576             3 => 'AE/AF Lock',
4577             4 => 'AE Lock Only',
4578             5 => 'AE Lock (reset on release)',
4579             6 => 'AE Lock (hold)',
4580             7 => 'AF Lock Only',
4581             8 => 'AF-On',
4582             10 => 'Bracketing Burst',
4583             11 => 'Matrix Metering',
4584             12 => 'Center-weighted Metering',
4585             13 => 'Spot Metering',
4586             14 => 'Playback',
4587             15 => 'My Menu Top Item',
4588             16 => '+NEF(RAW)',
4589             17 => 'Virtual Horizon',
4590             19 => 'Grid Display',
4591             20 => 'My Menu',
4592             # 21 => 'Disable Synchronized Release', # removed with D500
4593             22 => 'Remote Release Only',
4594             26 => 'Flash Disable/Enable',
4595             27 => 'Highlight-weighted Metering',
4596             36 => 'AF-Area Mode (Single)', # new with D500
4597             37 => 'AF-Area Mode (Dynamic Area 25 Points)', # new with D500
4598             38 => 'AF-Area Mode (Dynamic Area 72 Points)', # new with D500
4599             39 => 'AF-Area Mode (Dynamic Area 152 Points)', # new with D500
4600             40 => 'AF-Area Mode (Group Area AF)', # new with D500
4601             41 => 'AF-Area Mode (Auto Area AF)', # new with D500
4602             42 => 'AF-Area Mode + AF-On (Single)', # new with D500
4603             43 => 'AF-Area Mode + AF-On (Dynamic Area 25 Points)', # new with D500
4604             44 => 'AF-Area Mode + AF-On (Dynamic Area 72 Points)', # new with D500
4605             45 => 'AF-Area Mode + AF-On (Dynamic Area 152 Points)',# new with D500
4606             46 => 'AF-Area Mode + AF-On (Group Area AF)', # new with D500
4607             47 => 'AF-Area Mode + AF-On (Auto Area AF)', # new with D500
4608             49 => 'Sync Release (Master Only)', # new with D500
4609             50 => 'Sync Release (Remote Only)', # new with D500
4610             },
4611             },
4612             16.1 => { # CSf1-j
4613             Name => 'AssignBktButton',
4614             Mask => 0x07,
4615             PrintConv => {
4616             0 => 'Auto Bracketing',
4617             1 => 'Multiple Exposure',
4618             2 => 'HDR (high dynamic range)',
4619             3 => 'None',
4620             },
4621             },
4622             18.1 => { # CSf4-b
4623             Name => 'CommandDialsChangeMainSub',
4624             Mask => 0xe0,
4625             PrintConv => {
4626             0 => 'Autofocus Off, Exposure Off',
4627             1 => 'Autofocus Off, Exposure On',
4628             2 => 'Autofocus Off, Exposure On (Mode A)',
4629             4 => 'Autofocus On, Exposure Off',
4630             5 => 'Autofocus On, Exposure On',
4631             6 => 'Autofocus On, Exposure On (Mode A)',
4632             },
4633             },
4634             18.2 => { # CSf4-d
4635             Name => 'CommandDialsMenuAndPlayback',
4636             Mask => 0x18,
4637             PrintConv => {
4638             0 => 'On',
4639             1 => 'Off',
4640             2 => 'On (Image Review Excluded)',
4641             },
4642             },
4643             18.3 => { # CSf4-c
4644             Name => 'CommandDialsApertureSetting',
4645             Mask => 0x04,
4646             PrintConv => {
4647             0 => 'Sub-command Dial',
4648             1 => 'Aperture Ring',
4649             },
4650             },
4651             18.4 => { # CSf6
4652             Name => 'ReleaseButtonToUseDial',
4653             Mask => 0x01,
4654             PrintConv => \%noYes,
4655             },
4656             19.1 => { # CSc2
4657             Name => 'StandbyTimer',
4658             Mask => 0xf0,
4659             PrintConv => {
4660             0 => '4 s',
4661             1 => '6 s',
4662             3 => '10 s',
4663             5 => '30 s',
4664             6 => '1 min',
4665             7 => '5 min',
4666             8 => '10 min',
4667             9 => '30 min',
4668             10 => 'No Limit',
4669             },
4670             },
4671             20.1 => { # CSc3-a
4672             Name => 'SelfTimerTime',
4673             Mask => 0xc0,
4674             PrintConv => {
4675             0 => '2 s',
4676             1 => '5 s',
4677             2 => '10 s',
4678             3 => '20 s',
4679             },
4680             },
4681             20.2 => { # CSc3-c
4682             Name => 'SelfTimerShotInterval',
4683             Mask => 0x30,
4684             PrintConv => {
4685             0 => '0.5 s',
4686             1 => '1 s',
4687             2 => '2 s',
4688             3 => '3 s',
4689             },
4690             },
4691             20.3 => { # CSc3-b
4692             Name => 'SelfTimerShotCount',
4693             Mask => 0x0f,
4694             },
4695             21.1 => { # CSc4-d
4696             Name => 'ImageReviewMonitorOffTime',
4697             Mask => 0xe0,
4698             PrintConv => {
4699             0 => '2 s',
4700             1 => '4 s',
4701             3 => '10 s',
4702             4 => '20 s',
4703             5 => '1 min',
4704             6 => '5 min',
4705             7 => '10 min',
4706             },
4707             },
4708             21.2 => { # CSc4-e
4709             Name => 'LiveViewMonitorOffTime',
4710             Mask => 0x1c,
4711             PrintConv => {
4712             1 => '5 min',
4713             2 => '10 min',
4714             3 => '15 min',
4715             4 => '20 min',
4716             5 => '30 min',
4717             6 => 'No Limit',
4718             },
4719             },
4720             22.1 => { # CSc4-b
4721             Name => 'MenuMonitorOffTime',
4722             Mask => 0xe0,
4723             PrintConv => {
4724             0 => '4 s',
4725             2 => '10 s',
4726             4 => '20 s',
4727             5 => '1 min',
4728             6 => '5 min',
4729             7 => '10 min',
4730             },
4731             },
4732             22.2 => { # CSc4-c
4733             Name => 'ShootingInfoMonitorOffTime',
4734             Mask => 0x1c,
4735             PrintConv => {
4736             0 => '4 s',
4737             2 => '10 s',
4738             4 => '20 s',
4739             5 => '1 min',
4740             6 => '5 min',
4741             7 => '10 min',
4742             },
4743             },
4744             23.1 => { # CSe1
4745             Name => 'FlashSyncSpeed',
4746             Mask => 0xf0,
4747             PrintConv => {
4748             2 => '1/250 s (auto FP)',
4749             3 => '1/250 s',
4750             5 => '1/200 s',
4751             6 => '1/160 s',
4752             7 => '1/125 s',
4753             8 => '1/100 s',
4754             9 => '1/80 s',
4755             10 => '1/60 s',
4756             },
4757             },
4758             23.2 => { # CSe2
4759             Name => 'FlashShutterSpeed',
4760             Mask => 0x0f,
4761             PrintConvColumns => 2,
4762             PrintConv => {
4763             0 => '1/60 s',
4764             1 => '1/30 s',
4765             2 => '1/15 s',
4766             3 => '1/8 s',
4767             4 => '1/4 s',
4768             5 => '1/2 s',
4769             6 => '1 s',
4770             7 => '2 s',
4771             8 => '4 s',
4772             9 => '8 s',
4773             10 => '15 s',
4774             11 => '30 s',
4775             },
4776             },
4777             31.1 => { # CSe5
4778             Name => 'ModelingFlash',
4779             Mask => 0x20,
4780             PrintConv => \%onOff,
4781             },
4782             36.1 => { # CSc4-a
4783             Name => 'PlaybackMonitorOffTime',
4784             Mask => 0xe0,
4785             PrintConv => {
4786             0 => '4 s',
4787             1 => '10 s',
4788             2 => '20 s',
4789             3 => '1 min',
4790             4 => '5 min',
4791             5 => '10 min',
4792             },
4793             },
4794             37.1 => { # CSf2-c
4795             Name => 'MultiSelectorLiveView',
4796             Mask => 0xc0,
4797             PrintConv => {
4798             0 => 'Reset',
4799             1 => 'Zoom',
4800             3 => 'Not Used',
4801             },
4802             },
4803             38.1 => { # CSf3-a
4804             Name => 'ShutterSpeedLock',
4805             Mask => 0x80,
4806             PrintConv => \%offOn,
4807             },
4808             38.2 => { # CSf3-b
4809             Name => 'ApertureLock',
4810             Mask => 0x40,
4811             PrintConv => \%offOn,
4812             },
4813             38.3 => { # CSg1-h
4814             Name => 'MovieShutterButton',
4815             Mask => 0x10,
4816             PrintConv => {
4817             0 => 'Take Photo',
4818             1 => 'Record Movies',
4819             },
4820             },
4821             38.4 => { # CSe3
4822             Name => 'FlashExposureCompArea',
4823             Mask => 0x04,
4824             PrintConv => {
4825             0 => 'Entire Frame',
4826             1 => 'Background Only',
4827             },
4828             },
4829             38.5 => { # CSe4
4830             Name => 'AutoFlashISOSensitivity',
4831             Mask => 0x02,
4832             PrintConv => {
4833             0 => 'Subject and Background',
4834             1 => 'Subject Only',
4835             },
4836             },
4837             41.1 => { # CSg1-c
4838             Name => 'MovieFunc1Button',
4839             Mask => 0xf0,
4840             PrintConv => {
4841             0 => 'None',
4842             2 => 'Power Aperture (close)',
4843             3 => 'Index Marking',
4844             4 => 'View Photo Shooting Info',
4845             11 => 'Exposure Compensation -',
4846             },
4847             },
4848             41.2 => { # CSg1-a
4849             Name => 'MoviePreviewButton',
4850             Mask => 0x0f,
4851             PrintConv => {
4852             0 => 'None',
4853             1 => 'Power Aperture (open)',
4854             3 => 'Index Marking',
4855             4 => 'View Photo Shooting Info',
4856             10 => 'Exposure Compensation +',
4857             },
4858             },
4859             42.1 => { # CSf1-d
4860             Name => 'Func1ButtonPlusDials',
4861             Mask => 0x0f,
4862             PrintConv => {
4863             0 => 'None',
4864             1 => 'Choose Image Area (DX/1.3x)',
4865             2 => 'Shutter Speed & Aperture Lock',
4866             3 => 'One Step Speed / Aperture',
4867             4 => 'Choose Non-CPU Lens Number',
4868             5 => 'Active D-Lighting',
4869             7 => 'Photo Shooting Menu Bank',
4870             8 => 'Exposure Delay Mode',
4871             },
4872             },
4873             43.1 => { # CSf1-b
4874             Name => 'PreviewButtonPlusDials',
4875             Mask => 0x0f,
4876             PrintConv => {
4877             0 => 'None',
4878             1 => 'Choose Image Area (DX/1.3x)',
4879             2 => 'Shutter Speed & Aperture Lock',
4880             3 => 'One Step Speed / Aperture',
4881             4 => 'Choose Non-CPU Lens Number',
4882             5 => 'Active D-Lighting',
4883             7 => 'Photo Shooting Menu Bank', # new with D500
4884             8 => 'Exposure Delay Mode',
4885             },
4886             },
4887             45.1 => { # CSf1-k
4888             Name => 'AssignMovieRecordButtonPlusDials',
4889             Mask => 0x0f,
4890             PrintConv => {
4891             0 => 'None',
4892             1 => 'Choose Image Area (DX/1.3x)',
4893             2 => 'Shutter Speed & Aperture Lock',
4894             7 => 'Photo Shooting Menu Bank',
4895             11 => 'Exposure Mode',
4896             },
4897             },
4898             46.1 => { # CSb7-d
4899             Name => 'FineTuneOptHighlightWeighted',
4900             Mask => 0x0f,
4901             ValueConv => '($val > 0x7 ? $val - 0x10 : $val) / 6',
4902             ValueConvInv => 'int($val*6+($val>0?0.5:-0.5))',
4903             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
4904             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
4905             },
4906             47.1 => { # CSa12-b
4907             Name => 'DynamicAreaAFDisplay',
4908             Mask => 0x80,
4909             PrintConv => \%offOn,
4910             },
4911             47.2 => { # CSa12-a
4912             Name => 'AFPointIllumination',
4913             Mask => 0x40,
4914             PrintConv => {
4915             0 => 'Off',
4916             1 => 'On During Manual Focusing',
4917             },
4918             },
4919             47.3 => { # CSa7
4920             Name => 'StoreByOrientation',
4921             Mask => 0x18,
4922             PrintConv => {
4923             0 => 'Off',
4924             1 => 'Focus Point',
4925             2 => 'Focus Point and AF-area Mode',
4926             },
4927             },
4928             47.4 => { # CSa12-c
4929             Name => 'GroupAreaAFIllumination',
4930             Mask => 0x04,
4931             PrintConv => {
4932             0 => 'Squares',
4933             1 => 'Dots',
4934             },
4935             },
4936             48.1 => { # CSb5
4937             Name => 'MatrixMetering',
4938             Mask => 0x80,
4939             PrintConv => {
4940             0 => 'Face Detection On',
4941             1 => 'Face Detection Off',
4942             },
4943             },
4944             48.2 => { # CSf8
4945             Name => 'LiveViewButtonOptions',
4946             Mask => 0x30,
4947             PrintConv => {
4948             0 => 'Enable',
4949             1 => 'Enable (Standby Timer Active)', # new with D500
4950             2 => 'Disable',
4951             },
4952             },
4953             48.3 => { # CSa10
4954             Name => 'AFModeRestrictions',
4955             Mask => 0x03,
4956             PrintConv => {
4957             0 => 'No Restrictions',
4958             1 => 'AF-C',
4959             2 => 'AF-S',
4960             },
4961             },
4962             49.1 => { # CSa9
4963             Name => 'LimitAFAreaModeSelection',
4964             Mask => 0x7e,
4965             PrintConv => {
4966             0 => 'No Restrictions',
4967             BITMASK => {
4968             0 => 'Auto-area',
4969             1 => 'Group-area',
4970             2 => '3D-tracking',
4971             3 => 'Dynamic area (153 points)',
4972             4 => 'Dynamic area (72 points)',
4973             5 => 'Dynamic area (25 points)',
4974             },
4975             },
4976             },
4977             52.1 => { # CSf1-l
4978             Name => 'LensFocusFunctionButtons',
4979             Mask => 0x3f,
4980             PrintConv => {
4981             3 => 'AE/AF Lock',
4982             4 => 'AE Lock Only',
4983             7 => 'AF Lock Only',
4984             8 => 'AF-On',
4985             24 => 'Preset Focus Point',
4986             26 => 'Flash Disable/Enable',
4987             36 => 'AF-Area Mode (Single)',
4988             37 => 'AF-Area Mode (Dynamic Area 25 Points)',
4989             38 => 'AF-Area Mode (Dynamic Area 72 Points)',
4990             39 => 'AF-Area Mode (Dynamic Area 152 Points)',
4991             40 => 'AF-Area Mode (Group Area AF)',
4992             41 => 'AF-Area Mode (Auto Area AF)',
4993             42 => 'AF-Area Mode + AF-On (Single)',
4994             43 => 'AF-Area Mode + AF-On (Dynamic Area 25 Points)',
4995             44 => 'AF-Area Mode + AF-On (Dynamic Area 72 Points)',
4996             45 => 'AF-Area Mode + AF-On (Dynamic Area 152 Points)',
4997             46 => 'AF-Area Mode + AF-On (Group Area AF)',
4998             47 => 'AF-Area Mode + AF-On (Auto Area AF)',
4999             49 => 'Sync Release (Master Only)',
5000             50 => 'Sync Release (Remote Only)',
5001             },
5002             },
5003             66.1 => { # CSf10-d
5004             Name => 'VerticalMultiSelector',
5005             Mask => 0xff,
5006             PrintHex => 1,
5007             PrintConv => {
5008             0x00 => 'Same as Multi-Selector with Info(U/D) & Playback(R/L)',
5009             0x08 => 'Same as Multi-Selector with Info(R/L) & Playback(U/D)',
5010             0x80 => 'Focus Point Selection',
5011             },
5012             },
5013             67.1 => { # CSf10-a
5014             Name => 'AssignMB-D17FuncButton',
5015             Mask => 0x3f,
5016             PrintConv => {
5017             0 => 'None',
5018             1 => 'Preview',
5019             2 => 'FV Lock',
5020             3 => 'AE/AF Lock',
5021             4 => 'AE Lock Only',
5022             5 => 'AE Lock (reset on release)',
5023             6 => 'AE Lock (hold)',
5024             7 => 'AF Lock Only',
5025             8 => 'AF-On',
5026             10 => 'Bracketing Burst',
5027             11 => 'Matrix Metering',
5028             12 => 'Center-weighted Metering',
5029             13 => 'Spot Metering',
5030             14 => 'Playback',
5031             15 => 'My Menu Top Item',
5032             16 => '+NEF(RAW)',
5033             17 => 'Virtual Horizon',
5034             18 => 'Reset Focus Point',
5035             19 => 'Grid Display',
5036             20 => 'My Menu',
5037             22 => 'Remote Release Only',
5038             23 => 'Preset Focus Point',
5039             26 => 'Flash Disable/Enable',
5040             27 => 'Highlight-weighted Metering',
5041             36 => 'AF-Area Mode (Single)',
5042             37 => 'AF-Area Mode (Dynamic Area 25 Points)',
5043             38 => 'AF-Area Mode (Dynamic Area 72 Points)',
5044             39 => 'AF-Area Mode (Dynamic Area 152 Points)',
5045             40 => 'AF-Area Mode (Group Area AF)',
5046             41 => 'AF-Area Mode (Auto Area AF)',
5047             42 => 'AF-Area Mode + AF-On (Single)',
5048             43 => 'AF-Area Mode + AF-On (Dynamic Area 25 Points)',
5049             44 => 'AF-Area Mode + AF-On (Dynamic Area 72 Points)',
5050             45 => 'AF-Area Mode + AF-On (Dynamic Area 152 Points)',
5051             46 => 'AF-Area Mode + AF-On (Group Area AF)',
5052             47 => 'AF-Area Mode + AF-On (Auto Area AF)',
5053             49 => 'Sync Release (Master Only)',
5054             50 => 'Sync Release (Remote Only)',
5055             54 => 'Highlight Active Focus Point',
5056             },
5057             },
5058             68.1 => { # CSf10-b
5059             Name => 'AssignMB-D17FuncButtonPlusDials',
5060             Mask => 0x0f,
5061             PrintConv => {
5062             0 => 'None',
5063             1 => 'Choose Image Area (DX/1.3x)',
5064             2 => 'Shutter Speed & Aperture Lock',
5065             3 => 'One Step Speed / Aperture',
5066             4 => 'Choose Non-CPU Lens Number',
5067             5 => 'Active D-Lighting',
5068             7 => 'Photo Shooting Menu Bank',
5069             8 => 'Exposure Delay Mode',
5070             10 => 'ISO Sensitivity',
5071             11 => 'Exposure Mode',
5072             12 => 'Exposure Compensation',
5073             13 => 'Metering Mode',
5074             },
5075             },
5076             70.1 => { # CSf1-f
5077             Name => 'AF-OnButton',
5078             Mask => 0x3f,
5079             PrintConv => {
5080             0 => 'None',
5081             3 => 'AE/AF Lock',
5082             4 => 'AE Lock Only',
5083             5 => 'AE Lock (reset on release)',
5084             6 => 'AE Lock (hold)',
5085             7 => 'AF Lock Only',
5086             8 => 'AF-On',
5087             36 => 'AF-Area Mode (Single)',
5088             37 => 'AF-Area Mode (Dynamic Area 25 Points)',
5089             38 => 'AF-Area Mode (Dynamic Area 72 Points)',
5090             39 => 'AF-Area Mode (Dynamic Area 152 Points)',
5091             40 => 'AF-Area Mode (Group Area AF)',
5092             41 => 'AF-Area Mode (Auto Area AF)',
5093             42 => 'AF-Area Mode + AF-On (Single)',
5094             43 => 'AF-Area Mode + AF-On (Dynamic Area 25 Points)',
5095             44 => 'AF-Area Mode + AF-On (Dynamic Area 72 Points)',
5096             45 => 'AF-Area Mode + AF-On (Dynamic Area 152 Points)',
5097             46 => 'AF-Area Mode + AF-On (Group Area AF)',
5098             47 => 'AF-Area Mode + AF-On (Auto Area AF)',
5099             },
5100             },
5101             71.1 => { # CSf1-g
5102             Name => 'SubSelector',
5103             Mask => 0x80,
5104             PrintConv => {
5105             0 => 'Focus Point Selection',
5106             1 => 'Same as MultiSelector',
5107             },
5108             },
5109             72.1 => { # CSf1-h
5110             Name => 'SubSelectorCenter',
5111             Mask => 0x3f,
5112             PrintConv => {
5113             0 => 'None',
5114             1 => 'Preview',
5115             2 => 'FV Lock',
5116             3 => 'AE/AF Lock',
5117             4 => 'AE Lock Only',
5118             5 => 'AE Lock (reset on release)',
5119             6 => 'AE Lock (hold)',
5120             7 => 'AF Lock Only',
5121             8 => 'AF-On',
5122             10 => 'Bracketing Burst',
5123             11 => 'Matrix Metering',
5124             12 => 'Center-weighted Metering',
5125             13 => 'Spot Metering',
5126             14 => 'Playback',
5127             15 => 'My Menu Top Item',
5128             16 => '+NEF(RAW)',
5129             17 => 'Virtual Horizon',
5130             18 => 'Reset Focus Point',
5131             19 => 'Grid Display',
5132             20 => 'My Menu',
5133             22 => 'Remote Release Only',
5134             23 => 'Preset Focus Point',
5135             26 => 'Flash Disable/Enable',
5136             27 => 'Highlight-weighted Metering',
5137             36 => 'AF-Area Mode (Single)',
5138             37 => 'AF-Area Mode (Dynamic Area 25 Points)',
5139             38 => 'AF-Area Mode (Dynamic Area 72 Points)',
5140             39 => 'AF-Area Mode (Dynamic Area 152 Points)',
5141             40 => 'AF-Area Mode (Group Area AF)',
5142             41 => 'AF-Area Mode (Auto Area AF)',
5143             42 => 'AF-Area Mode + AF-On (Single)',
5144             43 => 'AF-Area Mode + AF-On (Dynamic Area 25 Points)',
5145             44 => 'AF-Area Mode + AF-On (Dynamic Area 72 Points)',
5146             45 => 'AF-Area Mode + AF-On (Dynamic Area 152 Points)',
5147             46 => 'AF-Area Mode + AF-On (Group Area AF)',
5148             47 => 'AF-Area Mode + AF-On (Auto Area AF)',
5149             49 => 'Sync Release (Master Only)',
5150             50 => 'Sync Release (Remote Only)',
5151             54 => 'Highlight Active Focus Point',
5152             },
5153             },
5154             73.1 => { # CSf1-i
5155             Name => 'SubSelectorPlusDials',
5156             Mask => 0x0f,
5157             PrintConv => {
5158             0 => 'None',
5159             1 => 'Choose Image Area (DX/1.3x)',
5160             2 => 'Shutter Speed & Aperture Lock',
5161             4 => 'Choose Non-CPU Lens Number',
5162             7 => 'Photo Shooting Menu Bank',
5163             },
5164             },
5165             74.1 => { # CSg1-f
5166             Name => 'AssignMovieSubselector',
5167             Mask => 0xf0,
5168             PrintConv => {
5169             0 => 'None',
5170             3 => 'Index Marking',
5171             4 => 'View Photo Shooting Info',
5172             5 => 'AE/AF Lock',
5173             6 => 'AE Lock (Only)',
5174             7 => 'AE Lock (Hold)',
5175             8 => 'AF Lock (Only)',
5176             },
5177             },
5178             75.1 => { # CSg1-d
5179             Name => 'AssignMovieFunc1ButtonPlusDials',
5180             Mask => 0x10,
5181             PrintConv => {
5182             0 => 'None',
5183             1 => 'Choose Image Area (DX/1.3x)',
5184             },
5185             },
5186             75.2 => { # CSg1-b
5187             Name => 'AssignMoviePreviewButtonPlusDials',
5188             Mask => 0x01,
5189             PrintConv => {
5190             0 => 'None',
5191             1 => 'Choose Image Area (DX/1.3x)',
5192             },
5193             },
5194             76.1 => { # CSg1-g
5195             Name => 'AssignMovieSubselectorPlusDials',
5196             Mask => 0x10,
5197             PrintConv => {
5198             0 => 'None',
5199             1 => 'Choose Image Area (DX/1.3x)',
5200             },
5201             },
5202             77.1 => { # CSd4
5203             Name => 'SyncReleaseMode', # new with D500
5204             Mask => 0x80,
5205             PrintConv => {
5206             0 => 'No Sync',
5207             1 => 'Sync',
5208             },
5209             },
5210             78.1 => { # CSa5
5211             Name => 'Three-DTrackingWatchArea', # new with D500
5212             Mask => 0x80,
5213             PrintConv => {
5214             0 => 'Wide',
5215             1 => 'Normal',
5216             },
5217             },
5218             78.2 => { # CSa3-b
5219             Name => 'SubjectMotion',
5220             Mask => 0x60,
5221             PrintConv => {
5222             0 => 'Steady',
5223             1 => 'Middle',
5224             2 => 'Erratic',
5225             },
5226             },
5227             78.3 => { # CSa8
5228             Name => 'AFActivation',
5229             Mask => 0x08,
5230             PrintConv => {
5231             0 => 'Shutter/AF-On',
5232             1 => 'AF-On Only',
5233             },
5234             },
5235             78.4 => { # CSc1
5236             Name => 'ShutterReleaseButtonAE-L',
5237             Mask => 0x03,
5238             PrintConv => {
5239             0 => 'Off',
5240             1 => 'On (Half Press)',
5241             2 => 'On (Burst Mode)'
5242             },
5243             },
5244             79.1 => { # CSf10-c
5245             Name => 'AssignMB-D17AF-OnButton',
5246             Mask => 0x7f,
5247             PrintConv => {
5248             0 => 'None',
5249             3 => 'AE/AF Lock',
5250             4 => 'AE Lock Only',
5251             5 => 'AE Lock (reset on release)',
5252             6 => 'AE Lock (hold)',
5253             7 => 'AF Lock Only',
5254             8 => 'AF-On',
5255             36 => 'AF-Area Mode (Single)',
5256             37 => 'AF-Area Mode (Dynamic Area 25 Points)',
5257             38 => 'AF-Area Mode (Dynamic Area 72 Points)',
5258             39 => 'AF-Area Mode (Dynamic Area 152 Points)',
5259             40 => 'AF-Area Mode (Group Area AF)',
5260             41 => 'AF-Area Mode (Auto Area AF)',
5261             42 => 'AF-Area Mode + AF-On (Single)',
5262             43 => 'AF-Area Mode + AF-On (Dynamic Area 25 Points)',
5263             44 => 'AF-Area Mode + AF-On (Dynamic Area 72 Points)',
5264             45 => 'AF-Area Mode + AF-On (Dynamic Area 152 Points)',
5265             46 => 'AF-Area Mode + AF-On (Group Area AF)',
5266             47 => 'AF-Area Mode + AF-On (Auto Area AF)',
5267             100 => 'Same as Camera AF-On Button',
5268             },
5269             },
5270             80.1 => { # CSf1-e
5271             Name => 'Func2Button',
5272             Mask => 0x3f,
5273             PrintConv => {
5274             0 => 'None',
5275             15 => 'My Menu Top Item',
5276             20 => 'My Menu',
5277             55 => 'Rating',
5278             },
5279             },
5280             82.1 => { # CSg1-e
5281             Name => 'AssignMovieFunc2Button',
5282             Mask => 0x70,
5283             PrintConv => {
5284             0 => 'None',
5285             3 => 'Index Marking',
5286             4 => 'View Photo Shooting Info',
5287             },
5288             },
5289             );
5290              
5291             # D610 custom settings (ref forum6942)
5292             %Image::ExifTool::NikonCustom::SettingsD610 = (
5293             PROCESS_PROC => \&Image::ExifTool::ProcessBinaryData,
5294             WRITE_PROC => \&Image::ExifTool::WriteBinaryData,
5295             CHECK_PROC => \&Image::ExifTool::CheckBinaryData,
5296             WRITABLE => 1,
5297             FIRST_ENTRY => 0,
5298             GROUPS => { 0 => 'MakerNotes', 2 => 'Camera' },
5299             NOTES => 'Custom settings for the D610.',
5300             0.1 => { #CSa1
5301             Name => 'AF-CPrioritySelection',
5302             Mask => 0x80,
5303             PrintConv => {
5304             0 => 'Release',
5305             1 => 'Focus',
5306             },
5307             },
5308             0.2 => { #CSa2
5309             Name => 'AF-SPrioritySelection',
5310             Mask => 0x20,
5311             PrintConv => {
5312             0 => 'Release',
5313             1 => 'Focus',
5314             },
5315             },
5316             0.3 => { # CSa6
5317             Name => 'NumberOfFocusPoints',
5318             Mask => 0x10,
5319             PrintConv => {
5320             0 => '39 Points',
5321             1 => '11 Points',
5322             },
5323             },
5324             0.4 => { # CSa3
5325             Name => 'FocusTrackingLockOn',
5326             Mask => 0x07,
5327             PrintConv => {
5328             0 => 'Off',
5329             1 => '1 Short',
5330             2 => '2',
5331             3 => '3 Normal',
5332             4 => '4',
5333             5 => '5 Long',
5334             },
5335             },
5336             1.1 => { # CSa5
5337             Name => 'FocusPointWrap',
5338             Mask => 0x08,
5339             PrintConv => {
5340             0 => 'No Wrap',
5341             1 => 'Wrap',
5342             },
5343             },
5344             1.2 => { # CSa4
5345             Name => 'AFPointIllumination',
5346             Mask => 0x06,
5347             PrintConv => {
5348             0 => 'Auto',
5349             1 => 'On',
5350             2 => 'Off',
5351             },
5352             },
5353             1.3 => { # CSa7
5354             Name => 'AFAssist',
5355             Mask => 0x01,
5356             PrintConv => \%onOff,
5357             },
5358             5.1 => { # CSb3
5359             Name => 'EasyExposureCompensation',
5360             Mask => 0x03,
5361             PrintConv => {
5362             0 => 'Off',
5363             1 => 'On',
5364             2 => 'On Auto Reset',
5365             },
5366             },
5367             6.1 => { # CSb2
5368             Name => 'ExposureControlStep',
5369             Mask => 0x40,
5370             PrintConv => {
5371             0 => '1/3 EV',
5372             1 => '1/2 EV',
5373             },
5374             },
5375             6.2 => { # CSb1
5376             Name => 'ISOSensitivityStep',
5377             Mask => 0x10,
5378             PrintConv => {
5379             0 => '1/3 EV',
5380             1 => '1/2 EV',
5381             },
5382             },
5383             7.1 => { # CSb4
5384             Name => 'CenterWeightedAreaSize',
5385             Mask => 0xe0,
5386             PrintConv => {
5387             0 => '8 mm',
5388             1 => '12 mm',
5389             2 => '15 mm',
5390             3 => '20 mm',
5391             4 => 'Average',
5392             },
5393             },
5394             7.2 => { # CSb5-a
5395             Name => 'FineTuneOptMatrixMetering',
5396             Mask => 0x0f,
5397             ValueConv => '($val > 0x7 ? $val - 0x10 : $val) / 6',
5398             ValueConvInv => 'int($val*6+($val>0?0.5:-0.5))',
5399             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
5400             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
5401             },
5402             8.1 => { # CSb5-b
5403             Name => 'FineTuneOptCenterWeighted',
5404             Mask => 0xf0,
5405             ValueConv => '($val > 0x7 ? $val - 0x10 : $val) / 6',
5406             ValueConvInv => 'int($val*6+($val>0?0.5:-0.5))',
5407             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
5408             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
5409             },
5410             8.2 => { # CSb5-c
5411             Name => 'FineTuneOptSpotMetering',
5412             Mask => 0x0f,
5413             ValueConv => '($val > 0x7 ? $val - 0x10 : $val) / 6',
5414             ValueConvInv => 'int($val*6+($val>0?0.5:-0.5))',
5415             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
5416             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
5417             },
5418             17.1 => { # CSc1
5419             Name => 'ShutterReleaseButtonAE-L',
5420             Mask => 0x02,
5421             PrintConv => \%offOn,
5422             },
5423             18.1 => { # CSc2
5424             Name => 'StandbyTimer',
5425             Mask => 0xf0,
5426             PrintConv => {
5427             0 => '4 s',
5428             1 => '6 s',
5429             2 => '10 s',
5430             3 => '30 s',
5431             4 => '1 min',
5432             5 => '5 min',
5433             6 => '10 min',
5434             7 => '30 min',
5435             8 => 'No Limit',
5436             },
5437             },
5438             18.2 => { # CSc5
5439             Name => 'RemoteOnDuration',
5440             Mask => 0x03,
5441             PrintConv => {
5442             0 => '1 min',
5443             1 => '5 min',
5444             2 => '10 min',
5445             3 => '20 min',
5446             },
5447             },
5448             19.1 => { # CSc3-a
5449             Name => 'SelfTimerTime',
5450             Mask => 0xc0,
5451             PrintConv => {
5452             0 => '2 s',
5453             1 => '5 s',
5454             2 => '10 s',
5455             3 => '20 s',
5456             },
5457             },
5458             19.2 => { # CSc3-c
5459             Name => 'SelfTimerShotInterval',
5460             Mask => 0x30,
5461             PrintConv => {
5462             0 => '0.5 s',
5463             1 => '1 s',
5464             2 => '2 s',
5465             3 => '3 s',
5466             },
5467             },
5468             19.3 => { # CSc3-b
5469             Name => 'SelfTimerShotCount',
5470             Mask => 0x0f,
5471             },
5472             20.1 => { # CSc4-d
5473             Name => 'ImageReviewMonitorOffTime',
5474             Mask => 0xe0,
5475             PrintConv => {
5476             0 => '2 s',
5477             1 => '4 s',
5478             2 => '10 s',
5479             3 => '20 s',
5480             4 => '1 min',
5481             5 => '5 min',
5482             6 => '10 min',
5483             },
5484             },
5485             20.2 => { # CSc4-e
5486             Name => 'LiveViewMonitorOffTime',
5487             Mask => 0x1c,
5488             PrintConv => {
5489             0 => '5 min',
5490             1 => '10 min',
5491             2 => '15 min',
5492             3 => '20 min',
5493             4 => '30 min',
5494             5 => 'No Limit',
5495             },
5496             },
5497             21.1 => { # CSc4-b
5498             Name => 'MenuMonitorOffTime',
5499             Mask => 0xe0,
5500             PrintConv => {
5501             0 => '4 s',
5502             1 => '10 s',
5503             2 => '20 s', # default
5504             3 => '1 min',
5505             4 => '5 min',
5506             5 => '10 min',
5507             },
5508             },
5509             21.2 => { # CSc4-c
5510             Name => 'ShootingInfoMonitorOffTime',
5511             Mask => 0x1c,
5512             PrintConv => {
5513             0 => '4 s',
5514             1 => '10 s', # default
5515             2 => '20 s',
5516             3 => '1 min',
5517             4 => '5 min',
5518             5 => '10 min',
5519             },
5520             },
5521             35.1 => { # CSc4-a
5522             Name => 'PlaybackMonitorOffTime',
5523             Mask => 0xe0,
5524             PrintConv => {
5525             0 => '4 s',
5526             1 => '10 s',
5527             2 => '20 s',
5528             3 => '1 min',
5529             4 => '5 min',
5530             5 => '10 min',
5531             },
5532             },
5533             );
5534              
5535             # D810 custom settings (ref 1)
5536             %Image::ExifTool::NikonCustom::SettingsD810 = (
5537             PROCESS_PROC => \&Image::ExifTool::ProcessBinaryData,
5538             WRITE_PROC => \&Image::ExifTool::WriteBinaryData,
5539             CHECK_PROC => \&Image::ExifTool::CheckBinaryData,
5540             WRITABLE => 1,
5541             FIRST_ENTRY => 0,
5542             DATAMEMBER => [ 24.1 ],
5543             GROUPS => { 0 => 'MakerNotes', 2 => 'Camera' },
5544             NOTES => 'Custom settings for the D810.',
5545             0.1 => { # CSf1
5546             Name => 'LightSwitch',
5547             Mask => 0x08,
5548             PrintConv => {
5549             0 => 'LCD Backlight',
5550             1 => 'LCD Backlight and Shooting Information',
5551             },
5552             },
5553             0.2 => {
5554             Name => 'CustomSettingsBank',
5555             Mask => 0x03,
5556             PrintConv => {
5557             0 => 'A',
5558             1 => 'B',
5559             2 => 'C',
5560             3 => 'D',
5561             },
5562             },
5563             1.1 => { #CSa1
5564             Name => 'AF-CPrioritySelection',
5565             Mask => 0xc0,
5566             PrintConv => {
5567             0 => 'Release',
5568             1 => 'Release + Focus',
5569             2 => 'Focus',
5570             },
5571             },
5572             1.2 => { # CSa2
5573             Name => 'AF-SPrioritySelection',
5574             Mask => 0x20,
5575             PrintConv => {
5576             0 => 'Focus',
5577             1 => 'Release',
5578             },
5579             },
5580             1.3 => { # CSa7
5581             Name => 'AFPointSelection',
5582             Mask => 0x10,
5583             PrintConv => {
5584             0 => '51 Points',
5585             1 => '11 Points',
5586             },
5587             },
5588             1.4 => { # CSa3
5589             Name => 'FocusTrackingLockOn',
5590             Mask => 0x07,
5591             PrintConv => {
5592             0 => 'Off',
5593             1 => '1 (Short)',
5594             2 => '2',
5595             3 => '3 (Normal)',
5596             4 => '4',
5597             5 => '5 (Long)',
5598             },
5599             },
5600             2.1 => { # CSa4
5601             Name => 'AFActivation',
5602             Mask => 0x80,
5603             PrintConv => {
5604             0 => 'Shutter/AF-On',
5605             1 => 'AF-On Only',
5606             },
5607             },
5608             2.2 => { # CSa7
5609             Name => 'FocusPointWrap',
5610             Mask => 0x08,
5611             PrintConv => {
5612             0 => 'No Wrap',
5613             1 => 'Wrap',
5614             },
5615             },
5616             2.3 => { # CSa6
5617             Name => 'AFPointBrightness',
5618             Mask => 0x06,
5619             PrintConv => {
5620             0 => 'Auto',
5621             1 => 'On',
5622             2 => 'Off',
5623             },
5624             },
5625             2.4 => { # CSa10
5626             Name => 'AFAssist',
5627             Mask => 0x01,
5628             PrintConv => \%onOff,
5629             },
5630             3.1 => { # CSd13
5631             Name => 'BatteryOrder',
5632             Mask => 0x40,
5633             PrintConv => {
5634             0 => 'MB-D12 First',
5635             1 => 'Camera Battery First',
5636             },
5637             },
5638             3.2 => { # CSd12
5639             Name => 'MB-D12BatteryType',
5640             Mask => 0x03,
5641             PrintConv => {
5642             0 => 'LR6 (AA alkaline)',
5643             1 => 'HR6 (AA Ni-MH)',
5644             2 => 'FR6 (AA lithium)',
5645             },
5646             },
5647             4.1 => { # CSd1-b
5648             Name => 'Pitch',
5649             Mask => 0x40,
5650             PrintConv => { 0 => 'High', 1 => 'Low' },
5651             },
5652             4.2 => { # CSf11
5653             Name => 'NoMemoryCard',
5654             Mask => 0x20,
5655             PrintConv => {
5656             0 => 'Release Locked',
5657             1 => 'Enable Release',
5658             },
5659             },
5660             4.3 => { # CSd8
5661             Name => 'ISODisplay',
5662             Mask => 0x0c,
5663             PrintConv => {
5664             0 => 'Show ISO/Easy ISO',
5665             1 => 'Show ISO Sensitivity',
5666             3 => 'Show Frame Count',
5667             },
5668             },
5669             4.4 => { # CSd7
5670             Name => 'GridDisplay',
5671             Mask => 0x02,
5672             PrintConv => \%onOff,
5673             },
5674             5.1 => { # CSd10
5675             Name => 'ShootingInfoDisplay',
5676             Mask => 0xc0,
5677             PrintConv => {
5678             0 => 'Not Set', # observed on a new camera prior to applying a setting for the first time
5679             1 => 'Auto',
5680             2 => 'Manual (dark on light)',
5681             3 => 'Manual (light on dark)',
5682             },
5683             },
5684             5.2 => { # CSd11
5685             Name => 'LCDIllumination',
5686             Mask => 0x20,
5687             PrintConv => \%offOn,
5688             },
5689             5.3 => { # CSd5
5690             Name => 'ElectronicFront-CurtainShutter',
5691             Mask => 0x08,
5692             PrintConv => \%offOn,
5693             },
5694             5.4 => { # CSd9
5695             Name => 'ScreenTips',
5696             Mask => 0x04,
5697             PrintConv => \%offOn,
5698             },
5699             5.5 => { # CSd1-a
5700             Name => 'Beep',
5701             Mask => 0x03,
5702             PrintConv => {
5703             0 => 'Off',
5704             1 => 'Low',
5705             2 => 'Medium',
5706             3 => 'High',
5707             },
5708             },
5709             6.1 => { # CSf12
5710             Name => 'ReverseIndicators',
5711             Mask => 0x80,
5712             PrintConv => {
5713             0 => '+ 0 -',
5714             1 => '- 0 +',
5715             },
5716             },
5717             6.2 => { # CSf9-a
5718             Name => 'CommandDialsReverseRotation',
5719             Mask => 0x18,
5720             PrintConv => {
5721             0 => 'No',
5722             1 => 'Shutter Speed & Aperture',
5723             2 => 'Exposure Compensation',
5724             3 => 'Exposure Compensation, Shutter Speed & Aperture',
5725             },
5726             },
5727             6.3 => { # CSb4
5728             Name => 'EasyExposureCompensation',
5729             Mask => 0x03,
5730             PrintConv => {
5731             0 => 'Off',
5732             1 => 'On',
5733             2 => 'On (auto reset)',
5734             },
5735             },
5736             7.1 => { # CSb2
5737             Name => 'ExposureControlStepSize',
5738             Mask => 0xc0,
5739             PrintConv => {
5740             0 => '1/3 EV',
5741             1 => '1/2 EV',
5742             2 => '1 EV',
5743             },
5744             },
5745             7.2 => { # CSb1
5746             Name => 'ISOStepSize',
5747             Mask => 0x30,
5748             PrintConv => {
5749             0 => '1/3 EV',
5750             1 => '1/2 EV',
5751             2 => '1 EV',
5752             },
5753             },
5754             7.3 => { # CSb3
5755             Name => 'ExposureCompStepSize',
5756             Mask => 0x0c,
5757             PrintConv => {
5758             0 => '1/3 EV',
5759             1 => '1/2 EV',
5760             2 => '1 EV',
5761             },
5762             },
5763             8.1 => { # CSb6
5764             Name => 'CenterWeightedAreaSize',
5765             Mask => 0xe0,
5766             PrintConv => {
5767             0 => '8 mm',
5768             1 => '12 mm',
5769             2 => '15 mm',
5770             3 => '20 mm',
5771             4 => 'Average',
5772             },
5773             },
5774             8.2 => { # CSb7-a
5775             Name => 'FineTuneOptMatrixMetering',
5776             Mask => 0x0f,
5777             ValueConv => '($val > 0x7 ? $val - 0x10 : $val) / 6',
5778             ValueConvInv => 'int($val*6+($val>0?0.5:-0.5))',
5779             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
5780             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
5781             },
5782             9.1 => { # CSb7-b
5783             Name => 'FineTuneOptCenterWeighted',
5784             Mask => 0xf0,
5785             ValueConv => '($val > 0x7 ? $val - 0x10 : $val) / 6',
5786             ValueConvInv => 'int($val*6+($val>0?0.5:-0.5))',
5787             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
5788             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
5789             },
5790             9.2 => { # CSb7-c
5791             Name => 'FineTuneOptSpotMetering',
5792             Mask => 0x0f,
5793             ValueConv => '($val > 0x7 ? $val - 0x10 : $val) / 6',
5794             ValueConvInv => 'int($val*6+($val>0?0.5:-0.5))',
5795             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
5796             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
5797             },
5798             10.1 => { # CSf2-a
5799             Name => 'MultiSelectorShootMode',
5800             Mask => 0xc0,
5801             PrintConv => {
5802             0 => 'Select Center Focus Point (Reset)',
5803             1 => 'Highlight Active Focus Point',
5804             2 => 'Preset Focus Point (Pre)',
5805             3 => 'Not Used (None)',
5806             },
5807             },
5808             10.2 => { # CSf2-b
5809             Name => 'MultiSelectorPlaybackMode',
5810             Mask => 0x30,
5811             PrintConv => {
5812             0 => 'Thumbnail On/Off',
5813             1 => 'View Histograms',
5814             2 => 'Zoom On/Off',
5815             3 => 'Choose Folder',
5816             },
5817             },
5818             10.3 => { # CSf3
5819             Name => 'MultiSelector',
5820             Mask => 0x01,
5821             PrintConv => {
5822             0 => 'Do Nothing',
5823             1 => 'Reset Meter-off Delay',
5824             },
5825             },
5826             11.1 => { # CSd4
5827             Name => 'ExposureDelayMode',
5828             Mask => 0xc0,
5829             PrintConv => {
5830             0 => 'Off',
5831             1 => '1 s',
5832             2 => '2 s',
5833             3 => '3 s',
5834             },
5835             },
5836             11.2 => { # CSd2
5837             Name => 'CLModeShootingSpeed',
5838             Mask => 0x0f,
5839             PrintConv => '"$val fps"',
5840             PrintConvInv => '$val=~s/\s*fps//i; $val',
5841             },
5842             12.1 => { # CSd3
5843             Name => 'MaxContinuousRelease',
5844             # values: 1-100
5845             },
5846             13.1 => { # CSe6
5847             Name => 'AutoBracketSet',
5848             Mask => 0xe0,
5849             PrintConv => {
5850             0 => 'AE & Flash',
5851             1 => 'AE Only',
5852             2 => 'Flash Only',
5853             3 => 'WB Bracketing',
5854             4 => 'Active D-Lighting',
5855             },
5856             },
5857             13.2 => { # CSe8
5858             Name => 'AutoBracketOrder',
5859             Mask => 0x10,
5860             PrintConv => {
5861             0 => '0,-,+',
5862             1 => '-,0,+',
5863             },
5864             },
5865             13.3 => { # CSe7
5866             Name => 'AutoBracketModeM',
5867             Mask => 0x0c,
5868             PrintConv => {
5869             0 => 'Flash/Speed',
5870             1 => 'Flash/Speed/Aperture',
5871             2 => 'Flash/Aperture',
5872             3 => 'Flash Only',
5873             },
5874             },
5875             14.1 => { # CSf4-a
5876             Name => 'FuncButton',
5877             Mask => 0x1f,
5878             PrintConv => {
5879             0 => 'None',
5880             1 => 'Preview',
5881             2 => 'FV Lock',
5882             3 => 'AE/AF Lock',
5883             4 => 'AE Lock Only',
5884             5 => 'AE Lock (reset on release)',
5885             6 => 'AE Lock (hold)',
5886             7 => 'AF Lock Only',
5887             8 => 'AF-On',
5888             10 => 'Bracketing Burst',
5889             11 => 'Matrix Metering',
5890             12 => 'Center-weighted Metering',
5891             13 => 'Spot Metering',
5892             14 => 'Playback',
5893             15 => 'My Menu Top Item',
5894             16 => '+NEF(RAW)',
5895             17 => 'Virtual Horizon',
5896             19 => 'Grid Display', # values 19 and 20 are swapped from the D4s encodings
5897             20 => 'My Menu',
5898             21 => 'Disable Synchronized Release',
5899             22 => 'Remote Release Only',
5900             26 => 'Flash Disable/Enable',
5901             27 => 'Highlight-weighted Metering', # new value with D810
5902             },
5903             },
5904             15.1 => { # CSf5-a
5905             Name => 'PreviewButton',
5906             Mask => 0x1f,
5907             PrintConv => {
5908             0 => 'None',
5909             1 => 'Preview',
5910             2 => 'FV Lock',
5911             3 => 'AE/AF Lock',
5912             4 => 'AE Lock Only',
5913             5 => 'AE Lock (reset on release)',
5914             6 => 'AE Lock (hold)',
5915             7 => 'AF Lock Only',
5916             8 => 'AF-On',
5917             10 => 'Bracketing Burst',
5918             11 => 'Matrix Metering',
5919             12 => 'Center-weighted Metering',
5920             13 => 'Spot Metering',
5921             14 => 'Playback',
5922             15 => 'My Menu Top Item',
5923             16 => '+NEF(RAW)',
5924             17 => 'Virtual Horizon',
5925             19 => 'Grid Display', # values 19 and 20 are swapped from the D4s encodings
5926             20 => 'My Menu',
5927             21 => 'Disable Synchronized Release',
5928             22 => 'Remote Release Only',
5929             26 => 'Flash Disable/Enable',
5930             27 => 'Highlight-weighted Metering', # new value with D810
5931             },
5932             },
5933             16.1 => { # CSf8
5934             Name => 'AssignBktButton',
5935             Mask => 0x07,
5936             PrintConv => {
5937             0 => 'Auto Bracketing',
5938             1 => 'Multiple Exposure',
5939             2 => 'HDR (high dynamic range)',
5940             3 => 'None',
5941             },
5942             },
5943             17.1 => { # CSf6-a
5944             Name => 'AELockButton',
5945             Mask => 0x1f,
5946             PrintConv => {
5947             0 => 'None',
5948             1 => 'Preview',
5949             2 => 'FV Lock',
5950             3 => 'AE/AF Lock',
5951             4 => 'AE Lock Only',
5952             5 => 'AE Lock (reset on release)',
5953             6 => 'AE Lock (hold)',
5954             7 => 'AF Lock Only',
5955             8 => 'AF-On',
5956             10 => 'Bracketing Burst',
5957             11 => 'Matrix Metering',
5958             12 => 'Center-weighted Metering',
5959             13 => 'Spot Metering',
5960             14 => 'Playback',
5961             15 => 'My Menu Top Item',
5962             16 => '+NEF(RAW)',
5963             17 => 'Virtual Horizon',
5964             19 => 'Grid Display', # values 19 and 20 are swapped from the D4s encodings
5965             20 => 'My Menu',
5966             21 => 'Disable Synchronized Release',
5967             22 => 'Remote Release Only',
5968             26 => 'Flash Disable/Enable',
5969             27 => 'Highlight-weighted Metering', # new value with D810
5970             },
5971             },
5972             18.1 => { # CSf9-b
5973             Name => 'CommandDialsChangeMainSub',
5974             Mask => 0xe0,
5975             PrintConv => {
5976             0 => 'Autofocus Off, Exposure Off',
5977             1 => 'Autofocus Off, Exposure On',
5978             2 => 'Autofocus Off, Exposure On (Mode A)',
5979             4 => 'Autofocus On, Exposure Off',
5980             5 => 'Autofocus On, Exposure On',
5981             6 => 'Autofocus On, Exposure On (Mode A)',
5982             },
5983             },
5984             18.2 => { # CSf9-d
5985             Name => 'CommandDialsMenuAndPlayback',
5986             Mask => 0x18,
5987             PrintConv => {
5988             0 => 'On',
5989             1 => 'Off',
5990             2 => 'On (Image Review Excluded)',
5991             },
5992             },
5993             18.3 => { # CSf9-c
5994             Name => 'CommandDialsApertureSetting',
5995             Mask => 0x04,
5996             PrintConv => {
5997             0 => 'Sub-command Dial',
5998             1 => 'Aperture Ring',
5999             },
6000             },
6001             18.4 => { # CSc1
6002             Name => 'ShutterReleaseButtonAE-L',
6003             Mask => 0x02,
6004             PrintConv => \%offOn,
6005             },
6006             18.5 => { # CSf10
6007             Name => 'ReleaseButtonToUseDial',
6008             Mask => 0x01,
6009             PrintConv => \%noYes,
6010             },
6011             19.1 => { # CSc2
6012             Name => 'StandbyTimer',
6013             Mask => 0xf0,
6014             PrintConv => {
6015             0 => '4 s',
6016             1 => '6 s',
6017             3 => '10 s',
6018             5 => '30 s',
6019             6 => '1 min',
6020             7 => '5 min',
6021             8 => '10 min',
6022             9 => '30 min',
6023             10 => 'No Limit', #1
6024             },
6025             },
6026             20.1 => { # CSc3-a
6027             Name => 'SelfTimerTime',
6028             Mask => 0xc0,
6029             PrintConv => {
6030             0 => '2 s',
6031             1 => '5 s',
6032             2 => '10 s',
6033             3 => '20 s',
6034             },
6035             },
6036             20.2 => { # CSc3-c
6037             Name => 'SelfTimerShotInterval',
6038             Mask => 0x30,
6039             PrintConv => {
6040             0 => '0.5 s',
6041             1 => '1 s',
6042             2 => '2 s',
6043             3 => '3 s',
6044             },
6045             },
6046             20.3 => { # CSc3-b
6047             Name => 'SelfTimerShotCount',
6048             Mask => 0x0f,
6049             },
6050             21.1 => { # CSc4-d
6051             Name => 'ImageReviewMonitorOffTime', # note: decode changed from D4s
6052             Mask => 0xe0,
6053             PrintConv => {
6054             0 => '2 s',
6055             1 => '4 s',
6056             3 => '10 s',
6057             4 => '20 s',
6058             5 => '1 min',
6059             6 => '5 min',
6060             7 => '10 min',
6061             },
6062             },
6063             21.2 => { # CSc4-e # note: decode changed from D4s
6064             Name => 'LiveViewMonitorOffTime',
6065             Mask => 0x1c,
6066             PrintConv => {
6067             1 => '5 min',
6068             2 => '10 min',
6069             3 => '15 min',
6070             4 => '20 min',
6071             5 => '30 min',
6072             6 => 'No Limit',
6073             },
6074             },
6075             22.1 => { # CSc4-b # note: decode changed from D4s
6076             Name => 'MenuMonitorOffTime',
6077             Mask => 0xe0,
6078             PrintConv => {
6079             0 => '4 s',
6080             2 => '10 s',
6081             4 => '20 s',
6082             5 => '1 min',
6083             6 => '5 min',
6084             7 => '10 min',
6085             },
6086             },
6087             22.2 => { # CSc4-c # note: decode changed from D4s
6088             Name => 'ShootingInfoMonitorOffTime',
6089             Mask => 0x1c,
6090             PrintConv => {
6091             0 => '4 s',
6092             2 => '10 s',
6093             4 => '20 s',
6094             5 => '1 min',
6095             6 => '5 min',
6096             7 => '10 min',
6097             },
6098             },
6099             23.1 => { # CSe1
6100             Name => 'FlashSyncSpeed',
6101             Mask => 0xf0,
6102             PrintConv => {
6103             0 => '1/320 s (auto FP)',
6104             2 => '1/250 s (auto FP)',
6105             3 => '1/250 s',
6106             5 => '1/200 s',
6107             6 => '1/160 s',
6108             7 => '1/125 s',
6109             8 => '1/100 s',
6110             9 => '1/80 s',
6111             10 => '1/60 s',
6112             },
6113             },
6114             23.2 => { # CSe2
6115             Name => 'FlashShutterSpeed',
6116             Mask => 0x0f,
6117             PrintConvColumns => 2,
6118             PrintConv => {
6119             0 => '1/60 s',
6120             1 => '1/30 s',
6121             2 => '1/15 s',
6122             3 => '1/8 s',
6123             4 => '1/4 s',
6124             5 => '1/2 s',
6125             6 => '1 s',
6126             7 => '2 s',
6127             8 => '4 s',
6128             9 => '8 s',
6129             10 => '15 s',
6130             11 => '30 s',
6131             },
6132             },
6133             24.1 => { # CSe3
6134             Name => 'FlashControlBuilt-in',
6135             Mask => 0xc0,
6136             RawConv => '$$self{FlashControlBuiltin} = $val',
6137             PrintConv => {
6138             0 => 'TTL',
6139             1 => 'Manual',
6140             2 => 'Repeating Flash',
6141             3 => 'Commander Mode',
6142             },
6143             },
6144             31.1 => { # CSe5
6145             Name => 'ModelingFlash',
6146             Mask => 0x20,
6147             PrintConv => \%onOff,
6148             },
6149             36.1 => { # CSc4-a
6150             Name => 'PlaybackMonitorOffTime',
6151             Mask => 0xe0,
6152             PrintConv => {
6153             0 => '4 s',
6154             1 => '10 s',
6155             2 => '20 s',
6156             3 => '1 min',
6157             4 => '5 min',
6158             5 => '10 min',
6159             },
6160             },
6161             37.1 => { # CSf2-c
6162             Name => 'MultiSelectorLiveView',
6163             Mask => 0xc0,
6164             PrintConv => {
6165             0 => 'Reset',
6166             1 => 'Zoom',
6167             3 => 'Not Used',
6168             },
6169             },
6170             38.1 => { # CSf7-a
6171             Name => 'ShutterSpeedLock',
6172             Mask => 0x80,
6173             PrintConv => \%offOn,
6174             },
6175             38.2 => { # CSf7-b
6176             Name => 'ApertureLock',
6177             Mask => 0x40,
6178             PrintConv => \%offOn,
6179             },
6180             38.3 => { # CSg4
6181             Name => 'MovieShutterButton',
6182             Mask => 0x20,
6183             PrintConv => {
6184             0 => 'Take Photo',
6185             1 => 'Record Movies',
6186             },
6187             },
6188             38.4 => { # CSe4
6189             Name => 'FlashExposureCompArea',
6190             Mask => 0x04,
6191             PrintConv => {
6192             0 => 'Entire frame',
6193             1 => 'Background only',
6194             },
6195             },
6196             40.1 => { # CSg3
6197             Name => 'MovieAELockButtonAssignment',
6198             Mask => 0x0f,
6199             PrintConv => {
6200             0 => 'None',
6201             3 => 'Index Marking',
6202             4 => 'View Photo Shooting Info',
6203             5 => 'AE/AF Lock',
6204             6 => 'AE Lock Only',
6205             7 => 'AE Lock (hold)',
6206             8 => 'AF Lock Only',
6207             },
6208             },
6209             41.1 => { # CSg1
6210             Name => 'MovieFunctionButton',
6211             Mask => 0x70,
6212             PrintConv => {
6213             0 => 'None',
6214             1 => 'Power Aperture (open)', # bit '02' is also toggled on for this setting
6215             3 => 'Index Marking',
6216             4 => 'View Photo Shooting Info',
6217             },
6218             },
6219             41.2 => { # CSg2
6220             Name => 'MoviePreviewButton',
6221             Mask => 0x07,
6222             PrintConv => {
6223             0 => 'None',
6224             2 => 'Power Aperture (open)', # bit '10' is also toggled on for this setting
6225             3 => 'Index Marking',
6226             4 => 'View Photo Shooting Info',
6227             },
6228             },
6229             42.1 => { # CSf4-b
6230             Name => 'FuncButtonPlusDials',
6231             Mask => 0x0f,
6232             PrintConv => {
6233             0 => 'None',
6234             1 => 'Choose Image Area (FX/DX/5:4)',
6235             2 => 'Shutter Speed & Aperture Lock',
6236             3 => 'One Step Speed / Aperture',
6237             4 => 'Choose Non-CPU Lens Number',
6238             5 => 'Active D-Lighting',
6239             8 => 'Exposure Delay Mode',
6240             },
6241             },
6242             43.1 => { # CSf5-b
6243             Name => 'PreviewButtonPlusDials',
6244             Mask => 0x0f,
6245             PrintConv => {
6246             0 => 'None',
6247             1 => 'Choose Image Area (FX/DX/5:4)',
6248             2 => 'Shutter Speed & Aperture Lock',
6249             3 => 'One Step Speed / Aperture',
6250             4 => 'Choose Non-CPU Lens Number',
6251             5 => 'Active D-Lighting',
6252             8 => 'Exposure Delay Mode',
6253             },
6254             },
6255             44.1 => { # CSf6-b
6256             Name => 'AELockButtonPlusDials',
6257             Mask => 0x0f,
6258             PrintConv => {
6259             0 => 'None',
6260             1 => 'Choose Image Area (FX/DX/5:4)',
6261             2 => 'Shutter Speed & Aperture Lock',
6262             4 => 'Choose Non-CPU Lens Number',
6263             8 => 'Exposure Delay Mode',
6264             },
6265             },
6266             45.1 => { # CSf13
6267             Name => 'AssignMovieRecordButton',
6268             Mask => 0x0f,
6269             PrintConv => {
6270             0 => 'None',
6271             1 => 'Choose Image Area (FX/DX/5:4)',
6272             2 => 'Shutter Speed & Aperture Lock',
6273             9 => 'White Balance',
6274             10 => 'ISO Sensitivity',
6275             },
6276             },
6277             46.1 => { # CSb7-d
6278             Name => 'FineTuneOptHighlightWeighted',
6279             Mask => 0x0f,
6280             ValueConv => '($val > 0x7 ? $val - 0x10 : $val) / 6',
6281             ValueConvInv => 'int($val*6+($val>0?0.5:-0.5))',
6282             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
6283             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
6284             },
6285             47.1 => { # CSa5-b
6286             Name => 'DynamicAreaAFDisplay',
6287             Mask => 0x80,
6288             PrintConv => \%offOn,
6289             },
6290             47.2 => { # CSa5-a # moved with D810
6291             Name => 'AFPointIllumination',
6292             Mask => 0x40,
6293             PrintConv => {
6294             0 => 'Off',
6295             1 => 'On During Manual Focusing',
6296             },
6297             },
6298             47.3 => { # CSa9
6299             Name => 'StoreByOrientation',
6300             Mask => 0x18,
6301             PrintConv => {
6302             0 => 'Off',
6303             1 => 'Focus Point',
6304             2 => 'Focus Point and AF-area mode',
6305             },
6306             },
6307             47.4 => { # CSa5-c
6308             Name => 'GroupAreaAFIllumination',
6309             Mask => 0x04,
6310             PrintConv => {
6311             0 => 'Squares', # moved with D810
6312             1 => 'Dots',
6313             },
6314             },
6315             48.1 => { # CSb5
6316             Name => 'MatrixMetering',
6317             Mask => 0x80,
6318             PrintConv => {
6319             0 => 'Face Detection On',
6320             1 => 'Face Detection Off',
6321             },
6322             },
6323             48.2 => { # CSf14
6324             Name => 'LiveViewButtonOptions',
6325             Mask => 0x30,
6326             PrintConv => {
6327             0 => 'Enable',
6328             2 => 'Disable',
6329             },
6330             },
6331             48.3 => { # CSa12
6332             Name => 'AFModeRestrictions',
6333             Mask => 0x03,
6334             PrintConv => {
6335             0 => 'No Restrictions',
6336             1 => 'AF-C',
6337             2 => 'AF-S',
6338             },
6339             },
6340             49.1 => { # CSa11
6341             Name => 'LimitAFAreaModeSelection',
6342             Mask => 0x7e,
6343             PrintConv => {
6344             0 => 'No Restrictions',
6345             BITMASK => {
6346             0 => 'Auto-area',
6347             1 => 'Group-area',
6348             2 => '3D-tracking',
6349             3 => 'Dynamic area (51 points)',
6350             4 => 'Dynamic area (21 points)',
6351             5 => 'Dynamic area (9 points)',
6352             },
6353             },
6354             },
6355             50.1 => { # CSf15
6356             Name => 'AF-OnForMB-D12',
6357             Mask => 0x07,
6358             PrintConv => {
6359             0 => 'AE/AF Lock',
6360             1 => 'AE Lock Only',
6361             2 => 'AF Lock Only',
6362             3 => 'AE Lock (hold)',
6363             4 => 'AE Lock (reset)',
6364             5 => 'AF-On',
6365             6 => 'FV Lock',
6366             7 => 'Same As Fn Button',
6367             },
6368             },
6369             51.1 => { # CSf16
6370             Name => 'AssignRemoteFnButton',
6371             Mask => 0x1f,
6372             PrintConv => {
6373             0 => 'None',
6374             1 => 'Preview',
6375             2 => 'FV Lock',
6376             3 => 'AE/AF Lock',
6377             4 => 'AE Lock Only',
6378             5 => 'AE Lock (reset on release)',
6379             7 => 'AF Lock Only',
6380             8 => 'AF-On',
6381             16 => '+NEF(RAW)',
6382             25 => 'Live View',
6383             26 => 'Flash Disable/Enable',
6384             },
6385             },
6386             52.1 => { # CSf17
6387             Name => 'LensFocusFunctionButtons',
6388             Mask => 0x3f,
6389             PrintConv => {
6390             3 => 'AE/AF Lock',
6391             4 => 'AE Lock Only',
6392             7 => 'AF Lock Only',
6393             21 => 'Disable Synchronized Release',
6394             22 => 'Remote Release Only',
6395             24 => 'Preset focus Point',
6396             26 => 'Flash Disable/Enable',
6397             32 => 'AF-Area Mode: Single-point AF',
6398             33 => 'AF-Area Mode: Dynamic-area AF (9 points)',
6399             34 => 'AF-Area Mode: Dynamic-area AF (21 points)',
6400             35 => 'AF-Area Mode: Dynamic-area AF (51 points)',
6401             36 => 'AF-Area Mode: Group-area AF',
6402             37 => 'AF-Area Mode: Auto area AF',
6403             },
6404             },
6405             );
6406              
6407             # D850 custom settings (ref 1)
6408             %Image::ExifTool::NikonCustom::SettingsD850 = (
6409             PROCESS_PROC => \&Image::ExifTool::ProcessBinaryData,
6410             WRITE_PROC => \&Image::ExifTool::WriteBinaryData,
6411             CHECK_PROC => \&Image::ExifTool::CheckBinaryData,
6412             WRITABLE => 1,
6413             FIRST_ENTRY => 0,
6414             GROUPS => { 0 => 'MakerNotes', 2 => 'Camera' },
6415             NOTES => 'Custom settings for the D850.',
6416             0.2 => {
6417             Name => 'CustomSettingsBank',
6418             Mask => 0x03,
6419             PrintConv => {
6420             0 => 'A',
6421             1 => 'B',
6422             2 => 'C',
6423             3 => 'D',
6424             },
6425             },
6426             1.1 => { #CSa1
6427             Name => 'AF-CPrioritySelection',
6428             Mask => 0xc0,
6429             PrintConv => {
6430             0 => 'Release',
6431             1 => 'Release + Focus',
6432             2 => 'Focus',
6433             3 => 'Focus + Release',
6434             },
6435             },
6436             1.2 => { # CSa2
6437             Name => 'AF-SPrioritySelection',
6438             Mask => 0x20,
6439             PrintConv => {
6440             0 => 'Focus',
6441             1 => 'Release',
6442             },
6443             },
6444             1.3 => { # CSa6
6445             Name => 'AFPointSelection',
6446             Mask => 0x10,
6447             PrintConv => {
6448             0 => '55 Points',
6449             1 => '15 Points',
6450             },
6451             },
6452             1.4 => { # CSa4
6453             Name => 'Three-DTrackingFaceDetection',
6454             Mask => 0x08,
6455             PrintConv => \%offOn,
6456             },
6457             1.5 => { # CSa3-a
6458             Name => 'BlockShotAFResponse',
6459             Mask => 0x07,
6460             PrintConv => {
6461             1 => '1 (Quick)',
6462             2 => '2',
6463             3 => '3 (Normal)',
6464             4 => '4',
6465             5 => '5 (Delay)',
6466             },
6467             },
6468             2.1 => { # CSa11
6469             Name => 'FocusPointWrap',
6470             Mask => 0x08,
6471             PrintConv => {
6472             0 => 'No Wrap',
6473             1 => 'Wrap',
6474             },
6475             },
6476             2.2 => { # CSa12-a
6477             Name => 'AFPointBrightness',
6478             Mask => 0x06,
6479             PrintConv => {
6480             0 => 'Auto',
6481             1 => 'On',
6482             2 => 'Off',
6483             },
6484             },
6485             4.1 => { # CSd3
6486             Name => 'ISODisplay',
6487             Mask => 0x08,
6488             PrintConv => {
6489             0 => 'Show ISO Sensitivity',
6490             1 => 'Show Frame Count',
6491             },
6492             },
6493             4.2 => { # CSd9
6494             Name => 'GridDisplay',
6495             Mask => 0x02,
6496             PrintConv => \%onOff,
6497             },
6498             5.1 => { # CSd10
6499             Name => 'LCDIllumination',
6500             Mask => 0x20,
6501             PrintConv => \%offOn,
6502             },
6503             5.2 => { # CSd6
6504             Name => 'ElectronicFront-CurtainShutter',
6505             Mask => 0x08,
6506             PrintConv => \%offOn,
6507             },
6508             6.1 => { # CSf7
6509             Name => 'ReverseIndicators',
6510             Mask => 0x80,
6511             PrintConv => {
6512             0 => '+ 0 -',
6513             1 => '- 0 +',
6514             },
6515             },
6516             6.2 => { # CSf4-a
6517             Name => 'CommandDialsReverseRotation',
6518             Mask => 0x18,
6519             PrintConv => {
6520             0 => 'No',
6521             1 => 'Shutter Speed & Aperture',
6522             2 => 'Exposure Compensation',
6523             3 => 'Exposure Compensation, Shutter Speed & Aperture',
6524             },
6525             },
6526             6.3 => { # CSb4
6527             Name => 'EasyExposureCompensation',
6528             Mask => 0x03,
6529             PrintConv => {
6530             0 => 'Off',
6531             1 => 'On',
6532             2 => 'On (Auto Reset)',
6533             },
6534             },
6535             7.1 => { # CSb2
6536             Name => 'ExposureControlStepSize',
6537             Mask => 0xc0,
6538             PrintConv => {
6539             0 => '1/3 EV',
6540             1 => '1/2 EV',
6541             2 => '1 EV',
6542             },
6543             },
6544             7.2 => { # CSb1
6545             Name => 'ISOStepSize',
6546             Mask => 0x30,
6547             PrintConv => {
6548             0 => '1/3 EV',
6549             1 => '1/2 EV',
6550             2 => '1 EV',
6551             },
6552             },
6553             7.3 => { # CSb3
6554             Name => 'ExposureCompStepSize',
6555             Mask => 0x0c,
6556             PrintConv => {
6557             0 => '1/3 EV',
6558             1 => '1/2 EV',
6559             2 => '1 EV',
6560             },
6561             },
6562             8.1 => { # CSb6
6563             Name => 'CenterWeightedAreaSize',
6564             Mask => 0xe0,
6565             PrintConv => {
6566             0 => '8 mm',
6567             1 => '12 mm',
6568             2 => '15 mm',
6569             3 => '20 mm',
6570             4 => 'Average',
6571             },
6572             },
6573             8.2 => { # CSb7-a
6574             Name => 'FineTuneOptMatrixMetering',
6575             Mask => 0x0f,
6576             ValueConv => '($val > 0x7 ? $val - 0x10 : $val) / 6',
6577             ValueConvInv => 'int($val*6+($val>0?0.5:-0.5))',
6578             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
6579             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
6580             },
6581             9.1 => { # CSb7-b
6582             Name => 'FineTuneOptCenterWeighted',
6583             Mask => 0xf0,
6584             ValueConv => '($val > 0x7 ? $val - 0x10 : $val) / 6',
6585             ValueConvInv => 'int($val*6+($val>0?0.5:-0.5))',
6586             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
6587             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
6588             },
6589             9.2 => { # CSb7-c
6590             Name => 'FineTuneOptSpotMetering',
6591             Mask => 0x0f,
6592             ValueConv => '($val > 0x7 ? $val - 0x10 : $val) / 6',
6593             ValueConvInv => 'int($val*6+($val>0?0.5:-0.5))',
6594             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
6595             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
6596             },
6597             10.1 => { # CSf2-a
6598             Name => 'MultiSelectorShootMode',
6599             Mask => 0xe0,
6600             PrintConv => {
6601             0 => 'Select Center Focus Point (Reset)',
6602             2 => 'Preset Focus Point (Pre)',
6603             3 => 'Highlight Active Focus Point',
6604             4 => 'Not Used (None)',
6605             },
6606             },
6607             10.2 => { # CSf2-b
6608             Name => 'MultiSelectorPlaybackMode',
6609             Mask => 0x0c,
6610             PrintConv => {
6611             0 => 'Thumbnail On/Off',
6612             1 => 'View Histograms',
6613             2 => 'Zoom On/Off',
6614             3 => 'Choose Folder',
6615             },
6616             },
6617             10.3 => { # CSf5
6618             Name => 'MultiSelector',
6619             Mask => 0x01,
6620             PrintConv => {
6621             0 => 'Do Nothing',
6622             1 => 'Reset Meter-off Delay',
6623             },
6624             },
6625             11.1 => { # CSd5
6626             Name => 'ExposureDelayMode',
6627             Mask => 0xe0,
6628             PrintConv => {
6629             0 => 'Off',
6630             1 => '0.2 s', #new with the D850
6631             2 => '0.5 s', #new with the D850
6632             3 => '1 s',
6633             4 => '2 s',
6634             5 => '3 s',
6635             },
6636             },
6637             11.2 => { # CSd1
6638             Name => 'CLModeShootingSpeed',
6639             Mask => 0x0f,
6640             PrintConv => '"$val fps"',
6641             PrintConvInv => '$val=~s/\s*fps//i; $val',
6642             },
6643             12.1 => { # CSd2
6644             Name => 'MaxContinuousRelease',
6645             # values: 1-100
6646             },
6647             13.1 => { # CSe7
6648             Name => 'AutoBracketOrder',
6649             Mask => 0x10,
6650             PrintConv => {
6651             0 => '0,-,+',
6652             1 => '-,0,+',
6653             },
6654             },
6655             13.2 => { # CSe6
6656             Name => 'AutoBracketModeM',
6657             Mask => 0x0c,
6658             PrintConv => {
6659             0 => 'Flash/Speed',
6660             1 => 'Flash/Speed/Aperture',
6661             2 => 'Flash/Aperture',
6662             3 => 'Flash Only',
6663             },
6664             },
6665             14.1 => { # CSf1-c
6666             Name => 'Func1Button',
6667             Mask => 0x3f,
6668             PrintConv => {
6669             0 => 'None',
6670             1 => 'Preview',
6671             2 => 'FV Lock',
6672             3 => 'AE/AF Lock',
6673             4 => 'AE Lock Only',
6674             5 => 'AE Lock (reset on release)',
6675             6 => 'AE Lock (hold)',
6676             7 => 'AF Lock Only',
6677             8 => 'AF-On',
6678             10 => 'Bracketing Burst',
6679             11 => 'Matrix Metering',
6680             12 => 'Center-weighted Metering',
6681             13 => 'Spot Metering',
6682             14 => 'Playback',
6683             15 => 'My Menu Top Item',
6684             16 => '+NEF(RAW)',
6685             17 => 'Virtual Horizon',
6686             19 => 'Grid Display',
6687             20 => 'My Menu',
6688             22 => 'Remote Release Only',
6689             26 => 'Flash Disable/Enable',
6690             27 => 'Highlight-weighted Metering',
6691             36 => 'AF-Area Mode (Single)',
6692             37 => 'AF-Area Mode (Dynamic Area 25 Points)',
6693             38 => 'AF-Area Mode (Dynamic Area 72 Points)',
6694             39 => 'AF-Area Mode (Dynamic Area 153 Points)',
6695             40 => 'AF-Area Mode (Group Area AF)',
6696             41 => 'AF-Area Mode (Auto Area AF)',
6697             42 => 'AF-Area Mode + AF-On (Single)',
6698             43 => 'AF-Area Mode + AF-On (Dynamic Area 25 Points)',
6699             44 => 'AF-Area Mode + AF-On (Dynamic Area 72 Points)',
6700             45 => 'AF-Area Mode + AF-On (Dynamic Area 153 Points)',
6701             46 => 'AF-Area Mode + AF-On (Group Area AF)',
6702             47 => 'AF-Area Mode + AF-On (Auto Area AF)',
6703             49 => 'Sync Release (Master Only)',
6704             50 => 'Sync Release (Remote Only)',
6705             56 => 'AF-Area Mode (Dynamic Area 9 Points)',
6706             57 => 'AF-Area Mode + AF-On (Dynamic Area 9 Points)',
6707             },
6708             },
6709             15.1 => { # CSf1-a
6710             Name => 'PreviewButton',
6711             Mask => 0x3f,
6712             PrintConv => {
6713             0 => 'None',
6714             1 => 'Preview',
6715             2 => 'FV Lock',
6716             3 => 'AE/AF Lock',
6717             4 => 'AE Lock Only',
6718             5 => 'AE Lock (reset on release)',
6719             6 => 'AE Lock (hold)',
6720             7 => 'AF Lock Only',
6721             8 => 'AF-On',
6722             10 => 'Bracketing Burst',
6723             11 => 'Matrix Metering',
6724             12 => 'Center-weighted Metering',
6725             13 => 'Spot Metering',
6726             14 => 'Playback',
6727             15 => 'My Menu Top Item',
6728             16 => '+NEF(RAW)',
6729             17 => 'Virtual Horizon',
6730             19 => 'Grid Display',
6731             20 => 'My Menu',
6732             22 => 'Remote Release Only',
6733             26 => 'Flash Disable/Enable',
6734             27 => 'Highlight-weighted Metering',
6735             36 => 'AF-Area Mode (Single)',
6736             37 => 'AF-Area Mode (Dynamic Area 25 Points)',
6737             38 => 'AF-Area Mode (Dynamic Area 72 Points)',
6738             39 => 'AF-Area Mode (Dynamic Area 153 Points)',
6739             40 => 'AF-Area Mode (Group Area AF)',
6740             41 => 'AF-Area Mode (Auto Area AF)',
6741             42 => 'AF-Area Mode + AF-On (Single)',
6742             43 => 'AF-Area Mode + AF-On (Dynamic Area 25 Points)',
6743             44 => 'AF-Area Mode + AF-On (Dynamic Area 72 Points)',
6744             45 => 'AF-Area Mode + AF-On (Dynamic Area 153 Points)',
6745             46 => 'AF-Area Mode + AF-On (Group Area AF)',
6746             47 => 'AF-Area Mode + AF-On (Auto Area AF)',
6747             49 => 'Sync Release (Master Only)',
6748             50 => 'Sync Release (Remote Only)',
6749             56 => 'AF-Area Mode (Dynamic Area 9 Points)',
6750             57 => 'AF-Area Mode + AF-On (Dynamic Area 9 Points)',
6751             },
6752             },
6753             16.1 => { # CSf1-j
6754             Name => 'AssignBktButton',
6755             Mask => 0x07,
6756             PrintConv => {
6757             0 => 'Auto Bracketing',
6758             1 => 'Multiple Exposure',
6759             2 => 'HDR (high dynamic range)',
6760             3 => 'None',
6761             },
6762             },
6763             18.1 => { # CSf4-b
6764             Name => 'CommandDialsChangeMainSub',
6765             Mask => 0xe0,
6766             PrintConv => {
6767             0 => 'Autofocus Off, Exposure Off',
6768             1 => 'Autofocus Off, Exposure On',
6769             2 => 'Autofocus Off, Exposure On (Mode A)',
6770             4 => 'Autofocus On, Exposure Off',
6771             5 => 'Autofocus On, Exposure On',
6772             6 => 'Autofocus On, Exposure On (Mode A)',
6773             },
6774             },
6775             18.2 => { # CSf4-d
6776             Name => 'CommandDialsMenuAndPlayback',
6777             Mask => 0x18,
6778             PrintConv => {
6779             0 => 'On',
6780             1 => 'Off',
6781             2 => 'On (Image Review Excluded)',
6782             },
6783             },
6784             18.3 => { # CSf4-c
6785             Name => 'CommandDialsApertureSetting',
6786             Mask => 0x04,
6787             PrintConv => {
6788             0 => 'Sub-command Dial',
6789             1 => 'Aperture Ring',
6790             },
6791             },
6792             18.4 => { # CSf6
6793             Name => 'ReleaseButtonToUseDial',
6794             Mask => 0x01,
6795             PrintConv => \%noYes,
6796             },
6797             19.1 => { # CSc2
6798             Name => 'StandbyTimer',
6799             Mask => 0xf0,
6800             PrintConv => {
6801             0 => '4 s',
6802             1 => '6 s',
6803             3 => '10 s',
6804             5 => '30 s',
6805             6 => '1 min',
6806             7 => '5 min',
6807             8 => '10 min',
6808             9 => '30 min',
6809             10 => 'No Limit',
6810             },
6811             },
6812             20.1 => { # CSc3-a
6813             Name => 'SelfTimerTime',
6814             Mask => 0xc0,
6815             PrintConv => {
6816             0 => '2 s',
6817             1 => '5 s',
6818             2 => '10 s',
6819             3 => '20 s',
6820             },
6821             },
6822             20.2 => { # CSc3-c
6823             Name => 'SelfTimerShotInterval',
6824             Mask => 0x30,
6825             PrintConv => {
6826             0 => '0.5 s',
6827             1 => '1 s',
6828             2 => '2 s',
6829             3 => '3 s',
6830             },
6831             },
6832             20.3 => { # CSc3-b
6833             Name => 'SelfTimerShotCount',
6834             Mask => 0x0f,
6835             },
6836             21.1 => { # CSc4-d
6837             Name => 'ImageReviewMonitorOffTime',
6838             Mask => 0xe0,
6839             PrintConv => {
6840             0 => '2 s',
6841             1 => '4 s',
6842             3 => '10 s',
6843             4 => '20 s',
6844             5 => '1 min',
6845             6 => '5 min',
6846             7 => '10 min',
6847             },
6848             },
6849             21.2 => { # CSc4-e
6850             Name => 'LiveViewMonitorOffTime',
6851             Mask => 0x1c,
6852             PrintConv => {
6853             1 => '5 min',
6854             2 => '10 min',
6855             3 => '15 min',
6856             4 => '20 min',
6857             5 => '30 min',
6858             6 => 'No Limit',
6859             },
6860             },
6861             22.1 => { # CSc4-b
6862             Name => 'MenuMonitorOffTime',
6863             Mask => 0xe0,
6864             PrintConv => {
6865             0 => '4 s',
6866             2 => '10 s',
6867             4 => '20 s',
6868             5 => '1 min',
6869             6 => '5 min',
6870             7 => '10 min',
6871             },
6872             },
6873             22.2 => { # CSc4-c
6874             Name => 'ShootingInfoMonitorOffTime',
6875             Mask => 0x1c,
6876             PrintConv => {
6877             0 => '4 s',
6878             2 => '10 s',
6879             4 => '20 s',
6880             5 => '1 min',
6881             6 => '5 min',
6882             7 => '10 min',
6883             },
6884             },
6885             23.1 => { # CSe1
6886             Name => 'FlashSyncSpeed',
6887             Mask => 0xf0,
6888             PrintConv => {
6889             2 => '1/250 s (auto FP)',
6890             3 => '1/250 s',
6891             5 => '1/200 s',
6892             6 => '1/160 s',
6893             7 => '1/125 s',
6894             8 => '1/100 s',
6895             9 => '1/80 s',
6896             10 => '1/60 s',
6897             },
6898             },
6899             23.2 => { # CSe2
6900             Name => 'FlashShutterSpeed',
6901             Mask => 0x0f,
6902             PrintConvColumns => 2,
6903             PrintConv => {
6904             0 => '1/60 s',
6905             1 => '1/30 s',
6906             2 => '1/15 s',
6907             3 => '1/8 s',
6908             4 => '1/4 s',
6909             5 => '1/2 s',
6910             6 => '1 s',
6911             7 => '2 s',
6912             8 => '4 s',
6913             9 => '8 s',
6914             10 => '15 s',
6915             11 => '30 s',
6916             },
6917             },
6918             31.1 => { # CSe5
6919             Name => 'ModelingFlash',
6920             Mask => 0x20,
6921             PrintConv => \%onOff,
6922             },
6923             36.1 => { # CSc4-a
6924             Name => 'PlaybackMonitorOffTime',
6925             Mask => 0xe0,
6926             PrintConv => {
6927             0 => '4 s',
6928             1 => '10 s',
6929             2 => '20 s',
6930             3 => '1 min',
6931             4 => '5 min',
6932             5 => '10 min',
6933             },
6934             },
6935             37.1 => { # CSf2-c
6936             Name => 'MultiSelectorLiveView',
6937             Mask => 0xc0,
6938             PrintConv => {
6939             0 => 'Reset',
6940             1 => 'Zoom',
6941             3 => 'Not Used',
6942             },
6943             },
6944             38.1 => { # CSf3-a
6945             Name => 'ShutterSpeedLock',
6946             Mask => 0x80,
6947             PrintConv => \%offOn,
6948             },
6949             38.2 => { # CSf3-b
6950             Name => 'ApertureLock',
6951             Mask => 0x40,
6952             PrintConv => \%offOn,
6953             },
6954             38.3 => { # CSg1-h
6955             Name => 'MovieShutterButton',
6956             Mask => 0x10,
6957             PrintConv => {
6958             0 => 'Take Photo',
6959             1 => 'Record Movies',
6960             },
6961             },
6962             38.4 => { # CSe3
6963             Name => 'FlashExposureCompArea',
6964             Mask => 0x04,
6965             PrintConv => {
6966             0 => 'Entire Frame',
6967             1 => 'Background Only',
6968             },
6969             },
6970             38.5 => { # CSe4
6971             Name => 'AutoFlashISOSensitivity',
6972             Mask => 0x02,
6973             PrintConv => {
6974             0 => 'Subject and Background',
6975             1 => 'Subject Only',
6976             },
6977             },
6978             41.1 => { # CSg1-c
6979             Name => 'MovieFunc1Button',
6980             Mask => 0xf0,
6981             PrintConv => {
6982             0 => 'None',
6983             2 => 'Power Aperture (close)',
6984             3 => 'Index Marking',
6985             4 => 'View Photo Shooting Info',
6986             11 => 'Exposure Compensation -',
6987             },
6988             },
6989             41.2 => { # CSg1-a
6990             Name => 'MoviePreviewButton',
6991             Mask => 0x0f,
6992             PrintConv => {
6993             0 => 'None',
6994             1 => 'Power Aperture (open)',
6995             3 => 'Index Marking',
6996             4 => 'View Photo Shooting Info',
6997             10 => 'Exposure Compensation +',
6998             },
6999             },
7000             42.1 => { # CSf1-d
7001             Name => 'Func1ButtonPlusDials',
7002             Mask => 0x0f,
7003             PrintConv => {
7004             0 => 'None',
7005             1 => 'Choose Image Area',
7006             2 => 'Shutter Speed & Aperture Lock',
7007             3 => 'One Step Speed / Aperture',
7008             4 => 'Choose Non-CPU Lens Number',
7009             5 => 'Active D-Lighting',
7010             7 => 'Photo Shooting Menu Bank',
7011             8 => 'Exposure Delay Mode',
7012             },
7013             },
7014             43.1 => { # CSf1-b
7015             Name => 'PreviewButtonPlusDials',
7016             Mask => 0x0f,
7017             PrintConv => {
7018             0 => 'None',
7019             1 => 'Choose Image Area',
7020             2 => 'Shutter Speed & Aperture Lock',
7021             3 => 'One Step Speed / Aperture',
7022             4 => 'Choose Non-CPU Lens Number',
7023             5 => 'Active D-Lighting',
7024             7 => 'Photo Shooting Menu Bank',
7025             8 => 'Exposure Delay Mode',
7026             },
7027             },
7028             45.1 => { # CSf1-k
7029             Name => 'AssignMovieRecordButtonPlusDials',
7030             Mask => 0x0f,
7031             PrintConv => {
7032             0 => 'None',
7033             1 => 'Choose Image Area',
7034             2 => 'Shutter Speed & Aperture Lock',
7035             7 => 'Photo Shooting Menu Bank',
7036             11 => 'Exposure Mode',
7037             },
7038             },
7039             46.1 => { # CSb7-d
7040             Name => 'FineTuneOptHighlightWeighted',
7041             Mask => 0x0f,
7042             ValueConv => '($val > 0x7 ? $val - 0x10 : $val) / 6',
7043             ValueConvInv => 'int($val*6+($val>0?0.5:-0.5))',
7044             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
7045             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
7046             },
7047             47.1 => { # CSa12-c
7048             Name => 'DynamicAreaAFDisplay',
7049             Mask => 0x80,
7050             PrintConv => \%offOn,
7051             },
7052             47.2 => { # CSa12-b
7053             Name => 'AFPointIllumination',
7054             Mask => 0x40,
7055             PrintConv => {
7056             0 => 'Off',
7057             1 => 'On During Manual Focusing',
7058             },
7059             },
7060             47.3 => { # CSa7
7061             Name => 'StoreByOrientation',
7062             Mask => 0x18,
7063             PrintConv => {
7064             0 => 'Off',
7065             1 => 'Focus Point',
7066             2 => 'Focus Point and AF-area Mode',
7067             },
7068             },
7069             48.1 => { # CSb5
7070             Name => 'MatrixMetering',
7071             Mask => 0x80,
7072             PrintConv => {
7073             0 => 'Face Detection On',
7074             1 => 'Face Detection Off',
7075             },
7076             },
7077             48.2 => { # CSf8
7078             Name => 'LiveViewButtonOptions',
7079             Mask => 0x30,
7080             PrintConv => {
7081             0 => 'Enable',
7082             1 => 'Enable (Standby Timer Active)',
7083             2 => 'Disable',
7084             },
7085             },
7086             48.3 => { # CSa10
7087             Name => 'AFModeRestrictions',
7088             Mask => 0x03,
7089             PrintConv => {
7090             0 => 'No Restrictions',
7091             1 => 'AF-C',
7092             2 => 'AF-S',
7093             },
7094             },
7095             49.1 => { # CSa9
7096             Name => 'LimitAFAreaModeSelection', #note that 'Dynamic area (9 points)' can be selected from the camera menu but the setting is not written to the EXIF data.
7097             Mask => 0x7e, #...This AF Mode was added to the D5 firmware several months after the camera's initial release which may help explain the inconsistency.
7098             PrintConv => {
7099             0 => 'No Restrictions',
7100             BITMASK => {
7101             0 => 'Auto-area',
7102             1 => 'Group-area',
7103             2 => '3D-tracking',
7104             3 => 'Dynamic area (153 points)',
7105             4 => 'Dynamic area (72 points)',
7106             5 => 'Dynamic area (25 points)',
7107             },
7108             },
7109             },
7110             52.1 => { # CSf1-l
7111             Name => 'LensFocusFunctionButtons',
7112             Mask => 0x3f,
7113             PrintConv => {
7114             3 => 'AE/AF Lock',
7115             4 => 'AE Lock Only',
7116             7 => 'AF Lock Only',
7117             8 => 'AF-On',
7118             24 => 'Preset Focus Point',
7119             26 => 'Flash Disable/Enable',
7120             36 => 'AF-Area Mode (Single)',
7121             37 => 'AF-Area Mode (Dynamic Area 25 Points)',
7122             38 => 'AF-Area Mode (Dynamic Area 72 Points)',
7123             39 => 'AF-Area Mode (Dynamic Area 153 Points)',
7124             40 => 'AF-Area Mode (Group Area AF)',
7125             41 => 'AF-Area Mode (Auto Area AF)',
7126             42 => 'AF-Area Mode + AF-On (Single)',
7127             43 => 'AF-Area Mode + AF-On (Dynamic Area 25 Points)',
7128             44 => 'AF-Area Mode + AF-On (Dynamic Area 72 Points)',
7129             45 => 'AF-Area Mode + AF-On (Dynamic Area 153 Points)',
7130             46 => 'AF-Area Mode + AF-On (Group Area AF)',
7131             47 => 'AF-Area Mode + AF-On (Auto Area AF)',
7132             49 => 'Sync Release (Master Only)',
7133             50 => 'Sync Release (Remote Only)',
7134             56 => 'AF-Area Mode (Dynamic Area 9 Points)',
7135             57 => 'AF-Area Mode + AF-On (Dynamic Area 9 Points)',
7136             },
7137             },
7138             66.1 => { # CSf10-d
7139             Name => 'VerticalMultiSelector',
7140             Mask => 0xff,
7141             PrintHex => 1,
7142             PrintConv => {
7143             0x00 => 'Same as Multi-Selector with Info(U/D) & Playback(R/L)',
7144             0x08 => 'Same as Multi-Selector with Info(R/L) & Playback(U/D)',
7145             0x80 => 'Focus Point Selection',
7146             },
7147             },
7148             67.1 => { # CSf10-a
7149             Name => 'AssignMB-D18FuncButton',
7150             Mask => 0x3f,
7151             PrintConv => {
7152             0 => 'None',
7153             1 => 'Preview',
7154             2 => 'FV Lock',
7155             3 => 'AE/AF Lock',
7156             4 => 'AE Lock Only',
7157             5 => 'AE Lock (reset on release)',
7158             6 => 'AE Lock (hold)',
7159             7 => 'AF Lock Only',
7160             8 => 'AF-On',
7161             10 => 'Bracketing Burst',
7162             11 => 'Matrix Metering',
7163             12 => 'Center-weighted Metering',
7164             13 => 'Spot Metering',
7165             14 => 'Playback',
7166             15 => 'My Menu Top Item',
7167             16 => '+NEF(RAW)',
7168             17 => 'Virtual Horizon',
7169             18 => 'Reset Focus Point',
7170             19 => 'Grid Display',
7171             20 => 'My Menu',
7172             22 => 'Remote Release Only',
7173             23 => 'Preset Focus Point',
7174             26 => 'Flash Disable/Enable',
7175             27 => 'Highlight-weighted Metering',
7176             36 => 'AF-Area Mode (Single)',
7177             37 => 'AF-Area Mode (Dynamic Area 25 Points)',
7178             38 => 'AF-Area Mode (Dynamic Area 72 Points)',
7179             39 => 'AF-Area Mode (Dynamic Area 153 Points)',
7180             40 => 'AF-Area Mode (Group Area AF)',
7181             41 => 'AF-Area Mode (Auto Area AF)',
7182             42 => 'AF-Area Mode + AF-On (Single)',
7183             43 => 'AF-Area Mode + AF-On (Dynamic Area 25 Points)',
7184             44 => 'AF-Area Mode + AF-On (Dynamic Area 72 Points)',
7185             45 => 'AF-Area Mode + AF-On (Dynamic Area 153 Points)',
7186             46 => 'AF-Area Mode + AF-On (Group Area AF)',
7187             47 => 'AF-Area Mode + AF-On (Auto Area AF)',
7188             49 => 'Sync Release (Master Only)',
7189             50 => 'Sync Release (Remote Only)',
7190             54 => 'Highlight Active Focus Point',
7191             56 => 'AF-Area Mode (Dynamic Area 9 Points)',
7192             57 => 'AF-Area Mode + AF-On (Dynamic Area 9 Points)',
7193             },
7194             },
7195             68.1 => { # CSf10-b
7196             Name => 'AssignMB-D18FuncButtonPlusDials',
7197             Mask => 0x0f,
7198             PrintConv => {
7199             0 => 'None',
7200             1 => 'Choose Image Area',
7201             2 => 'Shutter Speed & Aperture Lock',
7202             3 => 'One Step Speed / Aperture',
7203             4 => 'Choose Non-CPU Lens Number',
7204             5 => 'Active D-Lighting',
7205             7 => 'Photo Shooting Menu Bank',
7206             8 => 'Exposure Delay Mode',
7207             10 => 'ISO Sensitivity',
7208             11 => 'Exposure Mode',
7209             12 => 'Exposure Compensation',
7210             13 => 'Metering Mode',
7211             },
7212             },
7213             70.1 => { # CSf1-f
7214             Name => 'AF-OnButton',
7215             Mask => 0x3f,
7216             PrintConv => {
7217             0 => 'None',
7218             3 => 'AE/AF Lock',
7219             4 => 'AE Lock Only',
7220             5 => 'AE Lock (reset on release)',
7221             6 => 'AE Lock (hold)',
7222             7 => 'AF Lock Only',
7223             8 => 'AF-On',
7224             36 => 'AF-Area Mode (Single)',
7225             37 => 'AF-Area Mode (Dynamic Area 25 Points)',
7226             38 => 'AF-Area Mode (Dynamic Area 72 Points)',
7227             39 => 'AF-Area Mode (Dynamic Area 153 Points)',
7228             40 => 'AF-Area Mode (Group Area AF)',
7229             41 => 'AF-Area Mode (Auto Area AF)',
7230             42 => 'AF-Area Mode + AF-On (Single)',
7231             43 => 'AF-Area Mode + AF-On (Dynamic Area 25 Points)',
7232             44 => 'AF-Area Mode + AF-On (Dynamic Area 72 Points)',
7233             45 => 'AF-Area Mode + AF-On (Dynamic Area 153 Points)',
7234             46 => 'AF-Area Mode + AF-On (Group Area AF)',
7235             47 => 'AF-Area Mode + AF-On (Auto Area AF)',
7236             56 => 'AF-Area Mode (Dynamic Area 9 Points)',
7237             57 => 'AF-Area Mode + AF-On (Dynamic Area 9 Points)',
7238             },
7239             },
7240             71.1 => { # CSf1-g
7241             Name => 'SubSelector',
7242             Mask => 0x80,
7243             PrintConv => {
7244             0 => 'Focus Point Selection',
7245             1 => 'Same as MultiSelector',
7246             },
7247             },
7248             72.1 => { # CSf1-h
7249             Name => 'SubSelectorCenter',
7250             Mask => 0x3f,
7251             PrintConv => {
7252             0 => 'None',
7253             1 => 'Preview',
7254             2 => 'FV Lock',
7255             3 => 'AE/AF Lock',
7256             4 => 'AE Lock Only',
7257             5 => 'AE Lock (reset on release)',
7258             6 => 'AE Lock (hold)',
7259             7 => 'AF Lock Only',
7260             8 => 'AF-On',
7261             10 => 'Bracketing Burst',
7262             11 => 'Matrix Metering',
7263             12 => 'Center-weighted Metering',
7264             13 => 'Spot Metering',
7265             14 => 'Playback',
7266             15 => 'My Menu Top Item',
7267             16 => '+NEF(RAW)',
7268             17 => 'Virtual Horizon',
7269             18 => 'Reset Focus Point',
7270             19 => 'Grid Display',
7271             20 => 'My Menu',
7272             22 => 'Remote Release Only',
7273             23 => 'Preset Focus Point',
7274             26 => 'Flash Disable/Enable',
7275             27 => 'Highlight-weighted Metering',
7276             36 => 'AF-Area Mode (Single)',
7277             37 => 'AF-Area Mode (Dynamic Area 25 Points)',
7278             38 => 'AF-Area Mode (Dynamic Area 72 Points)',
7279             39 => 'AF-Area Mode (Dynamic Area 153 Points)',
7280             40 => 'AF-Area Mode (Group Area AF)',
7281             41 => 'AF-Area Mode (Auto Area AF)',
7282             42 => 'AF-Area Mode + AF-On (Single)',
7283             43 => 'AF-Area Mode + AF-On (Dynamic Area 25 Points)',
7284             44 => 'AF-Area Mode + AF-On (Dynamic Area 72 Points)',
7285             45 => 'AF-Area Mode + AF-On (Dynamic Area 153 Points)',
7286             46 => 'AF-Area Mode + AF-On (Group Area AF)',
7287             47 => 'AF-Area Mode + AF-On (Auto Area AF)',
7288             49 => 'Sync Release (Master Only)',
7289             50 => 'Sync Release (Remote Only)',
7290             54 => 'Highlight Active Focus Point',
7291             56 => 'AF-Area Mode (Dynamic Area 9 Points)',
7292             57 => 'AF-Area Mode + AF-On (Dynamic Area 9 Points)',
7293             },
7294             },
7295             73.1 => { # CSf1-i
7296             Name => 'SubSelectorPlusDials',
7297             Mask => 0x0f,
7298             PrintConv => {
7299             0 => 'None',
7300             1 => 'Choose Image Area',
7301             2 => 'Shutter Speed & Aperture Lock',
7302             4 => 'Choose Non-CPU Lens Number',
7303             7 => 'Photo Shooting Menu Bank',
7304             },
7305             },
7306             74.1 => { # CSg1-f
7307             Name => 'AssignMovieSubselector',
7308             Mask => 0xf0,
7309             PrintConv => {
7310             0 => 'None',
7311             3 => 'Index Marking',
7312             4 => 'View Photo Shooting Info',
7313             5 => 'AE/AF Lock',
7314             6 => 'AE Lock (Only)',
7315             7 => 'AE Lock (Hold)',
7316             8 => 'AF Lock (Only)',
7317             },
7318             },
7319             75.1 => { # CSg1-d
7320             Name => 'AssignMovieFunc1ButtonPlusDials',
7321             Mask => 0x10,
7322             PrintConv => {
7323             0 => 'None',
7324             1 => 'Choose Image Area',
7325             },
7326             },
7327             75.2 => { # CSg1-b
7328             Name => 'AssignMoviePreviewButtonPlusDials',
7329             Mask => 0x01,
7330             PrintConv => {
7331             0 => 'None',
7332             1 => 'Choose Image Area',
7333             },
7334             },
7335             76.1 => { # CSg1-g
7336             Name => 'AssignMovieSubselectorPlusDials',
7337             Mask => 0x10,
7338             PrintConv => {
7339             0 => 'None',
7340             1 => 'Choose Image Area',
7341             },
7342             },
7343             77.1 => { # CSd4
7344             Name => 'SyncReleaseMode',
7345             Mask => 0x80,
7346             PrintConv => {
7347             0 => 'No Sync',
7348             1 => 'Sync',
7349             },
7350             },
7351             77.2 => { # CSd11 (new with D850)
7352             Name => 'ContinuousModeLiveView',
7353             Mask => 0x40,
7354             PrintConv => \%offOn,
7355             },
7356             78.1 => { # CSa5
7357             Name => 'Three-DTrackingWatchArea',
7358             Mask => 0x80,
7359             PrintConv => {
7360             0 => 'Wide',
7361             1 => 'Normal',
7362             },
7363             },
7364             78.2 => { # CSa3-b
7365             Name => 'SubjectMotion',
7366             Mask => 0x60,
7367             PrintConv => {
7368             0 => 'Steady',
7369             1 => 'Middle',
7370             2 => 'Erratic',
7371             },
7372             },
7373             78.3 => { # CSa8
7374             Name => 'AFActivation',
7375             Mask => 0x08,
7376             PrintConv => {
7377             0 => 'Shutter/AF-On',
7378             1 => 'AF-On Only',
7379             },
7380             },
7381             78.4 => { # CSc1
7382             Name => 'ShutterReleaseButtonAE-L',
7383             Mask => 0x03,
7384             PrintConv => {
7385             0 => 'Off',
7386             1 => 'On (Half Press)',
7387             2 => 'On (Burst Mode)'
7388             },
7389             },
7390             79.1 => { # CSf10-c
7391             Name => 'AssignMB-D18AF-OnButton',
7392             Mask => 0x7f,
7393             PrintConv => {
7394             0 => 'None',
7395             3 => 'AE/AF Lock',
7396             4 => 'AE Lock Only',
7397             5 => 'AE Lock (reset on release)',
7398             6 => 'AE Lock (hold)',
7399             7 => 'AF Lock Only',
7400             8 => 'AF-On',
7401             36 => 'AF-Area Mode (Single)',
7402             37 => 'AF-Area Mode (Dynamic Area 25 Points)',
7403             38 => 'AF-Area Mode (Dynamic Area 72 Points)',
7404             39 => 'AF-Area Mode (Dynamic Area 153 Points)',
7405             40 => 'AF-Area Mode (Group Area AF)',
7406             41 => 'AF-Area Mode (Auto Area AF)',
7407             42 => 'AF-Area Mode + AF-On (Single)',
7408             43 => 'AF-Area Mode + AF-On (Dynamic Area 25 Points)',
7409             44 => 'AF-Area Mode + AF-On (Dynamic Area 72 Points)',
7410             45 => 'AF-Area Mode + AF-On (Dynamic Area 153 Points)',
7411             46 => 'AF-Area Mode + AF-On (Group Area AF)',
7412             47 => 'AF-Area Mode + AF-On (Auto Area AF)',
7413             56 => 'AF-Area Mode (Dynamic Area 9 Points)',
7414             57 => 'AF-Area Mode + AF-On (Dynamic Area 9 Points)',
7415             100 => 'Same as Camera AF-On Button',
7416             },
7417             },
7418             80.1 => { # CSf1-e
7419             Name => 'Func2Button',
7420             Mask => 0x3f,
7421             PrintConv => {
7422             0 => 'None',
7423             15 => 'My Menu Top Item',
7424             20 => 'My Menu',
7425             55 => 'Rating',
7426             },
7427             },
7428             82.1 => { # CSg1-e
7429             Name => 'AssignMovieFunc2Button',
7430             Mask => 0x70,
7431             PrintConv => {
7432             0 => 'None',
7433             3 => 'Index Marking',
7434             4 => 'View Photo Shooting Info',
7435             },
7436             },
7437             );
7438              
7439             # D5000 custom settings (ref PH)
7440             %Image::ExifTool::NikonCustom::SettingsD5000 = (
7441             PROCESS_PROC => \&Image::ExifTool::ProcessBinaryData,
7442             WRITE_PROC => \&Image::ExifTool::WriteBinaryData,
7443             CHECK_PROC => \&Image::ExifTool::CheckBinaryData,
7444             WRITABLE => 1,
7445             FIRST_ENTRY => 0,
7446             GROUPS => { 0 => 'MakerNotes', 2 => 'Camera' },
7447             NOTES => 'Custom settings for the D5000.',
7448             # Missing/Incomplete settings:
7449             # CSd7 - LiveViewDisplayOptions [couldn't find in data - try again with live view shots]
7450             0.1 => { # CSa1
7451             Name => 'AFAreaModeSetting',
7452             Mask => 0x60,
7453             PrintConv => {
7454             0 => 'Single Area',
7455             1 => 'Dynamic Area',
7456             2 => 'Auto-area',
7457             3 => '3D-tracking (11 points)',
7458             },
7459             },
7460             0.2 => { # CSa2
7461             Name => 'AFAssist',
7462             Mask => 0x01,
7463             PrintConv => \%onOff,
7464             },
7465             2.1 => { # CSd1
7466             Name => 'Beep',
7467             Mask => 0xc0,
7468             PrintConv => {
7469             0 => 'Off',
7470             1 => 'Low',
7471             2 => 'High',
7472             },
7473             },
7474             2.2 => { # CSd2
7475             Name => 'GridDisplay',
7476             Mask => 0x02,
7477             PrintConv => \%onOff,
7478             },
7479             2.3 => { # CSd3
7480             Name => 'ISODisplay',
7481             Mask => 0x08,
7482             PrintConv => \%onOff,
7483             },
7484             2.4 => { # CSf4
7485             Name => 'NoMemoryCard',
7486             Mask => 0x20,
7487             PrintConv => {
7488             0 => 'Release Locked',
7489             1 => 'Enable Release',
7490             },
7491             },
7492             3.1 => { # CSd4
7493             Name => 'FileNumberSequence',
7494             Mask => 0x08,
7495             PrintConv => \%onOff,
7496             },
7497             4.1 => { # CSa4
7498             Name => 'RangeFinder',
7499             Mask => 0x10,
7500             PrintConv => \%offOn,
7501             },
7502             4.2 => { # CSd6
7503             Name => 'DateImprint',
7504             Mask => 0x08,
7505             PrintConv => \%offOn,
7506             },
7507             4.3 => { # CSf5
7508             Name => 'ReverseIndicators',
7509             Mask => 0x80,
7510             PrintConv => {
7511             0 => '+ 0 -',
7512             1 => '- 0 +',
7513             },
7514             },
7515             5.1 => { # CSb1
7516             Name => 'EVStepSize',
7517             Mask => 0x40,
7518             PrintConv => {
7519             0 => '1/3 EV',
7520             1 => '1/2 EV',
7521             },
7522             },
7523             9.1 => { # CSd5
7524             Name => 'ExposureDelayMode',
7525             Mask => 0x40,
7526             PrintConv => \%offOn,
7527             },
7528             11.1 => { # CSe2
7529             Name => 'AutoBracketSet',
7530             Mask => 0xc0,
7531             PrintConv => {
7532             0 => 'Exposure',
7533             # (NOTE: the following are reversed in the D5100 -- is this correct?)
7534             1 => 'Active D-Lighting', #(NC)
7535             2 => 'WB Bracketing',
7536             },
7537             },
7538             12.1 => { # CSf1
7539             Name => 'TimerFunctionButton',
7540             Mask => 0x38,
7541             PrintConv => {
7542             0 => 'Self-timer',
7543             1 => 'Release Mode',
7544             2 => 'Image Quality/Size', #(NC)
7545             3 => 'ISO', #(NC)
7546             4 => 'White Balance', #(NC)
7547             5 => 'Active D-Lighting', #(NC)
7548             6 => '+ NEF (RAW)',
7549             7 => 'Auto Bracketing',
7550             },
7551             },
7552             15.1 => { # CSf2
7553             Name => 'AELockButton',
7554             Mask => 0x38,
7555             PrintConv => {
7556             0 => 'AE/AF Lock',
7557             1 => 'AE Lock Only', #(NC)
7558             2 => 'AF Lock Only', #(NC)
7559             3 => 'AE Lock (hold)',
7560             4 => 'AF-ON',
7561             },
7562             },
7563             16.1 => { # CSc1
7564             Name => 'ShutterReleaseButtonAE-L',
7565             Mask => 0x02,
7566             PrintConv => \%offOn,
7567             },
7568             16.2 => { # CSf3
7569             Name => 'CommandDialsReverseRotation',
7570             Mask => 0x80,
7571             PrintConv => \%noYes,
7572             },
7573             17.1 => { # CSc2-c
7574             Name => 'MeteringTime',
7575             Mask => 0x70,
7576             PrintConv => {
7577             0 => '4 s',
7578             1 => '8 s',
7579             2 => '20 s',
7580             3 => '1 min',
7581             4 => '30 min',
7582             },
7583             },
7584             17.2 => { # CSc4
7585             Name => 'RemoteOnDuration',
7586             Mask => 0x03,
7587             PrintConv => {
7588             0 => '1 min',
7589             1 => '5 min',
7590             2 => '10 min',
7591             3 => '15 min',
7592             },
7593             },
7594             18.1 => { # CSc3-a
7595             Name => 'SelfTimerTime',
7596             Mask => 0xc0,
7597             PrintConv => {
7598             0 => '2 s',
7599             1 => '5 s',
7600             2 => '10 s',
7601             3 => '20 s',
7602             },
7603             },
7604             18.2 => { # CSc3-b
7605             Name => 'SelfTimerShotCount',
7606             Mask => 0x1e,
7607             },
7608             19.1 => { # CSc2-b
7609             Name => 'ImageReviewTime',
7610             Mask => 0xe0,
7611             PrintConv => {
7612             0 => '4 s',
7613             1 => '8 s',
7614             2 => '20 s',
7615             3 => '1 min',
7616             4 => '10 min',
7617             },
7618             },
7619             20.1 => { # CSc2-a
7620             Name => 'PlaybackMenusTime',
7621             Mask => 0xe0,
7622             PrintConv => {
7623             0 => '8 s',
7624             1 => '12 s',
7625             2 => '20 s',
7626             3 => '1 min',
7627             4 => '10 min',
7628             },
7629             },
7630             22.1 => { # CSe1-a
7631             Name => 'InternalFlash',
7632             Mask => 0xc0,
7633             PrintConv => {
7634             0 => 'TTL',
7635             1 => 'Manual',
7636             },
7637             },
7638             22.2 => { # CSe1-b
7639             Name => 'ManualFlashOutput',
7640             Mask => 0x1f,
7641             ValueConv => '2 ** (-$val/3)',
7642             ValueConvInv => '$val > 0 ? -3*log($val)/log(2) : 0',
7643             PrintConv => q{
7644             return 'Full' if $val > 0.99;
7645             Image::ExifTool::Exif::PrintExposureTime($val);
7646             },
7647             PrintConvInv => '$val=~/F/i ? 1 : Image::ExifTool::Exif::ConvertFraction($val)',
7648             },
7649             32.1 => { # CSa3
7650             Name => 'LiveViewAF',
7651             Mask => 0x60,
7652             PrintConv => {
7653             0 => 'Face Priority',
7654             1 => 'Wide Area',
7655             2 => 'Normal Area',
7656             3 => 'Subject Tracking',
7657             },
7658             },
7659             );
7660              
7661             # D5100 custom settings (ref PH)
7662             %Image::ExifTool::NikonCustom::SettingsD5100 = (
7663             PROCESS_PROC => \&Image::ExifTool::ProcessBinaryData,
7664             WRITE_PROC => \&Image::ExifTool::WriteBinaryData,
7665             CHECK_PROC => \&Image::ExifTool::CheckBinaryData,
7666             WRITABLE => 1,
7667             FIRST_ENTRY => 0,
7668             GROUPS => { 0 => 'MakerNotes', 2 => 'Camera' },
7669             NOTES => 'Custom settings for the D5100.',
7670             0.1 => { # CSa1
7671             Name => 'AF-CPrioritySelection',
7672             Mask => 0x80,
7673             PrintConv => {
7674             0 => 'Release',
7675             1 => 'Focus',
7676             },
7677             },
7678             1.1 => { # CSa2
7679             Name => 'AFAssist',
7680             Mask => 0x01,
7681             PrintConv => \%onOff,
7682             },
7683             3.1 => { # CSd1
7684             Name => 'Beep',
7685             Mask => 0xc0,
7686             PrintConv => {
7687             0 => 'Off',
7688             1 => 'Low',
7689             2 => 'High',
7690             },
7691             },
7692             3.2 => { # CSf4
7693             Name => 'NoMemoryCard',
7694             Mask => 0x20,
7695             PrintConv => {
7696             0 => 'Release Locked',
7697             1 => 'Enable Release',
7698             },
7699             },
7700             3.3 => { # CSd2
7701             Name => 'ISODisplay',
7702             Mask => 0x08,
7703             PrintConv => \%onOff,
7704             },
7705             4.1 => { # CSd3
7706             Name => 'FileNumberSequence',
7707             Mask => 0x08,
7708             PrintConv => \%onOff,
7709             },
7710             5.1 => { # CSa3
7711             Name => 'RangeFinder',
7712             Mask => 0x10,
7713             PrintConv => \%offOn,
7714             },
7715             # (it looks like CSd5 DateImprint is not stored)
7716             5.2 => { # CSf5
7717             Name => 'ReverseIndicators',
7718             Mask => 0x80,
7719             PrintConv => {
7720             0 => '+ 0 -',
7721             1 => '- 0 +',
7722             },
7723             },
7724             6.1 => { # CSb1
7725             Name => 'EVStepSize',
7726             Mask => 0x40,
7727             PrintConv => {
7728             0 => '1/3 EV',
7729             1 => '1/2 EV',
7730             },
7731             },
7732             10.1 => { # CSd4
7733             Name => 'ExposureDelayMode',
7734             Mask => 0x40,
7735             PrintConv => \%offOn,
7736             },
7737             12.1 => { # CSe2
7738             Name => 'AutoBracketSet',
7739             Mask => 0xc0,
7740             PrintConv => {
7741             0 => 'Exposure',
7742             # (NOTE: the following are reversed from the D5000 -- is D5000 correct?)
7743             1 => 'WB Bracketing',
7744             2 => 'Active D-Lighting',
7745             },
7746             },
7747             13.1 => { # CSf1
7748             Name => 'TimerFunctionButton',
7749             Mask => 0x38,
7750             PrintConv => {
7751             0 => 'Self-timer',
7752             1 => 'Release Mode',
7753             2 => 'Image Quality/Size',
7754             3 => 'ISO',
7755             4 => 'White Balance',
7756             5 => 'Active D-Lighting',
7757             6 => '+ NEF (RAW)',
7758             7 => 'Auto Bracketing',
7759             },
7760             },
7761             16.1 => { # CSf2
7762             Name => 'AELockButton',
7763             Mask => 0x38,
7764             PrintConv => {
7765             0 => 'AE/AF Lock',
7766             1 => 'AE Lock Only',
7767             2 => 'AF Lock Only',
7768             3 => 'AE Lock (hold)',
7769             4 => 'AF-ON',
7770             },
7771             },
7772             17.1 => { # CSc1
7773             Name => 'ShutterReleaseButtonAE-L',
7774             Mask => 0x02,
7775             PrintConv => \%offOn,
7776             },
7777             17.2 => { # CSf3
7778             Name => 'CommandDialsReverseRotation',
7779             Mask => 0x80,
7780             PrintConv => \%noYes,
7781             },
7782             18.1 => { # CSc2-d
7783             Name => 'MeteringTime',
7784             Mask => 0x70,
7785             PrintConv => {
7786             0 => '4 s',
7787             1 => '8 s',
7788             2 => '20 s', #(NC)
7789             3 => '1 min',
7790             4 => '30 min', #(NC)
7791             },
7792             },
7793             18.2 => { # CSc4
7794             Name => 'RemoteOnDuration',
7795             Mask => 0x03,
7796             PrintConv => {
7797             0 => '1 min',
7798             1 => '5 min',
7799             2 => '10 min', #(NC)
7800             3 => '20 min', # (but picture in manual shows 15 min)
7801             },
7802             },
7803             19.1 => { # CSc3-a
7804             Name => 'SelfTimerTime',
7805             Mask => 0xc0,
7806             PrintConv => {
7807             0 => '2 s',
7808             1 => '5 s',
7809             2 => '10 s',
7810             3 => '20 s',
7811             },
7812             },
7813             19.2 => { # CSc3-b
7814             Name => 'SelfTimerShotCount',
7815             Mask => 0x0f,
7816             },
7817             20.1 => { # CSc2-b
7818             Name => 'ImageReviewTime',
7819             Mask => 0xe0,
7820             PrintConv => {
7821             0 => '4 s',
7822             1 => '8 s', #(NC)
7823             2 => '20 s',
7824             3 => '1 min', #(NC)
7825             4 => '10 min', #(NC)
7826             },
7827             },
7828             20.2 => { # CSc2-c
7829             Name => 'LiveViewMonitorOffTime',
7830             Mask => 0x1c,
7831             PrintConv => {
7832             0 => '3 min',
7833             1 => '5 min', #(NC)
7834             2 => '10 min',
7835             3 => '15 min', #(NC)
7836             4 => '20 min', #(NC)
7837             5 => '30 min', #(NC)
7838             },
7839             },
7840             21.1 => { # CSc2-a
7841             Name => 'PlaybackMenusTime',
7842             Mask => 0xe0,
7843             PrintConv => {
7844             0 => '8 s', #(NC)
7845             1 => '12 s',
7846             2 => '20 s',
7847             3 => '1 min',
7848             4 => '10 min', #(NC)
7849             },
7850             },
7851             23.1 => { # CSe1-a
7852             Name => 'InternalFlash',
7853             Mask => 0xc0,
7854             PrintConv => {
7855             0 => 'TTL',
7856             1 => 'Manual',
7857             },
7858             },
7859             23.1 => { # CSe1-b
7860             Name => 'ManualFlashOutput',
7861             Mask => 0x1f,
7862             ValueConv => '2 ** (-$val/3)',
7863             ValueConvInv => '$val > 0 ? -3*log($val)/log(2) : 0',
7864             PrintConv => q{
7865             return 'Full' if $val > 0.99;
7866             Image::ExifTool::Exif::PrintExposureTime($val);
7867             },
7868             PrintConvInv => '$val=~/F/i ? 1 : Image::ExifTool::Exif::ConvertFraction($val)',
7869             },
7870             );
7871              
7872             # D5200 custom settings (ref PH)
7873             %Image::ExifTool::NikonCustom::SettingsD5200 = (
7874             PROCESS_PROC => \&Image::ExifTool::ProcessBinaryData,
7875             WRITE_PROC => \&Image::ExifTool::WriteBinaryData,
7876             CHECK_PROC => \&Image::ExifTool::CheckBinaryData,
7877             WRITABLE => 1,
7878             FIRST_ENTRY => 0,
7879             GROUPS => { 0 => 'MakerNotes', 2 => 'Camera' },
7880             NOTES => 'Custom settings for the D5200.',
7881             0.1 => { # CSa1
7882             Name => 'AF-CPrioritySelection',
7883             Mask => 0x80,
7884             PrintConv => {
7885             0 => 'Release',
7886             1 => 'Focus',
7887             },
7888             },
7889             0.2 => { # CSa2
7890             Name => 'NumberOfFocusPoints',
7891             Mask => 0x10,
7892             PrintConv => {
7893             0 => '39 Points',
7894             1 => '11 Points',
7895             },
7896             },
7897             1.1 => { # CSa3
7898             Name => 'AFAssist',
7899             Mask => 0x01,
7900             PrintConv => \%onOff,
7901             },
7902             3.1 => { # CSd1
7903             Name => 'Beep',
7904             Mask => 0xc0,
7905             PrintConv => {
7906             0 => 'Off',
7907             1 => 'Low',
7908             2 => 'High',
7909             },
7910             },
7911             3.2 => { # CSf4
7912             Name => 'NoMemoryCard',
7913             Mask => 0x20,
7914             PrintConv => {
7915             0 => 'Release Locked',
7916             1 => 'Enable Release',
7917             },
7918             },
7919             3.3 => { # CSd3
7920             Name => 'ISODisplay',
7921             Mask => 0x08,
7922             PrintConv => \%onOff,
7923             },
7924             4.1 => { # CSd3
7925             Name => 'FileNumberSequence',
7926             Mask => 0x08,
7927             PrintConv => \%onOff,
7928             },
7929             5.1 => { # CSa4
7930             Name => 'RangeFinder',
7931             Mask => 0x04,
7932             PrintConv => \%offOn,
7933             },
7934             5.2 => { # CSf3-a
7935             Name => 'ReverseExposureCompDial',
7936             Mask => 0x10,
7937             PrintConv => \%noYes,
7938             },
7939             5.3 => { # CSf3-b
7940             Name => 'ReverseShutterSpeedAperture',
7941             Mask => 0x08,
7942             PrintConv => \%noYes,
7943             },
7944             5.4 => { # CSf5
7945             Name => 'ReverseIndicators',
7946             Mask => 0x80,
7947             PrintConv => {
7948             0 => '+ 0 -',
7949             1 => '- 0 +',
7950             },
7951             },
7952             6.1 => { # CSb1
7953             Name => 'EVStepSize',
7954             Mask => 0x40, # (bit 0x04 also changes)
7955             PrintConv => {
7956             0 => '1/3 EV',
7957             1 => '1/2 EV',
7958             },
7959             },
7960             10.1 => { # CSd5
7961             Name => 'ExposureDelayMode',
7962             Mask => 0x40,
7963             PrintConv => { 0 => 'Off', 1 => 'On' },
7964             },
7965             12.1 => { # CSe2
7966             Name => 'AutoBracketSet',
7967             Mask => 0xc0,
7968             PrintConv => {
7969             0 => 'Exposure',
7970             # (NOTE: the following are reversed from the D5000 -- is D5000 correct?)
7971             1 => 'WB Bracketing',
7972             2 => 'Active D-Lighting',
7973             },
7974             },
7975             13.1 => { # CSf1
7976             Name => 'FunctionButton',
7977             Mask => 0x1f,
7978             PrintConv => {
7979             3 => 'AE/AF Lock',
7980             4 => 'AE Lock Only',
7981             6 => 'AE Lock (hold)',
7982             7 => 'AF Lock Only',
7983             8 => 'AF-ON',
7984             16 => '+ NEF (RAW)',
7985             18 => 'Active D-Lighting',
7986             25 => 'Live View',
7987             26 => 'Image Quality',
7988             27 => 'ISO',
7989             28 => 'White Balance',
7990             29 => 'HDR',
7991             30 => 'Auto Bracketing',
7992             31 => 'AF-area Mode',
7993             },
7994             },
7995             16.1 => { # CSf2
7996             Name => 'AELockButton',
7997             Mask => 0x0f,
7998             PrintConv => {
7999             3 => 'AE/AF Lock',
8000             4 => 'AE Lock Only',
8001             6 => 'AE Lock (hold)',
8002             7 => 'AF Lock Only',
8003             8 => 'AF-ON',
8004             },
8005             },
8006             17.1 => { # CSc1
8007             Name => 'ShutterReleaseButtonAE-L',
8008             Mask => 0x02,
8009             PrintConv => \%offOn,
8010             },
8011             18.1 => { # CSc2-d
8012             Name => 'StandbyTimer',
8013             Mask => 0xe0,
8014             PrintConv => {
8015             0 => '4 s',
8016             1 => '8 s',
8017             2 => '20 s',
8018             3 => '1 min',
8019             4 => '30 min',
8020             },
8021             },
8022             18.2 => { # CSc4
8023             Name => 'RemoteOnDuration',
8024             Mask => 0x03,
8025             PrintConv => {
8026             0 => '1 min',
8027             1 => '5 min',
8028             2 => '10 min',
8029             3 => '15 min',
8030             },
8031             },
8032             19.1 => { # CSc3-a
8033             Name => 'SelfTimerTime',
8034             Mask => 0xc0,
8035             PrintConv => {
8036             0 => '2 s',
8037             1 => '5 s',
8038             2 => '10 s',
8039             3 => '20 s',
8040             },
8041             },
8042             19.2 => { # CSc3-b
8043             Name => 'SelfTimerShotCount',
8044             Mask => 0x0f,
8045             },
8046             20.1 => { # CSc2-b
8047             Name => 'ImageReviewTime',
8048             Mask => 0xe0,
8049             PrintConv => {
8050             1 => '4 s',
8051             2 => '8 s',
8052             4 => '20 s',
8053             5 => '1 min',
8054             7 => '10 min',
8055             },
8056             },
8057             20.2 => { # CSc2-c
8058             Name => 'LiveViewMonitorOffTime',
8059             Mask => 0x1c,
8060             PrintConv => {
8061             1 => '5 min',
8062             2 => '10 min',
8063             3 => '15 min',
8064             4 => '20 min',
8065             5 => '30 min',
8066             },
8067             },
8068             21.1 => { # CSc2-a
8069             Name => 'PlaybackMenusTime',
8070             Mask => 0xe0,
8071             PrintConv => {
8072             1 => '8 s',
8073             4 => '20 s',
8074             5 => '1 min',
8075             6 => '5 min',
8076             7 => '10 min',
8077             },
8078             },
8079             23.1 => { # CSe1-a
8080             Name => 'InternalFlash',
8081             Mask => 0xc0,
8082             PrintConv => {
8083             0 => 'TTL',
8084             1 => 'Manual',
8085             },
8086             },
8087             23.2 => { # CSe1-b
8088             Name => 'ManualFlashOutput',
8089             Mask => 0x1f,
8090             ValueConv => '2 ** (-$val/3)',
8091             ValueConvInv => '$val > 0 ? -3*log($val)/log(2) : 0',
8092             PrintConv => q{
8093             return 'Full' if $val > 0.99;
8094             Image::ExifTool::Exif::PrintExposureTime($val);
8095             },
8096             PrintConvInv => '$val=~/F/i ? 1 : Image::ExifTool::Exif::ConvertFraction($val)',
8097             },
8098             );
8099              
8100             # D7000 custom settings (ref 2)
8101             %Image::ExifTool::NikonCustom::SettingsD7000 = (
8102             PROCESS_PROC => \&Image::ExifTool::ProcessBinaryData,
8103             WRITE_PROC => \&Image::ExifTool::WriteBinaryData,
8104             CHECK_PROC => \&Image::ExifTool::CheckBinaryData,
8105             WRITABLE => 1,
8106             FIRST_ENTRY => 0,
8107             DATAMEMBER => [ 23.1 ],
8108             GROUPS => { 0 => 'MakerNotes', 2 => 'Camera' },
8109             NOTES => 'Custom settings for the D7000.',
8110             0.1 => { # CSa1
8111             Name => 'AF-CPrioritySelection',
8112             Mask => 0x80,
8113             PrintConv => {
8114             0 => 'Release',
8115             1 => 'Focus',
8116             },
8117             },
8118             0.2 => { # CSa2
8119             Name => 'AF-SPrioritySelection',
8120             Mask => 0x20,
8121             PrintConv => {
8122             0 => 'Focus',
8123             1 => 'Release',
8124             },
8125             },
8126             0.3 => { # CSa6
8127             Name => 'NumberOfFocusPoints',
8128             Mask => 0x10,
8129             PrintConv => {
8130             0 => '39 Points',
8131             1 => '11 Points',
8132             },
8133             },
8134             0.4 => { # CSa3
8135             Name => 'FocusTrackingLockOn',
8136             Mask => 0x07,
8137             PrintConv => {
8138             0 => 'Off',
8139             1 => '1 Short',
8140             2 => '2',
8141             3 => '3 Normal',
8142             4 => '4',
8143             5 => '5 Long',
8144             },
8145             },
8146             1.1 => { # CSa5
8147             Name => 'FocusPointWrap',
8148             Mask => 0x08,
8149             PrintConv => {
8150             0 => 'No Wrap',
8151             1 => 'Wrap',
8152             },
8153             },
8154             1.2 => { # CSa4
8155             Name => 'AFPointIllumination',
8156             Mask => 0x06,
8157             PrintConv => {
8158             0 => 'Auto',
8159             1 => 'On',
8160             2 => 'Off',
8161             },
8162             },
8163             1.3 => { # CSa7
8164             Name => 'AFAssist',
8165             Mask => 0x01,
8166             PrintConv => \%onOff,
8167             },
8168             2.1 => { # CSd14
8169             Name => 'BatteryOrder',
8170             Mask => 0x40,
8171             PrintConv => {
8172             0 => 'MB-D11 First',
8173             1 => 'Camera Battery First',
8174             },
8175             },
8176             2.2 => { # CSa10
8177             Name => 'AF-OnForMB-D11',
8178             Mask => 0x1c,
8179             PrintConv => {
8180             0 => 'AE/AF Lock',
8181             1 => 'AE Lock Only',
8182             2 => 'AF Lock Only',
8183             3 => 'AE Lock (hold)',
8184             4 => 'AF-ON',
8185             5 => 'FV Lock',
8186             6 => 'Same as FUNC Button',
8187             },
8188             },
8189             2.3 => { # CSd13
8190             Name => 'MB-D11BatteryType',
8191             Mask => 0x03,
8192             PrintConv => {
8193             0 => 'LR6 (AA alkaline)',
8194             1 => 'Ni-MH (AA Ni-MH)',
8195             2 => 'FR6 (AA lithium)',
8196             },
8197             },
8198             3.1 => { # CSd1-b
8199             Name => 'BeepPitch',
8200             Mask => 0xc0,
8201             PrintConv => {
8202             0 => 'Off',
8203             1 => 'Low',
8204             2 => 'High',
8205             },
8206             },
8207             3.2 => { # CSf8
8208             Name => 'NoMemoryCard',
8209             Mask => 0x20,
8210             PrintConv => {
8211             0 => 'Release Locked',
8212             1 => 'Enable Release',
8213             },
8214             },
8215             3.3 => { # CSd3
8216             Name => 'ISODisplay',
8217             Mask => 0x0c,
8218             PrintConv => {
8219             0 => 'Show ISO/Easy ISO',
8220             1 => 'Show ISO Sensitivity',
8221             3 => 'Show Frame Count',
8222             },
8223             },
8224             3.4 => { # CSd2
8225             Name => 'GridDisplay',
8226             Mask => 0x02,
8227             PrintConv => \%onOff,
8228             },
8229             3.5 => { # CSd4
8230             Name => 'ViewfinderWarning',
8231             Mask => 0x01,
8232             PrintConv => \%onOff,
8233             },
8234             4.1 => { # CSd9
8235             Name => 'ShootingInfoDisplay',
8236             Mask => 0xc0,
8237             PrintConv => {
8238             0 => 'Auto',
8239             2 => 'Manual (dark on light)',
8240             3 => 'Manual (light on dark)',
8241             },
8242             },
8243             4.2 => { # CSd10
8244             Name => 'LCDIllumination',
8245             Mask => 0x20,
8246             PrintConv => \%offOn,
8247             },
8248             4.3 => { # CSd8
8249             Name => 'FileNumberSequence',
8250             Mask => 0x08,
8251             PrintConv => \%onOff,
8252             },
8253             4.4 => { # CSd5
8254             Name => 'ScreenTips',
8255             Mask => 0x04,
8256             PrintConv => \%offOn,
8257             },
8258             4.5 => { # CSd1-a
8259             Name => 'BeepVolume',
8260             Mask => 0x03,
8261             PrintConv => {
8262             0 => 'Off',
8263             1 => '1',
8264             2 => '2',
8265             3 => '3',
8266             },
8267             },
8268             5.1 => { # CSf9
8269             Name => 'ReverseIndicators',
8270             Mask => 0x80,
8271             PrintConv => {
8272             0 => '+ 0 -',
8273             1 => '- 0 +',
8274             },
8275             },
8276             5.2 => { # CSb3
8277             Name => 'EasyExposureCompensation',
8278             Mask => 0x03,
8279             PrintConv => {
8280             0 => 'Off',
8281             1 => 'On',
8282             2 => 'On Auto Reset',
8283             },
8284             },
8285             6.1 => { # CSb2
8286             Name => 'ExposureControlStep',
8287             Mask => 0x40,
8288             PrintConv => {
8289             0 => '1/3 EV',
8290             1 => '1/2 EV',
8291             },
8292             },
8293             6.2 => { # CSb1
8294             Name => 'ISOSensitivityStep',
8295             Mask => 0x10,
8296             PrintConv => {
8297             0 => '1/3 EV',
8298             1 => '1/2 EV',
8299             },
8300             },
8301             7.1 => { # CSb4
8302             Name => 'CenterWeightedAreaSize',
8303             Mask => 0xe0,
8304             PrintConv => {
8305             0 => '6 mm',
8306             1 => '8 mm',
8307             2 => '10 mm',
8308             3 => '13 mm',
8309             4 => 'Average',
8310             },
8311             },
8312             10.1 => { # CSd11
8313             Name => 'ExposureDelayMode',
8314             Mask => 0x40,
8315             PrintConv => \%offOn,
8316             },
8317             10.2 => { # CSd6
8318             Name => 'CLModeShootingSpeed',
8319             Mask => 0x07,
8320             PrintConv => '"$val fps"',
8321             PrintConvInv => '$val=~s/\s*fps//i; $val',
8322             },
8323             11 => { # CSd7
8324             Name => 'MaxContinuousRelease',
8325             # values: 1-100
8326             },
8327             12.1 => { # CSe5
8328             Name => 'AutoBracketSet',
8329             Mask => 0xe0, #(NC)
8330             PrintConv => {
8331             0 => 'AE & Flash', # default
8332             1 => 'AE Only',
8333             2 => 'Flash Only', #(NC)
8334             3 => 'WB Bracketing', #(NC)
8335             4 => 'Active D-Lighting', #(NC)
8336             },
8337             },
8338             12.2 => { # CSe6
8339             Name => 'AutoBracketOrder',
8340             Mask => 0x10,
8341             PrintConv => {
8342             0 => '0,-,+',
8343             1 => '-,0,+',
8344             },
8345             },
8346             13.1 => { # CSf3
8347             Name => 'FuncButton',
8348             Mask => 0xf8,
8349             PrintConv => {
8350             0 => 'Grid Display',
8351             1 => 'FV Lock',
8352             2 => 'Flash Off',
8353             3 => 'Matrix Metering',
8354             4 => 'Center-weighted Metering',
8355             5 => 'Spot Metering',
8356             6 => 'My Menu Top',
8357             7 => '+ NEF (RAW)',
8358             8 => 'Active D-Lighting',
8359             9 => 'Preview',
8360             10 => 'AE/AF Lock',
8361             11 => 'AE Lock Only',
8362             12 => 'AF Lock Only',
8363             13 => 'AE Lock (hold)',
8364             14 => 'Bracketing Burst',
8365             15 => 'Playback',
8366             16 => '1EV Step Speed/Aperture',
8367             17 => 'Choose Non-CPU Lens',
8368             18 => 'Virtual Horizon',
8369             19 => 'Start Movie Recording',
8370             },
8371             },
8372             14.1 => { # CSf4
8373             Name => 'PreviewButton',
8374             Mask => 0xf8,
8375             PrintConv => {
8376             0 => 'Grid Display',
8377             1 => 'FV Lock',
8378             2 => 'Flash Off',
8379             3 => 'Matrix Metering',
8380             4 => 'Center-weighted Metering',
8381             5 => 'Spot Metering',
8382             6 => 'My Menu Top',
8383             7 => '+ NEF (RAW)',
8384             8 => 'Active D-Lighting',
8385             9 => 'Preview',
8386             10 => 'AE/AF Lock',
8387             11 => 'AE Lock Only',
8388             12 => 'AF Lock Only',
8389             13 => 'AE Lock (hold)',
8390             14 => 'Bracketing Burst',
8391             15 => 'Playback',
8392             16 => '1EV Step Speed/Aperture',
8393             17 => 'Choose Non-CPU Lens',
8394             18 => 'Virtual Horizon',
8395             19 => 'Start Movie Recording',
8396             },
8397             },
8398             16.1 => { # CSf5
8399             Name => 'AELockButton',
8400             Mask => 0x38,
8401             PrintConv => {
8402             0 => 'AE/AF Lock',
8403             1 => 'AE Lock Only',
8404             2 => 'AF Lock Only',
8405             3 => 'AE Lock (hold)',
8406             4 => 'AF-ON',
8407             5 => 'FV Lock',
8408             },
8409             },
8410             15.1 => { # CSf2
8411             Name => 'OKButton',
8412             Mask => 0x18,
8413             PrintConv => {
8414             1 => 'Select Center Focus Point',
8415             2 => 'Highlight Active Focus Point',
8416             3 => 'Not Used', #(NC)
8417             0 => 'Off', #(NC)
8418             },
8419             },
8420             17.1 => { # CSf6-a
8421             Name => 'CommandDialsReverseRotation',
8422             Mask => 0x80,
8423             PrintConv => \%noYes,
8424             },
8425             17.2 => { # CSf6-b
8426             Name => 'CommandDialsChangeMainSub',
8427             Mask => 0x60,
8428             PrintConv => {
8429             0 => 'Off',
8430             1 => 'On',
8431             2 => 'On (A mode only)',
8432             },
8433             },
8434             17.3 => { # CSf6-c
8435             Name => 'CommandDialsApertureSetting',
8436             Mask => 0x04,
8437             PrintConv => {
8438             0 => 'Sub-command Dial',
8439             1 => 'Aperture Ring',
8440             },
8441             },
8442             17.4 => { # CSf6-d
8443             Name => 'CommandDialsMenuAndPlayback',
8444             Mask => 0x18,
8445             PrintConv => {
8446             0 => 'On',
8447             2 => 'On (Image Review Exclude)',
8448             1 => 'Off',
8449             },
8450             },
8451             17.5 => { # CSc1
8452             Name => 'ShutterReleaseButtonAE-L',
8453             Mask => 0x02,
8454             PrintConv => \%offOn,
8455             },
8456             17.6 => { # CSf7
8457             Name => 'ReleaseButtonToUseDial',
8458             Mask => 0x01,
8459             PrintConv => \%noYes,
8460             },
8461             18.1 => { # CSc2
8462             Name => 'MeteringTime',
8463             Mask => 0xf0,
8464             PrintConvColumns => 2,
8465             PrintConv => {
8466             0 => '4 s',
8467             1 => '6 s', # default
8468             2 => '8 s',
8469             3 => '16 s',
8470             4 => '30 s',
8471             5 => '1 min',
8472             6 => '5 min',
8473             7 => '10 min',
8474             8 => '30 min',
8475             9 => 'No Limit',
8476             },
8477             },
8478             18.2 => { # CSc5
8479             Name => 'RemoteOnDuration',
8480             Mask => 0x03,
8481             PrintConv => {
8482             0 => '1 min',
8483             1 => '5 min',
8484             2 => '10 min',
8485             3 => '15 min',
8486             },
8487             },
8488             19.1 => { # CSc3-a
8489             Name => 'SelfTimerTime',
8490             Mask => 0xc0,
8491             PrintConv => {
8492             0 => '2 s',
8493             1 => '5 s',
8494             2 => '10 s', # default
8495             3 => '20 s',
8496             },
8497             },
8498             19.2 => { # CSc3-c
8499             Name => 'SelfTimerInterval',
8500             Mask => 0x30,
8501             PrintConv => {
8502             0 => '0.5 s',
8503             1 => '1 s',
8504             2 => '2 s', # default
8505             3 => '3 s',
8506             },
8507             },
8508             19.3 => { # CSc3-b
8509             Name => 'SelfTimerShotCount',
8510             Mask => 0x0f,
8511             },
8512             20.1 => { # CSc4-d
8513             Name => 'ImageReviewTime',
8514             Mask => 0xe0,
8515             PrintConv => { #(NC)
8516             0 => '4 s',
8517             1 => '10 s', # default
8518             2 => '20 s',
8519             3 => '1 min',
8520             4 => '5 min',
8521             5 => '10 min',
8522             },
8523             },
8524             20.2 => { # CSc4-e
8525             Name => 'LiveViewMonitorOffTime',
8526             Mask => 0x1c,
8527             PrintConv => { #(NC)
8528             0 => '4 s',
8529             1 => '10 s', # default
8530             2 => '20 s',
8531             3 => '1 min',
8532             4 => '5 min',
8533             5 => '10 min',
8534             },
8535             },
8536             21.1 => { # CSc4-b
8537             Name => 'MenuMonitorOffTime',
8538             Mask => 0xe0,
8539             PrintConv => {
8540             0 => '4 s',
8541             1 => '10 s', # default
8542             2 => '20 s',
8543             3 => '1 min',
8544             4 => '5 min',
8545             5 => '10 min',
8546             },
8547             },
8548             21.2 => { # CSc4-c
8549             Name => 'ShootingInfoMonitorOffTime',
8550             Mask => 0x1c,
8551             PrintConv => { #(NC)
8552             0 => '4 s',
8553             1 => '10 s', # default
8554             2 => '20 s',
8555             3 => '1 min',
8556             4 => '5 min',
8557             5 => '10 min',
8558             },
8559             },
8560             22.1 => { # CSe1
8561             Name => 'FlashSyncSpeed',
8562             Mask => 0xf0,
8563             PrintConv => {
8564             0 => '1/320 s (auto FP)',
8565             1 => '1/250 s (auto FP)',
8566             2 => '1/250 s',
8567             3 => '1/200 s',
8568             4 => '1/160 s',
8569             5 => '1/125 s',
8570             6 => '1/100 s',
8571             7 => '1/80 s',
8572             8 => '1/60 s',
8573             },
8574             },
8575             22.2 => { # CSe2
8576             Name => 'FlashShutterSpeed',
8577             Mask => 0x0f,
8578             PrintConvColumns => 2,
8579             PrintConv => {
8580             0 => '1/60 s',
8581             1 => '1/30 s',
8582             2 => '1/15 s',
8583             3 => '1/8 s',
8584             4 => '1/4 s',
8585             5 => '1/2 s',
8586             6 => '1 s',
8587             7 => '2 s',
8588             8 => '4 s',
8589             9 => '8 s',
8590             10 => '15 s',
8591             11 => '30 s',
8592             },
8593             },
8594             23.1 => { # CSe3
8595             Name => 'FlashControlBuilt-in',
8596             Mask => 0xc0,
8597             RawConv => '$$self{FlashControlBuiltin} = $val',
8598             PrintConv => {
8599             0 => 'TTL',
8600             1 => 'Manual',
8601             2 => 'Repeating Flash',
8602             3 => 'Commander Mode',
8603             },
8604             },
8605             23.2 => { # CSe3-b
8606             Name => 'ManualFlashOutput',
8607             Condition => '$$self{FlashControlBuiltin} == 1',
8608             Mask => 0x1f,
8609             ValueConv => '2 ** (-$val/3)',
8610             ValueConvInv => '$val > 0 ? -3*log($val)/log(2) : 0',
8611             PrintConv => q{
8612             return 'Full' if $val > 0.99;
8613             Image::ExifTool::Exif::PrintExposureTime($val);
8614             },
8615             PrintConvInv => '$val=~/F/i ? 1 : Image::ExifTool::Exif::ConvertFraction($val)',
8616             },
8617             24.1 => { # CSe3-ca
8618             Name => 'RepeatingFlashOutput',
8619             Condition => '$$self{FlashControlBuiltin} == 2',
8620             Mask => 0x70,
8621             ValueConv => '2 ** (-$val-2)',
8622             ValueConvInv => '$val > 0 ? int(-log($val)/log(2)-2+0.5) : 0',
8623             PrintConv => 'Image::ExifTool::Exif::PrintExposureTime($val)',
8624             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
8625             },
8626             24.2 => { # CSe3-cb
8627             Name => 'RepeatingFlashCount',
8628             Condition => '$$self{FlashControlBuiltin} == 2',
8629             Mask => 0x0f,
8630             ValueConv => '$val < 10 ? $val + 1 : 5 * ($val - 7)',
8631             ValueConvInv => '$val <= 10 ? $val - 1 : $val / 5 + 7',
8632             },
8633             25.1 => { # CSe3-cc (NC)
8634             Name => 'RepeatingFlashRate',
8635             Condition => '$$self{FlashControlBuiltin} == 2',
8636             Mask => 0xf0,
8637             ValueConv => '$val < 10 ? $val + 1 : 10 * ($val - 8)',
8638             ValueConvInv => 'int(($val <= 10 ? $val - 1 : $val / 10 + 8) + 0.5)',
8639             PrintConv => '"$val Hz"',
8640             PrintConvInv => '$val=~/(\d+)/; $1 || 0',
8641             },
8642             26.1 => { # CSe3-da
8643             Name => 'CommanderInternalTTLCompBuiltin',
8644             Condition => '$$self{FlashControlBuiltin} == 3',
8645             Mask => 0x1f,
8646             ValueConv => '($val - 9) / 3',
8647             ValueConvInv => '$val * 3 + 9',
8648             PrintConv => '$val ? sprintf("%+.1f",$val) : 0',
8649             PrintConvInv => '$val',
8650             },
8651             27.1 => { # CSe3-db
8652             Name => 'CommanderInternalTTLCompGroupA',
8653             Condition => '$$self{FlashControlBuiltin} == 3',
8654             Mask => 0x1f,
8655             ValueConv => '($val - 9) / 3',
8656             ValueConvInv => '$val * 3 + 9',
8657             PrintConv => '$val ? sprintf("%+.1f",$val) : 0',
8658             PrintConvInv => '$val',
8659             },
8660             28.1 => { # CSe3-dc
8661             Name => 'CommanderInternalTTLCompGroupB',
8662             Condition => '$$self{FlashControlBuiltin} == 3',
8663             Mask => 0x1f,
8664             ValueConv => '($val - 9) / 3',
8665             ValueConvInv => '$val * 3 + 9',
8666             PrintConv => '$val ? sprintf("%+.1f",$val) : 0',
8667             PrintConvInv => '$val',
8668             },
8669             30.1 => { # CSd11
8670             Name => 'FlashWarning',
8671             Mask => 0x80,
8672             PrintConv => \%onOff,
8673             },
8674             30.2 => { # CSe4
8675             Name => 'ModelingFlash',
8676             Mask => 0x20,
8677             PrintConv => \%onOff,
8678             },
8679             34.1 => { # CSa8-b
8680             Name => 'LiveViewAFAreaMode',
8681             Mask => 0x60,
8682             PrintConv => {
8683             0 => 'Face-Priority',
8684             1 => 'NormalArea',
8685             2 => 'WideArea',
8686             3 => 'SubjectTracking',
8687             },
8688             },
8689             34.2 => { # CSa8-a
8690             Name => 'LiveViewAFMode',
8691             Mask => 0x02,
8692             PrintConv => {
8693             0 => 'AF-C',
8694             1 => 'AF-F',
8695             },
8696             },
8697             35.1 => { # CSc4-a
8698             Name => 'PlaybackMonitorOffTime',
8699             Mask => 0xe0,
8700             PrintConv => {
8701             0 => '4 s',
8702             1 => '10 s', # default
8703             2 => '20 s',
8704             3 => '1 min',
8705             4 => '5 min',
8706             5 => '10 min',
8707             },
8708             },
8709             );
8710              
8711             # D4/D4S custom settings (ref 1, decoded from D4S)
8712             %Image::ExifTool::NikonCustom::SettingsD4 = (
8713             PROCESS_PROC => \&Image::ExifTool::ProcessBinaryData,
8714             WRITE_PROC => \&Image::ExifTool::WriteBinaryData,
8715             CHECK_PROC => \&Image::ExifTool::CheckBinaryData,
8716             WRITABLE => 1,
8717             FIRST_ENTRY => 0,
8718             GROUPS => { 0 => 'MakerNotes', 2 => 'Camera' },
8719             NOTES => 'Custom settings for the D4 and D4S.',
8720             0.1 => {
8721             Name => 'CustomSettingsBank',
8722             Mask => 0x03,
8723             PrintConv => {
8724             0 => 'A',
8725             1 => 'B',
8726             2 => 'C',
8727             3 => 'D',
8728             },
8729             },
8730             1.1 => { #CSa1
8731             Name => 'AF-CPrioritySelection',
8732             Mask => 0xc0,
8733             PrintConv => {
8734             0 => 'Release',
8735             1 => 'Release + Focus',
8736             2 => 'Focus',
8737             3 => 'Focus + Release',
8738             },
8739             },
8740             1.2 => { # CSa2
8741             Name => 'AF-SPrioritySelection',
8742             Mask => 0x20,
8743             PrintConv => {
8744             0 => 'Focus',
8745             1 => 'Release',
8746             },
8747             },
8748             1.3 => { # CSa7
8749             Name => 'AFPointSelection',
8750             Mask => 0x10,
8751             PrintConv => {
8752             0 => '51 Points',
8753             1 => '11 Points',
8754             },
8755             },
8756             1.4 => { # CSa3
8757             Name => 'FocusTrackingLockOn',
8758             Mask => 0x07,
8759             PrintConv => {
8760             0 => 'Off',
8761             1 => '1 (Short)',
8762             2 => '2',
8763             3 => '3 (Normal)',
8764             4 => '4',
8765             5 => '5 (Long)',
8766             },
8767             },
8768             2.1 => { # CSa4
8769             Name => 'AFActivation',
8770             Mask => 0x80,
8771             PrintConv => {
8772             0 => 'Shutter/AF-On',
8773             1 => 'AF-On Only',
8774             },
8775             },
8776             2.2 => { # CSa6
8777             Name => 'FocusPointWrap',
8778             Mask => 0x08,
8779             PrintConv => {
8780             0 => 'No Wrap',
8781             1 => 'Wrap',
8782             },
8783             },
8784             4.1 => { # CSd1-b
8785             Name => 'Pitch',
8786             Mask => 0x40,
8787             PrintConv => { 0 => 'High', 1 => 'Low' },
8788             },
8789             4.2 => { # CSf12
8790             Name => 'NoMemoryCard',
8791             Mask => 0x20,
8792             PrintConv => {
8793             0 => 'Release Locked',
8794             1 => 'Enable Release',
8795             },
8796             },
8797             4.3 => { # CSd6
8798             Name => 'GridDisplay',
8799             Mask => 0x02,
8800             PrintConv => \%onOff,
8801             },
8802             5.1 => { # CSd9
8803             Name => 'ShootingInfoDisplay',
8804             Mask => 0xc0,
8805             PrintConv => {
8806             # 0 - seen for D4 (PH)
8807             1 => 'Auto',
8808             2 => 'Manual (dark on light)',
8809             3 => 'Manual (light on dark)',
8810             },
8811             },
8812             5.2 => { # CSd10
8813             Name => 'LCDIllumination',
8814             Mask => 0x20,
8815             PrintConv => \%offOn,
8816             },
8817             5.3 => { # CSd8
8818             Name => 'ScreenTips',
8819             Mask => 0x04,
8820             PrintConv => \%offOn,
8821             },
8822             5.4 => { # CSd1-a
8823             Name => 'Beep',
8824             Mask => 0x03,
8825             PrintConv => {
8826             0 => 'Off',
8827             1 => 'Low',
8828             2 => 'Medium',
8829             3 => 'High',
8830             },
8831             },
8832             6.1 => { # CSf13
8833             Name => 'ReverseIndicators',
8834             Mask => 0x80,
8835             PrintConv => {
8836             0 => '+ 0 -',
8837             1 => '- 0 +',
8838             },
8839             },
8840             6.2 => { # CSd7-a
8841             Name => 'RearDisplay',
8842             Mask => 0x40,
8843             PrintConv => {
8844             0 => 'ISO',
8845             1 => 'Exposures Remaining',
8846             },
8847             },
8848             6.3 => { # CSd7-b
8849             Name => 'ViewfinderDisplay',
8850             Mask => 0x20,
8851             PrintConv => {
8852             0 => 'Frame Count',
8853             1 => 'Exposures Remaining',
8854             },
8855             },
8856             6.4 => { # CSd10-a
8857             Name => 'CommandDialsReverseRotation',
8858             Mask => 0x18,
8859             PrintConv => {
8860             0 => 'No',
8861             1 => 'Shutter Speed & Aperture',
8862             2 => 'Exposure Compensation',
8863             3 => 'Exposure Compensation, Shutter Speed & Aperture',
8864             },
8865             },
8866             6.5 => { # CSb4
8867             Name => 'EasyExposureCompensation',
8868             Mask => 0x03,
8869             PrintConv => {
8870             0 => 'Off',
8871             1 => 'On',
8872             2 => 'On (auto reset)',
8873             },
8874             },
8875             7.1 => { # CSb2
8876             Name => 'ExposureControlStepSize',
8877             Mask => 0xc0,
8878             PrintConv => {
8879             0 => '1/3 EV',
8880             1 => '1/2 EV',
8881             2 => '1 EV',
8882             },
8883             },
8884             7.2 => { # CSb1
8885             Name => 'ISOStepSize',
8886             Mask => 0x30,
8887             PrintConv => {
8888             0 => '1/3 EV',
8889             1 => '1/2 EV',
8890             2 => '1 EV',
8891             },
8892             },
8893             7.3 => { # CSb3
8894             Name => 'ExposureCompStepSize',
8895             Mask => 0x0c,
8896             PrintConv => {
8897             0 => '1/3 EV',
8898             1 => '1/2 EV',
8899             2 => '1 EV',
8900             },
8901             },
8902             8.1 => { # CSb6 (CSb5 for D4)
8903             Name => 'CenterWeightedAreaSize',
8904             Mask => 0xe0,
8905             PrintConv => {
8906             0 => '8 mm',
8907             1 => '12 mm',
8908             2 => '15 mm',
8909             3 => '20 mm',
8910             4 => 'Average',
8911             },
8912             },
8913             8.2 => { # CSb7-a
8914             Name => 'FineTuneOptMatrixMetering',
8915             Mask => 0x0f,
8916             ValueConv => '($val > 0x7 ? $val - 0x10 : $val) / 6',
8917             ValueConvInv => 'int($val*6+($val>0?0.5:-0.5))',
8918             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
8919             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
8920             },
8921             9.1 => { # CSb7-b
8922             Name => 'FineTuneOptCenterWeighted',
8923             Mask => 0xf0,
8924             ValueConv => '($val > 0x7 ? $val - 0x10 : $val) / 6',
8925             ValueConvInv => 'int($val*6+($val>0?0.5:-0.5))',
8926             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
8927             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
8928             },
8929             9.2 => { # CSb7-c
8930             Name => 'FineTuneOptSpotMetering',
8931             Mask => 0x0f,
8932             ValueConv => '($val > 0x7 ? $val - 0x10 : $val) / 6',
8933             ValueConvInv => 'int($val*6+($val>0?0.5:-0.5))',
8934             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
8935             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
8936             },
8937             10.1 => { # CSf1-a
8938             Name => 'MultiSelectorShootMode',
8939             Mask => 0xc0,
8940             PrintConv => {
8941             0 => 'Select Center Focus Point (Reset)',
8942             2 => 'Preset Focus Point (Pre)',
8943             3 => 'Not Used (None)',
8944             },
8945             },
8946             10.2 => { # CSf1-b
8947             Name => 'MultiSelectorPlaybackMode',
8948             Mask => 0x30,
8949             PrintConv => {
8950             0 => 'Thumbnail On/Off',
8951             1 => 'View Histograms',
8952             2 => 'Zoom On/Off',
8953             3 => 'Choose Folder',
8954             },
8955             },
8956             10.3 => { # CSf2
8957             Name => 'MultiSelector',
8958             Mask => 0x01,
8959             PrintConv => {
8960             0 => 'Do Nothing',
8961             1 => 'Reset Meter-off Delay',
8962             },
8963             },
8964             11.1 => { # CSd4
8965             Name => 'ExposureDelayMode',
8966             Mask => 0xc0,
8967             PrintConv => {
8968             0 => 'Off',
8969             1 => '1 s',
8970             2 => '2 s',
8971             3 => '3 s',
8972             },
8973             },
8974             11.2 => { # CSd2-a
8975             Name => 'CHModeShootingSpeed',
8976             Mask => 0x10,
8977             PrintConv => {
8978             0 => '10 fps',
8979             1 => '11 fps',
8980             },
8981             },
8982             11.3 => { # CSd2-b
8983             Name => 'CLModeShootingSpeed',
8984             Mask => 0x0f,
8985             PrintConv => '"$val fps"',
8986             PrintConvInv => '$val=~s/\s*fps//i; $val',
8987             },
8988             12 => { # CSd3
8989             Name => 'MaxContinuousRelease',
8990             # values: 1-200
8991             },
8992             13.1 => { # CSe6
8993             Name => 'AutoBracketSet',
8994             Mask => 0xe0,
8995             PrintConv => {
8996             0 => 'AE & Flash',
8997             1 => 'AE Only',
8998             2 => 'Flash Only',
8999             3 => 'WB Bracketing',
9000             4 => 'Active D-Lighting',
9001             },
9002             },
9003             13.2 => { # CSe8
9004             Name => 'AutoBracketOrder',
9005             Mask => 0x10,
9006             PrintConv => {
9007             0 => '0,-,+',
9008             1 => '-,0,+',
9009             },
9010             },
9011             13.3 => { # CSe7
9012             Name => 'AutoBracketModeM',
9013             Mask => 0x0c,
9014             PrintConv => {
9015             0 => 'Flash/Speed',
9016             1 => 'Flash/Speed/Aperture',
9017             2 => 'Flash/Aperture',
9018             3 => 'Flash Only',
9019             },
9020             },
9021             14.1 => { # CSf3-a
9022             Name => 'FuncButton',
9023             Mask => 0xf8,
9024             PrintConv => {
9025             0 => 'None',
9026             1 => 'Preview',
9027             2 => 'FV Lock',
9028             3 => 'AE/AF Lock',
9029             4 => 'AE Lock Only',
9030             5 => 'AE Lock (reset on release)',
9031             6 => 'AE Lock (hold)',
9032             7 => 'AF Lock Only',
9033             8 => 'AF-On',
9034             10 => 'Bracketing Burst',
9035             11 => 'Matrix Metering',
9036             12 => 'Center-weighted Metering',
9037             13 => 'Spot Metering',
9038             14 => 'Playback',
9039             15 => 'My Menu Top Item',
9040             16 => '+NEF(RAW)',
9041             17 => 'Virtual Horizon',
9042             18 => 'My Menu',
9043             20 => 'Grid Display',
9044             21 => 'Disable Synchronized Release',
9045             22 => 'Remote Release Only',
9046             26 => 'Flash Disable/Enable',
9047             },
9048             },
9049             14.2 => { # CSf3-b
9050             Name => 'FuncButtonPlusDials',
9051             Mask => 0x07,
9052             PrintConv => {
9053             0 => 'None',
9054             1 => 'Choose Image Area (FX/DX/5:4)',
9055             2 => 'Shutter Speed & Aperture Lock',
9056             3 => 'One Step Speed / Aperture',
9057             4 => 'Choose Non-CPU Lens Number',
9058             5 => 'Active D-Lighting',
9059             6 => 'Shooting Bank Menu',
9060             },
9061             },
9062             15.1 => { # CSf4-a
9063             Name => 'PreviewButton',
9064             Mask => 0xf8,
9065             PrintConv => {
9066             0 => 'None',
9067             1 => 'Preview',
9068             2 => 'FV Lock',
9069             3 => 'AE/AF Lock',
9070             4 => 'AE Lock Only',
9071             5 => 'AE Lock (reset on release)',
9072             6 => 'AE Lock (hold)',
9073             7 => 'AF Lock Only',
9074             8 => 'AF-On',
9075             10 => 'Bracketing Burst',
9076             11 => 'Matrix Metering',
9077             12 => 'Center-weighted Metering',
9078             13 => 'Spot Metering',
9079             14 => 'Playback',
9080             15 => 'My Menu Top Item',
9081             16 => '+NEF(RAW)',
9082             17 => 'Virtual Horizon',
9083             18 => 'My Menu',
9084             20 => 'Grid Display',
9085             21 => 'Disable Synchronized Release',
9086             22 => 'Remote Release Only',
9087             26 => 'Flash Disable/Enable',
9088             },
9089             },
9090             15.2 => { # CSf4-b
9091             Name => 'PreviewButtonPlusDials',
9092             Mask => 0x07,
9093             PrintConv => {
9094             0 => 'None',
9095             1 => 'Choose Image Area (FX/DX/5:4)',
9096             2 => 'Shutter Speed & Aperture Lock',
9097             3 => 'One Step Speed / Aperture',
9098             4 => 'Choose Non-CPU Lens Number',
9099             5 => 'Active D-Lighting',
9100             6 => 'Shooting Bank Menu',
9101             },
9102             },
9103             16.1 => { # CSf9
9104             Name => 'AssignBktButton',
9105             Mask => 0x07,
9106             PrintConv => {
9107             0 => 'Auto Bracketing',
9108             1 => 'Multiple Exposure',
9109             2 => 'HDR (high dynamic range)',
9110             3 => 'None',
9111             },
9112             },
9113             18.1 => { # CSf10-b
9114             Name => 'CommandDialsChangeMainSub',
9115             Mask => 0xe0,
9116             PrintConv => {
9117             0 => 'Autofocus Off, Exposure Off',
9118             1 => 'Autofocus Off, Exposure On',
9119             2 => 'Autofocus Off, Exposure On (Mode A)',
9120             4 => 'Autofocus On, Exposure Off',
9121             5 => 'Autofocus On, Exposure On',
9122             6 => 'Autofocus On, Exposure On (Mode A)',
9123             },
9124             },
9125             18.2 => { # CSf10-d
9126             Name => 'CommandDialsMenuAndPlayback',
9127             Mask => 0x18,
9128             PrintConv => {
9129             0 => 'On',
9130             1 => 'Off',
9131             2 => 'On (Image Review Excluded)',
9132             },
9133             },
9134             18.3 => { # CSf10-c
9135             Name => 'CommandDialsApertureSetting',
9136             Mask => 0x04,
9137             PrintConv => {
9138             0 => 'Sub-command Dial',
9139             1 => 'Aperture Ring',
9140             },
9141             },
9142             18.4 => { # CSc1
9143             Name => 'ShutterReleaseButtonAE-L',
9144             Mask => 0x02,
9145             PrintConv => \%offOn,
9146             },
9147             18.5 => { # CSf11
9148             Name => 'ReleaseButtonToUseDial',
9149             Mask => 0x01,
9150             PrintConv => \%noYes,
9151             },
9152             19.1 => { # CSc2
9153             Name => 'StandbyTimer',
9154             Mask => 0xf0,
9155             PrintConv => {
9156             0 => '4 s',
9157             1 => '6 s',
9158             3 => '10 s',
9159             5 => '30 s',
9160             6 => '1 min',
9161             7 => '5 min',
9162             8 => '10 min',
9163             9 => '30 min',
9164             },
9165             },
9166             20.1 => { # CSc3-a
9167             Name => 'SelfTimerTime',
9168             Mask => 0xc0,
9169             PrintConv => {
9170             0 => '2 s',
9171             1 => '5 s',
9172             2 => '10 s',
9173             3 => '20 s',
9174             },
9175             },
9176             20.2 => { # CSc3-b
9177             Name => 'SelfTimerShotCount',
9178             Mask => 0x0f,
9179             },
9180             20.3 => { # CSc3-c
9181             Name => 'SelfTimerShotInterval',
9182             Mask => 0x30,
9183             PrintConv => {
9184             0 => '0.5 s',
9185             1 => '1 s',
9186             2 => '2 s',
9187             3 => '3 s',
9188             },
9189             },
9190             21.1 => { # CSc4-d
9191             Name => 'ImageReviewMonitorOffTime',
9192             Mask => 0xe0,
9193             PrintConv => {
9194             0 => '2 s',
9195             1 => '4 s',
9196             2 => '10 s',
9197             3 => '20 s',
9198             4 => '1 min',
9199             5 => '5 min',
9200             6 => '10 min',
9201              
9202             },
9203             },
9204             21.2 => { # CSc4-e
9205             Name => 'LiveViewMonitorOffTime',
9206             Mask => 0x1c,
9207             PrintConv => {
9208             0 => '5 min',
9209             1 => '10 min',
9210             2 => '15 min',
9211             3 => '20 min',
9212             4 => '30 min',
9213             5 => 'No Limit',
9214             },
9215             },
9216             22.1 => { # CSc4-b
9217             Name => 'MenuMonitorOffTime',
9218             Mask => 0xe0,
9219             PrintConv => {
9220             0 => '4 s',
9221             1 => '10 s',
9222             2 => '20 s',
9223             3 => '1 min',
9224             4 => '5 min',
9225             5 => '10 min',
9226             },
9227             },
9228             22.2 => { # CSc4-c
9229             Name => 'ShootingInfoMonitorOffTime',
9230             Mask => 0x1c,
9231             PrintConv => {
9232             0 => '4 s',
9233             1 => '10 s',
9234             2 => '20 s',
9235             3 => '1 min',
9236             4 => '5 min',
9237             5 => '10 min',
9238             },
9239             },
9240             23.1 => { # CSe1
9241             Name => 'FlashSyncSpeed',
9242             Mask => 0xf0,
9243             PrintConv => {
9244             # 0x00 - seen for D4 (PH)
9245             1 => '1/250 s (auto FP)',
9246             2 => '1/250 s',
9247             3 => '1/200 s',
9248             4 => '1/160 s',
9249             5 => '1/125 s',
9250             6 => '1/100 s',
9251             7 => '1/80 s',
9252             8 => '1/60 s',
9253             },
9254             },
9255             23.2 => { # CSe2
9256             Name => 'FlashShutterSpeed',
9257             Mask => 0x0f,
9258             PrintConvColumns => 2,
9259             PrintConv => {
9260             0 => '1/60 s',
9261             1 => '1/30 s',
9262             2 => '1/15 s',
9263             3 => '1/8 s',
9264             4 => '1/4 s',
9265             5 => '1/2 s',
9266             6 => '1 s',
9267             7 => '2 s',
9268             8 => '4 s',
9269             9 => '8 s',
9270             10 => '15 s',
9271             11 => '30 s',
9272             },
9273             },
9274             31.1 => { # CSe5
9275             Name => 'ModelingFlash',
9276             Mask => 0x20,
9277             PrintConv => \%onOff,
9278             },
9279             36.1 => { # CSc4-a
9280             Name => 'PlaybackMonitorOffTime',
9281             Mask => 0xe0,
9282             PrintConv => {
9283             0 => '4 s',
9284             1 => '10 s',
9285             2 => '20 s',
9286             3 => '1 min',
9287             4 => '5 min',
9288             5 => '10 min',
9289             },
9290             },
9291             37.1 => { # CSf15
9292             Name => 'PlaybackZoom',
9293             Mask => 0x01,
9294             PrintConv => {
9295             0 => 'Use Separate Zoom Buttons',
9296             1 => 'Use Either Zoom Button with Command Dial',
9297             },
9298             },
9299             38.1 => { # CSf8-a
9300             Name => 'ShutterSpeedLock',
9301             Mask => 0x80,
9302             PrintConv => \%offOn,
9303             },
9304             38.2 => { # CSf8-b
9305             Name => 'ApertureLock',
9306             Mask => 0x40,
9307             PrintConv => \%offOn,
9308             },
9309             38.3 => { # CSg4
9310             Name => 'MovieShutterButton',
9311             Mask => 0x30,
9312             PrintConv => {
9313             0 => 'Take Photo',
9314             1 => 'Record Movies',
9315             2 => 'Live Frame Grab',
9316             },
9317             },
9318             38.4 => { # CSe4
9319             Name => 'FlashExposureCompArea',
9320             Mask => 0x04,
9321             PrintConv => {
9322             0 => 'Entire frame',
9323             1 => 'Background only',
9324             },
9325             },
9326             41.1 => { # CSg1-a
9327             Name => 'MovieFunctionButton',
9328             Mask => 0x70,
9329             PrintConv => {
9330             0 => 'None',
9331             1 => 'Power Aperture (open)', # bit '02' is also toggled on for this setting
9332             3 => 'Index Marking',
9333             4 => 'View Photo Shooting Info',
9334             },
9335             },
9336             41.2 => { # CSg2-a
9337             Name => 'MoviePreviewButton',
9338             Mask => 0x07,
9339             PrintConv => {
9340             0 => 'None',
9341             2 => 'Power Aperture (open)', # bit '10' is also toggled on for this setting
9342             3 => 'Index Marking',
9343             4 => 'View Photo Shooting Info',
9344             },
9345             },
9346             42.1 => { # CSf14
9347             Name => 'VerticalMultiSelector',
9348             Mask => 0x60,
9349             PrintConv => {
9350             0 => 'Same as Multi-Selector with Info(U/D) & Playback(R/L)',
9351             1 => 'Same as Multi-Selector with Info(R/L) & Playback(U/D)',
9352             2 => 'Focus Point Selection',
9353             },
9354             },
9355             42.2 => { # CSf7-a
9356             Name => 'VerticalFuncButton',
9357             Mask => 0x1f,
9358             PrintConv => {
9359             0 => 'None',
9360             1 => 'Preview',
9361             2 => 'FV Lock',
9362             3 => 'AE/AF Lock',
9363             4 => 'AE Lock Only',
9364             5 => 'AE Lock (reset on release)',
9365             6 => 'AE Lock (hold)',
9366             7 => 'AF Lock Only',
9367             10 => 'Bracketing Burst',
9368             11 => 'Matrix Metering',
9369             12 => 'Center-weighted Metering',
9370             13 => 'Spot Metering',
9371             14 => 'Playback',
9372             15 => 'My Menu Top Item',
9373             16 => '+NEF(RAW)',
9374             17 => 'Virtual Horizon',
9375             18 => 'My Menu',
9376             20 => 'Grid Display',
9377             26 => 'Flash Disable/Enable',
9378             },
9379             },
9380             43.1 => { # CSf7-b
9381             Name => 'VerticalFuncButtonPlusDials',
9382             Mask => 0xf0,
9383             PrintConv => {
9384             0 => 'None',
9385             1 => 'Choose Image Area (FX/DX/5:4)',
9386             2 => 'Shutter Speed & Aperture Lock',
9387             3 => 'One Step Speed / Aperture',
9388             4 => 'Choose Non-CPU Lens Number',
9389             5 => 'Active D-Lighting',
9390             6 => 'Shooting Bank Menu',
9391             7 => 'ISO Sensitivity',
9392             8 => 'Exposure Mode',
9393             9 => 'Exposure Compensation',
9394             10 => 'Metering',
9395             },
9396             },
9397             43.2 => { # CSf16
9398             Name => 'AssignMovieRecordButton',
9399             Mask => 0x07,
9400             PrintConv => {
9401             0 => 'None',
9402             1 => 'Choose Image Area (FX/DX/5:4)',
9403             2 => 'Shutter Speed & Aperture Lock',
9404             3 => 'ISO Sensitivity',
9405             4 => 'Shooting Bank Menu',
9406             },
9407             },
9408             46.1 => { # CSa5-c
9409             Name => 'DynamicAreaAFDisplay',
9410             Mask => 0x80,
9411             PrintConv => \%offOn,
9412             },
9413             46.2 => { # CSa5-a
9414             Name => 'AFPointIllumination',
9415             Mask => 0x60,
9416             PrintConv => {
9417             0 => 'Off',
9418             1 => 'On in Continuous Shooting Modes',
9419             2 => 'On During Manual Focusing',
9420             3 => 'On in Continuous Shooting and Manual Focusing',
9421             },
9422             },
9423             46.3 => { # CSa10 (D4 is slightly different -- needs checking)
9424             Name => 'StoreByOrientation',
9425             Mask => 0x18,
9426             PrintConv => {
9427             0 => 'Off',
9428             1 => 'Focus Point',
9429             2 => 'Focus Point and AF-area mode',
9430             },
9431             },
9432             46.4 => { # CSa5-d
9433             Name => 'GroupAreaAFIllumination',
9434             Mask => 0x04,
9435             PrintConv => {
9436             0 => 'Squares',
9437             1 => 'Dots',
9438             },
9439             },
9440             46.5 => { # CSa5-b
9441             Name => 'AFPointBrightness',
9442             Mask => 0x03,
9443             PrintConv => {
9444             0 => 'Low',
9445             1 => 'Normal',
9446             2 => 'High',
9447             3 => 'Extra High',
9448             },
9449             },
9450             47.1 => { # CSa8
9451             Name => 'AFOnButton',
9452             Mask => 0x70,
9453             PrintConv => {
9454             0 => 'AF On',
9455             1 => 'AE/AF Lock',
9456             2 => 'AE Lock Only',
9457             3 => 'AE Lock (reset on release)',
9458             4 => 'AE Lock (hold)',
9459             5 => 'AF Lock Only',
9460             6 => 'None',
9461             },
9462             },
9463             47.2 => { # CSa9
9464             Name => 'VerticalAFOnButton',
9465             Mask => 0x07,
9466             PrintConv => {
9467             0 => 'Same as AF On',
9468             1 => 'AF On',
9469             2 => 'AE/AF Lock',
9470             3 => 'AE Lock Only',
9471             4 => 'AE Lock (reset on release)',
9472             5 => 'AE Lock (hold)',
9473             6 => 'AF Lock Only',
9474             7 => 'None',
9475             },
9476             },
9477             48.1 => { # CSf5
9478             Name => 'SubSelectorAssignment',
9479             Mask => 0x80,
9480             PrintConv => {
9481             0 => 'Focus Point Selection',
9482             1 => 'Same As Multi-selector',
9483             },
9484             },
9485             48.2 => { # CSg3-a
9486             Name => 'MovieSubSelectorAssignment',
9487             Mask => 0x07,
9488             PrintConv => {
9489             0 => 'None',
9490             1 => 'Index Marking',
9491             2 => 'AE/AF Lock',
9492             3 => 'AE Lock Only',
9493             4 => 'AE Lock (hold)',
9494             5 => 'AF Lock Only',
9495             6 => 'View Photo Shooting Info',
9496             },
9497             },
9498             49.1 => { # CSf6-a
9499             Name => 'SubSelector',
9500             Mask => 0xf8,
9501             PrintConv => {
9502             0 => 'None',
9503             1 => 'Preview',
9504             2 => 'FV Lock',
9505             3 => 'AE/AF Lock',
9506             4 => 'AE Lock Only',
9507             5 => 'AE Lock (reset on release)',
9508             6 => 'AE Lock (hold)',
9509             7 => 'AF Lock Only',
9510             8 => 'AF-On',
9511             # 9 - seen for D4 (PH)
9512             10 => 'Bracketing Burst',
9513             11 => 'Matrix Metering',
9514             12 => 'Center-weighted Metering',
9515             13 => 'Spot Metering',
9516             14 => 'Playback',
9517             15 => 'My Menu Top Item',
9518             16 => '+NEF(RAW)',
9519             17 => 'Virtual Horizon',
9520             18 => 'My Menu',
9521             19 => 'Reset', # value appears to be specific to this control at this time
9522             20 => 'Grid Display',
9523             21 => 'Disable Synchronized Release',
9524             22 => 'Remote Release Only',
9525             23 => 'Preview', # value appears to be specific to this control at this time
9526             26 => 'Flash Disable/Enable',
9527             },
9528             },
9529             49.2 => { # CSf6-b
9530             Name => 'SubSelectorPlusDials',
9531             Mask => 0x07,
9532             PrintConv => {
9533             # (not all values from CSf3-b/CSf4-b are available for CSf6-b)
9534             0 => 'None',
9535             1 => 'Choose Image Area (FX/DX/5:4)',
9536             2 => 'Shutter Speed & Aperture Lock',
9537             # 3 => 'One Step Speed / Aperture', # (not available)
9538             4 => 'Choose Non-CPU Lens Number',
9539             # 5 => 'Active D-Lighting', # (not available)
9540             6 => 'Shooting Bank Menu',
9541             },
9542             },
9543             50.1 => { # CSb5
9544             Name => 'MatrixMetering',
9545             Condition => '$$self{Model} =~ /\bD4S/',
9546             Notes => 'D4S only',
9547             Mask => 0x80,
9548             PrintConv => {
9549             0 => 'Face Detection On',
9550             1 => 'Face Detection Off',
9551             },
9552             },
9553             50.2 => { # CSf17
9554             Name => 'LiveViewButtonOptions',
9555             Condition => '$$self{Model} =~ /\bD4S/',
9556             Notes => 'D4S only',
9557             Mask => 0x30,
9558             PrintConv => {
9559             0 => 'Enable',
9560             1 => 'Enable (standby time active)',
9561             2 => 'Disable',
9562             },
9563             },
9564             50.3 => { # CSa12
9565             Name => 'AFModeRestrictions',
9566             Condition => '$$self{Model} =~ /\bD4S/',
9567             Notes => 'D4S only',
9568             Mask => 0x03,
9569             PrintConv => {
9570             0 => 'Off',
9571             1 => 'AF-C',
9572             2 => 'AF-S',
9573             },
9574             },
9575             51.1 => { # CSa11
9576             Name => 'LimitAFAreaModeSelection',
9577             Condition => '$$self{Model} =~ /\bD4S/',
9578             Notes => 'D4S only',
9579             Mask => 0x7e,
9580             PrintConv => {
9581             0 => 'No Restrictions',
9582             BITMASK => {
9583             0 => 'Auto-area',
9584             1 => 'Group-area',
9585             2 => '3D-tracking',
9586             3 => 'Dynamic area (51 points)',
9587             4 => 'Dynamic area (21 points)',
9588             5 => 'Dynamic area (9 points)',
9589             },
9590             },
9591             },
9592             52.1 => { # CSg1-b
9593             Name => 'MovieFunctionButtonPlusDials',
9594             Mask => 0x10,
9595             PrintConv => {
9596             0 => 'None',
9597             1 => 'Choose Image Area',
9598             },
9599             },
9600             52.2 => { # CSg2-b
9601             Name => 'MoviePreviewButtonPlusDials',
9602             Mask => 0x01,
9603             PrintConv => {
9604             0 => 'None',
9605             1 => 'Choose Image Area',
9606             },
9607             },
9608             53.1 => { # CSg3-b
9609             Name => 'MovieSubSelectorAssignmentPlusDials',
9610             Mask => 0x10,
9611             PrintConv => {
9612             0 => 'None',
9613             1 => 'Choose Image Area',
9614             },
9615             },
9616             54.1 => { # CSf18
9617             Name => 'AssignRemoteFnButton',
9618             Condition => '$$self{Model} =~ /\bD4S/',
9619             Notes => 'D4S only',
9620             Mask => 0x1f,
9621             PrintConv => {
9622             0 => 'None',
9623             1 => 'Preview',
9624             2 => 'FV Lock',
9625             3 => 'AE/AF Lock',
9626             4 => 'AE Lock Only',
9627             5 => 'AE Lock (reset on release)',
9628             7 => 'AF Lock Only',
9629             8 => 'AF-On',
9630             16 => '+NEF(RAW)',
9631             25 => 'Live View',
9632             26 => 'Flash Disable/Enable',
9633             },
9634             },
9635             55.1 => { # CSf19
9636             Name => 'LensFocusFunctionButtons',
9637             Condition => '$$self{Model} =~ /\bD4S/',
9638             Notes => 'D4S only',
9639             Mask => 0x3f,
9640             PrintConv => {
9641             3 => 'AE/AF Lock',
9642             4 => 'AE Lock Only',
9643             7 => 'AF Lock Only',
9644             21 => 'Disable Synchronized Release',
9645             22 => 'Remote Release Only',
9646             24 => 'Preset focus Point',
9647             26 => 'Flash Disable/Enable',
9648             32 => 'AF-Area Mode: Single-point AF',
9649             33 => 'AF-Area Mode: Dynamic-area AF (9 points)',
9650             34 => 'AF-Area Mode: Dynamic-area AF (21 points)',
9651             35 => 'AF-Area Mode: Dynamic-area AF (51 points)',
9652             36 => 'AF-Area Mode: Group-area AF',
9653             37 => 'AF-Area Mode: Auto area AF',
9654             },
9655             },
9656             );
9657              
9658             # Z9 custom settings (ref 1) #base at offset26 + 1035 (firmware 1.0.0)
9659             %Image::ExifTool::NikonCustom::SettingsZ9 = (
9660             PROCESS_PROC => \&Image::ExifTool::ProcessBinaryData,
9661             WRITE_PROC => \&Image::ExifTool::WriteBinaryData,
9662             CHECK_PROC => \&Image::ExifTool::CheckBinaryData,
9663             DATAMEMBER => [ 185, 529 ],
9664             WRITABLE => 1,
9665             FIRST_ENTRY => 0,
9666             GROUPS => { 0 => 'MakerNotes', 2 => 'Camera' },
9667             NOTES => 'Custom settings for the Z9.',
9668             1 => {
9669             Name => 'CustomSettingsBank',
9670             PrintConv => {
9671             0 => 'A',
9672             1 => 'B',
9673             2 => 'C',
9674             3 => 'D',
9675             },
9676             },
9677             3 => { # CSa1
9678             Name => 'AF-CPrioritySelection',
9679             PrintConv => {
9680             0 => 'Release',
9681             1 => 'Release + Focus',
9682             3 => 'Focus',
9683             },
9684             },
9685             5 => { Name => 'AF-SPrioritySelection', PrintConv => {0 => 'Release',1 => 'Focus'}}, #CSa2
9686             7 => { # CSa3-a #when AFAreaMode is 3D-tracking, blocked shot response will be 3, regardless of this setting
9687             Name => 'BlockShotAFResponse',
9688             PrintConv => {
9689             1 => '1 (Quick)',
9690             2 => '2',
9691             3 => '3 (Normal)',
9692             4 => '4',
9693             5 => '5 (Delayed)',
9694             },
9695             },
9696             11 => {Name => 'AFPointSel',PrintConv => { 0 => 'Use All',1 => 'Use Half' }}, # CSa4
9697             13 => { # CSa5
9698             Name => 'StoreByOrientation',
9699             PrintConv => {
9700             0 => 'Off',
9701             1 => 'Focus Point',
9702             2 => 'Focus Point and AF-area mode',
9703             },
9704             },
9705             15 => { Name => 'AFActivation', PrintConv => {0 => 'AF-On Only', 1 => 'Shutter/AF-On'}}, # CSa6-a
9706             16 => { Name => 'AF-OnOutOfFocusRelease', PrintConv => {0 => 'Disable', 1 => 'Enable'}, Unknown => 1}, # CSa6-b
9707             17 => { Name => 'LimitAF-AreaModeSelPinpoint', PrintConv => \%limitNolimit, Unknown => 1 }, # CSa8
9708             19 => { Name => 'LimitAF-AreaModeSelWideAF_S', PrintConv => \%limitNolimit, Unknown => 1 }, # CSa8
9709             20 => { Name => 'LimitAF-AreaModeSelWideAF_L', PrintConv => \%limitNolimit, Unknown => 1 }, # CSa8
9710             21 => { Name => 'LimitAFAreaModeSelAuto', PrintConv => \%limitNolimit, Unknown => 1 }, # CSa8 #left out hypen to retain compatibility with tag name in NikonSettings
9711             22 => { Name => 'FocusPointWrap', PrintConv => { 0 => 'No Wrap', 1 => 'Wrap' }, Unknown => 1 }, # CSa10
9712             23 => { Name => 'ManualFocusPointIllumination', PrintConv => {0 => 'On During Focus Point Selection Only', 1 => 'On', }, Unknown => 1 }, # CSa11a
9713             24 => { Name => 'DynamicAreaAFAssist', PrintConv => { 0 => 'Focus Point Only',1 => 'Focus and Surrounding Points',}, Unknown => 1 }, # CSa11b
9714             25 => { Name => 'AF-AssistIlluminator', PrintConv => \%offOn }, # CSa12
9715             26 => { Name => 'ManualFocusRingInAFMode', PrintConv => \%offOn }, # CSa14
9716             27 => { Name => 'ExposureControlStepSize', PrintConv => \%thirdHalfFull }, # CSb2
9717             29 => { # CSb3
9718             Name => 'EasyExposureCompensation',
9719             PrintConv => {
9720             0 => 'Off',
9721             1 => 'On',
9722             2 => 'On (auto reset)',
9723             },
9724             },
9725             31 => { # CSb5
9726             Name => 'CenterWeightedAreaSize',
9727             PrintConv => {
9728             0 => '8 mm',
9729             1 => '12 mm',
9730             4 => 'Average',
9731             },
9732             },
9733             33 => { # CSb6-a
9734             Name => 'FineTuneOptMatrixMetering',
9735             Format => 'int8s',
9736             ValueConv => '$val / 6',
9737             ValueConvInv => 'int($val*6)',
9738             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
9739             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
9740             },
9741             35 => { # CSb6-b
9742             Name => 'FineTuneOptCenterWeighted',
9743             Format => 'int8s',
9744             ValueConv => '$val / 6',
9745             ValueConvInv => 'int($val*6)',
9746             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
9747             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
9748             },
9749             37 => { # CSb6-c
9750             Name => 'FineTuneOptSpotMetering',
9751             Format => 'int8s',
9752             ValueConv => '$val / 6',
9753             ValueConvInv => 'int($val*6)',
9754             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
9755             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
9756             },
9757             39 => { # CSb6-d
9758             Name => 'FineTuneOptHighlightWeighted',
9759             Format => 'int8s',
9760             ValueConv => '$val / 6',
9761             ValueConvInv => 'int($val*6)',
9762             PrintConv => '$val ? sprintf("%+.2f", $val) : 0',
9763             PrintConvInv => 'Image::ExifTool::Exif::ConvertFraction($val)',
9764             },
9765             41 => { # CSc1
9766             Name => 'ShutterReleaseButtonAE-L',
9767             PrintConv => {
9768             0 => 'Off',
9769             1 => 'On (Half Press)',
9770             2 => 'On (Burst Mode)',
9771             },
9772             },
9773             43 => { # CSc3-a
9774             Name => 'SelfTimerTime',
9775             PrintConv => {
9776             0 => '2 s',
9777             1 => '5 s',
9778             2 => '10 s',
9779             3 => '20 s',
9780             },
9781             },
9782             45 => { Name => 'SelfTimerShotCount', }, # CSc3-b 1-9
9783             49 => { # CSc3-c
9784             Name => 'SelfTimerShotInterval',
9785             PrintConv => {
9786             0 => '0.5 s',
9787             1 => '1 s',
9788             2 => '2 s',
9789             3 => '3 s',
9790             },
9791             },
9792             51 => { Name => 'PlaybackMonitorOffTime', %powerOffDelayTimesZ9 }, # CSc4-a
9793             53 => { Name => 'MenuMonitorOffTime', %powerOffDelayTimesZ9 }, # CSc4-b
9794             55 => { Name => 'ShootingInfoMonitorOffTime',%powerOffDelayTimesZ9 }, # CSc4-c
9795             57 => { Name => 'ImageReviewMonitorOffTime', %powerOffDelayTimesZ9 }, # CSc4-d
9796             59 => { Name => 'CLModeShootingSpeed', ValueConv => '$val + 1', ValueConvInv => '$val - 1', PrintConv => '"$val fps"', PrintConvInv => '$val=~s/\s*fps//i; $val' }, # CSd1b
9797             61 => { # CSd2 # values: 1-200 & 'No Limit'
9798             Name => 'MaxContinuousRelease',
9799             Format => 'int16s',
9800             ValueConv => '($val = -1 ? \'No Limit\' : $val ) ',
9801             },
9802             65 => { Name => 'SyncReleaseMode', PrintConv => { 0 => 'No Sync', 1 => 'Sync' }, Unknown => 1 }, # CSd4
9803             69 => { Name => 'LimitSelectableImageAreaDX', PrintConv => \%limitNolimit, Unknown => 1 }, # CSd6-1
9804             70 => { Name => 'LimitSelectableImageArea1To1', PrintConv => \%limitNolimit, Unknown => 1 }, # CSd6-2
9805             71 => { Name => 'LimitSelectableImageArea16To9', PrintConv => \%limitNolimit, Unknown => 1 }, # CSd6-3
9806             72 => { Name => 'FileNumberSequence', PrintConv => \%offOn }, # CSd7
9807             73 => { #CSa13b
9808             Name => 'FocusPeakingLevel',
9809             Unknown => 1,
9810             PrintConv => {
9811             0 => 'High Sensitivity',
9812             1 => 'Standard Sensitivity',
9813             2 => 'Low Sensitivity',
9814             },
9815             },
9816             75 => { #CSa13c
9817             Name => 'FocusPeakingHighlightColor',
9818             Unknown => 1,
9819             PrintConv => {
9820             0 => 'Red',
9821             1 => 'Yellow',
9822             2 => 'Blue',
9823             3 => 'White',
9824             },
9825             },
9826             81 => { Name => 'ContinuousModeDisplay', PrintConv => \%offOn }, # CSd12
9827             83 => { # CSe1-a Previous cameras reported this with HighSpeedSync indicator appended as '(Auto FP)'. Z9 separated the 2 fields.
9828             Name => 'FlashSyncSpeed',
9829             ValueConv => '($val-144)/8',
9830             PrintConv => {
9831             0 => '1/60 s',
9832             1 => '1/80 s',
9833             2 => '1/100 s',
9834             3 => '1/125 s',
9835             4 => '1/160 s',
9836             5 => '1/200 s',
9837             6 => '1/250 s',
9838             },
9839             },
9840             85 => { Name => 'HighSpeedSync', PrintConv => \%offOn }, # CSe1-b
9841             87 => { # CSe2
9842             Name => 'FlashShutterSpeed',
9843             ValueConv => 'my $t = ($val - 16) % 24; $t ? $val / 24 : 2 + ($val - 16) / 24', #unusual decode perhaps due to need to accomodate 4 new values?
9844             PrintConv => {
9845             0 => '1 s',
9846             1 => '1/2 s',
9847             2 => '1/4 s',
9848             3 => '1/8 s',
9849             4 => '1/15 s',
9850             5 => '1/30 s',
9851             6 => '1/60 s',
9852             7 => '30 s',
9853             8 => '15 s',
9854             9 => '8 s',
9855             10 => '4 s',
9856             11 => '2 s',
9857             },
9858             },
9859             89 => { Name => 'FlashExposureCompArea', PrintConv => { 0 => 'Entire Frame', 1 => 'Background Only' } }, # CSe3
9860             91 => { Name => 'AutoFlashISOSensitivity', PrintConv => { 0 => 'Subject and Background',1 => 'Subject Only'} }, # CSe4
9861             93 => { Name => 'ModelingFlash', PrintConv => \%offOn }, # CSe5
9862             95 => { # CSe6
9863             Name => 'AutoBracketModeM',
9864             PrintConv => {
9865             0 => 'Flash/Speed',
9866             1 => 'Flash/Speed/Aperture',
9867             2 => 'Flash/Aperture',
9868             3 => 'Flash Only',
9869             4 => 'Flash/ISO',
9870             },
9871             },
9872             97 => { Name => 'AutoBracketOrder', PrintConv => { 0 => '0,-,+',1 => '-,0,+' } }, # CSe7
9873             99 => { Name => 'Func1Button', %buttonsZ9}, # CSf2-a
9874             #101 Func1Button submenu: Preview 0 => 'Press To Recall', 1=> 'Hold To Recall' # CSf2-a
9875             #103 Func1Button submenu: AreaMode 0-7 => S, Dyn-S, Dyn-M, Dyn-L, Wide-S, Wide-L, 3D, Auto; 11=>n/a # CSf2-a
9876             #105 Func1Button submenu: AreaMode+AF-On 0-7 => S, Dyn-S, Dyn-M, Dyn-L, Wide-S, Wide-L, 3D, Auto; 11=>n/a # CSf2-a
9877             #109 Func1Button submenu: SynchronizedRelease 1=>'Master', 2=>'Remote' # CSf2-a
9878             #111 Func1Button submenu: Zoom 0=>'Zoom (Low)', 2=>'Zoom (1:1)', 2=>'Zoom (High)' # CSf2-a
9879             #113 Func1Button & Func1ButtonPlayback submenu: Rating # CSf2-a & CSf3a 0=>'Candidate For Deletion' 6=>''None'
9880             115 => { Name => 'Func2Button', %buttonsZ9}, # CSf2-b
9881             #117 Func2Button submenu: Preview 0 => 'Press To Recall', 1=> 'Hold To Recall' # CSf2-b
9882             #119 Func2Button submenu: AreaMode 0-7 => S, Dyn-S, Dyn-M, Dyn-L, Wide-S, Wide-L, 3D, Auto; 11=>n/a # CSf2-b
9883             #121 Func2Button submenu: AreaMode+AF-On 0-7 => S, Dyn-S, Dyn-M, Dyn-L, Wide-S, Wide-L, 3D, Auto; 11=>n/a # CSf2-b
9884             #125 Func2Button submenu: SynchronizedRelease 1=>'Master', 2=>'Remote' # CSf2-b
9885             #127 Func2Button submenu: Zoom 0=>'Zoom (Low)', 2=>'Zoom (1:1)', 2=>'Zoom (High)' # CSf2-b
9886             #129 Func2Button & Func2ButtonPlayback submenu: Rating # CSf2-b & CSf3b 0=>'Candidate For Deletion' 6=>''None'
9887             131 => { Name => 'AFOnButton', %buttonsZ9}, # CSf2-c
9888             143 => { Name => 'SubSelector', %buttonsZ9, Unknown => 1}, # CSf2-g
9889             155 => { Name => 'AssignMovieRecordButton', %buttonsZ9, Unknown => 1}, # CSf2-m
9890             159 => { Name => 'LensFunc1Button', %buttonsZ9}, # CSf2-o
9891             167 => { Name => 'LensFunc2Button', %buttonsZ9}, # CSf2-p
9892             173 => { # CSf2-q
9893             Name => 'LensControlRing',
9894             PrintConv => {
9895             0 => 'None (Disabled)',
9896             1 => 'Focus (M/A)',
9897             2 => 'ISO Sensitivity',
9898             3 => 'Exposure Compensation',
9899             4 => 'Aperture',
9900             },
9901             },
9902             175 => { Name => 'MultiSelectorShootMode', %buttonsZ9}, # CSf2-h called the OK button in camera, tag name retained for compatibility
9903             179 => { Name => 'MultiSelectorPlaybackMode', %buttonsZ9}, # CSf3f
9904             183 => { Name => 'ShutterSpeedLock', PrintConv => \%offOn }, # CSf4-a
9905             184 => { Name => 'ApertureLock', PrintConv => \%offOn }, # CSf4-b
9906             185 => { # CSf5-a Previous cameras reported this tag as part of CmdDialsReverseRotation. Blend with CSf5-b separate settings together to match extant tag name and values
9907             Name => 'CmdDialsReverseRotExposureComp',
9908             RawConv => '$$self{CmdDialsReverseRotExposureComp} = $val',
9909             Hidden => 1,
9910             },
9911             186 => [{ # CSf5-a (continued from above)
9912             Name => 'CmdDialsReverseRotation',
9913             Condition => '$$self{CmdDialsReverseRotExposureComp} == 0',
9914             PrintConv => {
9915             0 => 'No',
9916             1 => 'Shutter Speed & Aperture',
9917             },
9918             },{
9919             Name => 'CmdDialsReverseRotation',
9920             PrintConv => {
9921             0 => 'Exposure Compensation',
9922             1 => 'Exposure Compensation, Shutter Speed & Aperture',
9923             },
9924             }],
9925             191 => { Name => 'UseDialWithoutHold', PrintConv => \%offOn, Unknown => 1 }, # CSf6
9926             193 => { Name => 'ReverseIndicators', PrintConv => { 0 => '+ 0 -', 1 => '- 0 +' }, Unknown => 1 }, # CSf7
9927             195 => { Name => 'MovieFunc1Button', %buttonsZ9}, # CSg2-a
9928             199 => { Name => 'MovieFunc2Button', %buttonsZ9}, # CSg2-b
9929             203 => { Name => 'MovieAF-OnButton', %buttonsZ9}, # CSg2-f
9930             215 => { # CSg2-z
9931             Name => 'MovieLensControlRing',
9932             PrintConv => {
9933             0 => 'None (Disabled)',
9934             2 => 'ISO Sensitivity',
9935             3 => 'Exposure Compensation',
9936             4 => 'Power Aperture',
9937             5 => 'Hi-Res Zoom',
9938             },
9939             },
9940             217 => { Name => 'MovieMultiSelector', %buttonsZ9, Unknown => 1}, # CSg2-h
9941             221 => { Name => 'MovieAFSpeed', ValueConv => '$val - 5', ValueConvInv => '$val + 5' }, # CSg6-a
9942             223 => { Name => 'MovieAFSpeedApply', PrintConv => {0 => 'Always', 1 => 'Only During Recording'},}, # CSg6-b
9943             225 => { # CSg7
9944             Name => 'MovieAFTrackingSensitivity',
9945             PrintConv => {
9946             0 => '1 (High)',
9947             1 => '2',
9948             2 => '3',
9949             3 => '4 (Normal)',
9950             4 => '5',
9951             5 => '6',
9952             6 => '7 (Low)',
9953             },
9954             },
9955             257 => { Name => 'LCDIllumination', PrintConv => \%offOn, Unknown => 1 }, # CSd11
9956             258 => { Name => 'ExtendedShutterSpeeds', PrintConv => \%offOn }, # CSd5
9957             259 => { Name => 'SubjectMotion', PrintConv => {0 => 'Erratic', 1 => 'Steady'} }, # CSa3-b
9958             261 => { Name => 'FocusPointPersistence', PrintConv => {0 => 'Auto', 1 => 'Off'} }, # CSa7
9959             263 => { Name => 'AutoFocusModeRestrictions', PrintConv => \%focusModeRestrictionsZ9, Unknown => 1}, # CSa9
9960             267 => { Name => 'CHModeShootingSpeed', ValueConv => '$val + 1', ValueConvInv => '$val - 1', PrintConv => '"$val fps"', PrintConvInv => '$val=~s/\s*fps//i; $val' }, # CSd1a
9961             269.1 => { Name => 'LimitReleaseModeSelCL', Mask => 0x02, PrintConv => \%limitNolimit, Unknown => 1 }, # CSd3-a
9962             269.2 => { Name => 'LimitReleaseModeSelCH', Mask => 0x04, PrintConv => \%limitNolimit, Unknown => 1 }, # CSd3-b
9963             269.3 => { Name => 'LimitReleaseModeSelC30', Mask => 0x10, PrintConv => \%limitNolimit, Unknown => 1 }, # CSd3-e
9964             269.4 => { Name => 'LimitReleaseModeSelC120', Mask => 0x40, PrintConv => \%limitNolimit, Unknown => 1 }, # CSd3-c
9965             269.5 => { Name => 'LimitReleaseModeSelSelf', Mask => 0x80, PrintConv => \%limitNolimit, Unknown => 1 }, # CSd3-d
9966             273 => { Name => 'FlashBurstPriority', PrintConv => { 0 => 'Frame Rate',1 => 'Exposure'}, Unknown => 1 }, # CSe8
9967             277 => { Name => 'VerticalFuncButton', %buttonsZ9}, # CSf2-c
9968             281 => { Name => 'Func3Button', %buttonsZ9}, # CSf2-c
9969             285 => { Name => 'VerticalAFOnButton', %buttonsZ9}, # CSf2-l
9970             293 => { Name => 'VerticalMultiSelectorPlaybackMode', PrintConv => { 0 => 'Image Scroll L/R', 1 => 'Image Scroll Up/Down' }, Unknown => 1}, # CSf3-j
9971             295 => { Name => 'MovieFunc3Button', %buttonsZ9}, # CSg2-c
9972             335 => { Name => 'LimitAF-AreaModeSelDynamic_S', PrintConv => \%limitNolimit, Unknown => 1 }, # CSa8
9973             336 => { Name => 'LimitAF-AreaModeSelDynamic_M', PrintConv => \%limitNolimit, Unknown => 1 }, # CSa8
9974             337 => { Name => 'LimitAF-AreaModeSelDynamic_L', PrintConv => \%limitNolimit, Unknown => 1 }, # CSa8
9975             339 => { Name => 'LimitAF-AreaModeSel3DTracking', PrintConv => \%limitNolimit, Unknown => 1 }, # CSa8
9976             341 => { Name => 'PlaybackFlickUp', PrintConv => \%flicksZ9, Unknown => 1}, # CSf11-a
9977             345 => { Name => 'PlaybackFlickDown', PrintConv => \%flicksZ9, Unknown => 1}, # CSf11-b
9978             349 => { Name => 'ISOStepSize', PrintConv => \%thirdHalfFull }, # CSb1
9979             355 => { Name => 'ReverseFocusRing', PrintConv => { 0 => 'Not Reversed', 1 => 'Reversed' } }, # CSf8
9980             356 => { Name => 'EVFImageFrame', PrintConv => \%offOn, Unknown => 1 }, # CSd14
9981             357 => { Name => 'EVFGrid', PrintConv => \%evfGridsZ9, Unknown => 1 }, # CSd15
9982             359 => { Name => 'VirtualHorizonStyle', PrintConv => {0 => 'Type A (Cockpit)', 1 => 'Type B (Sides)' }, Unknown => 1}, #CSd16
9983             373 => { Name => 'Func4Button', %buttonsZ9, Unknown => 1}, # CSf2-e
9984             379 => { Name => 'AudioButton', %buttonsZ9, Unknown => 1}, # CSf2-i
9985             381 => { Name => 'QualityButton', %buttonsZ9, Unknown => 1}, # CSf2-j
9986             399 => { Name => 'VerticalMultiSelector', %buttonsZ9, Unknown => 1}, # CSf2-k
9987             421 => { Name => 'Func1ButtonPlaybackMode', %buttonsZ9, Unknown => 1}, # CSf3-a
9988             423 => { Name => 'Func2ButtonPlaybackMode', %buttonsZ9, Unknown => 1}, # CSf3-b
9989             425 => { Name => 'Func3ButtonPlaybackMode', %buttonsZ9, Unknown => 1}, # CSf3-c
9990             431 => { Name => 'Func4ButtonPlaybackMode', %buttonsZ9, Unknown => 1}, # CSf3-e
9991             437 => { Name => 'MovieRecordButtonPlaybackMode', %buttonsZ9, Unknown => 1}, # CSf3-m
9992             439 => { Name => 'VerticalFuncButtonPlaybackMode', %buttonsZ9, Unknown => 1}, # CSf3-d
9993             441 => { Name => 'AudioButtonPlaybackMode', %buttonsZ9, Unknown => 1}, # CSf3-g
9994             447 => { Name => 'QualityButtonPlaybackMode', %buttonsZ9, Unknown => 1}, # CSf3-h
9995             467 => { Name => 'FocusPointLock', PrintConv => \%offOn, Unknown => 1}, # CSf4-c
9996             453 => { Name => 'WhiteBalanceButtonPlaybackMode', %buttonsZ9, Unknown => 1}, # CSf3-i
9997             459 => { Name => 'CommandDialPlaybackMode', PrintConv => \%dialsZ9, Unknown => 1}, # CSf3-k
9998             463 => { Name => 'SubCommandDialPlaybackMode', PrintConv => \%dialsZ9, Unknown => 1}, # CSf3-l
9999             469 => { Name => 'ControlRingResponse', PrintConv => { 0 => 'High', 1 => 'Low' } }, # CSf10
10000             481 => { Name => 'VerticalMovieFuncButton', %buttonsZ9, Unknown => 1}, # CSg2-d
10001             505 => { Name => 'VerticalMovieAFOnButton', %buttonsZ9, Unknown => 1}, # CSg2-l
10002             515 => { Name => 'MovieAFAreaMode', %buttonsZ9, Unknown => 1}, # CSg2-e
10003             #521 => { Name => 'MovieLimitAF-AreaModeSelWideAF_S', PrintConv => \%limitNolimit, Unknown => 1 }, # CSg4-a
10004             #522 => { Name => 'MovieLimitAF-AreaModeSelWideAF_W', PrintConv => \%limitNolimit, Unknown => 1 }, # CSg4-b
10005             #523 => { Name => 'MovieLimitAF-AreaModeSelSubjectTrack', PrintConv => \%limitNolimit, Unknown => 1 }, # CSg4-c
10006             #524 => { Name => 'MovieLimitAFAreaModeSelAuto', PrintConv => \%limitNolimit, Unknown => 1 }, # CSg4-d
10007             #525 => { Name => 'MovieAutoFocusModeRestrictions', PrintConv => \%focusModeRestrictionsZ9, Unknown => 1}, # CSa9
10008             527 => { Name => 'HDMIViewAssist', PrintConv => \%offOn, Unknown => 1 }, # CSg8
10009             529 => { # CSg9-a
10010             Name => 'ZebraPatternToneRange',
10011             Unknown => 1,
10012             RawConv => '$$self{ZebraPatternToneRange} = $val',
10013             PrintConv => {
10014             0 => 'Off',
10015             1 => 'Highlights',
10016             2 => 'Midtones',
10017             },
10018             },
10019             531 => { Name => 'MovieZebraPattern', Condition => '$$self{ZebraPatternToneRange} and $$self{ZebraPatternToneRange} != 0', PrintConv => {0 => 'Pattern 1', 1 => 'Pattern 2'}, Unknown => 1}, # CSg9-b
10020             533 => { Name => 'MovieHighlightDisplayThreshold', Condition => '$$self{ZebraPatternToneRange} and $$self{ZebraPatternToneRange} == 1', Unknown => 1 }, # CSg9-c 120-25 when highlights are the selected tone range
10021             535 => { Name => 'MovieMidtoneDisplayValue', Condition => '$$self{ZebraPatternToneRange} and $$self{ZebraPatternToneRange} == 2', Unknown => 1 }, # CSg9-d1 when midtones are the selected tone range
10022             537 => { Name => 'MovieMidtoneDisplayRange', Condition => '$$self{ZebraPatternToneRange} and $$self{ZebraPatternToneRange} == 2', PrintConv => '"+/-$val"', Unknown => 1 }, # CSg9-d1 when midtones are the selected tone range
10023             #539 CS g-10 LimitZebraPatternToneRange 0=>'No Restrictions', 1=> 'Highlights', 2=> 'Midtones'
10024             541 => { Name => 'MovieEVFGrid', PrintConv => \%evfGridsZ9, Unknown => 1 }, # CSg11
10025             549 => { Name => 'MovieShutterSpeedLock', PrintConv => \%offOn, Unknown => 1}, # CSg4-a
10026             550 => { Name => 'MovieFocusPointLock', PrintConv => \%offOn, Unknown => 1}, # CSf4-c
10027             563 => { Name => 'MatrixMetering', PrintConv => { 0 => 'Face Detection Off', 1 => 'Face Detection On' }, Unknown => 1 }, # CSb4
10028             564 => { Name => 'AF-CFocusDisplay', PrintConv => \%offOn }, # CSa11c
10029             565 => { Name => 'FocusPeakingDisplay', PrintConv => \%offOn, Unknown => 1}, # CSa13a
10030             567 => { # CSb7
10031             Name => 'KeepExposure',
10032             PrintConv => {
10033             0 => 'Off',
10034             1 => 'Shutter Speed',
10035             2 => 'ISO',
10036             },
10037             },
10038             #569 CDd8 (adjust viewfinder/monitor hue, brightness and/or white balance settings) 0=>'No adjustment', 1=>'Adjust'. Related ontrols & adjustments stored in following dozen bytes or so.
10039             585 => { Name => 'StarlightView', PrintConv => \%offOn, Unknown => 1 }, # CSd9
10040             587 => { # CSd10-a
10041             Name => 'EVFWarmDisplayMode',
10042             Unknown => 1,
10043             PrintConv => {
10044             0 => 'Off',
10045             1 => 'Mode 1',
10046             2 => 'Mode 2',
10047             },
10048             },
10049             589 => { # CSd10-b values in range -3 to +3
10050             Name => 'EVFWarmDisplayBrightness',
10051             Format => 'int8s',
10052             Unknown => 1,
10053             },
10054             591 => { #CSd13
10055             Name => 'EVFReleaseIndicator',
10056             Unknown => 1,
10057             PrintConv => {
10058             0 => 'Off',
10059             1 => 'Type A (Dark)',
10060             2 => 'Type B (Border)',
10061             3 => 'Type C (Sides)',
10062             },
10063             },
10064             601 => { Name => 'MovieApertureLock', PrintConv => \%offOn, Unknown => 1 }, # CSg4-b
10065             607 => { Name => 'FlickAdvanceDirection', PrintConv => { 0 => 'Left to Right', 1 => 'Right to Left' }, Unknown => 1 }, # CSf11-c
10066             );
10067              
10068             1; # end
10069              
10070             __END__