dodal.devices.apple2_undulator.Apple2#

class dodal.devices.apple2_undulator.Apple2[source]#
Apple 2 ID/undulator has 4 extra degrees of freedom compare to the standard Undulator,

each bank of magnet can move independently to each other, which allow the production of different x-ray polarisation as well as energy. This type of ID is use on I10, I21, I09, I17 and I06 for soft x-ray.

A pair of look up tables are needed to provide the conversion between motor position

and energy.

This conversion (update_lookuptable) and the way the id move (set) are two abstract

methods that are beamline specific and need to be implemented.

Parameters:
  • id_gap (UndulatorGap)

  • id_phase (UndulatorPhaseAxes)

  • prefix (str, default: '')

  • name (str, default: '')

  • id_gap – An UndulatorGap device.

  • id_phase – An UndulatorPhaseAxes device.

  • prefix – Not in use but needed for device_instantiation.

  • name – Name of the device.

Methods

determinePhaseFromHardware()

Try to determine polarisation and phase value using row phase motor position pattern.

update_lookuptable()

Attributes

pol

abstract update_lookuptable() None[source]#
Return type:

None

Abstract method to update the stored lookup tabled from file. This function should include check to ensure the lookuptable is in the correct format:

# ensure the importing lookup table is the correct format Lookuptable.model_validate(<loockuptable>)

async determinePhaseFromHardware() tuple[str | None, float][source]#

Try to determine polarisation and phase value using row phase motor position pattern. However there is no way to return lh3 polarisation or higher harmonic setting. (May be for future one can use the inverse poly to work out the energy and try to match it with the current energy to workout the polarisation but during my test the inverse poly is too unstable for general use.)

Return type:

tuple[str | None, float]