Skip to content
Snippets Groups Projects
Commit 37f430c8 authored by Jan David Mol's avatar Jan David Mol
Browse files

Match latest PCC OPC-UA interface

parent 5fafeb8e
No related branches found
No related tags found
No related merge requests found
......@@ -203,6 +203,11 @@ class RCUSCC(Device):
access=AttrWriteType.READ_WRITE,
)
ADC_JESD_R = attribute(
dtype=(('DevDouble',),),
max_dim_x=32, max_dim_y=3,
)
CLK_PLL_locked_R = attribute(
dtype='DevLong64',
)
......@@ -219,13 +224,13 @@ class RCUSCC(Device):
# )
LED_R = attribute(
dtype=(('DevLong64',),),
max_dim_x=32, max_dim_y=3,
dtype=('DevLong64',),
max_dim_x=32,
)
LED_RW = attribute(
dtype=(('DevLong64',),),
max_dim_x=32, max_dim_y=3,
dtype=('DevLong64',),
max_dim_x=32,
access=AttrWriteType.READ_WRITE,
)
......@@ -285,6 +290,12 @@ class RCUSCC(Device):
# Modify as soon as we have a real multi-dimensional array
self.attribute_mapping["Band_RW"] = (self.get_pcc_node("RCUs_Band1_RW"), self.get_pcc_node("RCUs_Band2_RW"), self.get_pcc_node("RCUs_Band3_RW"))
# 2020-11-27, thomas
# TODO
# Modify as soon as we have a real multi-dimensional array
self.attribute_mapping["ADC_JESD_R"] = (self.get_pcc_node("RCUs_ADC1_JESD_R"), self.get_pcc_node("RCUs_ADC2_JESD_R"), self.get_pcc_node("RCUs_ADC3_JESD_R"))
self.attribute_mapping["CLK_PLL_locked_R"] = self.get_pcc_node("CLK_PLL_locked_R")
# self.attribute_mapping["Dither_Frequency_R"] = self.get_pcc_node("RCUs_Dither_Frequency_R")
......@@ -333,6 +344,9 @@ class RCUSCC(Device):
self._Band_RW = ((0,),)
self.attribute_mapping["Band_RW"] = {}
self._ADC_JESD_R = ((0,),)
self.attribute_mapping["ADC_JESD_R"] = {}
self._Dither_Frequency_R = ((0.0,),)
self.attribute_mapping["Dither_Frequency_R"] = {}
......@@ -441,6 +455,13 @@ class RCUSCC(Device):
self.attribute_mapping["Band_RW"][2].set_value(value[2])
self._Band_RW = value
@only_when_on
@fault_on_opcua_error
def read_ADC_JESD_R(self):
"""Return the Band_R attribute."""
self._ADC_JESD_R = numpy.array([self.attribute_mapping["ADC_JESD_R"][0].get_value(), self.attribute_mapping["ADC_JESD_R"][1].get_value(), self.attribute_mapping["ADC_JESD_R"][2].get_value()])
return self._ADC_JESD_R
@only_when_on
@fault_on_opcua_error
def read_Dither_Frequency_R(self):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment