Welcome, Guest. Please login or register.
Did you miss your activation email?
March 22, 2010, 08:12:34 AM

Pages: [1]
  Print  
Author Topic: Trying to log serial data  (Read 347 times)
jfedison741
Newbie
*
Posts: 13


« on: January 25, 2010, 12:54:39 PM »

I am feeding a serial smart board an integer followed by a carriage return (hexidecimal 0D) every 10 seconds and am trying to log this data using the data logging feature of iobridge.com. The data is not showing up in the log. Is there something else that need to be configured?

The serial data is showing up in the module page in the "Serial Data" window but this data is not reaching the log.

Also, how often does the data get logged from the serial smart board? (there appears to be no "Channel Push Update Mode: " or "Auto Message Period (seconds):" for a channel in serail mode)

Thanks.
Logged
iobridge
Administrator
Sr. Member
*****
Posts: 413



WWW
« Reply #1 on: January 25, 2010, 01:48:33 PM »

Are you using the Serial Web Services API?

http://www.iobridge.net/wiki/api/serial-web-services-api

The format should be the following:

Code:
[[[data_log|key|timestamp|data]]]

I would remove the carriage return. The serial message gets added to the data log when the end brackets gets reached "]]]".
Logged

ioBridge Support
Community Team
jfedison741
Newbie
*
Posts: 13


« Reply #2 on: January 25, 2010, 02:17:16 PM »

No, I am using the data logging section of the "Modules" dashboard on iobridge.com. I have added a data log to log "External Input" . How do I get this to log data from the serial board?

When I click "View Data Log" and try to download the log, it is empty.
Also, the "Data Source" appears to be an API Key. Whereas I am trying to make the serial smart board the data source.

Am I correct is in thinking I can log data from the serail smart board? I may not have set it up properly. Any suggestions on how to set it up?

Thanks.
Logged
iobridge
Administrator
Sr. Member
*****
Posts: 413



WWW
« Reply #3 on: January 25, 2010, 03:18:37 PM »

Do you have the ability to manipulate the serial string?

All you have to do is change the serial output so it follows this format:

[[[data_log|key|timestamp|data]]]

Replace "key" with the Data Source API Key for that log

Keep "timestamp" blank to use the current GMT time or specifiy your own time (as long as it follows the YYYY-MM-DD HH:nn:00 format)

Replace "data" with the data that you want to log
« Last Edit: January 25, 2010, 03:20:09 PM by iobridge » Logged

ioBridge Support
Community Team
jfedison741
Newbie
*
Posts: 13


« Reply #4 on: January 25, 2010, 05:43:38 PM »

Yes, after putting the data in the above format it is now logging.

Thanks ioBridge for an excellent product!!
Logged
jfedison741
Newbie
*
Posts: 13


« Reply #5 on: January 26, 2010, 10:32:10 AM »

I am using "[[[data_log|key||data]]]" to log data.

With the timestamp field left blank, is there a way to make the API generate the time including real seconds (instead of hh:mm:00)? My data is at approx. 60 (+/- 2%) second intervals and the logged time stamp occasionally skips or repeats a minute.

Thanks.
Logged
iobridge
Administrator
Sr. Member
*****
Posts: 413



WWW
« Reply #6 on: January 26, 2010, 09:52:55 PM »

Unfortunately the service's logging resolution is once a minute.
Logged

ioBridge Support
Community Team
nick
Full Member
***
Posts: 138


« Reply #7 on: January 27, 2010, 12:35:23 AM »

You could get the current time using the web services API DATETIME command at the start of your program, and then keep track of the time on your device and populate the log yourself.
Logged
jfedison741
Newbie
*
Posts: 13


« Reply #8 on: January 29, 2010, 05:57:46 PM »

Thanks, that sounds like a good way of getting higher time resolution.

The serail-API wiki notes indicate that the [[[datetime]]] transaction replys with the following format:
yyyy-mm-dd hh:nn:ss (GMT/UTC)

Does anyone know if this reply is enclosed in brackets and would the length of the reply (29 characters in the above example) ever change? I assume that the reply will always be in GMT/UTC time. I am trying to determine the best way for the microcontroller to determine where the end of the reply string is.

Thanks.
Logged
iobridge
Administrator
Sr. Member
*****
Posts: 413



WWW
« Reply #9 on: January 29, 2010, 06:10:33 PM »

A valid response is always 29 characters.
Logged

ioBridge Support
Community Team
Pages: [1]
  Print  
 
Jump to:  



 
Powered by SMF 1.1.11 | SMF © 2006-2009, Simple Machines LLC
| © ioBridge Corporation | RSS Feed