Connect to my Network Drive

Post here about your Arduino projects, get help - for Adafruit customers!

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
User avatar
Billr083046
 
Posts: 16
Joined: Fri Jul 24, 2015 3:41 pm

Connect to my Network Drive

Post by Billr083046 »

I have Uno with CC3000 Shield with SDcard
buildtest works fine. Completes the sketch Displays IP address as 10.0.017 Ping successful and disconnects. I can see the Uno on my network devices.
SD card works fine can read and write to sd card
datalogger sketch works fine. So far I have tried a number of sketches and no problems yet. Baud rate on serial monitor had to be changed to 115200
Without disconnecting how do I connect 10.0.0.220 on my network which is a public folder no login required. This is where for example the datalogger.txt from the sdcard would be sent to.

My guess is to start with the code in buildtest that does the ping on adafruit,com and redirect that to my IP address.
I have looked for example sketches and have found nothing that resembles what I am trying to do. If there are any sample sketches out there point me in that direction.
Right now I am going piece by piece with the sketches to make sure everything is working. So far so good.
Thanks Bill Roberts.

Code: Select all

#ifndef CC3000_TINY_DRIVER
  /* Try looking up www.adafruit.com */
  uint32_t ip = 0;
  Serial.print(F("www.adafruit.com -> "));
  while  (ip  ==  0)  {
    if  (!  cc3000.getHostByName("www.adafruit.com", &ip))  {
      Serial.println(F("Couldn't resolve!"));
    }
    delay(500);
  }  
  cc3000.printIPdotsRev(ip);
  
  /* Do a quick ping test on adafruit.com */  
  Serial.print(F("\n\rPinging ")); cc3000.printIPdotsRev(ip); Serial.print("...");  
  uint8_t replies = cc3000.ping(ip, 5);
  Serial.print(replies); Serial.println(F(" replies"));
  if (replies)
    Serial.println(F("Ping successful!"));

User avatar
adafruit_support_mike
 
Posts: 67446
Joined: Thu Feb 11, 2010 2:51 pm

Re: Connect to my Network Drive

Post by adafruit_support_mike »

You'll need some kind of software running on the target machine that can accept data from the network and write it to the drive.

In most cases, people use a webserver because that offers a lightweight way to transmit information from one machine to another. If you're using a network drive running NFS or SAMBA, you'll need to write a client program that runs on the Arduino and knows how to communicate using those protocols.

I don't know of any such code, and don't know if an Arduino has enough memory to work that way.

User avatar
Billr083046
 
Posts: 16
Joined: Fri Jul 24, 2015 3:41 pm

Re: Connect to my Network Drive

Post by Billr083046 »

ok frustration is setting in with trying to FTP with adafruit cc3000.
I have taken the buildtest and stripped it down to minimum code to save space which works.
I have played around with adding code and cannot get anything to connect to FTP . If someone can give me simple sample code using adafriut cc3000 FTP to log on show directory and files and disconnect that would of immense help and get me in the right direction.
from my laptop cmd prompt I can send the ftp commands to the IP address and log on and show the directory and files no problem so if I can do it from there I should be able to do it from the Adafruit CC3000
My network drive is setup for FTP
FTP address is 10.0.0.9 anonymous.

I have looked at other posts and searched and seems as others are having similar problems with FTP
Having a problem uploading code to this post for some reason but it is the buildtest sketch which I have just striped down so that is does not scan for all ssid and print them ad the sketch works
Thanks for any help pointers
Bill Roberts

Locked
Please be positive and constructive with your questions and comments.

Return to “Arduino”