tags:

views:

55

answers:

2

I Using rabbit single board computer. I would like to save the data I/O which connected to another rabbit single board computer through wireless connection. Is it able to save the data inside the pc such as .txt file? Thanks.

A: 

If you can establish a connection to a PC, and the PC is running some server to log data, yes, you could save to a PC. For example, the PC could run a TFTP server or FTP server on the same wireless network, and you could connect to it from the rabbit SBC and save whatever data you need to.

bdonlan
I using GPIO server for the wireless connection but not FTP server. The data can show in the STDIO in dynamic C, just don't know how to save the data inside my PC. is it possible ?
Austin
STDIO can't easily be saved - in production (ie, when you load to flash) it gets stubbed out. Other serial ports are much easier to get data off of.
bdonlan
So i need to find another way than use STDIO. Thanx lot.
Austin
A: 

Yes, this is possible.

There are two parts to this scenario. Your embedded app needs to know how to connect to a server application running on the PC or network, and you must, of course, have said server application running on the target machine.

If you're sending entire files, FTP, as bdonlan suggested, is a good way to go. The protocol is well-understood and you can probably find a library to wrap it for you.

If you need to log data real-time, you'll need to have some sort of application which can receive messages or accept a socket connection, and a protocol to get the text across the wire(less). A web server may be a good way to do this, because you can POST chunks of data to the server with a simple HTTP request, and the server app can decide how to organize and store the information. Once you have a web server running, you may find it beneficial to build some pages that provide basic reporting functionality, so you can see the logged data from any web browser.

This could be less restrictive than FTP, but will require some web development expertise on your part.

Any reasonable solution is going to require that you already have a connection to the wireless network with a correctly-configured and functioning IP stack. Without that, you're probably out of luck connecting to any networked resources.

David Lively
the best way is using the FTP to save the data. Because until now i only used the GPIO server to do my connection rather then FTP. so now is the time to change the connection to FTP. Thanx David. As bdonlan said, using STDIO is very hard to save the data into the pc. I also try to find all the library in the Dynamic C, the file only can save into FAT such as memory card which is built in SBC. Thanx again.
Austin