up previous next
open a socket connection
OpenSocket(Machine: STRING, Port: STRING): DEVICE |
***** NOT YET IMPLEMENTED *****
This function opens a client socket (I/O) connection.
It requires the name of the machine with the server socket and the
port number (expressed as a STRING).
CoCoA-4 communicates with the CoCoAServer via socket which, by
default, runs on
localhost
on
port
"0xc0c0"
.
To change these settings redefine in your
userinit.coc
or
.cocoarc
the variables
MEMORY.CoCoAServerMachine := "localhost";
MEMORY.CoCoAServerPort := "0xc0c0";
D := OpenSocket("localhost", "10000");
Print 100^6 On D;
Source D;
Close(D);
|