PAM Programming Manual
Link-Level Programming Examples
PAM Programming Manual—142482
B-2
Data Declarations
Data Declarations
The coding example assumes the presence of the following data declarations:
--/---------------------------------------------------------------/
-- L2 Service Access Point Exercise Program: Declarations
--/---------------------------------------------------------------/
-- L2SAP File Information
--/---------------------------------------------------------------/
INT .INT^L2SAP^file^name^ptr [0:11] := [ 12 * [” “] ];
STRING .L2SAP^file^name^ptr :=
@INT^L2SAP^file^name^ptr ’<<’ 1;
INT L2SAP^file^num;
--/---------------------------------------------------------------/
-- Aggregate SDU Buffer
--/---------------------------------------------------------------/
STRUCT .EXT buffer^lst^ptr ( Buffer^Lst^Entry^Template )
[0: (Max^NoWait^Depth - 1 )];
--/---------------------------------------------------------------/
-- Startup Message Parameters
--/---------------------------------------------------------------/
INT Port^type;
INT command^code;
INT P^F^flag;
INT rsp^flag;
INT loop^cnt;
INT SDU^cnt;
INT begin^user^data^size^b;
INT current^user^data^size^b;
INT end^user^data^size^b;
INT NoWait^depth;
STRING .Foreign^Addr^ptr [0: ( ZLAM^Val^MAC^Addr^Size - 1 )];
--/---------------------------------------------------------------/
-- Report File Information
--/---------------------------------------------------------------/
INT .INT^report^file^name^ptr [0:11];
STRING .report^file^name^ptr :=
@INT^report^file^name^ptr ’<<’ 1;
INT report^file^num;
INT .INT^report^buf^ptr [0:39];
STRING .report^buf^ptr := @INT^report^buf^ptr ’<<’ 1;
--/---------------------------------------------------------------/
-- Instrumentation
--/---------------------------------------------------------------/
INT(32) delta^time;
INT start^time [0:2];
INT end^time [0:2];
INT total^time [0:2];
INT date^time [0:6];
STRING test^char;