1 #include "Diffractometer.h"
2 #include "AxisAttrib.h"
3 #include "PseudoAxesAttrib.h"
6 namespace Diffractometer_ns
8 void Diffractometer::refresh_crystal_parameters()
10 DEBUG_STREAM
<< "Diffractometer::refresh_crystal_parameters(): entering... !" << endl
;
14 _hklAdapter
->get_sample_lattices(attr_A_read
, attr_B_read
, attr_C_read
,
15 attr_Alpha_read
, attr_Beta_read
, attr_Gamma_read
,
16 attr_AStar_read
, attr_BStar_read
, attr_CStar_read
,
17 attr_AlphaStar_read
, attr_BetaStar_read
, attr_GammaStar_read
);
20 HklGeometryType
Diffractometer::get_type_from_property(std::string
const & name
)
24 if (!strcasecmp(name
.c_str(), "2CV"))
25 type
= HKL_GEOMETRY_TYPE_TWOC_VERTICAL
;
26 else if (!strcasecmp(name
.c_str(), "E4CV"))
27 type
= HKL_GEOMETRY_TYPE_EULERIAN4C_VERTICAL
;
28 else if (!strcasecmp(name
.c_str(), "K4CV"))
29 type
= HKL_GEOMETRY_TYPE_KAPPA4C_VERTICAL
;
30 else if (!strcasecmp(name
.c_str(), "K6C"))
31 type
= HKL_GEOMETRY_TYPE_KAPPA6C
;
32 else if (!strcasecmp(name
.c_str(), "E6C"))
33 type
= HKL_GEOMETRY_TYPE_EULERIAN6C
;
34 else if (!strcasecmp(name
.c_str(), "ZAXIS"))
35 type
= HKL_GEOMETRY_TYPE_ZAXIS
;
37 type
= HKL_GEOMETRY_TYPE_EULERIAN4C_VERTICAL
;
42 void Diffractometer::create_dynamic_attributes(void)
45 _hklAdapter
->add_dynamic_attributes_to_device();
48 void Diffractometer::remove_dynamic_attributes(void)
51 _hklAdapter
->delete_dynamic_attributes();