| ... | ... | @@ -14,59 +14,67 @@ |
|
|
|
- [Troubleshooting](#troubleshooting)
|
|
|
|
|
|
|
|
## Required Imports
|
|
|
|
from iexcode.macros.Kappa import *
|
|
|
|
from iexcode.macros.xrays import *
|
|
|
|
|
|
|
|
## Kappa Initialization
|
|
|
|
tey,d3,d4,mesh,tth_pv,tthdet,ls331 = kappa_init('UserName', xrays=True)
|
|
|
|
```python
|
|
|
|
from iexcode.macros.Kappa import *
|
|
|
|
from iexcode.macros.xrays import *
|
|
|
|
```
|
|
|
|
|
|
|
|
## Kappa Initialization
|
|
|
|
```python
|
|
|
|
tey,d3,d4,mesh,tth_pv,tthdet,ls331 = kappa_init('UserName', xrays=True)
|
|
|
|
```
|
|
|
|
|
|
|
|
## Kappa Chamber
|
|
|
|
Kappa_get_all() #print Kappa status
|
|
|
|
Kappa_safe_state() #put Kappa chamber in a safe state
|
|
|
|
safe_state() #put the beamline in a safe state
|
|
|
|
Kappa_light(ON_OFF) #turn on/off the light in Kappa chamber
|
|
|
|
```python
|
|
|
|
Kappa_get_all() #print Kappa status
|
|
|
|
Kappa_safe_state() #put Kappa chamber in a safe state
|
|
|
|
safe_state() #put the beamline in a safe state
|
|
|
|
Kappa_light(ON_OFF) #turn on/off the light in Kappa chamber
|
|
|
|
```
|
|
|
|
|
|
|
|
## X-ray
|
|
|
|
xrays_get_all() #get current beamline settings
|
|
|
|
energy_get_all() #get current ID and mono settings
|
|
|
|
energy_get() #return the photon energy
|
|
|
|
energy(hv_eV) #set the photon energy (ID, mono, apertures)
|
|
|
|
polarization(H/V/RCP/LCP) #set the polarization but not the energy
|
|
|
|
mvID(hv_eV) #set the ID setpoint
|
|
|
|
qp(QP_ratio) #set the QP ration (off = 100 )
|
|
|
|
mvmono(eV) #set the mono energy
|
|
|
|
grating(MEG/HEG) #changes grating ('HEG','MEG')
|
|
|
|
-------------------------------------------------------------
|
|
|
|
apertures_set(c_2B=1) #(c_2B <1 kills flux)
|
|
|
|
slit_get() #get the exit slit size
|
|
|
|
slit(size_um) #set the vertical size of exit slit
|
|
|
|
m3r_align() #align pre-Kappa beam position
|
|
|
|
-------------------------------------------------------------
|
|
|
|
resolution() #prints resolution for current setting
|
|
|
|
```python
|
|
|
|
xrays_get_all() #get current beamline settings
|
|
|
|
energy_get_all() #get current ID and mono settings
|
|
|
|
energy_get() #return the photon energy
|
|
|
|
energy(hv_eV) #set the photon energy (ID, mono, apertures)
|
|
|
|
polarization(H/V/RCP/LCP) #set the polarization but not the energy
|
|
|
|
mvID(hv_eV) #set the ID setpoint
|
|
|
|
qp(QP_ratio) #set the QP ration (off = 100 )
|
|
|
|
mvmono(eV) #set the mono energy
|
|
|
|
grating(MEG/HEG) #changes grating ('HEG','MEG')
|
|
|
|
-------------------------------------------------------------
|
|
|
|
apertures_set(c_2B=1) #(c_2B <1 kills flux)
|
|
|
|
slit_get() #get the exit slit size
|
|
|
|
slit(size_um) #set the vertical size of exit slit
|
|
|
|
m3r_align() #align pre-Kappa beam position
|
|
|
|
-------------------------------------------------------------
|
|
|
|
resolution() #prints resolution for current setting
|
|
|
|
```
|
|
|
|
|
|
|
|
## Motors and Scans
|
|
|
|
There are seven motors in Kappa:
|
|
|
|
`mot` = `tth`, `th`, `chi`, `phi`, `x`, `y`, `z`
|
|
|
|
|
|
|
|
mprint() #prints current position
|
|
|
|
mvsample(['', x, y, z, th, chi, phi]) #move to position
|
|
|
|
mvxyz(x, y, z) #move to sample xyz
|
|
|
|
-------------------------------------------------------------
|
|
|
|
mv[mot](val) #move to an absolute position
|
|
|
|
dmv[mot](val) #move to a relative position
|
|
|
|
scan[mot](start,stop,step) #scan absolute positions
|
|
|
|
dscan[mot](delta_start,delta_stop,step) #scan relative positions
|
|
|
|
-------------------------------------------------------------
|
|
|
|
scanXAS([[hv_start, hv_end, hv_step],...],ID_tracking=True) #scan X-ray energy
|
|
|
|
scanXAS_array(hv_list,ID_tracking=True) #scan X-ray energy using a given energy list
|
|
|
|
scanth2th(tth_start, tth_stop, tth_step, th_offset) #th-tth scan
|
|
|
|
scanth2th_table(tth_table, th_offset) #th-tth scan using a given tth list
|
|
|
|
scan_time(npts, step_second=1) #scan n points
|
|
|
|
scan_temp(temp_start, temp_end, temp_step) #scan temperatures
|
|
|
|
scan_mesh(motor1, start1, end1, step1, motor2, start2, end2, step2) #scan two motors
|
|
|
|
map_orientation(th_start, th_stop, th_step, chi_start, chi_stop, chi_step) #map out intensities in a solid angle, used for peak searching
|
|
|
|
map_sample(y_start, y_stop, y_step, x_start, x_stop, x_step) #map out intensities in real space, used for sample spot searching
|
|
|
|
|
|
|
|
```python
|
|
|
|
mprint() #prints current position
|
|
|
|
mvsample(['', x, y, z, th, chi, phi]) #move to position
|
|
|
|
mvxyz(x, y, z) #move to sample xyz
|
|
|
|
-------------------------------------------------------------
|
|
|
|
mv[mot](val) #move to an absolute position
|
|
|
|
dmv[mot](val) #move to a relative position
|
|
|
|
scan[mot](start,stop,step) #scan absolute positions
|
|
|
|
dscan[mot](delta_start,delta_stop,step) #scan relative positions
|
|
|
|
-------------------------------------------------------------
|
|
|
|
scanXAS([[hv_start, hv_end, hv_step],...],ID_tracking=True) #scan X-ray energy
|
|
|
|
scanXAS_array(hv_list,ID_tracking=True) #scan X-ray energy using a given energy list
|
|
|
|
scanth2th(tth_start, tth_stop, tth_step, th_offset) #th-tth scan
|
|
|
|
scanth2th_table(tth_table, th_offset) #th-tth scan using a given tth list
|
|
|
|
scan_time(npts, step_second=1) #scan n points
|
|
|
|
scan_temp(temp_start, temp_end, temp_step) #scan temperatures
|
|
|
|
scan_mesh(motor1, start1, end1, step1, motor2, start2, end2, step2) #scan two motors
|
|
|
|
map_orientation(th_start, th_stop, th_step, chi_start, chi_stop, chi_step) #map out intensities in a solid angle, used for peak searching
|
|
|
|
map_sample(y_start, y_stop, y_step, x_start, x_stop, x_step) #map out intensities in real space, used for sample spot searching
|
|
|
|
```
|
|
|
|
---
|
|
|
|
|
|
|
|
## Diffraction
|
| ... | ... | |