フィルターのクリア

Raspberry PI - "Timeout while receiving data from remote server"

30 ビュー (過去 30 日間)
Matthieu GATINE
Matthieu GATINE 2018 年 10 月 23 日
回答済み: Kyle Mitchell 2021 年 12 月 21 日
Hi, I have this error message :"Timeout while receiving data from remote server" when I use the command "raspi" in the command window. But the ping command is working fine so I'm connected to my raspberry pi.
  2 件のコメント
Jan Hrabina
Jan Hrabina 2018 年 12 月 14 日
Hi, I have the same problem. The connection to RPi is fine, I am able to connect to it with "raspi" command and control it by shell commands or use raspi object read functions like "showPins". But write functions (writeLED, configurePIN, ... ) ends in error: "Timeout while receiving data from remote server".
Work with PINS/LEDS by shelll commands works OK (system(rpi, 'echo 0 | sudo tee /sys/class/leds/led0/brightness');)
Any reason/solution, please?
Jonathan
Jonathan 2019 年 2 月 13 日
I had the same issue - RPI connection is fine, pinging the Pi works fine, but the writeRead function gives the same timeout error.
Switching off Windows firewall (I'm using Windows 7) completely solves the problem. (Note: switching the Firewall off after connecting using the 'raspi' command doesn't seem to work, it seems I need to switch off the Firewall before that).
Does anyone know how to add an exception in Windows Firewall in order to allow this to work without completely shutting down the Firewall? I have tried adding an exception (both inbound and outbound) for the IP address and port using the procedure shown here, but the problem seems to persist. I can live with switching the Firewall on and off but it's not particularly convenient.

サインインしてコメントする。

回答 (9 件)

Oscar Pilloni
Oscar Pilloni 2018 年 11 月 27 日
Had the exact same problem.
TL;DR: Disable your firewall (or make the appropiate rule changes)
Disabled mine, everything works great.

Fabian Schilling
Fabian Schilling 2018 年 10 月 23 日
編集済み: Fabian Schilling 2018 年 10 月 23 日
I have the same Problem since three days und five try's to install the support packages. The Connection via Simulink works….

M LaRosa
M LaRosa 2018 年 10 月 24 日
I had the same problem after selecting "Connect directly to host computer" during the "Hardware Setup" of Simulink Support Package for Raspberry Pi Hardware version 18.2.0. I do not get the error message if I select "Connect to wireless network" (depending on what you are trying to do, this might be an acceptable workaround).

Peter Demeter
Peter Demeter 2018 年 11 月 8 日
I have same issue, I tried connect directly and over LAN also, results were same. After "rpi = raspi();" command, SSH doesnt work with default user and password.

Austin Gosling
Austin Gosling 2019 年 1 月 11 日
I have a similar issue since installing R2018B, which then automatically updated the Raspberry Pi Matlab server to version 18.2.1 from 18.1.0. If the connection is left too long without use it times out afterwards. For example, If I do this in a script:
clear dac
clear rpi
rpi=raspi
dac = rpi.spidev('CE1',1,2000000)
writeDAC0(rpi,dac,2.0) % my function that writes to the DAC via SPI
for i=1:100
writeDAC0(rpi,dac,2.0+i/100)
fprintf('%d ',i)
pause(1)
end
It works fine, and if I am fast enough to start the for loop again, it keeps going. If I enter these commands manually, and wait too long after the rpi=raspi command, then the dac = ... command times out. If I enter the rpi=raspi and the dac = ... commands quickly and wait too long for the writeDAC0 command, it times out. If I try the writeDAC0 command again after a few seconds, it times out.
The behaviour is the same if I just try simple commands like rpi.writeDigitalPin, etc.
Timeout message: Timeout while receiving data from remote server
I've tried running a continuous ping in a command shell (Windows), but this makes no difference. netstat -n reports the TCP connection to 18734 active throughout the whole process, whether I time out or not, so I suspect it is somewhere in the matlabIOserver on the Raspberry Pi, or in Matlab on windows.
Everything works fine with no timeouts on R2018A and matlabIOserver v18.1.0.
Working configuration:
  • Windows 64 bit
  • Matlab R2018A
  • Raspberry Pi Model 3 B (not +)
  • server_v18.1.0 on Rapberry Pi
Not working configuration:
  • Windows 64 bit
  • Matlab R2018B
  • Raspberry Pi Model 3 B (not +)
  • server_v18.2.1 on Rapberry Pi
  1 件のコメント
Jonas DK
Jonas DK 2019 年 2 月 4 日
編集済み: Jonas DK 2019 年 2 月 4 日
I am experiencing the same. If I start my script after waiting for too long, it gives the timeout error. If I am fast enough it runs okay (I a talking about blinking the LED...).
I am using 2018b, Raspberry PI model 1B and raspbian v18.2.0

サインインしてコメントする。


Austin Gosling
Austin Gosling 2019 年 2 月 28 日
Update: disabling the windows fireall for private networks resolved the issue for R2018B

Brian
Brian 2019 年 9 月 30 日
Check out youtube video 'Request Timed Out Fix Windows 10/8/7' this worked for me, without disabling the firewall

Oihan Irazu
Oihan Irazu 2020 年 3 月 2 日
Hi, I am having the same problem. Desactivating the firewalls does not work for me and continueing the video "Request Timed Out Fix Windows 10/8/7" give me error because I am connected with WIFI to Internet I think.
Any other suggestion to try to solve this problem?
Thank you!
  2 件のコメント
Miroslav
Miroslav 2020 年 3 月 31 日
Have you resolved the issue yet?
Oihan Irazu
Oihan Irazu 2020 年 4 月 1 日
Yes!
I desactivate the firewalls and then restart the computer. Then everythings works well.

サインインしてコメントする。


Kyle Mitchell
Kyle Mitchell 2021 年 12 月 21 日
It appears that the Matlab Server running on the PI pings the host computer every 5-7 seconds as a heart beat. If these pings fail the Server on the PI closes the connection.
Allowing ping responces in the firewall for private networks seems to be the fix for this issue.

カテゴリ

Help Center および File ExchangeMATLAB Support Package for Raspberry Pi Hardware についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by