LPT1 and USB communication in C++

Hello, I really need your help...
I am working on a project...
It consists of doing a laser (taken off from a CD-Reader) scan of the surface of a coin : the laser beam emmited from a laser diode is reflected on the surface of the coin. The power of the beam reflected and catched in the photodiodes is a function of the distance between the laser diode and a point of the coin.

I am using a Roland DXY-1200 (HPGL Language) connected to an LPT1 port to move the coin precisely under the laser beam.
So I'm generating (x,y)=(x+0.025,y+0.025) couples and want to send them to the plotter via LPT1.
For each (x,y) I have an analog value from the photodiodes (V) that I transform to digital values (Binary) using a National instruments USB-6008 ADC.

After transforming tese values into decimal ones, I want to build a matrix of all these decimals.
Then I want to plot this matrix using a matlab function (imagesc) : plot the coin surface on the sceen.

- How can I write commands (such as IN;PU;PAx,y...) on LPT1 ? ( I have the driver of the plotter)
- How can I read binary from USB port ? and put each value I read in the matrix ?
- How can I use a matlab function in C++ ?

Thanks a lot for your help.
P.S. If you have any question concerning the project don't hesitate to ask me :)

Topic archived. No new replies allowed.