Skip to content

Adding the monopulse tracking example for the ADRV9009ZU11EG RF-SOM.#200

Open
aronkis wants to merge 1 commit intoanalogdevicesinc:masterfrom
aronkis:master
Open

Adding the monopulse tracking example for the ADRV9009ZU11EG RF-SOM.#200
aronkis wants to merge 1 commit intoanalogdevicesinc:masterfrom
aronkis:master

Conversation

@aronkis
Copy link
Copy Markdown

@aronkis aronkis commented Feb 25, 2026

No description provided.

Comment on lines +173 to +199
for i = 1:used_rx_channels
data(:, i) = data(:, i) * gcal(i);
end

% Apply boresight phase calibration first
for i = 2:used_rx_channels % Channel 1 is reference
channel_phase = mod(phase_cal(i), 360.0);
channel_phase_rad = deg2rad(channel_phase);
data(:, i) = data(:, i) * exp(1j * channel_phase_rad);
end

% Apply steering phase on top of boresight calibration
for i = 1:used_rx_channels
idx = i - 1;
steering_phase = mod(current_phase * idx, 360.0);
steering_phase_rad = deg2rad(steering_phase);
data(:, i) = data(:, i) * exp(1j * steering_phase_rad);
end

% Sum and Delta Beams
% Sum: ch0+ch1+ch2+ch3
% Delta: (ch0+ch1)-(ch2+ch3)
sum_beam = data(:,1) + data(:,2) + data(:,3) + data(:,4);
delta_beam = (data(:,1) + data(:,2)) - (data(:,3) + data(:,4));

% Correlation
sum_delta_correlation = sum(sum_beam .* conj(delta_beam));
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you vectorize these operations? These should be able to go significantly faster. For example

        for i = 1:used_rx_channels
            data(:, i) = data(:, i) * gcal(i);
        end

To

data = data .* gcal;

Signed-off-by: Aron Kis <kis.aron@analog.com>
@aronkis
Copy link
Copy Markdown
Author

aronkis commented Feb 26, 2026

V2:

  • Changed looped operations for vectorized operations.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants