<<< DISK$DATA:[NOTES$LIBRARY]VAX_VMS.NOTE;1 >>> -< SIG VAX/VMS >- ================================================================================ Note 1445.0 How to filter OPCOM messages 7 replies DECUSF::BROWN_N "Nick BROWN, Conseil de l'Europe" 9 lines 20-AUG-1991 16:24 -------------------------------------------------------------------------------- This is probably an easy one... I want to write a sink for OPCOM messages, to run in parallel with OPCOM, which will allow me to read, filter, select, and pass on selected operator messages to other applications (eg, to broadcast them to a PC running PCSA RCV). Is the best way to do this to use the V5.4 virtual terminal and define a virtual operator terminal (my knowledge of the virtual terminal is limited to the fact that it apparently exists), or is there a better way ? ================================================================================ Note 1445.1 How to filter OPCOM messages 1 of 7 DECUSF::OURGHANLIA_B "Eppur si muove..." 1 line 21-AUG-1991 07:12 -< GOTO VMS: >- -------------------------------------------------------------------------------- Take a look to VMS:OPCOM_CATCHER.TXT and ... enjoy ! ================================================================================ Note 1445.2 How to filter OPCOM messages 2 of 7 DECUSF::COLAS_Y 7 lines 21-AUG-1991 10:09 -< Voir telebase ;-) >- -------------------------------------------------------------------------------- Vous avez aussi dans la telebase un article en Fortran intitulé : Example-FORTRAN How To Intercept OPCOM Messages SOURCE: Customer Support Center/Colorado Springs USA Yann COLAS ================================================================================ Note 1445.3 How to filter OPCOM messages 3 of 7 DECUSF::BROWN_N "Nick BROWN, Conseil de l'Europe" 22 lines 21-AUG-1991 17:40 -< Thanks >- -------------------------------------------------------------------------------- I copied OPCOM_CATCHER.TXT, but it has a few problems: - it won't compile (on my version of C (3.2)), OPCDEF.H has got screwed up, and opc$t_ms_oname is not an array. A bit of casting fixed this, but since all the $SNDOPR data structures are incapable of representation in a general way in almost any high-level language, I hacked together my own structure, which allows the whole thing to be initialised at compile time. - POKE_PCB has a bug, whereby the device name may overflow its buffer. The buffer size is 8, including the size byte, so "LTA4444:" will overflow into the next PCB field (PCB$L_PQB). Apparently this does not matter (it didn't crash my system), but it is rather dubious... some utilities show the terminal name as LTA4444¿: (¿ is the VT200 "backward query" (unknown) character). The macro code needs to check for the maximum size (the : is not needed in the PCB anyway). Anyway, to enhance my understanding of the program, I modified it extensively; the result is in VMS:OPCOM_CATCHER2.TXT, in the same format as the original. Thanks for the replies; I now have all I need. ================================================================================ Note 1445.4 How to filter OPCOM messages 4 of 7 DECUSF::OURGHANLIA_B "Eppur si muove..." 9 lines 21-AUG-1991 18:33 -< Sorry... >- -------------------------------------------------------------------------------- Do you need a non screwed up OPCDEF.H ? I apologize for this bug, which I didn't catch it because I tested the program on a non standard VMS version (V5.999999....) on which the PCB field lengths are not the same... By the way, there is no risk to crash the system but you will also screw up the JIB$T_USERNAME (as an other side effect) which means the accounting information will be wrong... Sorry about that... ================================================================================ Note 1445.5 How to filter OPCOM messages 5 of 7 DECUSF::BROWN_N "Nick BROWN, Conseil de l'Europe" 14 lines 22-AUG-1991 09:12 -< OK, thanks >- -------------------------------------------------------------------------------- I removed the code which tries to suppress the username in the JIB, as this also had a bug (and I don't mind it showing up in the accounting): the code moves 11 spaces to the username field starting at byte 1, but this field is not (length+data), it's fixed-length, so it should move 12 bytes starting at byte 0. I imagine you can probably fix this yourself... I think OPCDEF has become screwed up with a version of C; probably this should be SPR'ed (hint, hint). However, $SNDOPR's data structures are easily the worst I have seen in VMS, and I prefere to handle them with care using explicit structures for each one, than trust the complex and non-standard variant union types used in OPCDEF.H. It must be an interesting exercise to try and call $SNDOPR using data structures built only with (ANSI-standard) Fortran... ================================================================================ Note 1445.6 How to filter OPCOM messages 6 of 7 DECUSF::OURGHANLIA_B "Eppur si muove..." 5 lines 22-AUG-1991 19:59 -< opcdef.h shouldn't be screwed up ... >- -------------------------------------------------------------------------------- I don't think your opcdef.h has been screwed up by a new compiler version (I've checked in the standard VAXC V3.2 kit) but it seems your opcdef.h is an old one (VAXC V2.3) : I think you should re-install VAXC V3.2 (or extract the text library from the kit) and asked for the *.h files. ================================================================================ Note 1445.7 How to filter OPCOM messages 7 of 7 DECUSF::BROWN_N "Nick BROWN, Conseil de l'Europe" 3 lines 6-SEP-1991 15:06 -< I can't see it here >- -------------------------------------------------------------------------------- My VAXCDEF.TLB has a creation date of 30-NOV-1990 and a modification date (when I installed it) of 13-JUN-1991... The .H file is 100% identical to the library entry. What is your VAXCDEF.TLB creation date?