dodal.devices.insertion_device.energy_motor_lookup.EnergyMotorLookup#

class dodal.devices.insertion_device.energy_motor_lookup.EnergyMotorLookup[source]#

Handles a lookup table for Apple2 ID, converting energy/polarisation to a motor position.

After update_lookup_table() has populated the lookup table, find_value_in_lookup_table() can be used to compute gap / phase for a requested energy / polarisation pair.

Parameters:

lut (LookupTable | None, default: None)

Methods

find_value_in_lookup_table(energy, pol)

Convert energy and polarisation to a value from the lookup table.

update_lookup_table()

Do nothing by default.

update_lookup_table() None[source]#

Do nothing by default. Sub classes may override this method to provide logic on what updating lookup table does.

Return type:

None

find_value_in_lookup_table(energy: float, pol: Pol) float[source]#

Convert energy and polarisation to a value from the lookup table.

Return type:

float

Parameters:#

energyfloat

Desired energy.

polPol

Polarisation mode.

Returns:#

: float

gap / phase motor position from the lookup table.

param energy:

type energy:

float

param pol:

type pol:

Pol