Skip to content

Commit

Permalink
DEBUG: Check libm2k access using signal tests only
Browse files Browse the repository at this point in the history
Signed-off-by: Julia Pineda <[email protected]>
  • Loading branch information
jpineda3 committed Apr 29, 2024
1 parent 071a32d commit b8d6d13
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 17 deletions.
2 changes: 1 addition & 1 deletion JenkinsfileHW
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ lock('nuc04') {
// Test stage
harness.set_matlab_commands(["addpath(genpath('test'))",
"pyenv('Version','/usr/bin/python3')",
"clib.libm2k.libm2k.context.getVersion()",
"disp(clib.libm2k.libm2k.context.getVersion())",
"runHWTests(getenv('board'))"])
harness.add_stage(harness.stage_library("MATLABTests"),'continueWhenFail')

Expand Down
32 changes: 16 additions & 16 deletions test/AD4630_24Tests.m
Original file line number Diff line number Diff line change
Expand Up @@ -49,22 +49,22 @@ function testAD4630_24Smoke(testCase)
testCase.assertTrue(sum(abs(double(data)))>0);
end

function testAD4630_24AttrSampleRate(testCase,sample_rate)
% '1760000' is set as '1754386'
adc = adi.AD4630_24.Rx('uri',testCase.uri);
adc.uri = testCase.uri;
val = sample_rate;
adc.SampleRate = val;
[data,valid] = adc();
ret_val = adc.getDeviceAttributeRAW('sampling_frequency',9);
adc.release();
testCase.assertTrue(valid);
testCase.assertTrue(sum(abs(double(data)))>0);
% testCase.assertTrue(strcmp(val,string(ret_val)), ...
% 'Sample rate unexpected')
testCase.verifyEqual(str2double(ret_val),str2double(val), ...
'RelTol',0.01,'Sample rate unexpected')
end
% function testAD4630_24AttrSampleRate(testCase,sample_rate)
% % '1760000' is set as '1754386'
% adc = adi.AD4630_24.Rx('uri',testCase.uri);
% adc.uri = testCase.uri;
% val = sample_rate;
% adc.SampleRate = val;
% [data,valid] = adc();
% ret_val = adc.getDeviceAttributeRAW('sampling_frequency',9);
% adc.release();
% testCase.assertTrue(valid);
% testCase.assertTrue(sum(abs(double(data)))>0);
% % testCase.assertTrue(strcmp(val,string(ret_val)), ...
% % 'Sample rate unexpected')
% testCase.verifyEqual(str2double(ret_val),str2double(val), ...
% 'RelTol',0.01,'Sample rate unexpected')
% end

% function testAD4630_24AttrSampleAveragingLength(testCase,sample_averaging_length)
% % The average mode works only with the output data mode set to 30-bit average
Expand Down

0 comments on commit b8d6d13

Please sign in to comment.