06-05-2012 11:01 AM
I can try this out to know the answer, but until I I have access to the system, I thought I could post the question.
Can I use a loop back conector to Send and Receive info within the same computer? Thereby, eliminating the need for me to use two COM ports and have a serial cable in between?
Currently, I have a software sending data (say COM 1) and LabVIEW exe receiving data (say COM 2), Can I just use COM 1, use a loop back connector and have both the software and LabVIEW exe use COM 1? Will LV flag resource COM1 as being used by another application if I do so?
Thanks!
V
06-05-2012 11:04 AM
YES. Short pins 2 & 3 together. I do it all the time to test the com port.
06-05-2012 11:06 AM
My gut says no and the OS should prevent two processes from trying to acquire control of the same resource.
PortMon is capable of reaching into the transmit/recieve buffers so if you want to reseach how PortMon does it, you may figure out a way.
Sorry but that is all I can offer off hand.
Ben
06-05-2012 11:12 AM
Thank you for both replies. I actually do not want to test the port. I want to actually use it for communication between two softwares.
@BEn, I thought so too, because even in my original configuration, when the software was using (say COM 1) and I have accidently setup LabVIEW exe to use COM 1, LabVIEW threw out a nast error 🙂
06-06-2012 11:59 AM - last edited on 12-02-2024 05:56 PM by Content Cleaner
Here is a KB that you may want to check out:
https://knowledge.ni.com/KnowledgeArticleDetails?id=kA03q000000YHn8CAG&l=en-US
06-06-2012 12:04 PM - last edited on 12-02-2024 05:57 PM by Content Cleaner
@PedroMunoz wrote:
Here is a KB that you may want to check out:
https://knowledge.ni.com/KnowledgeArticleDetails?id=kA03q000000YHn8CAG&l=en-US
Sorry Pedro but this thread is not about "How to Do a Loopback Test" but rather how to share the serial port data between two simultaneously running applications.
Now if you can find a white paper explaining how to tap into the transmit and recieve buffers (like what is done with PortMon) of a thrird party application, that would be helpful.
Ben
06-06-2012 12:15 PM
I wonder how PortMon is able to tap into the send buffer and display the data. That is exactly what I need to know and this would save us in hardware costs.
06-06-2012 12:26 PM - last edited on 12-02-2024 05:57 PM by Content Cleaner
@VeeJay wrote:
I wonder how PortMon is able to tap into the send buffer and display the data. That is exactly what I need to know and this would save us in hardware costs.
An easy method to get at those buffers would have helped in this application as well.
In that app I had to intercet the GPS feed to some third party mapping and navigation software (The Cap'n) to do my math while letting the Cap'n do its thing.
And before you start thinking "That looks like a fun project!" it was the low man on the totem pole that had to go out and run that software because you would get the "He3L beat out of you" while the craft wen through it manuvers.
Ben
06-06-2012 03:16 PM - edited 06-06-2012 03:20 PM
Well @ Ben, I am still gonna say, sounds like a fun project! And a perfect solution as well 🙂
I do the same thing. I have this commercial ECG software from GE which I use to communicate( through RS232 Serial port) to my LabVIEW application to control my device (an MR compatible Treadmill). I had to make sure that I had 2 read and 2write lines each for the software and LV application to communicate back and forth.