Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
T
tango
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Jira issues
Open Jira
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
LOFAR2.0
tango
Commits
be06a7e4
Commit
be06a7e4
authored
3 years ago
by
Stefano Di Frischia
Browse files
Options
Downloads
Patches
Plain Diff
L2SS-643
: add calculate_bf_weights command
parent
3b470635
No related branches found
No related tags found
1 merge request
!294
Resolve L2SS-643 "Calculate beamlet bfweights"
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
tangostationcontrol/tangostationcontrol/devices/sdp/beamlet.py
+17
-3
17 additions, 3 deletions
...stationcontrol/tangostationcontrol/devices/sdp/beamlet.py
with
17 additions
and
3 deletions
tangostationcontrol/tangostationcontrol/devices/sdp/beamlet.py
+
17
−
3
View file @
be06a7e4
...
...
@@ -8,10 +8,10 @@
"""
# PyTango imports
from
tango.server
import
device_property
from
tango
import
AttrWriteType
# Additional import
from
tango.server
import
device_property
,
command
from
tango
import
AttrWriteType
,
DevVarFloatArray
,
DevVarULongArray
# Additional import
from
tangostationcontrol.common.entrypoint
import
entry
from
tangostationcontrol.clients.attribute_wrapper
import
attribute_wrapper
from
tangostationcontrol.devices.opcua_device
import
opcua_device
...
...
@@ -130,9 +130,23 @@ class Beamlet(opcua_device):
# Overloaded functions
# --------
# --------
# internal functions
# --------
def
_calculate_bf_weights
(
self
,
phases
:
numpy
.
ndarray
):
pass
# --------
# Commands
# --------
@command
(
dtype_in
=
DevVarFloatArray
,
dtype_out
=
DevVarULongArray
)
def
calculate_bf_weights
(
self
,
phases
:
numpy
.
ndarray
):
"""
converts a difference in phase (in radiants) to a FPGA weight (in complex number)
"""
# Calculate the FPGA weight array
bf_weights
=
self
.
_calculate_bf_weights
(
phases
)
return
bf_weights
# ----------
# Run server
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment