esp8266FTPServer icon indicating copy to clipboard operation
esp8266FTPServer copied to clipboard

Faster transfers

Open bbx10 opened this issue 8 years ago • 6 comments

I made some changes to increase transfer speeds to the range of 100 - 300 Kbytes/s. Also reduces blocking so ftp can co-exist with other services. Let me know if you want a PR.

https://github.com/bbx10/esp8266FTPServer/tree/speedup

bbx10 avatar Jun 30 '17 10:06 bbx10

great work! thanks. Good timing too, as I just got a esp32 and was going to test the library with it. I'll test out your changes and verify esp32 library as well. (unless someone has already tried it on esp32 and can confirm it works fine...)

nailbuster avatar Jun 30 '17 15:06 nailbuster

SPIFFs for arduino-esp32 is not ready but I will also try it when it is.

bbx10 avatar Jun 30 '17 18:06 bbx10

The FTP server is faster than expected. wget ftp://esp8266:[email protected]/512kb.dat shows 877 KB/s for a 512 KB file.

$ wget ftp://esp8266:[email protected]/512kb.dat
--2017-06-30 11:40:08--  ftp://esp8266:*password*@192.168.1.129/512kb.dat
           => ‘512kb.dat.6’
Connecting to 192.168.1.129:21... connected.
Logging in as esp8266 ... Logged in!
==> SYST ... 
Server error, can't determine system type.
==> PWD ... done.
==> TYPE I ... done.  ==> CWD not needed.
==> SIZE 512kb.dat ... 526294
==> PASV ... done.    ==> RETR 512kb.dat ... done.
Length: 526294 (514K) (unauthoritative)

100%[======================================>] 526,294      877KB/s   in 0.6s   

bbx10 avatar Jun 30 '17 22:06 bbx10

@bbx10 Congratulations !!! Working flawlessly on the Wemos D1 Mini Pro till the flash got corrupted.

@nailbuster Your original library was corrupting my 16 MB flash, so I'm currently testing @bbx10 changes now on 3 MB of flash. My ESP32 will arrive next week so I can test it if you want.

capedra avatar Jul 29 '17 09:07 capedra

Well, I'm doing some tests on 3 MB of SPIFFS now, because with 14900866 total bytes of flash, every now and then my files get corrupted after transferring them to SPIFFS. I wish to have some luck this time. You can get some updates on here:

https://github.com/esp8266/Arduino/issues/2581

capedra avatar Jul 30 '17 08:07 capedra

@nailbuster & @bbx10 As SPIFFS on ESP32 is working now I added support for the ESP32 to your FTP server. I merged as well bbx10's changes for speed improvement and reduction for blocking. Tested on my ESP32 dev module with FileZilla.

I added as well a library.json (needs to be adapted though) so that the library can be used with PlatformIO.

See pull request Added ESP32 support, merged bbx10 speed improvement

beegee-tokyo avatar Oct 16 '17 07:10 beegee-tokyo