From: CRDGW2::CRDGW2::MRGATE::"SMTP::CRVAX.SRI.COM::RELAY-INFO-VAX" 28-MAY-1991 08:54:22.65 To: ARISIA::EVERHART CC: Subj: RE: Does anyone know the NICE protocol? From: RELAY-INFO-VAX@CRVAX.SRI.COM@SMTP@CRDGW2 To: Everhart@Arisia@MRGATE Received: by crdgw1.ge.com (5.57/GE 1.97) id AA17064; Tue, 28 May 91 07:47:23 EDT Message-Id: <9105281147.AA17064@crdgw1.ge.com> Received: From SUN2.NSFNET-RELAY.AC.UK by CRVAX.SRI.COM with TCP; Tue, 28 MAY 91 04:38:21 PDT Received: from ncdlab.ulcc.ac.uk by sun2.nsfnet-relay.ac.uk via JANET with NIFTP id <8412-0@sun2.nsfnet-relay.ac.uk>; Tue, 28 May 1991 12:14:26 +0100 Date: Tue, 28 May 91 12:16 BST From: Nick de Smith To: INFO-VAX <@nsfnet-relay.ac.uk:INFO-VAX@CRVAX.SRI.com> Subject: RE: Does anyone know the NICE protocol? Hi, > Subj: Does anyone know the NICE protocol? > I bought the functional description of the NICE protocol, only to find > that it has not been updated since 1983! Consequently, what I really wanted > was not in it, which is to be able to interrogate the LINK database from a > program. Its not in that manual. You really need the NICE V2.2 definition (I determined it from the 'fiche). The LINK stuff is under "system specific implementation". Sigh. The CD listings make life a *lot* simpler for this sort of tracking. Also the interface to NMLSHR is not documented, and if you are serious about this, you have to use NMLSHR. You need to use: status = NML$INITIALIZE(); /* Set up our interface to NML */ if ( (status & STS$M_SUCCESS) == 0 ) { return status; } NML$PROCESS_NICE( /* Start processing the NICE command */ &x_nml_command , /* NML command */ CALLBACK_ROUTINE); /* NMLSHR callback routine */ status = NML$TERMINATE(); /* Finish with NML */ if ( (status & STS$M_SUCCESS) == 0 ) { return status; } where x_nml_command is a VMS descriptor describing the NICE command to use, and where CALLBACK_ROUTINE() is an action routine provided by you which is called by NMLSHR with one parameter, the address of a VMS descriptor that contains either a partial or complete response. It is beyond the scope of this mail message to fully describe this interface, but see below about the availability of examples. > I have the dec example programs which talk NICE to NML and they work fine, > but I dont know the parameters for looking at logical link numbers. > > Does anyone have any experience in this area? Might have... You have to use function code NMA$C_FNC_SYS, system type NMA$C_SYS_VMS, operation code NMA$C_FNC_REA (Read) and entity ident NMA$C_SENT_LNK (link number). The sent entity is then set to the link number. If you want to do a wildcard link lookup, .OR. in 0xFF00 with the entity identification. If you want the characteristics returned, .OR. in 0x0020 with the entity identification (eg. NMA$C_SENT_LNK | 0xFF00). Decoding the response from NMLSHR is tricky. The manual you have is still valid for the general case. Although the response message contains explicit formatting information, its "general case" only. NCP makes use of knowledge of the command that was originally sent to provide more detailed formatting, such as splitting a 16 bit integer into a DECnet "area.node" number where required. Try assigning the logical name NML$LOG to "1" when debugging NICE protocols. It is extremely useful to compare what your program thinks its getting and what NMLSHR is doing. Also you can compare what NCP sends/receives with your program. > I _know_ that it will be obsolete when Phase V comes, but this application > cannot wait. _Please_ don't tell me about that. What I need is advice from > a serious source listing guru! No one has ever accused me of being serious 8-). Rabid, yes, serious, no. I have example programs written in C that communicate with NMLSHR to process NICE messages and their reponses. Specific examples include the equivalent of NCP SHOW KNOWN LINKS, SHO LINK nnnn and SHOW LINK nnnn CHARACTERISTICS. Let me know if you need a copy. > Thanks whatever, I have never been called a whatever before! How many insults can a message contain ;-) regards, nick NICK@NCDLAB.ULCC.AC.UK