CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to CCS Technical Support

Displaying data from serial port in excel.

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
MiniMe



Joined: 17 Nov 2009
Posts: 50

View user's profile Send private message

Displaying data from serial port in excel.
PostPosted: Sun Aug 14, 2011 11:21 am     Reply with quote

Hi!

I'm sorry if the topic name sounds like placement in wrong kind of forum.

The feature i love about CCS compiler is very dynamic and efficient way to output data using well known "printf" -s. Outputting data using UART module to PC-s serial port. I'm not sure if I'm using correct terms but i thought that my problem... it could be useful thing to know and that happens to be the thing i need.

The problem:
How i can create connection between serial port (COM port) and MS Excel. Is there a easy way to do it. To display data in real-time for analysis and better understanding purposes.


Thank you in advance!
arunb



Joined: 08 Sep 2003
Posts: 492
Location: India

View user's profile Send private message Send e-mail

RE:
PostPosted: Sun Aug 14, 2011 10:09 pm     Reply with quote

Quote:
How i can create connection between serial port (COM port) and MS Excel. Is there a easy way to do it. To display data in real-time for analysis and better understanding purposes.


You can do this using VBA (Visual Basic for Applications) quite easily.

Make a VB application that interfaces to the hardware, use the MSCOMM serial port control for this. Establish communication with your hardware, acquire real-time data from the device. Use DDE technique to establish communication with MS Excel.

The MSDN help pages contain excellent tutorials and example codes that demonstrate DDE and MSCOMM control usage.

I made a similar project in Microsoft Visual Basic 6.0 using the above mentioned techniques.

A VB 6.0 application communicated with the hardware device (an ADC card, that consisted of a 16F628 PIC and a MCP 3208 ADC) using the serial port of the computer. The same application interfaced with Excel using DDE.

The system was designed to run on Windows XP/2000, and worked very well, I could plot the acquired in real-time on an Excel chart just like an oscilloscope.

I am not sure if DDE is supported in Windows 7 or Vista you have to check this out.

thanks
a
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group