===Procedure for METIS_ifu_cal_distortion ===

Procedure to determine the detector distortion maps. A pinhole grid is inserted in the optical path of the instrument. The pinhole grid is illuminated, simulating a set of point sources at various positions of the detector.

<color #00a2e8>Setup METIS: Background exposures</color>
  * Set ''cfo-pp1'' (''INS.OPTI1.NAME'') to ''PPS-CFO1''
  * Set ''cfo-fp2'' (''INS.OPTI2.NAME'') to ''FIELD-11''
  * Set ''cfo-lms'' (''INS.OPTI4.NAME'') to ''IN''
  * Set ''lms-pwa'' (''INS.OPTI5.NAME'') to ''PPS-LMS''
  * Set ''lms-msa'' (''INS.OPTI6.NAME'') to ''nominal''
  * Set ''lms-pra'' (''INS.OPTI7.NAME'') to list of settings
  * Set ''lms-gra'' (''INS.OPTI8.NAME'') to list of settings
  * Set ''wcu-per'' (''INS.OPTI17.NAME'') to ''IN''
  * Set ''wcu-pp1'' (''INS.OPTI18.NAME'') to ''ELT_mask''
  * Set ''wcu-bb-aperture-mask'' (''INS.OPTI19.NAME'') to ''CLOSED''
  * Set ''wcu-fp2-1'' (''INS.OPTI20.NAME'') to ''grid-LM'' (pinhole mask position)
  * Set ''wcu-bb'' (''SEQ.WCU.BB.TEMP'') to ''TEMP-L''
  * Wait for about 45 minutes (warming up time, depends on the BB temperature selection)
  * Check the power readout. If the power is detectable, continue
  * Take background measurements with requested DIT, NDIT and NEXPO

<color #00a2e8>Setup METIS: Science exposures</color>
  * Set ''wcu-bb-aperture-mask'' (''INS.OPTI19.NAME'') to ''OPEN''
  * Set ''lms-pra'' (''INS.OPTI7.NAME'') to list of settings
  * Set ''lms-gra'' (''INS.OPTI8.NAME'') to list of settings
  * Start science exposures with the LMS with the requested DIT and NDIT
  * Move grid by known offsets in the field using the chopper, repeat exposures


===Parameters for METIS_ifu_cal_distortion ===


^Parameter             ^Hidden     ^Range (default)            ^Label^  
|DPR CATG              |yes        |CALIB TEST (CALIB) |Data product category|
|DPR TECH              |yes        |IFU (IFU)                 |Data product technique|
|DPR TYPE              |yes        |DISTORTION (DISTORTION)|Data product type|         
|DET1 DIT               |yes         |0..TBD (NODEFAULT)         |IMG-LM Detector integration time (DIT)|
|DET1 NDIT              |yes         |1..TBD (NODEFAULT)         |IMG-LM Number of Integrations (NDIT)|
|DET1 NCORRS NAME       |no         |CDS                         |IMG-LM Readout mode|
|DET2 DIT               |yes         |0..TBD (NODEFAULT)         |IMG-N Detector integration time (DIT)|
|DET2 NDIT              |yes         |1..TBD (NODEFAULT)         |IMG-N Number of Integrations (NDIT)|
|DET2 NCORRS NAME       |no         |CDS                         |IMG-N Readout mode|
|DET3 DIT               |yes         |0..TBD (NODEFAULT)         |LMS Detector integration time (DIT)|
|DET3 NDIT              |yes         |1..TBD (NODEFAULT)         |LMS Number of Integrations (NDIT)|
|DET3 NCORRS NAME       |no         |CDS                         |LMS Readout mode|
|DET1 CUBE MODE        |no         |T F (F)                    |Toggle cube mode| 
|DET3 CUBE MODE        |no         |T F (F)                    |Toggle cube mode| 
|SEQ TIME              |no         |0..TBD (NODEFAULT)         |Total integration time (sec)|
|SEQ NEXPO             |no         |0..1000 (NODEFAULT)        |Number of exposures per offset|
|INS WLEN CEN         |no         |2700 - 5300 nm (NODEFAULT)           |Central wavelength|
|SEQ WCU_BB_TEMP       |yes        |TEMP-L TEMP-M (NODEFAULT)   |WCU BB temperature for specific filter|
|SEQ WCU_OFF_NFRAMES   |yes        |TBD                        |Number of WCU off frames to take |
|INS OPTI1 NAME         |yes        | PPS-CFO1 (PPS-CFO1)                |CFO-PP1 mask wheel|
|INS OPTI2 NAME         |yes        | OUT (OUT)                |CFO-PP1 ADC wheel|
|INS OPTI3 NAME         |yes         |FIELD-11 (FIELD-11)       |CFO FP2 mask/slit wheel|
|INS OPTI4 NAME         |yes        |IN (IN)                  |LMS beamsplitter pickoff wheel|
|INS OPTI5 NAME         |yes        |open PPS-LMS SPM-LMS (PPS-LMS)   |LMS PP1 mask wheel|
|INS OPTI6 NAME         |no        |Nominal Extended (NODEFAULT)                  |LMS spectral IFU mechanism|
|INS OPTI7 NAME         |yes        |TBD (TBD)                  |LMS pre-disperser|
|INS OPTI8 NAME         |yes        |TBD (TBD)                  |LMS main disperser|
|INS OPTI9 NAME         |no         |open PPS-LM SPM-LM (SPM-LM)                  |IMG-LM Mask/Grism name|
|INS OPTI10 NAME         |no         |L' H2Oice shortL IB4.05 PAH3.3 PAH3.3ref Br-alpha Br-alpharef M' CO(1-0)/ice COref HCIL-short HCIL-long (L')                |IMG-LM Filter name|
|INS OPTI11 NAME         |no         |OPEN ND1 ND2 ND3 ND4 ND5 DARK (NODEFAULT)                  |IMG-LM Neutral density filter|
|INS OPTI15 NAME         |yes        |OUT (OUT)                    | IMG-LM pupil imaging lens|
|INS OPTI17 NAME         |yes        |IN (IN)                    | WCU periscope arm|
|INS OPTI18 NAME	|yes                |WCU_mask AIV_mask ELT_mask (ELT_mask)             |WCU PP1 masks|
|INS OPTI19 NAME	|yes                |OPEN CLOSED (OPEN)                              |WCU BB exit aperture masks|
|INS OPTI20 NAME        |yes         |grid-LM (grid-LM) |WCU FP2.1 mask wheel|