- Ensure that the IP address 8.8.8.8 is not blocked on the network to which your Raspberry Pi is connected.Ensure that you enabled passwordless sudo: https://www.mathworks.com/help/simulink/supportpkg/raspberrypi_ug/enable-passwordless-sudo-in-linux-on-raspberry-pi-hardware.html
- Ping the Raspi from MATLAB:
- Ping the Raspi without timeout: The outputs of 'resultTimeout' and 'resultNoTO', as well as the elapsed time returned by tic-toc will help us debug more.
- If the above commands produce errors, then connect to Raspberry Pi through an SSH session and execute the following command:
- Share the output with us, this would give us more information about sudo privileges for a given username. Also, execute the following commands directly on the Raspi:
- https://www.mathworks.com/matlabcentral/answers/2078281-matlab-support-package-test-connection-error
- https://www.mathworks.com/help/simulink/supportpkg/raspberrypi_ug/access-internet-when-raspberry-pi-is-directly-connected-to-computer-using-ethernet.html