SNMP Subagent Programmer's Guide
Programming Tutorials
SNMP Subagent Programmer’s Guide—119728 2-7
Hello World Program
Include Statements
The include statement at the beginning of the MIB definition identifies a header file that 
the MIB compiler, GDMOC, needs to resolve data types. The header file, named 
typessmi, contains definitions of all the standard SNMP data types. 
Note that this MIB also contains an IMPORT statement defining standard data types for 
objects in the MIB. Although GDMOC ignores this statement, obtaining instead the 
information it needs on types from typessmi, some managers need type definitions such 
as these before a MIB can be compiled on the manager station.  Refer to “Installing the 
MIB,” later in this subsection, for more information on MIB definition changes for 
manager stations.
 helloFreqChange TRAP-TYPE
 ENTERPRISE hello
 VARIABLES { helloPrintFreq }
 DESCRIPTION
 "A helloFreqChange trap signifies that the 
 sending hello world entity has had its 
 'helloPrintFreq' variable modified."
 ::= 0
END
EXTEND OBJECT-TYPE helloOutputText
 WITH C_VARIABLE helloText
 IN C
EXTEND OBJECT-TYPE helloPrintFreq
 WITH C_VARIABLE helloPrintFreq
 IN C
EXTEND OBJECT-TYPE helloPrintCnt
 WITH C_VARIABLE helloPrintCnt
 IN C
Example 2-1. Hello World MIB Definition (page 2 of 2)










