Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
LOFAR
Manage
Activity
Members
Labels
Plan
Issues
Wiki
Jira issues
Open Jira
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
RadioObservatory
LOFAR
Commits
39603cd8
Commit
39603cd8
authored
16 years ago
by
Max Avruch
Browse files
Options
Downloads
Patches
Plain Diff
Bug 1293:
fixed error in array sizes for station geopos and ant coord responses
parent
cbccd444
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
MAC/APL/PIC/MIS/src/MISSession.cc
+24
-7
24 additions, 7 deletions
MAC/APL/PIC/MIS/src/MISSession.cc
with
24 additions
and
7 deletions
MAC/APL/PIC/MIS/src/MISSession.cc
+
24
−
7
View file @
39603cd8
...
@@ -874,8 +874,8 @@ GCFEvent::TResult MISSession::getAntennaCorrelation_state(GCFEvent& e, GCFPortIn
...
@@ -874,8 +874,8 @@ GCFEvent::TResult MISSession::getAntennaCorrelation_state(GCFEvent& e, GCFPortIn
ackout
.
acmdataNOE
=
_nrOfRCUs
*
_nrOfRCUs
;
ackout
.
acmdataNOE
=
_nrOfRCUs
*
_nrOfRCUs
;
ackout
.
geoposNOE
=
3
;
ackout
.
geoposNOE
=
3
;
ackout
.
geopos
=
new
double
[
3
];
//lat,lon,h
ackout
.
geopos
=
new
double
[
3
];
//lat,lon,h
ackout
.
antcoordsNOE
=
_nrOfRCUs
*
3
*
2
;
ackout
.
antcoordsNOE
=
_nrOfRCUs
*
3
;
ackout
.
antcoords
=
new
double
[
_nrOfRCUs
*
3
*
2
];
//xyz Xpol, xyz Ypol
ackout
.
antcoords
=
new
double
[
_nrOfRCUs
*
3
];
//xyz Xpol, xyz Ypol
//ackout.data = new double[_nrOfRCUs * 512]; // PROBLEM why doesn't this give an error? I see no 'data' element
//ackout.data = new double[_nrOfRCUs * 512]; // PROBLEM why doesn't this give an error? I see no 'data' element
}
}
assert
(
_pRememberedEvent
);
assert
(
_pRememberedEvent
);
...
@@ -1080,16 +1080,21 @@ GCFEvent::TResult MISSession::getAntennaCorrelation_state(GCFEvent& e, GCFPortIn
...
@@ -1080,16 +1080,21 @@ GCFEvent::TResult MISSession::getAntennaCorrelation_state(GCFEvent& e, GCFPortIn
// I have been assured that working stations will either be "LBA" or "HBA"
// I have been assured that working stations will either be "LBA" or "HBA"
// but if none found, special case: test station has FTS-1-LBA, FTS-1-HBA
// but if none found, special case: test station has FTS-1-LBA, FTS-1-HBA
// otherwise, return zeros
// otherwise, return zeros
const
CAL
::
AntennaArray
*
targetarray
=
_daemon
.
m_arrays
.
getByName
(
targetarrayname
);
char
hostName
[
200
];
if
(
targetarray
==
NULL
){
gethostname
(
hostName
,
200
);
LOG_DEBUG
(
formatString
(
"MAXMOD gethostname = %s"
,
hostName
));
const
CAL
::
AntennaArray
*
targetarray
;
if
(
strncmp
(
hostName
,
"CS001T"
,
6
)
==
0
){
//test station
if
(
targetarrayname
==
"LBA"
)
{
if
(
targetarrayname
==
"LBA"
)
{
targetarrayname
=
"FTS-1-LBA"
;
targetarrayname
=
"FTS-1-LBA"
;
}
}
else
{
else
{
targetarrayname
=
"FTS-1-HBA"
;
targetarrayname
=
"FTS-1-HBA"
;
}
}
targetarray
=
_daemon
.
m_arrays
.
getByName
(
targetarrayname
);
}
}
targetarray
=
_daemon
.
m_arrays
.
getByName
(
targetarrayname
);
if
(
targetarray
!=
NULL
){
if
(
targetarray
!=
NULL
){
LOG_DEBUG
(
formatString
(
"MAXMOD N_LBA=%d, N_HBA=%d, targetarray %s"
,
N_LBA
,
N_HBA
,
targetarray
->
getName
().
c_str
()));
LOG_DEBUG
(
formatString
(
"MAXMOD N_LBA=%d, N_HBA=%d, targetarray %s"
,
N_LBA
,
N_HBA
,
targetarray
->
getName
().
c_str
()));
}
}
...
@@ -1114,7 +1119,19 @@ GCFEvent::TResult MISSession::getAntennaCorrelation_state(GCFEvent& e, GCFPortIn
...
@@ -1114,7 +1119,19 @@ GCFEvent::TResult MISSession::getAntennaCorrelation_state(GCFEvent& e, GCFPortIn
ackout
.
geopos
[
i
]
=
targetarray
->
getGeoLoc
()(
i
);
ackout
.
geopos
[
i
]
=
targetarray
->
getGeoLoc
()(
i
);
LOG_DEBUG
(
formatString
(
"MAXMOD ackout.geopos[%d]=%f"
,
i
,
ackout
.
geopos
[
i
]));
LOG_DEBUG
(
formatString
(
"MAXMOD ackout.geopos[%d]=%f"
,
i
,
ackout
.
geopos
[
i
]));
}
}
//MAXMOD DEBUG
/**
LOG_DEBUG_STR("MAXMOD targetarray->getAntennaPos : " << targetarray->getAntennaPos());
for (int i = 0; i < targetarray->getAntennaPos().extent(firstDim) ; i ++){
for (int j = 0; j < targetarray->getAntennaPos().extent(secondDim) ; j ++){
for (int k = 0; k < targetarray->getAntennaPos().extent(thirdDim) ; k ++){
LOG_DEBUG(formatString("MAXMOD targetarray->getAntennaPos(%d,%d,%d) = %f", i,j,k,targetarray->getAntennaPos()(i,j,k)));
}
}
}
**/
for
(
int
i
=
0
;
i
<
targetarray
->
getAntennaPos
().
extent
(
firstDim
)
;
i
++
){
for
(
int
i
=
0
;
i
<
targetarray
->
getAntennaPos
().
extent
(
firstDim
)
;
i
++
){
//ackout.antcoords[i*6] = *(const_cast<double *>(targetarray->getAntennaPos()(i,0,0).data()));
//ackout.antcoords[i*6] = *(const_cast<double *>(targetarray->getAntennaPos()(i,0,0).data()));
ackout
.
antcoords
[
i
*
6
]
=
targetarray
->
getAntennaPos
()(
i
,
0
,
0
);
ackout
.
antcoords
[
i
*
6
]
=
targetarray
->
getAntennaPos
()(
i
,
0
,
0
);
...
@@ -1123,7 +1140,7 @@ GCFEvent::TResult MISSession::getAntennaCorrelation_state(GCFEvent& e, GCFPortIn
...
@@ -1123,7 +1140,7 @@ GCFEvent::TResult MISSession::getAntennaCorrelation_state(GCFEvent& e, GCFPortIn
ackout
.
antcoords
[
i
*
6
+
3
]
=
targetarray
->
getAntennaPos
()(
i
,
1
,
0
);
ackout
.
antcoords
[
i
*
6
+
3
]
=
targetarray
->
getAntennaPos
()(
i
,
1
,
0
);
ackout
.
antcoords
[
i
*
6
+
4
]
=
targetarray
->
getAntennaPos
()(
i
,
1
,
1
);
ackout
.
antcoords
[
i
*
6
+
4
]
=
targetarray
->
getAntennaPos
()(
i
,
1
,
1
);
ackout
.
antcoords
[
i
*
6
+
5
]
=
targetarray
->
getAntennaPos
()(
i
,
1
,
2
);
ackout
.
antcoords
[
i
*
6
+
5
]
=
targetarray
->
getAntennaPos
()(
i
,
1
,
2
);
LOG_DEBUG
(
formatString
(
"MAXMOD AntennaPos
i=
%d"
,
i
));
LOG_DEBUG
(
formatString
(
"MAXMOD AntennaPos
row
%d"
,
i
));
//LOG_DEBUG(formatString("MAXMOD (Xpol-x1) ackout.antcoords[%d]=%f",i*6,ackout.antcoords[i*6]));
//LOG_DEBUG(formatString("MAXMOD (Xpol-x1) ackout.antcoords[%d]=%f",i*6,ackout.antcoords[i*6]));
}
}
}
}
...
...
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