Minimal Working - seems too good?!
This commit is contained in:
@@ -53,7 +53,22 @@ classdef Amplifier
|
||||
|
||||
end
|
||||
|
||||
function [y_out,nase] = process(obj,x_in,optional)
|
||||
function signalclass_out = process(obj,signalclass_in)
|
||||
|
||||
% actual processing of the signal (steps 1. - 3.)
|
||||
signalclass_in.signal = obj.process_(signalclass_in.signal);
|
||||
|
||||
% append to logbook
|
||||
lbdesc = ['Amp '];
|
||||
signalclass_in = signalclass_in.logbookentry(lbdesc);
|
||||
|
||||
% write to output
|
||||
signalclass_out = signalclass_in;
|
||||
|
||||
end
|
||||
|
||||
|
||||
function [y_out,nase] = process_(obj,x_in,optional)
|
||||
|
||||
arguments
|
||||
obj
|
||||
@@ -98,11 +113,11 @@ classdef Amplifier
|
||||
if obj.amp_mode == "output_power"
|
||||
seemsright = pow_out_dbm == obj.amplification_db;
|
||||
elseif obj.amp_mode == "gain"
|
||||
seemsright = pow_out_dbm == pow_in_dbm+ obj.amplification_db;
|
||||
seemsright = pow_out_dbm == pow_in_dbm + obj.amplification_db;
|
||||
end
|
||||
|
||||
if ~seemsright
|
||||
warning("Amplifier output not correct, please check the reason");
|
||||
% warning("Amplifier output not correct, please check the reason");
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user