File tree Expand file tree Collapse file tree 2 files changed +15
-1
lines changed Expand file tree Collapse file tree 2 files changed +15
-1
lines changed Original file line number Diff line number Diff line change @@ -168,7 +168,11 @@ void NetSioPort::end()
168168bool NetSioPort::poll (int ms)
169169{
170170 if (_initialized)
171- return wait_sock_readable (ms);
171+ {
172+ if (handle_netsio () > 0 )
173+ return true ;
174+ return (wait_sock_readable (ms));
175+ }
172176 fnSystem.delay (ms);
173177 return false ;
174178}
Original file line number Diff line number Diff line change @@ -554,6 +554,9 @@ void sioFuji::sio_copy_file()
554554 char *dataBuf;
555555 unsigned char sourceSlot;
556556 unsigned char destSlot;
557+ #ifndef ESP_PLATFORM
558+ uint64_t poll_ts = fnSystem.millis ();
559+ #endif
557560
558561 dataBuf = (char *)malloc (532 );
559562
@@ -648,6 +651,13 @@ void sioFuji::sio_copy_file()
648651 bool err = false ;
649652 do
650653 {
654+ #ifndef ESP_PLATFORM
655+ if (fnSioCom.get_sio_mode () == SioCom::sio_mode::NETSIO && fnSystem.millis () - poll_ts > 1000 )
656+ {
657+ fnSioCom.poll (1 );
658+ poll_ts = fnSystem.millis ();
659+ }
660+ #endif
651661 readCount = fnio::fread (dataBuf, 1 , 532 , sourceFile);
652662 readTotal += readCount;
653663 // Check if we got enough bytes on the read
You can’t perform that action at this time.
0 commit comments