3636 num_eeg_channels
3737 num_aux_channels
3838 marker_pulse_width_sec
39+ protocol_type
40+ connection_status
3941 end
4042
4143 properties (SetAccess = private , Dependent )
@@ -343,27 +345,46 @@ function stop(obj)
343345 end
344346
345347 function n = get .num_eeg_channels(obj )
346- n = getparam(obj , {' UDP Decode' ,' UDP_Decode_Biosignal/Decode UDP Messages/NeurOne Decode' },' numEEGch' );
348+ if obj .protocol_type == 2 % actiCHamp
349+ n = obj .getsignal({' UDP Decode' ,' UDP_Decode_Biosignal/Decode UDP Messages/TurboLink Decode' ,...
350+ ' TurboLink_UDP_Decode/MATLAB Function' },1 ) * 32 ;
351+ else
352+ n = getparam(obj , {' UDP Decode' ,' UDP_Decode_Biosignal/Decode UDP Messages/NeurOne Decode' },' numEEGch' );
353+ end
347354 end
348355
349356 function set .num_eeg_channels(obj , n )
350357 arguments
351358 obj
352359 n uint8 {mustBeInteger ,mustBeNonnegative }
353360 end
354- setparam(obj , {' UDP Decode' ,' UDP_Decode_Biosignal/Decode UDP Messages/NeurOne Decode' },' numEEGch' , n );
361+
362+ if obj .protocol_type == 2 % actiCHamp
363+ warning(' Number of EEG channels is determined automically for actiCHamp. This input will be ignored.' );
364+ else
365+ setparam(obj , {' UDP Decode' ,' UDP_Decode_Biosignal/Decode UDP Messages/NeurOne Decode' },' numEEGch' , n );
366+ end
355367 end
356368
357369 function n = get .num_aux_channels(obj )
358- n = getparam(obj , {' UDP Decode' ,' UDP_Decode_Biosignal/Decode UDP Messages/NeurOne Decode' },' numAUXch' );
370+ if obj .protocol_type == 2 % actiCHamp
371+ n = 8 ;
372+ else
373+ n = getparam(obj , {' UDP Decode' ,' UDP_Decode_Biosignal/Decode UDP Messages/NeurOne Decode' },' numAUXch' );
374+ end
359375 end
360376
361377 function set .num_aux_channels(obj , n )
362378 arguments
363379 obj
364380 n uint8 {mustBeInteger ,mustBeNonnegative }
365381 end
366- setparam(obj , {' UDP Decode' ,' UDP_Decode_Biosignal/Decode UDP Messages/NeurOne Decode' },' numAUXch' , n );
382+
383+ if obj .protocol_type == 2 % actiCHamp
384+ warning(' Number of AUX channels is determined automically for actiCHamp. This input will be ignored.' );
385+ else
386+ setparam(obj , {' UDP Decode' ,' UDP_Decode_Biosignal/Decode UDP Messages/NeurOne Decode' },' numAUXch' , n );
387+ end
367388 end
368389
369390 function val = get .marker_pulse_width_sec(obj )
@@ -374,6 +395,14 @@ function stop(obj)
374395 setparam(obj , ' GEN' , ' marker_pulse_width_sec' , val );
375396 end
376397
398+ function val = get .protocol_type(obj )
399+ val = obj .getsignal({' UDP Decode' ,' UDP_Decode_Biosignal/Decode UDP Messages/Protocol Selector' },1 );
400+ end
401+
402+ function val = get .connection_status(obj )
403+ val = obj .getsignal({' UDP Receive' ,' UDP_Receive_Queue/UDP Connection Status' },1 );
404+ end
405+
377406 function obj = configure_generator_sequence(obj , sequence )
378407 arguments
379408 obj bossdevice
0 commit comments