NetIPC 3000/XL Programmer's Reference Manual (5958-8600)
Table Of Contents
- 1 NetIPC Fundamentals
- 2 Cross-System NetIPC
- 3 NetIPC Intrinsics
- 4 NetIPC Examples
- A IPC Interpreter (IPCINT)
- B Cause and Diagnostic Codes
- C ErrorMessages
- D Migration From PTOP to NetIPC and RPM
- E C Program Language Considerations

142 Chapter4
NetIPC Examples
Example 2
vd.d_desc_type1 := DESC_TYPE;
vd.d_desc_type2 := DESC_TYPE;
flags := [ F_VECTORED ];
{ Receive the message in a double vector }
messag1 := ' '; { 46 }
messag2 := ' '; { 46 }
vd.d_desc_len1 := 27; { max we are willing to receive }
vd.d_desc_len2 := 80; { max we are willing to receive }
dlen := DESC_LEN * 2; { 2 vectors }
ipcrecv ( cd_local, vd, dlen, flags, , result );
if result <> 0 then
writeln ('ipcrecv data failed');
if dlen <> 40 then
writeln ('dlen was not = 40');
{ Check that the correct data was received in the first vector }
expect := '40 four oh forty XL 40 four ';
error := false;
for i := 1 to 27 do
if messag1[i] <> expect[i] then
error := true;
if error then
begin
writeln ('did not receive expected first vector data, got:');
writeln ( messag1 );
end;
{ Check that the correct data was received in the second vector }
expect := ' tens fortify';
error := false;
for i := 1 to (dlen - 27) do
if messag2[i] <> expect[i] then
error := true;
if error then
begin
writeln ('did not receive expected second vector data, got:');
writeln ( messag2 );
end;
{ Now send a single vectored message to the local side }
messag1 := '.'; { This means GREETINGS }
vd.d_desc_len1 := 1; { byte size of message }
dlen := DESC_LEN;
ipcsend ( cd_local, vd, dlen, flags, , result );
if result <> 0 then
writeln ('ipcsend failed');
{ do a regular receive of the double vectored send }
messag1 := ' '; { 46 }
dlen := 46; { max amount of data to receive }
ipcrecv ( cd_local, messag1, dlen, , , result );
if result <> 0 then
writeln ('ipcrecv data failed');
if dlen <> 21 then