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

Merge branch 'rollout-v0.28.1-2' into 'master'

Rollout fixes v0.28.1

- Wait for FPGA to be booted before returning from power_hardware_on
- Use valid placeholders for unused MAC & destination IPs

See merge request !853
parents b05519e9 3b6362d9
No related branches found
No related tags found
1 merge request!853Rollout fixes v0.28.1
...@@ -166,6 +166,7 @@ Next change the version in the following places: ...@@ -166,6 +166,7 @@ Next change the version in the following places:
# Release Notes # Release Notes
* 0.28.2 Bugfixes / rollout fixes
* 0.28.1 Bugfixes / rollout fixes * 0.28.1 Bugfixes / rollout fixes
* 0.28.0 Make `StationManager` device asynchronous * 0.28.0 Make `StationManager` device asynchronous
* 0.27.2 Add new attributes in OPCUA devices * 0.27.2 Add new attributes in OPCUA devices
......
0.28.1 0.28.2
...@@ -32,7 +32,7 @@ class PowerHierarchyDevice(AbstractHierarchyDevice): ...@@ -32,7 +32,7 @@ class PowerHierarchyDevice(AbstractHierarchyDevice):
HIBERNATE_TIMEOUT = 60.0 HIBERNATE_TIMEOUT = 60.0
STANDBY_TIMEOUT = 300.0 STANDBY_TIMEOUT = 300.0
ON_TIMEOUT = 300.0 ON_TIMEOUT = 600.0
def init( def init(
self, self,
......
...@@ -34,6 +34,7 @@ from tangostationcontrol.common.constants import ( ...@@ -34,6 +34,7 @@ from tangostationcontrol.common.constants import (
) )
# Additional import # Additional import
from tangostationcontrol.common.device_decorators import debugit
from tangostationcontrol.common.lofar_logging import log_exceptions from tangostationcontrol.common.lofar_logging import log_exceptions
from tangostationcontrol.common.proxy import create_device_proxy from tangostationcontrol.common.proxy import create_device_proxy
from tangostationcontrol.common.sdp import phases_to_weights from tangostationcontrol.common.sdp import phases_to_weights
...@@ -650,12 +651,17 @@ class Beamlet(OPCUADevice): ...@@ -650,12 +651,17 @@ class Beamlet(OPCUADevice):
"FPGA_beamlet_output_nof_destinations_RW_default_shorthand" "FPGA_beamlet_output_nof_destinations_RW_default_shorthand"
] ]
default_settings = [] default_settings = [
("FPGA_beamlet_output_nof_destinations_RW", [nof_destinations] * N_pn),
]
# Set MAC, IP, port # Set MAC, IP, port
for setting, value_if_undefined in [ for setting, value_if_undefined in [
("FPGA_beamlet_output_multiple_hdr_eth_destination_mac_RW", ""), (
("FPGA_beamlet_output_multiple_hdr_ip_destination_address_RW", ""), "FPGA_beamlet_output_multiple_hdr_eth_destination_mac_RW",
"00:00:00:00:00:00",
),
("FPGA_beamlet_output_multiple_hdr_ip_destination_address_RW", "0.0.0.0"),
("FPGA_beamlet_output_multiple_hdr_udp_destination_port_RW", 0), ("FPGA_beamlet_output_multiple_hdr_udp_destination_port_RW", 0),
]: ]:
# obtain shorthand description (first values per fpga) # obtain shorthand description (first values per fpga)
...@@ -680,6 +686,7 @@ class Beamlet(OPCUADevice): ...@@ -680,6 +686,7 @@ class Beamlet(OPCUADevice):
# report effective number of output destinations # report effective number of output destinations
return self.read_attribute("FPGA_beamlet_output_nof_destinations_act_R") return self.read_attribute("FPGA_beamlet_output_nof_destinations_act_R")
@debugit()
def write_FPGA_beamlet_output_nof_destinations_RW(self, value): def write_FPGA_beamlet_output_nof_destinations_RW(self, value):
old_FPGA_processing_enable = self.sdp_proxy.FPGA_processing_enable_RW old_FPGA_processing_enable = self.sdp_proxy.FPGA_processing_enable_RW
try: try:
......
...@@ -359,6 +359,13 @@ class SDPFirmware(OPCUADevice): ...@@ -359,6 +359,13 @@ class SDPFirmware(OPCUADevice):
self.Firmware_Boot_timeout, self.Firmware_Boot_timeout,
) )
# Wait for the new image to be booted
self.wait_attribute(
"TR_fpga_communication_error_R",
lambda attr: (~attr | ~wait_for).all(),
self.Firmware_Boot_timeout,
)
def _power_hardware_on(self): def _power_hardware_on(self):
"""Boot the SDP Firmware user image""" """Boot the SDP Firmware user image"""
......
...@@ -135,11 +135,11 @@ class TestBeamletDevice(base.TestCase): ...@@ -135,11 +135,11 @@ class TestBeamletDevice(base.TestCase):
self.assertListEqual( self.assertListEqual(
defaults["FPGA_beamlet_output_multiple_hdr_eth_destination_mac_RW"], defaults["FPGA_beamlet_output_multiple_hdr_eth_destination_mac_RW"],
[MACs + [""] * (N_bdo_destinations_mm - 4)] * N_pn, [MACs + ["00:00:00:00:00:00"] * (N_bdo_destinations_mm - 4)] * N_pn,
) )
self.assertListEqual( self.assertListEqual(
defaults["FPGA_beamlet_output_multiple_hdr_ip_destination_address_RW"], defaults["FPGA_beamlet_output_multiple_hdr_ip_destination_address_RW"],
[IPs + [""] * (N_bdo_destinations_mm - 4)] * N_pn, [IPs + ["0.0.0.0"] * (N_bdo_destinations_mm - 4)] * N_pn,
) )
self.assertListEqual( self.assertListEqual(
defaults["FPGA_beamlet_output_multiple_hdr_udp_destination_port_RW"], defaults["FPGA_beamlet_output_multiple_hdr_udp_destination_port_RW"],
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment