I am looking for a pass/fail status the the initial TCP connection.
t = tcpclient('192.168.1.15', 52801);
if exist('t','var')
disp('TCP Connection setup');
else
disp('TCP Connection not setup');
end
When the TCP connection is unsuccessful, an error message is generated in the console, and the code execution is aborted. This is the error message in the console:
Error using Untitled (line 2)
Cannot create a communication link with the remote server. Please check the input arguments(ADDRESS and PORT) and make sure the server is running.
Additional Information: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond.
Is there another way to check that status of a tcp connection with the Instrument Control Toolbox? (i.e. A ping command that doesn't require the "MATLAB Compiler SDK").
Thank you!
Rob