Using Sockets to sync two scripts

I have two Eggplant license installed on a Linux machine, I run two suite’s that vnc to two other Linux machines and execute a separate script on each. I have these two scripts communicate with each other via a file, I would like them to communicate via a socket. Since both scripts are controlled from one Linux machine when I do a hostAddresses they both return with the main machine address not the address of the machine tah I connected to. Question - how do you communicate on a socket on the local machine, like use IN_ADDDR_ANY with a port. I tried open socket “0.0.0.0:5900” and localHoast to no avail .

The local machine should always be accessible at IP 127.0.0.1.

here are my two scripts, the read does not block even for a second and never returns any data

readSocket

put “127.0.0.1:5990” into readme

open socket readme

repeat forever
read from socket readme into data
log "Data Rx = " && data
wait 1
end repeat

writeSocket

put “127.0.0.1:5990” into writeme

open socket writeme

repeat forever
write “hello” to socket writeme
wait 1
end repeat