NEW BOARD SETUP
RULE: All scripts with date in their name are using fiducial coordinates and have to be adjusted once fiducials are setup.
MSIM Load XML File with Newscale Data
- Get XML file from Mitsuko
- Load XML file into database.
Camera Adjustment
- Take image with MaximDL5 to look at pixel values and background. Currently background dominates with 2000 and pixels are only about 10% above.
- Turn Off Illumination.
- Run script take_dark_image.lst to take dark images (exposure time, save image).
- Copy dark image to DarkBiasImages dir. (PFSTests)
- Turn On Illumination!
Fiducial Setup
- Take image with MSIM using take_fiducial_image.lst
- Open from MSIM Control Panel -> Camera -> GetImage -> ImageProcessing Tab
- Clear the command dialog.
- Now click in the "Threshold binary Image" on the coordinates for the fiducials then click on the image processing pane on "Add Fiducial cmd".
- This adds a command in the command dialog.
cmd_setHornMethodFiducialCoordinate 96,1644, 10
The last argument (10) is the radius around your provided center (argument 1 x and 2 y).
- Repeat this for all fiducials, then save the commands to a file and use it in all your scripts.
Frequency Sweep/Calibration
- Run Script CalibrateCommand to get all frequencies and save them to DB.
Positioner Coarse Centers
- Home all Positioners. Use 2017_10_09_home_All.lst for this.
- Update the fiducial lines in 2017_10_09_take_fiducial_image.lst
- Run the script 2017_10_09_take_fiducial_image.lst
- Open from MSIM Control Panel -> Camera -> GetImage -> ImageProcessing Tab
- Now click on the image with one center dot -> on the image processing pane edit the PID number and click on "Add Positioner cmd".
- This adds a command in the command dialog.
cmd_tbd 96,1644, 10
The last argument (10) is the radius around your provided center (argument 1 x and 2 y).
- Repeat this for all positioners.
- Add cmd_save_Database to it and execute the script.
Positioner Fine Centers
- Now that we have coarse positioner locations, MSIM can identify the centroids.
- Open script 2019_xx_xx_centers_at_home.lst and update fiducial coordinates.
- Run the script.
- Copy the results folder over to dropbox.
- Run
createCenters.m
- Check all centers for correctness. This will produce issues if you haven't loaded the correct xml file.
Link Lengths
- Manually put positioners in non colliding configuration.
- Run 2018_04_09_link_lengths_not_colliding.lst
- Execute the command to find theta centers and save the results:
createLinkLengths
- For each Positioner, decide whether to use the data or not.
- Save the resulting xml and load it into MSIM.
Phi Stage Inside Hard stops
- Make sure manually that all phi stages are on inside hardstop.
- Run 2018_04_10_measure_phi_hardstop.lst
- tbd
- Save the resulting xml and load it into MSIM.
Phi Stage Outside Hardstops
- Make sure manually that all phi stages are on outside hardstop.
- If ontimes have to be adjusted to reach outside, record successful ontimes.
- Run 2018_04_10_measure_phi_hardstop.lst
- tbs
- Save the resulting xml and load it into MSIM.
Positioner Z-Orientation Setup
- Manually run positioners home to negative hardstop.
- Update script 2018_04_10_setHardstopOrientations_manual_ccw.lst with fiducial info.
- Run the script.
- Manually run positioners anti-home.
- Update script 2018_04_10_setHardstopOrientations_manual_cw.lst with fiducial info.
- Run the script.
On-Time Tuning (tbd)
Generating Targets
- Change the matlab directory to where you want the target files generated
- Create an archive folder and move the existing targets in there first.
- Open and edit the inputs for the target generation script in Matlab to make targets: \Dropbox\PFS_EM\SVN\MATLAB\targGenerator.m
- Run the script
- Restart MSIM
Running Targets
- Open the latest target script in Dropbox\PFS_EM\SVN\MSIM and edit it to have the right positioners
- Also check that fiducial definitions are correct and motor polarity's are right
Target Convergence Analysis
- Copy MSIM target log dir on testbed computer (eg: D:\PfsTests\06_16_14_10_36_21_TargetRun\Log) to the drobox test results target convergence folder (Dropbox\PFS_EM\TEST_RESULTS\TargetConvergence\). Rename the log directory in dropbox to have the same name as the mother directory on testbed computer (eg: 06_16_14_10_36_21_TargetRun). This directory will now be referred to as the test directory here.
- Move the appropriate CobraConfig xml (the most recent file in explorer:Libraries->xmlfiles) used by MSIM into the test directory.
- Change the matlab current folder to the test directory in dropbox.
- Execute the following command to run the target analysis script:
analyzeTargetRun
- When prompted, select the appropriate xml which was used for the MSIM test. The one you moved into test directory.
- Run the script and mat files will be saved to the same log directory as the log txt files are in.
Target Convergence Comparisons
- Change the matlab current folder to Dropbox\PFS_EM\TEST_RESULTS\TargetConvergenceRun the target convergence analysis on data you wish to compare. The mat files from that script are needed for this comparison.
- Open the convergence comparison matlab script in that folder: convCompare.m
- Edit the INPUTS section so that the dataDirs array contains the folder names of test data you wish to compare. These must all contain the results of analyzeTargetRun script.
- Run the script.
- The convergence comparison figure will automatically be saved in the last folder of the dataDirs array, so make sure that is in order.
Motor Map Update
- Do a TargetConvergenceAnalysis as described above.
- Add your new test directory to the list of directories in the beginning of updateMotorMapsFromTargetData.m
- Uncomment all directories that contain data you want to include in the analysis.
- Run the script with your latest xml and take a thorough look at the results. Look for extreme map values and decide whether it is realistic and ok for the positioner to have these values.
- Follow the Loading XML into MSIM procedure above.
--
JohannesGross - 12 Oct 2017
This topic: Subaru/PFS
> WebHome >
POSitionerProd > ModuleTestingProcedure
Topic revision: r8 - 2018-04-23 - JohannesGross