sdfghj
Dependencies: FTPClient SDFileSystem WIZnetInterface mbed
Fork of FTP_TESTClient by
Revision 1:b6196ce9efac, committed 2017-12-14
- Comitter:
- akshaytom
- Date:
- Thu Dec 14 04:50:55 2017 +0000
- Parent:
- 0:e35dac7e4c95
- Commit message:
- asdfghj
Changed in this revision
--- a/FTPClient.lib Tue Nov 28 09:47:16 2017 +0000 +++ b/FTPClient.lib Thu Dec 14 04:50:55 2017 +0000 @@ -1,1 +1,1 @@ -https://developer.mbed.org/users/Ricky_Kwon/code/FTPClient/#4fd8e5cd6307 +https://os.mbed.com/users/akshaytom/code/FTPClient/#8ecc32e7c69b
--- a/WIZnetInterface.lib Tue Nov 28 09:47:16 2017 +0000 +++ b/WIZnetInterface.lib Thu Dec 14 04:50:55 2017 +0000 @@ -1,1 +1,1 @@ -https://developer.mbed.org/teams/WIZnet/code/WIZnetInterface_Ricky/#5a1969320666 +https://os.mbed.com/users/akshaytom/code/WIZnetInterface/#584efa51ee60
--- a/main.cpp Tue Nov 28 09:47:16 2017 +0000 +++ b/main.cpp Thu Dec 14 04:50:55 2017 +0000 @@ -18,29 +18,35 @@ char ftpServer_control_ip_addr[] = "demo.wftpserver.com"; // FTP Server location char* userid = "demo-user"; //FTP Server User ID - char* password = "demo-user"; //FTP Server Password - EthernetInterface eth; - uint8_t mac_addr[6] = {0x00, 0x08, 0xdc, 0x12, 0x34, 0x45}; - char IP_Addr[] = "192.168.0.100"; -char IP_Subnet[] = "255.255.255.0"; -char IP_Gateway[] = "192.168.0.1"; + char* pass = "demo-user"; //FTP Server Password + EthernetInterface eth; + uint8_t mac_addr[6] = {0x00, 0x08, 0xdc, 0x12, 0x34, 0x45}; + char IP_Addr[] = "192.168.0.101"; + char IP_Subnet[] = "255.255.255.0"; + char IP_Gateway[] = "192.168.0.1"; eth.init(mac_addr, IP_Addr, IP_Subnet, IP_Gateway); //Use Static eth.connect(); - pc.printf("The IP address of the client is %s\r\n",eth.getIPAddress()); + pc.printf("\nThe IP address of the client is %s\r\n",eth.getIPAddress()); while(1) { - char Msg_c = pc.getc(); + //char Msg_c = pc.getc(); + + //if(Msg_c==0x31) + //{ - if(Msg_c==0x31){ - - pc.printf("Connecting...FTPServer\r\nIP:%s, PORT:%d\r\n", ftpServer_control_ip_addr, FTP_SERVER_PORT); - int n = FTP.open("demo.wftpserver.com", 21,"demo-user","demo-user"); - pc.printf("%d\r\n",n); + pc.printf("\nConnecting...FTPServer\r\nIP:%s, PORT:%d\r\n", ftpServer_control_ip_addr, FTP_SERVER_PORT); + //pc.printf("Test\n"); + + //FTP.open("demo.wftpserver.com"); + + bool n = FTP.open("192.168.0.100", 21,"FTP","user"); + + //pc.printf("%d\r\n",n); wait(10); - printf("The Files and folders available in the server are :\r\n"); + printf("\nThe Files and folders available in the server are :\r\n"); FTP.ls(); printf("\r\n"); - wait(10); + wait(10); printf("The Files in upload folder are :\r\n"); FTP.cd("/upload"); FTP.ls(); @@ -49,9 +55,9 @@ FTP.cd("/download"); FTP.ls(); printf("\r\n"); - wait(10); + wait(10); - } + // } }