Skip to content

Commit f5a9fa0

Browse files
committed
Fix n-module check
1 parent 6a12dd3 commit f5a9fa0

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Functions/+BpodLib/+calibration/+liquid/+portarray/createValveManager.m

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,8 @@
3232
%}
3333

3434
PortArrayCal = BpodLib.calibration.liquid.ValveDataManagerClass();
35-
36-
for moduleNumber = 1:BpodSystem.Modules.nModules
35+
nModules = numel(BpodSystem.Modules.Connected);
36+
for moduleNumber = 1:nModules
3737
for valveIndex = 1:8 % Todo: Only the connected PA's?
3838
PortArrayCal.createValve(sprintf('PA%i_%i', moduleNumber, valveIndex));
3939
end

0 commit comments

Comments
 (0)