File tree 3 files changed +17
-11
lines changed 3 files changed +17
-11
lines changed Original file line number Diff line number Diff line change 144
144
% call and by the destructor
145
145
obj .connectToDAQandSetUpChannels
146
146
147
- % Start the acquisition
148
- obj .start
149
- fprintf(' Close figure to quit acquisition\n ' )
147
+ if isvalid(obj )
148
+ % Start the acquisition
149
+ obj .start
150
+ fprintf(' Close figure to quit acquisition\n ' )
151
+ end
150
152
end % close constructor
151
153
152
154
Original file line number Diff line number Diff line change 122
122
% call and by the destructor
123
123
obj .connectToDAQandSetUpChannels
124
124
125
- % Start the acquisition
126
- obj .start
127
- fprintf(' Close figure to quit acquisition\n ' )
125
+ if isvalid(obj )
126
+ % Start the acquisition
127
+ obj .start
128
+ fprintf(' Close figure to quit acquisition\n ' )
129
+ end
128
130
end % close constructor
129
131
130
132
Original file line number Diff line number Diff line change 167
167
obj .connectToDAQandSetUpChannels
168
168
169
169
% Start the acquisition
170
- % Report frame rate to screen
171
- fprintf(' Scanning with a frame size of %d by %d at %0.2f frames per second\n ' , ...
172
- obj .imSize , obj .imSize , obj .FPS );
173
- obj .start
174
- fprintf(' Close figure to quit acquisition\n ' )
170
+ if isvalid(obj )
171
+ % Report frame rate to screen
172
+ fprintf(' Scanning with a frame size of %d by %d at %0.2f frames per second\n ' , ...
173
+ obj .imSize , obj .imSize , obj .FPS );
174
+ obj .start
175
+ fprintf(' Close figure to quit acquisition\n ' )
176
+ end
175
177
end % close constructor
176
178
177
179
You can’t perform that action at this time.
0 commit comments