Anyone can help??

Please support our C++ advertiser: Intel Parallel Studio Home
Reply

Join Date: Mar 2006
Posts: 4
Reputation: francis adepoju is an unknown quantity at this point 
Solved Threads: 0
francis adepoju francis adepoju is offline Offline
Newbie Poster

Anyone can help??

 
0
  #1
Mar 22nd, 2006
I'm not a C++ programmer in the real sense of it, but my project involves gathering some data, store the data in memory with time stamp and later upload to the PC where a C++ algorithm will be used to manipulate it and then produce a graph of the manipulated data.
I can gather the data using assembly language and store to memory, well in ASCII (HEX).
(1) I do not know how to start/initiate my data upload to the PC
(2) I do not know how to manage the HEX data once it gets to the PC.
(3) Do I need to convert data to Decimal before I can run algorithms on it?
I'm really stuck here.. Based on my requirements? can anybody make a suggestion that I can consider for my implementation please?
Is there any Textbook that I might find useful?
Reply With Quote Quick reply to this message  
Join Date: Sep 2004
Posts: 7,698
Reputation: Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute 
Solved Threads: 729
Team Colleague
Narue's Avatar
Narue Narue is offline Offline
Code Goddess

Re: Anyone can help??

 
0
  #2
Mar 22nd, 2006
>1) I do not know how to start/initiate my data upload to the PC
First you need to have a clear idea of what 'upload' means to you. Are you gathering the data on another system and transferring it through a network to the PC? Are you reading from a file, from a process, from a socket? Upload to what? A file? A memory map? A pipe?

>(2) I do not know how to manage the HEX data once it gets to the PC.
If it's in text format then depending on the needs of the C++ program, you need to convert as necessary.

>(3) Do I need to convert data to Decimal before I can run algorithms on it?
If the data is in text format as you said, you need to convert it to binary so that it can be treated as numeric values rather than character values. Once in binary format, decimal and hexadecimal are nothing more than representation differences, and internally are identical.
I'm here to prove you wrong.
Reply With Quote Quick reply to this message  
Join Date: Mar 2006
Posts: 233
Reputation: Lord Soth is an unknown quantity at this point 
Solved Threads: 4
Lord Soth's Avatar
Lord Soth Lord Soth is offline Offline
Posting Whiz in Training

Re: Anyone can help??

 
0
  #3
Mar 22nd, 2006
Hi,

If you need to upload the data later to the PC where algorithm resides then where were it in the first placee ? Anther computer, or a data acquisition device ? What is the type of connection between the hardware the data comes from and the PC ? In which format the HEX coded data is ? And, yes you need to convert the data from ASCII based HEX presentation to an integer type.

Loren Soth
Reply With Quote Quick reply to this message  
Join Date: Mar 2006
Posts: 4
Reputation: francis adepoju is an unknown quantity at this point 
Solved Threads: 0
francis adepoju francis adepoju is offline Offline
Newbie Poster

Re: Anyone can help??

 
0
  #4
Mar 22nd, 2006
[QUOTE=Narue]>1) I do not know how to start/initiate my data upload to the PC
First you need to have a clear idea of what 'upload' means to you. Are you gathering the data on another system and transferring it through a network to the PC? Are you reading from a file, from a process, from a socket? Upload to what? A file? A memory map? A pipe?
>(2) I do not know how to manage the HEX data once it gets to the PC.
If it's in text format then depending on the needs of the C++ program, you need to convert as necessary.
So I might have to convert to binary. Have any way of doing it in C++?

MORE..
The way it is at the moment, I hope to store the HEX output from the ADC in RAM or a data logger(if I can find any appropriate one), then at the end of data capture, transmit (upload) to a PC (file) via UART.
It is at this stage that I want to write a C++ algorithm to sort, compare, manipulate, etc before doing a graph..
Reply With Quote Quick reply to this message  
Join Date: Mar 2006
Posts: 4
Reputation: francis adepoju is an unknown quantity at this point 
Solved Threads: 0
francis adepoju francis adepoju is offline Offline
Newbie Poster

Re: Anyone can help??

 
0
  #5
Mar 23rd, 2006
Originally Posted by Narue
>1) I do not know how to start/initiate my data upload to the PC
First you need to have a clear idea of what 'upload' means to you. Are you gathering the data on another system and transferring it through a network to the PC? Are you reading from a file, from a process, from a socket? Upload to what? A file? A memory map? A pipe?

>(2) I do not know how to manage the HEX data once it gets to the PC.
If it's in text format then depending on the needs of the C++ program, you need to convert as necessary.

>(3) Do I need to convert data to Decimal before I can run algorithms on it?
If the data is in text format as you said, you need to convert it to binary so that it can be treated as numeric values rather than character values. Once in binary format, decimal and hexadecimal are nothing more than representation differences, and internally are identical.
Thanks for your earlier comments. Answers to some of your queries are as follows:
The way my design is at the moment, my inputs are mVolts data going into the ADC at a regular interval. I hope to store the HEX outputs from the ADC into RAM or a data logger (if I can find any appropriate one), then at the end of data capture, transmit (upload) the data to a PC (file system) via UART.
At the end of this stage, I’ll want to write a C++ algorithm to sort, compare, manipulate, etc before doing a graph of the original data.
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:



Other Threads in the C++ Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC