-
I'm trying to set up an experiment where I need to send a command to an external mass balance, (output) and collect the value the scale reads (input). I need to send the characters "?1" out commport 2 and then place the numbers that come back into an array for analysis. I only have VB 6.0 working model, and it doesn't seem to have the communications control. Can anyone give me an example of how to set this up? Here's a chunk of what I've got so far:
How do I set up the variables? (MSComm1, etc.)
'Set up communication with balance
MSComm1.CommPort = 2
MSComm1.Settings = "2400,N,8,1"
MSComm1.PortOpen = True
'Set up start and end times
StartTime = Timer
EndTime = StartTime + (SampleTime * 60)
'Run timer loop until sampling time is reached
Do While CurrentTime < EndTime
i = i + 1
'Take a mass measurement:
MSComm1.Output = "?1"
MassData(i) = MSComm1.Input
-
-
Serial Communication
Hi
Have you added the MSComm control to your form?????
If you have, then you need to look at the properties of the MSComm control.
There you can find the MSComm1!!!
Good Luck
If you know someone who can help me with my problem, I need to communicate with a DSP evaluation board
-
Viperke,
I can help, tell me where are you stuck or what you need to be done.
-
The MSComm control is working now :)
-
Communication with DSP
Hi, Sacred_knight
First I'm sorry for my english, it isn't that good.
OK
For my thesis I need to display a weather image on my PC screen.
Data comming from the receiver goes to an evaluation board with a DSP on board(TMS320C5X)(Texas Instuments).
Now I need to be able to download the *.dsk file to the evaluation board. After that I need to run the software on the DSP, so he can transfer the data to the serial poort. This data I need to display on my screen.
My problem is the communication with the DSP evaluation board. I can't find enough information.
Now, I can open and close the port, drop DTR low and after that High (for resetting the DSP). Now I need to send a start bit to the DSP. Here starts my problem. The DSP need to answer with a ESC (27) character. The DSP answers me, but no the right way. He sends me strange characters!!!!
I also can't find information about downloading the *.dsk file to the evaluation bord.
I hope you can help me, because at this moment no one can hepl me. If you need my source code, or other information, please ask!!!!
TNX
Viperke