From f862869dd7e012bf39e44005af5a205d1e2bfaee Mon Sep 17 00:00:00 2001 From: Pablo Romero Date: Sun, 3 May 2026 00:23:26 +0200 Subject: [PATCH 1/9] Run tests on R2026a too. --- .github/workflows/main.yml | 2 +- tests/commonSetupTests.m | 15 +++++++++------ toolbox/dependencies/bossapi | 2 +- 3 files changed, 11 insertions(+), 8 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 368595d..ef94c15 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -62,7 +62,7 @@ jobs: strategy: fail-fast: false # Run with every MATLAB version independently matrix: - matlabVer: [R2024b, R2025b] # List of MATLAB releases to test + matlabVer: [R2024b, R2025b, R2026a] # List of MATLAB releases to test runs-on: matlab # Steps represent a sequence of tasks that will be executed as part of the job diff --git a/tests/commonSetupTests.m b/tests/commonSetupTests.m index 766acff..92bf8fd 100644 --- a/tests/commonSetupTests.m +++ b/tests/commonSetupTests.m @@ -22,16 +22,19 @@ function setupBossdevice(testCase) testCase.bd = bossdevice; testCase.assertThat(@() bossapi.tg.pingTarget(testCase.bd.targetObject),... - Eventually(IsTrue,"WithTimeoutOf",60),'Should wait until bossdevice has rebooted.'); + Eventually(IsTrue,"WithTimeoutOf",60),'Target is not reachable at test class setup.'); - % Wait additional seconds since the target may respond ping but not be ready yet - pause(testCase.waitTimeReboot); + % Boot on QNX or Linux based on current release + bossapi.tg.setBootForCurrentRelease("TargetObject",testCase.bd.targetObject,"AutoReboot",true); + pause(10); % Must wait a bit because reboot command is not immediate + testCase.assertThat(@() bossapi.tg.pingTarget(testCase.bd.targetObject),... + Eventually(IsTrue,"WithTimeoutOf",60),'Target is not available after setting boot OS.'); % Update target and wait until it has rebooted testCase.bd.targetObject.update; - testCase.assertThat(@() bossapi.tg.pingTarget(testCase.bd.targetObject),... - Eventually(IsTrue,"WithTimeoutOf",60),'Should wait until bossdevice has rebooted.'); + testCase.assertThat(@() bossapi.tg.pingTarget(testCase.tg),... + Eventually(IsTrue,"WithTimeoutOf",60),'Target is not available after updating.'); % Wait additional seconds since the target may respond ping but not be ready yet pause(testCase.waitTimeReboot); @@ -56,7 +59,7 @@ function rebootTarget(testCase) import matlab.unittest.constraints.Eventually import matlab.unittest.constraints.IsTrue - if ~isempty(testCase.bd) && testCase.bd.isConnected + if ~isempty(testCase.bd) && testCase.bd.isInitialized disp('Rebooting bossdevice to teardown test class.'); testCase.bd.reboot; end diff --git a/toolbox/dependencies/bossapi b/toolbox/dependencies/bossapi index a5ce805..f017093 160000 --- a/toolbox/dependencies/bossapi +++ b/toolbox/dependencies/bossapi @@ -1 +1 @@ -Subproject commit a5ce8052661f139288ba507c30aa66cf4ed611ab +Subproject commit f017093ce76c95fb1bb66266829bb7a6461d461e From c2d1eb7595bb45980ba61baf1b740c0a31a8e0af Mon Sep 17 00:00:00 2001 From: Pablo Romero Date: Sun, 3 May 2026 00:52:07 +0200 Subject: [PATCH 2/9] Update target object in ping assertion test --- tests/commonSetupTests.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/commonSetupTests.m b/tests/commonSetupTests.m index 92bf8fd..5e527de 100644 --- a/tests/commonSetupTests.m +++ b/tests/commonSetupTests.m @@ -33,7 +33,7 @@ function setupBossdevice(testCase) % Update target and wait until it has rebooted testCase.bd.targetObject.update; - testCase.assertThat(@() bossapi.tg.pingTarget(testCase.tg),... + testCase.assertThat(@() bossapi.tg.pingTarget(testCase.bd.targetObject),... Eventually(IsTrue,"WithTimeoutOf",60),'Target is not available after updating.'); % Wait additional seconds since the target may respond ping but not be ready yet From 60c21cfaa6423e201ebe91818ac27e00ab6b6535 Mon Sep 17 00:00:00 2001 From: Pablo Romero Date: Sun, 3 May 2026 09:26:32 +0200 Subject: [PATCH 3/9] Update Ethernet interface handling based on MATLAB version --- toolbox/src/bossdevice.m | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/toolbox/src/bossdevice.m b/toolbox/src/bossdevice.m index a437813..710ad35 100644 --- a/toolbox/src/bossdevice.m +++ b/toolbox/src/bossdevice.m @@ -272,7 +272,11 @@ function initialize(obj) % Load firmware on the bossdevice if not loaded yet if ~obj.targetObject.isLoaded % Set Ethernet IP in secondary interface - bossapi.tg.setEthernetInterface(obj.targetObject,'wm1','192.168.200.5/24'); + if isMATLABReleaseOlderThan("R2026a") + bossapi.tg.setEthernetInterface(obj.targetObject,'wm1','192.168.200.5/24'); + else + bossapi.tg.setEthernetInterface(obj.targetObject,'enp4s0','192.168.200.5/24'); + end obj.logObj.info('Loading application "%s" on "%s"...',obj.appName,obj.targetObject.TargetSettings.name); obj.targetObject.load(obj.firmwareFilepath); From 11c8b7c06d5d8e79e99a9d9b3a72d8b0ba42ba91 Mon Sep 17 00:00:00 2001 From: Pablo Romero Date: Sun, 3 May 2026 23:55:43 +0200 Subject: [PATCH 4/9] Wait after issuing reboot with RTLinux. --- tests/commonSetupTests.m | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tests/commonSetupTests.m b/tests/commonSetupTests.m index 5e527de..b927507 100644 --- a/tests/commonSetupTests.m +++ b/tests/commonSetupTests.m @@ -62,6 +62,10 @@ function rebootTarget(testCase) if ~isempty(testCase.bd) && testCase.bd.isInitialized disp('Rebooting bossdevice to teardown test class.'); testCase.bd.reboot; + + if ~isMATLABReleaseOlderThan("R2026a") + pause(testCase.waitTimeReboot); + end end end end From eab3f223ae634aedc9f7f0fc2a185ad8c298b5b2 Mon Sep 17 00:00:00 2001 From: Pablo Romero Date: Sun, 17 May 2026 21:00:05 +0200 Subject: [PATCH 5/9] Update bossapi submodule to match main branch. --- toolbox/dependencies/bossapi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/toolbox/dependencies/bossapi b/toolbox/dependencies/bossapi index f017093..a6b958d 160000 --- a/toolbox/dependencies/bossapi +++ b/toolbox/dependencies/bossapi @@ -1 +1 @@ -Subproject commit f017093ce76c95fb1bb66266829bb7a6461d461e +Subproject commit a6b958d8f23d7395785b62104c9d5ca43a29ef7d From 3d62732a981012d4e5739d8ded72c031cea4bc77 Mon Sep 17 00:00:00 2001 From: Pablo Romero Date: Sun, 17 May 2026 21:39:02 +0200 Subject: [PATCH 6/9] Fix updateSGdeps.m for R2026a and later. --- buildUtilities/updateSGdeps.m | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/buildUtilities/updateSGdeps.m b/buildUtilities/updateSGdeps.m index 5d8553f..522a9eb 100644 --- a/buildUtilities/updateSGdeps.m +++ b/buildUtilities/updateSGdeps.m @@ -10,7 +10,11 @@ % Figure out list of Speedgoat tools to copy sgTools = dir(fullfile(sgDefaultPath,'sg_resources')); -sgTools = sgTools(~[sgTools.isdir]); +if isMATLABReleaseOlderThan('R2026a') + sgTools = sgTools(~[sgTools.isdir]); +else + sgTools = sgTools(ismember({sgTools.name},{'antelope_rtos'})); +end % Create dependencies folder in local toolbox destFolder = fullfile(projObj.RootFolder,'toolbox/dependencies/sg'); From ebaf40c16f6e251ed8aa7b2a9a72753a115cbb0a Mon Sep 17 00:00:00 2001 From: Pablo Romero Date: Sun, 17 May 2026 23:02:00 +0200 Subject: [PATCH 7/9] Fix typos. --- toolbox/src/bossdevice.m | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/toolbox/src/bossdevice.m b/toolbox/src/bossdevice.m index 1cfccd4..c4253a5 100644 --- a/toolbox/src/bossdevice.m +++ b/toolbox/src/bossdevice.m @@ -609,11 +609,11 @@ function restoreInstrument(obj) obj bossdevice signalName {mustBeTextScalar} % Signal to log in buffer bufferLen (1,1) {mustBePositive} % Buffer length in seconds - options.ArrayIndex {mustBeVector,mustBeInteger} = 1; % If signal is multidimensional only buffers the indicated element(s) + options.ArrayIndex {mustBeVector(options.ArrayIndex,"allow-all-empties"),mustBeInteger} = []; options.SignalProps {mustBeText} = {}; % Additional signal properties like bus element name or decimation end - % Initializie streamingAsyncBuffer object + % Initialize streamingAsyncBuffer object bufObj = slrtCustomInst.streamingAsyncBuffer(signalName,'',bufferLen,... 'AppName',obj.firmwareFilepath,'ArrayIndex',options.ArrayIndex,'SignalProps',options.SignalProps); end From e97ef334ff818c7dded04755043cac3e721a67a3 Mon Sep 17 00:00:00 2001 From: Pablo Romero Date: Sun, 17 May 2026 23:09:05 +0200 Subject: [PATCH 8/9] Fix typo. --- toolbox/examples/demo_phase_prediction_error_simple.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/toolbox/examples/demo_phase_prediction_error_simple.m b/toolbox/examples/demo_phase_prediction_error_simple.m index 3edca4c..64d36ca 100644 --- a/toolbox/examples/demo_phase_prediction_error_simple.m +++ b/toolbox/examples/demo_phase_prediction_error_simple.m @@ -43,7 +43,7 @@ alpha_ip = sigData{1}.data; disp('Done.'); -% Compensante offset in instantaneous predicted phase +% Compensate offset in instantaneous predicted phase numSamples = bd.alpha.offset_samples; assert(numSamples >= 1); From 012e699ad80a749cb51a4069940fab7b2a399d8e Mon Sep 17 00:00:00 2001 From: Pablo Romero Date: Sun, 17 May 2026 23:10:48 +0200 Subject: [PATCH 9/9] Disable example demo_phase_prediction_error_simple on R2026a. --- buildUtilities/testTask.m | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/buildUtilities/testTask.m b/buildUtilities/testTask.m index ff378ef..7cfdd3c 100644 --- a/buildUtilities/testTask.m +++ b/buildUtilities/testTask.m @@ -51,4 +51,10 @@ testcases(ismember(testcases,{... 'demo_mu_rhythm_phase_triggering.m'})) = []; +if ~isMATLABReleaseOlderThan('R2026a') + % Example fails due to getBufferedData. To be replaced by new asyncBuffer object + testcases(ismember(testcases,{... + 'demo_phase_prediction_error_simple.m'})) = []; +end + end