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

162 Chapter4
NetIPC Examples
Example 4
if result16 <> 0 then
writeln('addopt IPCRECVCN x25 flags failed', result16);
(* set deferred flags for receive connection : bit 18 *)
flag[1] := 0; (* flags : 00000000000000000100000000000000 *)
flag[2] := 0;
flag[3] := 32;
flag[4] := 0; (* deferred *)
writeln;
writeln('***** IPCRECVCN deferred');
ipcrecvcn ( sd_local, cd_local, flag, opt, result );
if result <> 0 then
writeln ('ipcrecvcn failed', result);
(* check receive CUD *)
optlen := CUD_MAX;
readopt(opt,0,optioncode,optlen,cud,result16);
if result16 <> 0 then
writeln('readdata failed (cud) ',result16:1);
if optlen <> CUD_MAX then
writeln('CUD length error : (length = ',optlen:1, ' )');
i := 1;
while i <= optlen do
begin
if cud[i] <> i then
writeln('CUD error : #',i:1,' ',cud[i]);
i := i + 1;
end;
(* check facilities *)
optlen := 109;
readopt(opt,1,optioncode,optlen, sf,result16);
if result16 <> 0 then
writeln('readdata failed (special facility) ',result16:1);
writeln('facilities received in Incoming call packet (length =
',optlen:1,')');
for i := 1 to optlen do
write (sf[i]:1,' ');
writeln;
(* check calling node address *)
optlen := 8;
readopt(opt,2,optioncode,optlen, cnaddr,result16);
if result16 <> 0 then
writeln('readdata failed (calling node address) ',result16:1);
writeln('Calling Node Address (length = ',optlen:1,')');
for i := 1 to optlen do
begin
write ((cnaddr[i] div 16):1);
write ((cnaddr[i] mod 16):1);
end;