Hi everyone,i am currently trying to communicate with two computers at the moment using TCP/IP.I have done a simple server and client VI but the server doesnt seem to be writing the string im trying to send and it also gives an error message
Error 1 occurred at TCP Write in Server.vi
LabVIEW: An input parameter is invalid. For example if the input is a path, the path might contain a character not allowed by the OS such as ? or @.
Please find attached the simple server and client VIs i have done.can you help me?
Probably better to start a new thread rather than adding to one that last saw activity more than a decade ago...
The error you're seeing is because, in the server, you wired the "Listener ID out" terminal instead of the "Connection ID out" to the TCP write.
You'll want to put some sort of wait in your VI; a loop with no wait will spin as fast as possible, consuming all available processor time and preventing other code from responding.
Thanks Nathand,it worked .Do you have an email i can reach you at incase i encounter another problem as this is the first and very tiny step to what i will be hoping to do.Thanks again
If you run into problems, post your questions to the forum. You'll get better advice because more people will reply, and other users will benefit from having that information available publicly.
Hi guys,i was able to send a string and receive them at the client side.I have upgraded a little now trying to send a sine pattern but think there is a problem.I dont have any error message per say but i am not getting what i see on the server side on the client side.I will attach the VI so it can be view and hopefully what im doing wrong would be spotted.Thanks guys
There are two problems here:
1) The server sends 128 samples * 8 bytes/sample = 1024 bytes, but the client only reads 8 bytes. This can work, especially if the client runs faster than the server, but it would be better to read all the data at once.
2) The range of the X axis of the chart is not long enough. You're getting the sine wave, you just can't see it. Try setting the X axis to autoscale.