Commit before first big baudrate sweep

This commit is contained in:
Silas Labor Zizou
2024-10-24 19:41:59 +02:00
parent cfd1bdb513
commit bafc7f12b7
11 changed files with 588 additions and 318 deletions

View File

@@ -7,11 +7,12 @@ classdef Awg2Scope
Scope
mapping;
waitUntilClick
end
methods (Access=public)
function obj = Awg2Scope(Awg,Scope,mapping)
function obj = Awg2Scope(Awg,Scope,mapping,options)
%Simple class to call the Awg and Scope and map the signals
%accordingly in the correct formats with correct l
% ogbook
@@ -21,16 +22,19 @@ classdef Awg2Scope
Awg
Scope
mapping
options.waitUntilClick = 0;
end
obj.Awg = Awg;
obj.Scope = Scope;
obj.mapping = mapping; % AWG CH [1,2,3,4] -> Scope CH [0,0,0,1]
obj.waitUntilClick = options.waitUntilClick;
end
function [S1,S2,S3,S4] = process(obj,channels)
function [S1,S2,S3,S4] = process(obj,channels, options)
arguments
obj
@@ -41,15 +45,33 @@ classdef Awg2Scope
channels.signal4 Informationsignal = Informationsignal([])
% add new optional arguments here
options.waitUntilClick = obj.waitUntilClick;
end
%%% UPLOAD TO AWG %%%
[S1,S2,S3,S4]=obj.Awg.upload("signal1",channels.signal1,...
"signal2",channels.signal2,...
"signal3",channels.signal3,...
"signal4",channels.signal4...
);
%%% UPLOAD TO AWG %%%
scpe_sig_cell = obj.Scope.read();
%%% READ FROM SCOPE %%%
scpe_sig_cell = obj.Scope.read("waitUntilClick",options.waitUntilClick);
%%% READ FROM SCOPE %%%
% Map Scope measurement to output signal
% mapping index is the AWG chanel and mapping number is the