Store information in Arduino then dump information into a computer

Hi i need to store information in my Arduino and then plug it in to the computer and them dump all the date into the computer. I am using a Moisture sensor and i don't want to drag a computer around as well. CAn any one point me in the right direction XD

i need to store information in my Arduino

How much information? Store it where?

and then plug it in to the computer and them dump all the date into the computer.

Opening the serial port will reset the Arduino. Depending on where you've stored data, it might all just have vanished.

I am getting information from a moisture sensor to the Arduino every second and i want that to be stored somewhere on the Arduino and then when plugged into the computer to send that data to the computer.

I am getting information from a moisture sensor to the Arduino every second

Really? You think the moisture level will change that often?

At least, we now know how often you collect data. Now, all we need to know is what type the variable is that holds the data, and how long you need to be able to collect data when not connected to the computer. Then, we'll be able to talk about options.

Feel free to provide ALL the information needed at once time.

I am doing a school experiment and i have 12 containers with different water contents ranging from 5%-50% and i don't what to have to take a expensive computer out side and do my measurements with it exposed to the elements. So i what the moisture sensor to store its data on the Arduino and when plugged into the computer to up load that information to it. The information is numbers ranging from 774 (100% water) to 0 (No water) can this be done.
thanks :slight_smile:

What people are trying to get you to do is state all of the parameters that could affect a possible solution. Things like what Arduino do you have, what is your budget, what is your time requirements for building it, how much experience do you have, how often are you sampling the data, how many distinct samples will you get each time, how big are the samples in terms of bytes (i.e. is it an integer or float, and what is the range of values), how many samples will you need to collect before uploading them to the computer. In addition, they were pointing out if you are sampling every minute, it may be too often.

Now, there are two general ways to store persistent data on an Arduino that does not get erased, using the EEPROM memory that is built into many Arduinos (but not the Due), or writing the results to an external memory device like a micro-SD card. The EEPROM (if you have it) is free, but it doesn't hold that much memory. So go into google/bing/yahoo/etc. and type in arduino eeprom, and you will see some links, some of which point back here. Also type in arduino sd card. If you had typed in arduino persistant memory, it should give you pointers to both solutions.

Then once you have it recorded, you need to figure out some way to upload it to the computer. There are various approaches, but one may be having something in the program that recognizes when to dump the data instead of read the data.

okay i am using a Arduino RedBoard my budget is low under $5-10 i only need twelve samples, so maybe have a button and when pressed it will tack three recordings and same them using eeprom so that would be 36 readings is that to much? I have built a moisture sensor (attachment below) and have a bit of experience.
all help will be helpful
thanks :slight_smile:

Well Sparkfun doesn't actually list how much EEPROM is on the chip. The Uno has 1K of EEPROM, so if the Redboard has the same amount, that means you could store 512 16-bit integers in EEPROM. You probably need one integer in the EEPROM to indicate the last position, so figure 511 samples can be stored.

okay, has any one got some code that i can work on then!

okay, has any one got some code that i can work on then!

// Global variables are declared here

void setup()
{
   // One time stuff goes here
}

void loop()
{
    // Stuff that happens over and over goes here
}