Possibilities of MOD5270LC Kit?

Discussion to talk about software related topics only.
Post Reply
mezz64
Posts: 9
Joined: Mon Feb 02, 2009 8:50 am

Possibilities of MOD5270LC Kit?

Post by mezz64 »

Hello,
I am about to begin a data logging project where I would like to use the MOD5270LC kit to provide ethernet connectivity. I believe the MOD5270LC is suited to my needs but I have a few "is this possible?" style questions.

I'd like to be able to display the serial data from my logging micro controller in real-time via the netburner webserver. The netburner and logging micro would communicate via serial. If I understood the examples correctly I have a few options on getting this to work, such as Java, Flex, Flash, Ajax, or similar correct?

Second, and the more pressing question, is it possible to collect a set of data from the logging micro and then on the netburner convert this data into a text file that could be downloaded by the user? I realize this is probably a function of the particular coding language I would use, but I was just wondering if there were any examples out there.


Thanks!
- John
User avatar
lgitlitz
Posts: 331
Joined: Wed Apr 23, 2008 11:43 am
Location: San Diego, CA
Contact:

Re: Possibilities of MOD5270LC Kit?

Post by lgitlitz »

You are correct about the first question. Any web application that can maintain an open TCP connection should be able to display this data in real time. Here is an example that has a text terminal in FLEX: http://forum.embeddedethernet.com/viewt ... ?f=5&t=104

The second part of your data logger should probably use the file system. You need to come up with a method to properly convert your binary data to ascii. Then write your data to a file and use the EFFS FTP server. Look at the example: C:\Nburn\examples\EFFS\EFFS-HTTP

-Larry
seulater
Posts: 445
Joined: Fri Apr 25, 2008 5:26 am

Re: Possibilities of MOD5270LC Kit?

Post by seulater »

Yes you can do what you want. For the first part of your question i am sending live data to the clients web browser using FLEX with an open TCP connection back to the MOD5234.
The MOD5234 pushes up the live data via this TCP connection to the flex app on the clients computer to display it.

For the second part, this same project has an MP3 recorder IC & a +/- 1 sec RTC on board. Whenever audio is detected it starts recording the audio via .MP3 format. when audio has stopped it takes all the digital samples and creates a new file on the SD card with the time stamp as the files name and saves this data to the card. I have FTP running on the board so that a customer can open his FTP client and download the .mp3 files if they choose.

So the bottom line is yes, you can do what you want.
thomastaranowski
Posts: 82
Joined: Sun May 11, 2008 2:17 pm
Location: Los Angeles, CA
Contact:

Re: Possibilities of MOD5270LC Kit?

Post by thomastaranowski »

I have an app that uses the Ajax method to send low priority 1-second updates to the web browser. Works fine even with multiple users connected on a loaded system.

I store some event logs to an SDCard, then allow the user to either ftp the file down, or view it directly with a web browser. Alternatively, one can click on typical form save button that POSTs to the webserver. This was kinda tricky to get the web browser to show the proper save/open dialog. Sending the following header back was critical in getting it to work like I wanted. The rest of the code just dynamically generates the content that gets sent back

Code: Select all

//Send back the event log as an attachment
writestring( sock, "HTTP/1.1 200 OK\r\nContent-disposition: attachment; filename=\"eventlog.txt\"\r\nContent-Type: application/octet-stream\r\nLocation: eventlog.txt\r\n\r\n" );

//Send the log
sdcardGetHandler(sock, "/EVENTLOG.TXT", rxBuffer);
//Send the parameter configuration
writestring(sock, "\r\n\r\n");
writestring(sock, "System Parameter Configuration\r\n");
writestring(sock, "=============================\r\n");
showParamStorage(sock);
mezz64
Posts: 9
Joined: Mon Feb 02, 2009 8:50 am

Re: Possibilities of MOD5270LC Kit?

Post by mezz64 »

Thanks for the replies guys. My development kit is on the way and I've started playing with using TCP connections in flex since it seems like the best option for my needs.

Can anyone provide some example code for utilizing the EFFS, or is there some provided in the examples that ship with the dev kit?

Thanks!
seulater
Posts: 445
Joined: Fri Apr 25, 2008 5:26 am

Re: Possibilities of MOD5270LC Kit?

Post by seulater »

Yes, there are examples.
Post Reply