Click here to Skip to main content
15,887,214 members
Please Sign up or sign in to vote.
1.00/5 (2 votes)
See more:
I have an application in which I have to plot one sine wave with respect to some data came from an hardware in real time.I am using VC++ MFC Dialog based application.Please help me.
Thanks in advance
Posted
Comments
[no name] 19-Jun-13 10:35am    
And what have you tried and what is the specific problem that you need help with?
debarunb 19-Jun-13 10:47am    
Data are come from serial and read that data and plot a 2D sin wave
Richard MacCutchan 19-Jun-13 13:29pm    
Start with the first point, then go through all points in turn and draw lines between them. There are lots of samples of simple drawing programs to be found on the internet.
debarunb 20-Jun-13 1:05am    
Sir Please give me some example in VC++,actually
1.In my application data came from hardware like USB or Serial Interface and then I have to read that real time data and plot that data in a sine wave/or any format and show it on dialog.
2.Which control I have to use to display the 2D plot of that data?
Please give me some code example so I can proceed further

1 solution

You're using pretty out dated technology, C# is easier to use.

There's any number of graphing libraries. However, nowadays, people tend to write stuff in C#, you'd be looking for something pretty old, I reckon. You're basically asking us to do the work for you, though. You should be able to do this, you need to learn how to draw on your form ( which happens in your paint event ), and then you need to write the code to draw your graph, it's that simple.
 
Share this answer
 
Comments
debarunb 20-Jun-13 1:05am    
Sir Please give me some example in VC++,actually
1.In my application data came from hardware like USB or Serial Interface and then I have to read that real time data and plot that data in a sine wave/or any format and show it on dialog.
2.Which control I have to use to display the 2D plot of that data?
Please give me some code example so I can proceed further
Christian Graus 20-Jun-13 1:06am    
You're not proceeding at all if you can only work by copying and pasting our code. There is no control built in. You will have to write one. I gave you pointers on how.
debarunb 20-Jun-13 2:37am    
Sir please give me some link that I can read and implement in my application,Actually I am new to this concept..
Thanks in advance

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900