Hi everyone!
I'm trying to make an simulation using 3D Rad and, in order to do that, I need to get some data from the COMx Port (I have a device connected to that port from which I want to collect the messages sent). From what I searched, I couldn't find a direct method for 3D Rad to connect to the COM port. So, I wrote a DLL in c++ that opens the port, waits for a message, splits the message into an array of floats, closes the COM port and transmits the float array back to 3D Rad. All good, in theory (at least this is how I imagined it ), but it doesn't work. The DLL is recognised, the method is called, but no result is returned. I tested the method in a console app and it works. What could be the problem? Does 3D Rad has a timeout when calling a DLL method? If this is the case, what is it? Or, can anyone give me another solution to read messages from a COM port..?
Thanks in advance for your answers
I'm trying to make an simulation using 3D Rad and, in order to do that, I need to get some data from the COMx Port (I have a device connected to that port from which I want to collect the messages sent). From what I searched, I couldn't find a direct method for 3D Rad to connect to the COM port. So, I wrote a DLL in c++ that opens the port, waits for a message, splits the message into an array of floats, closes the COM port and transmits the float array back to 3D Rad. All good, in theory (at least this is how I imagined it ), but it doesn't work. The DLL is recognised, the method is called, but no result is returned. I tested the method in a console app and it works. What could be the problem? Does 3D Rad has a timeout when calling a DLL method? If this is the case, what is it? Or, can anyone give me another solution to read messages from a COM port..?
Thanks in advance for your answers