Unreliable Operation: FTP, Telnet, Power, ...
Re: Unreliable Operation: FTP, Telnet, Power, ...
While we're at it: Midnight Commander also shows a strange symptom with the WiPy. FTP basically works, but after I changed to the /flash directory and press Ctrl-R (Refresh) a couple of times, the WiPy will sometimes return the contents of /flash (correct) but sometimes it returns the contents of / (wrong). However, storing and loading files always works reliably.
pyBoard v1.0 + LCD32MKv1.0 | WiPy + Expansion Board | GitHub
- danicampora
- Posts: 342
- Joined: Tue Sep 30, 2014 7:20 am
- Contact:
Re: Unreliable Operation: FTP, Telnet, Power, ...
OK, I'll test it to see what's the problem. Thanks for the report.
Re: Unreliable Operation: FTP, Telnet, Power, ...
Here is the lftp debug information:danicampora wrote:What's that about? Any idea what are the errors that lftp refers to?2 errors detected
I think the 4 errors should be:$ lftp 192.168.6.111
lftp 192.168.6.111:~> user micro python
lftp micro@192.168.6.111:~> debug 9
lftp micro@192.168.6.111:~> mirror -R flash flash
---- Connecting to 192.168.6.111 (192.168.6.111) port 21
<--- 220 Micropython FTP Server
---> FEAT
<--- 332
---> AUTH TLS
<--- 332
---> USER micro
**** SSL_connect: unknown protocol
---- Closing control socket
---- Connecting to 192.168.6.111 (192.168.6.111) port 21
<--- 220 Micropython FTP Server
---> FEAT
<--- 332
---> USER micro
<--- 331
---> PASS python
<--- 230
---> PWD
<--- 257 /
---> MKD flash
<--- 550
---- CWD path to be sent is `~/flash'
---> CWD flash
<--- 250
---> PASV
<--- 227 (192,168,6,111,7,232)
---- Connecting data socket to (192.168.6.111) port 2024
---- Data connection established
---> LIST
<--- 150
<--- 226
---- Got EOF on data connection
---- Closing data socket
---> TYPE I
<--- 200
---> MDTM boot.py
<--- 213 20151102213652
---> MDTM cert
<--- 213 20150101000022
---> MDTM lib
<--- 213 20150101000022
---> MDTM main.py
<--- 213 20151102200722
---> MDTM setup_blynk.py
<--- 213 20151102204934
---> MDTM setup_repl.py
<--- 213 20151102181030
---> MDTM setup_time.py
<--- 213 20151102193250
---> MDTM setup_wifi.py
<--- 213 20151102213652
---> MDTM sys
<--- 213 20150101000022
---> MDTM test.py
<--- 213 20150101000040
---> MDTM wipy_info.py
<--- 213 20151102181038
---> PASV
<--- 227 (192,168,6,111,7,232)
---- Connecting data socket to (192.168.6.111) port 2024
---- Data connection established
---> ALLO 8
<--- 502
---> STOR t.py
<--- 150
---- Closing data socket
<--- 226
---> SITE UTIME 20151104081322 t.py
<--- 502
---> SITE UTIME t.py 20151104081322 20151104081322 20151104081322 UTC
<--- 502
---- CWD path to be sent is `~/flash/lib'
---> CWD
<--- 250
---> CWD flash
<--- 550
mirror: Access failed: 550 (~/flash/lib)
---> CWD lib
<--- 250
---- CWD path to be sent is `~/flash'
---> CWD
<--- 250
---> CWD flash
<--- 250
---> SITE CHMOD 644 t.py
<--- 502
New: 1 file, 0 symlinks
8 bytes transferred
To be removed: 2 directories, 1 file, 0 symlinks
4 errors detected
1. 'AUTH TLS';
2. 'MKD flash';
3. CWD to 'lib' from 'flash' dir ('cd flash/lib' works, but 'cd lib' after 'cd flash' doesn't, wired)
4. don't know...
PYBv1.0, WiPy
Re: Unreliable Operation: FTP, Telnet, Power, ...
OK, I know why CWD failed: `cd ~/flash/lib` doesn't work
lftp micro@192.168.6.111:~> cd ~/flash
cd ok, cwd=~/flash
lftp micro@192.168.6.111:~/flash> cd ~/flash/lib
cd: Access failed: 550 (~/flash/lib)
lftp micro@192.168.6.111:~/flash> cd /flash
cd ok, cwd=/flash
lftp micro@192.168.6.111:/flash> cd /flash/lib
cd ok, cwd=/flash/lib
lftp micro@192.168.6.111:/flash/lib>
PYBv1.0, WiPy
- danicampora
- Posts: 342
- Joined: Tue Sep 30, 2014 7:20 am
- Contact:
Re: Unreliable Operation: FTP, Telnet, Power, ...
OK I see, thanks. It's probably worth adding support for that.
Re: Unreliable Operation: FTP, Telnet, Power, ...
hi
I received my WiPy on Friday and generally everything works. I used telnet for interactive Pythoning, and found most things as expected.
For the FTP transfer, I set up Filezilla as documented and it worked perfectly. e.g. I used it to transfer boot.py and main.py to my PC.
But... If I use ftp in console mode, it doesn't work as expected.
e.g.
As shown above, when I use "ls" (or "dir"), I expect to get a listing of files and directories, but I just get numbers (502).
This is odd, since Filezilla correctly shows the directories and files.
What am I doing wrong in console mode?
Thanks
Gary
I received my WiPy on Friday and generally everything works. I used telnet for interactive Pythoning, and found most things as expected.
For the FTP transfer, I set up Filezilla as documented and it worked perfectly. e.g. I used it to transfer boot.py and main.py to my PC.
But... If I use ftp in console mode, it doesn't work as expected.
e.g.
Code: Select all
>ftp 192.168.1.1
Connected to 192.168.1.1
220 Micropython FTP Server
<enter credentials, and log in>
ftp> ls
502
502
ftp> cd /flash
ftp> ls
502
This is odd, since Filezilla correctly shows the directories and files.
What am I doing wrong in console mode?
Thanks
Gary
- danicampora
- Posts: 342
- Joined: Tue Sep 30, 2014 7:20 am
- Contact:
Re: Unreliable Operation: FTP, Telnet, Power, ...
Hi Gary,
This is in the docs. You need to set the mode to passive. After loging in, just type:
ftp> passive
Press enter, and the everything will work.
Cheers,
Daniel
This is in the docs. You need to set the mode to passive. After loging in, just type:
ftp> passive
Press enter, and the everything will work.
Cheers,
Daniel
Re: Unreliable Operation: FTP, Telnet, Power, ...
hi Daniel
Yes I saw the documentation comment to use "passive"mode but I tried this before posting, and it didn't work.
I have looked further into this and found that the native Windows ftp client does not support "passive" mode. Linux clients do.
I've found WinSCP which can be used in both GUI and command line mode and that works fine.
Gary
Yes I saw the documentation comment to use "passive"mode but I tried this before posting, and it didn't work.
I have looked further into this and found that the native Windows ftp client does not support "passive" mode. Linux clients do.
I've found WinSCP which can be used in both GUI and command line mode and that works fine.
Gary