down loading data from a data logger is it posable?

XBee projects like the adapter, xBee tutorials, tweetawatt/wattcher, etc. from Adafruit

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
User avatar
timwjkl
 
Posts: 56
Joined: Wed Jul 03, 2013 2:48 pm

down loading data from a data logger is it posable?

Post by timwjkl »

Is there a way to retrieve the data from the data logger after a week of unattended logging? I can get the data by pulling the card out of the test project but the real project will be almost unreachable once setup up a tall pole :D

User avatar
adafruit_support_bill
 
Posts: 88093
Joined: Sat Feb 07, 2009 10:11 am

Re: down loading data from a data logger is it posable?

Post by adafruit_support_bill »

You could connect a serial line, XBee or CC3000 WiFi module and write code to stream the data from the SD card.

User avatar
timwjkl
 
Posts: 56
Joined: Wed Jul 03, 2013 2:48 pm

Re: down loading data from a data logger is it posable?

Post by timwjkl »

so with xbee 1 I can let the logger work and then drive up and have it download to a laptop with another xbee attached to it ? that is fantastic news I haven't haven't been able to find a example with that but it is exactly what I need.

User avatar
adafruit_support_bill
 
Posts: 88093
Joined: Sat Feb 07, 2009 10:11 am

Re: down loading data from a data logger is it posable?

Post by adafruit_support_bill »

Yes. To the Arduino, the Xbee looks just like a serial port. I don't know of any examples that do exactly what you want. The SerialCallResponseASCII example in the Arduino IDE shows how to make a very simple ASCII serial protocol. You could extend that to read from the log files instead of the sensors.

User avatar
timwjkl
 
Posts: 56
Joined: Wed Jul 03, 2013 2:48 pm

Re: down loading data from a data logger is it posable?

Post by timwjkl »

Thank you I will look into this and see what i can do. :)

User avatar
timwjkl
 
Posts: 56
Joined: Wed Jul 03, 2013 2:48 pm

Re: down loading data from a data logger is it posable?

Post by timwjkl »

Well I have been working on this and so far I can connect arduino to a raspberry pi using the GPIO serial pins and capture the serial stream and input it into a MYSQL database. Then I can output it to a very basic web page with PHP. But what i haven't figured out yet is how to get the arduino to stop what it is doing and read a logged file file back to the serial port. Any help a point in the right direction. Being able to use the rPi may make this just a because that is what i started to do thing but it is that kind of thing. Driving me nuts.

User avatar
adafruit_support_bill
 
Posts: 88093
Joined: Sat Feb 07, 2009 10:11 am

Re: down loading data from a data logger is it posable?

Post by adafruit_support_bill »

But what i haven't figured out yet is how to get the arduino to stop what it is doing and read a logged file file back to the serial port.
Do you want that to be controlled automatically by the Pi, or by some user input?

User avatar
timwjkl
 
Posts: 56
Joined: Wed Jul 03, 2013 2:48 pm

Re: down loading data from a data logger is it posable?

Post by timwjkl »

Some type of user input would be needed for use without the pi permanently attached. That is what i started out looking to do and would still like to for ease of use.

well like a signal from a x bee or some type of if received read log to serial port.

User avatar
adafruit_support_bill
 
Posts: 88093
Joined: Sat Feb 07, 2009 10:11 am

Re: down loading data from a data logger is it posable?

Post by adafruit_support_bill »

Streaming from a file to the serial port is pretty straightforward.

Code: Select all

File file = SD.open("xyz.txt");

{
   while (file.available()) 
   {
      Serial.write(file.read());
   }
   file.close();
} 
Other than that, you need to figure out what kind of signal you will use to trigger that action.

User avatar
timwjkl
 
Posts: 56
Joined: Wed Jul 03, 2013 2:48 pm

Re: down loading data from a data logger is it posable?

Post by timwjkl »

using a xbee can i sent a signal to stop logging and send the file it was writhing and when done resume logging? Can it be anything? like pin 14 high on the arduion side ?

Code: Select all

   if(pin 14 () == HIGH){

 File file = SD.open("xyz.txt");

    {
       while (file.available())
       {
          Serial.write(file.read());
       }
       file.close();}
    }
Sorry haven't really used the xbee yet got sidetracked by the pi.

User avatar
adafruit_support_bill
 
Posts: 88093
Joined: Sat Feb 07, 2009 10:11 am

Re: down loading data from a data logger is it posable?

Post by adafruit_support_bill »

Yes. You could use a signal on any pin to trigger it. XBees can be configured for 'line passing' mode. You would need a button or some other signal on the transmitting XBee and you could connect the corresponding output on the receiving XBee to the Arduino pin.

User avatar
timwjkl
 
Posts: 56
Joined: Wed Jul 03, 2013 2:48 pm

Re: down loading data from a data logger is it posable?

Post by timwjkl »

adafruit_support_bill wrote:Yes. You could use a signal on any pin to trigger it. XBees can be configured for 'line passing' mode. You would need a button or some other signal on the transmitting XBee and you could connect the corresponding output on the receiving XBee to the Arduino pin.

being lazy here but line passing mode ? This is still allowing the serial data to be sent using the same xbees correct. I can activate a pin on the receiving xbee the one on the arduino with a button push on the xbee on the pi to trigger the high state and still be using the xbee to listen correct?

I think line passing may be what i want ot use.

thank you very much

User avatar
adafruit_support_bill
 
Posts: 88093
Joined: Sat Feb 07, 2009 10:11 am

Re: down loading data from a data logger is it posable?

Post by adafruit_support_bill »

Yes. This page describes how it operates: http://www.digi.com/support/kbase/kbase ... tl?id=2188

User avatar
timwjkl
 
Posts: 56
Joined: Wed Jul 03, 2013 2:48 pm

Re: down loading data from a data logger is it posable?

Post by timwjkl »

now usin g the info from my post viewtopic.php?f=50&t=60279 i should be able to use XBees and a (mosfet or npn transistor)? to reset the arduino and a pi to program the above code to read the files correct? but it is easier to use pi and WiFi to start with and cheaper too.?

User avatar
adafruit_support_bill
 
Posts: 88093
Joined: Sat Feb 07, 2009 10:11 am

Re: down loading data from a data logger is it posable?

Post by adafruit_support_bill »

but it is easier to use pi and WiFi to start with
A Pi with WiFi communicating to what? Please post a diagram of the system you are talking about.

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

Return to “XBee products (discontinued)”