From b8d6d138bede5fe4e8eb25fc10f709ae434d6038 Mon Sep 17 00:00:00 2001 From: Julia Pineda Date: Mon, 29 Apr 2024 15:48:18 +0800 Subject: [PATCH] DEBUG: Check libm2k access using signal tests only Signed-off-by: Julia Pineda --- JenkinsfileHW | 2 +- test/AD4630_24Tests.m | 32 ++++++++++++++++---------------- 2 files changed, 17 insertions(+), 17 deletions(-) diff --git a/JenkinsfileHW b/JenkinsfileHW index b16e261..43afad7 100644 --- a/JenkinsfileHW +++ b/JenkinsfileHW @@ -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') diff --git a/test/AD4630_24Tests.m b/test/AD4630_24Tests.m index b140e45..8b84165 100644 --- a/test/AD4630_24Tests.m +++ b/test/AD4630_24Tests.m @@ -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