-- *****************************************************************

RAISECOM-OPTICAL-ENTITY-MIB DEFINITIONS ::= BEGIN

IMPORTS
    MODULE-IDENTITY, OBJECT-TYPE, NOTIFICATION-TYPE, IpAddress
        FROM SNMPv2-SMI
    TEXTUAL-CONVENTION, TimeStamp, DisplayString
        FROM SNMPv2-TC
    RcOptModuleType
      	FROM RAISECOM-OPTICAL-MODULE-TYPE-MIB
    rcNotifsTrapLocation
        FROM RAISECOM-NOTIFICATION-MIB
    optSysMgmt
        FROM RAISECOM-BASE-MIB
    raisecomUpgradeCtrl, raisecomFTPFileType
    	  FROM RAISECOM-COMMON-MANAGEMENT-MIB;
    
raisecomOptEntityMIB MODULE-IDENTITY
    LAST-UPDATED "1303061000Z" 
    ORGANIZATION "Optical Working Group"
    CONTACT-INFO
        "           "
    DESCRIPTION
        "The MIB module to describe rc006 PDH Card objects."
    REVISION	"0607101100Z"
    DESCRIPTION
    "
    1add rcEntPhysicalHardwareVersion
    2add rcEntPhysicalSoftwareVersion
    3add rcEntPhysicalFirmwareVersion
   	"
    REVISION	"0612131711Z"
    DESCRIPTION
    "
    1add rcEntDownloadFileRequestTrap
    2add rcEntDownloadFileOkTrap    
    "
    REVISION	"0612211500Z"
    DESCRIPTION
    "
    1modify rcEntDownloadFileRequestTrap to rcEntSvcFileTransmitReqTrap
    2modify rcEntDownloadFileOkTrap to rcEntSvcFileTransmitOkTrap   
    "     
    
    REVISION 	"0801101020Z"
 	DESCRIPTION
 	"
 	1. add  rcEntPhysicalConfigurationgWrite
 	"   
    REVISION	"0904141000Z"
    DESCRIPTION
    "
    rcEntPhysicalHardwareVersionrcEntPhysicalSoftwareVersionrcEntPhysicalFirmwareVersion change to SIZE(0..64)
    "    
    REVISION	"0906151000Z"
    DESCRIPTION
    "
    1. add rcEntPhysicalAddType and rcEntPhysicalStatus
    2. add rcEntDelCardTrap,rcEntAddCardTrap,rcEntCardMismatchTrap
    
    "
    REVISION	"1006011000Z"
    DESCRIPTION
    "
    1. add enum to rcEntPhysicalStatus -- by wangzhizhuo
    2. add rcEntPhysicalConnectStatus
    3. add rcEntLossConnectTrap and rcEntLossConnectOkTrap   
    "
    REVISION	"1108091000Z"
    DESCRIPTION
    "
    1. add rcEntPhysicalOrderinfo and rcEntPhysicalAddCardwithOrder
    2. add rcEntDelCardTrap,rcEntAddCardTrap,rcEntCardMismatchTrap
    " 
    REVISION	"1108091000Z"
    DESCRIPTION
    "
    1. add rcEntManufactureInfoTable
    "     
    REVISION	"1206011000Z"
    DESCRIPTION
    " 
    1. add rcEntPhysicalReboot and rcEntPhysicalRebootState
    2. add rcEntSoftRebootTrap,rcEntSoftRebootOKTrap
    "   
    REVISION	"1208301000Z"
    DESCRIPTION
    " 
    1. add rcEntPhysicalSupportIPMng
    "     
    REVISION	"1303061000Z"
    DESCRIPTION
    " 
    1. add rcEntPhysicalIpAddr by zhangqian
    "    
    
    REVISION	"1410101030Z"
    DESCRIPTION
    " 
    1. add rcEntPhysicalAddCardwithbasedevt by zhaobaolin
    " 
    
    ::= { optSysMgmt 4 }      

rcEntityMIBObjects OBJECT IDENTIFIER ::= { raisecomOptEntityMIB 1 }

-- MIB contains 2 groups
rcEntityPhysical OBJECT IDENTIFIER ::= { rcEntityMIBObjects 1 }
rcEntityGeneral  OBJECT IDENTIFIER ::= { rcEntityMIBObjects 2 }

-- Textual Conventions
PhysicalClass ::= TEXTUAL-CONVENTION
    STATUS          current
    DESCRIPTION
            " "
    SYNTAX      INTEGER  {
        other(1),
        unknown(2),
        chassis(3),     -- 
        backplane(4),   -- 
        container(5),   -- ӿĲ
        powerSupply(6), 
        fan(7),
        sensor(8),
        slotModule(9),      -- ʽ忨
        remoteModule(10),   -- Զ˶豸
        subm(11),           -- Զӿ
        port(12),       -- ˿
        stack(13)       -- e.g., stack of multiple chassis entities
    }

--           The Physical Entity Table
rcEntPhysicalTable OBJECT-TYPE
    SYNTAX      SEQUENCE OF RcEntPhysicalEntry
    MAX-ACCESS  not-accessible
    STATUS      current
    DESCRIPTION
            "This table contains one row per physical entity.  There is
            always at least one row for an 'overall' physical entity."
    ::= { rcEntityPhysical 1 }

rcEntPhysicalEntry       OBJECT-TYPE
    SYNTAX      RcEntPhysicalEntry
    MAX-ACCESS  not-accessible
    STATUS      current
    DESCRIPTION
            "Information about a particular physical entity."
    INDEX   { rcEntPhysicalID }
    ::= { rcEntPhysicalTable 1 }

RcEntPhysicalEntry ::= SEQUENCE {
      rcEntPhysicalID           OCTET STRING,
      rcEntPhysicalModuleType   RcOptModuleType,
      rcEntPhysicalVendorType   OBJECT IDENTIFIER,
      rcEntPhysicalClass        PhysicalClass,
      rcEntPhysicalName         DisplayString,
      rcEntPhysicalTrapEnable   INTEGER,
      rcEntPhysicalHardwareVersion DisplayString,
      rcEntPhysicalSoftwareVersion DisplayString,
      rcEntPhysicalFirmwareVersion DisplayString,
      rcEntPhysicalConfigurationSave INTEGER,
      rcEntPhysicalAddType 		RcOptModuleType,
      rcEntPhysicalStatus		  INTEGER,
      rcEntPhysicalConnectStatus  INTEGER,
      rcEntPhysicalOrderinfo	     DisplayString,
      rcEntPhysicalAddCardwithOrder  DisplayString,
      rcEntPhysicalSupportIPMng   INTEGER,
      rcEntPhysicalAddCardwithbasedevt  DisplayString,
      rcEntPhysicalReboot		  INTEGER,
      rcEntPhysicalRebootState	  INTEGER,    
      rcEntPhysicalIpAddr         IpAddress    
}

rcEntPhysicalID OBJECT-TYPE
    SYNTAX      OCTET STRING (SIZE (0..12))
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
            "The index for this entry. It's a UNNID described as a octect string 
            Byte    1   2    3   4   5   6   7   8  9   10 11  
                 Shelf Slot Hop  Hop1ID  Hop2ID Hop3ID  Hop4ID 
            Byte 0 indicates Shelf ID of the UUID. Shelf id starts from 1.
            Byte 1 indicates Slot ID of the UNIID. Slot id starts from 0.
            Byte 2 is Hop, means how many hops from the local card to remote device. 
            HopNID means relative ID of this hop. Each Hop ID occupies 2 bytes.
            For local card, the Hop is zero.
            Limitation for the string is 12 bytes now. That means maximum hops is 4. 
            If you need to support more than 4 hops, the defination of SYTAX should 
            be changed."
    ::= { rcEntPhysicalEntry 1 }

rcEntPhysicalModuleType OBJECT-TYPE
    SYNTAX      RcOptModuleType
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
            "An indication of the vendor-specific hardware module type of the
            physical entity."
    ::= { rcEntPhysicalEntry 3 }

rcEntPhysicalVendorType OBJECT-TYPE
    SYNTAX      OBJECT IDENTIFIER
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
            "An indication of the vendor-specific hardware type of the
            physical entity. Normally, it's the same as MIB-II's sysObjectID.

            An agent should set this object to a enterprise-specific
            registration identifier value indicating the specific
            equipment type in detail.  The associated instance of
            rcEntPhysicalClass is used to indicate the general type of
            hardware device.

            If no vendor-specific registration identifier exists for
            this physical entity, or the value is unknown by this agent,
            then the value { 0 0 } is returned."
    ::= { rcEntPhysicalEntry 4 }

rcEntPhysicalClass OBJECT-TYPE
    SYNTAX      PhysicalClass
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
            "An indication of the general hardware type of the physical
            entity.

            An agent should set this object to the standard enumeration
            value which most accurately indicates the general class of
            the physical entity, or the primary class if there is more
            than one.

            If no appropriate standard registration identifier exists
            for this physical entity, then the value 'other(1)' is
            returned. If the value is unknown by this agent, then the
            value 'unknown(2)' is returned."
    ::= { rcEntPhysicalEntry 5 }

rcEntPhysicalName OBJECT-TYPE
    SYNTAX      DisplayString (SIZE(0..64))
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
            "The textual name of the physical entity.  The value of this
            object should be the name of the component as assigned by
            the local device and should be suitable for use in commands
            entered at the device's `console'.  This might be a text
            name, such as `console' or a simple component number (e.g.,
            port or module number), such as `1', depending on the
            physical component naming syntax of the device.

            If there is no local name, or this object is otherwise not
            applicable, then this object contains a zero-length string.

            Note that the value of rcEntPhysicalName for two physical
            entities will be the same in the event that the console
            interface does not distinguish between them, e.g., slot-1
            and the card in slot-1."
    ::= { rcEntPhysicalEntry 7 }

rcEntPhysicalTrapEnable OBJECT-TYPE
    SYNTAX      INTEGER
        {
            enable(1),
            disable(2)
        }
    MAX-ACCESS  read-write
    STATUS      current
    DESCRIPTION
            "Enable the physical entity send trap."
    DEFVAL { enable }
    ::= { rcEntPhysicalEntry 8 }
    
rcEntPhysicalHardwareVersion OBJECT-TYPE
    SYNTAX     DisplayString (SIZE(0..64))
    MAX-ACCESS read-only
    STATUS     current
    DESCRIPTION
    "
        Hardware version.
    "
    ::= { rcEntPhysicalEntry 9 }

rcEntPhysicalSoftwareVersion OBJECT-TYPE
    SYNTAX     DisplayString (SIZE(0..64))
    MAX-ACCESS read-only
    STATUS     current
    DESCRIPTION
    "
        Software version.
    "
    ::= { rcEntPhysicalEntry 10 }
    
rcEntPhysicalFirmwareVersion OBJECT-TYPE
    SYNTAX     DisplayString (SIZE(0..64))
    MAX-ACCESS read-only
    STATUS     current
    DESCRIPTION
    "
        Firmware version.
    "
    ::= { rcEntPhysicalEntry 11 }   
    
rcEntPhysicalConfigurationSave OBJECT-TYPE
	SYNTAX	INTEGER
	{    
		saving(1),
		ready(2),
		success(3),
		failure(4)		
	}  
	MAX-ACCESS read-write
	STATUS	current
	DESCRIPTION
	"
		write the configuration of the physical entity  
	"
    ::= { rcEntPhysicalEntry 12 }     
    
rcEntPhysicalAddType	OBJECT-TYPE
	SYNTAX	    RcOptModuleType
	MAX-ACCESS	read-write
	STATUS		current
	DESCRIPTION
	"
		add card or delete card to the physical entity 
		rcEntPhysicalAddTypeΪЧʱΪӰ忨rcEntPhysicalAddTypeΪnotExist(0)ʱ
		Ϊɾ忨
	"
    ::= { rcEntPhysicalEntry 13 }    
               
                           
rcEntPhysicalStatus	OBJECT-TYPE
	SYNTAX	INTEGER
	{
		bsNull(0),  
		bsOffline(1),		
		bsPower(2),
		bsMismatch(3),
		bsInservice(4),
		
		bsRegistering(10),
		bsConfiguring(11),
		bsWorking(12)
	}                  
	MAX-ACCESS	read-only
	STATUS		current
	DESCRIPTION
	"
		the status of the physical entity
	"
    ::= { rcEntPhysicalEntry 14 } 
	        
rcEntPhysicalConnectStatus    OBJECT-TYPE
	SYNTAX	INTEGER
	{
		normal(1),  
		noPoll(2)
	}                  
	MAX-ACCESS	read-only
	STATUS		current
	DESCRIPTION
	"
		the connect status of the physical entity
	"
    ::= { rcEntPhysicalEntry 15 }
    
rcEntPhysicalOrderinfo OBJECT-TYPE
    SYNTAX     DisplayString (SIZE(0..128))
    MAX-ACCESS read-only
    STATUS     current
    DESCRIPTION
    "
        real orderinfo got after the card is plug in.
    "
    ::= { rcEntPhysicalEntry 16 }

rcEntPhysicalAddCardwithOrder OBJECT-TYPE
    SYNTAX     DisplayString (SIZE(0..128))
    MAX-ACCESS read-write
    STATUS     current
    DESCRIPTION
    "
        add card which has orderinfo.
    "
    ::= { rcEntPhysicalEntry 17 }     

rcEntPhysicalSupportIPMng OBJECT-TYPE
    SYNTAX      INTEGER
        {
            true (1),
            false (2)
        }
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
            "Whether the device is NE with IP"
    ::= { rcEntPhysicalEntry 18 }

rcEntPhysicalAddCardwithbasedevt OBJECT-TYPE
    SYNTAX     DisplayString (SIZE(14..77))
    MAX-ACCESS read-write
    STATUS     current
    DESCRIPTION
    "
        add card with basedevt.
    "
    ::= { rcEntPhysicalEntry 19 }  
 
rcEntPhysicalReboot    OBJECT-TYPE
	SYNTAX	INTEGER
	{
		noReboot(1),
		softReboot(2),  
		hardReset(3)
	}                  
	MAX-ACCESS	read-write
	STATUS		current
	DESCRIPTION
	"
		the reboot type of the physical entity
	"
    ::= { rcEntPhysicalEntry 20 }

rcEntPhysicalRebootState    OBJECT-TYPE
	SYNTAX	INTEGER
	{
		ready(1),  
		rebooting(2)
	}                  
	MAX-ACCESS	read-only
	STATUS		current
	DESCRIPTION
	"
		the reboot state of the physical entity
	"
    ::= { rcEntPhysicalEntry 21 }    

rcEntPhysicalIpAddr    OBJECT-TYPE
	SYNTAX IpAddress
	MAX-ACCESS  read-only
	STATUS      current
	DESCRIPTION
	"
		豸ڲip.
	"
        ::= { rcEntPhysicalEntry 31 }            
        
-- product information of physical entity 
rcEntManufactureInfoTable OBJECT-TYPE
    SYNTAX      SEQUENCE OF RcEntManufactureInfoEntry
    MAX-ACCESS  not-accessible
    STATUS      current
    DESCRIPTION
            "This table contains one row per physical entity.  There is
            always at least one row for an 'overall' physical entity."
    ::= { rcEntityPhysical 2 }

rcEntManufactureInfoEntry       OBJECT-TYPE
    SYNTAX      RcEntManufactureInfoEntry
    MAX-ACCESS  not-accessible
    STATUS      current
    DESCRIPTION
            "Information about a particular ManufactureInfo entity."
    INDEX   { rcEntPhysicalID }
    ::= { rcEntManufactureInfoTable 1 }

RcEntManufactureInfoEntry ::= SEQUENCE {
      rcEntMfiVendor        OCTET STRING,
      rcEntMfiSerialNo      OCTET STRING,
      rcEntMfiProductName   OCTET STRING,
      rcEntMfiProductVer    OCTET STRING,
      rcEntMfiMac           OCTET STRING
}

rcEntMfiVendor OBJECT-TYPE
    SYNTAX      OCTET STRING (SIZE (0..128))
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
            "Vendor of the product"
    ::= { rcEntManufactureInfoEntry 1 }

rcEntMfiSerialNo OBJECT-TYPE
    SYNTAX      OCTET STRING (SIZE (0..128))
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
            "Serial Number of the product."
    ::= { rcEntManufactureInfoEntry 2 }

rcEntMfiProductName OBJECT-TYPE
    SYNTAX      OCTET STRING (SIZE (0..128))
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
            "Name of the product."
    ::= { rcEntManufactureInfoEntry 3 }


rcEntMfiProductVer OBJECT-TYPE
    SYNTAX      OCTET STRING (SIZE (0..128))
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
            "Version of the product."
    ::= { rcEntManufactureInfoEntry 4 }


rcEntMfiMac OBJECT-TYPE
    SYNTAX      OCTET STRING (SIZE (0..128))
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
            "Mac of the product."
    ::= { rcEntManufactureInfoEntry 5 }



-- last change time stamp for the whole MIB
rcEntLastChangeTime OBJECT-TYPE
    SYNTAX      TimeStamp
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
            "The value of sysUpTime at the time a conceptual row is
            created, modified, or deleted of rcEntPhysicalTable. "
    ::= { rcEntityGeneral 1 }

-- Entity MIB Trap Definitions
rcEntityMIBTraps      OBJECT IDENTIFIER ::= { raisecomOptEntityMIB 2 }
rcEntityMIBTrapPrefix OBJECT IDENTIFIER ::= { rcEntityMIBTraps 0 }

rcEntDisappearTrap   NOTIFICATION-TYPE
    OBJECTS { rcNotifsTrapLocation, rcEntPhysicalID , rcEntPhysicalModuleType }
    STATUS             current
    DESCRIPTION
            " "
   ::= { rcEntityMIBTrapPrefix 61 }

rcEntDiscoverTrap   NOTIFICATION-TYPE
    OBJECTS { rcNotifsTrapLocation, rcEntPhysicalID , rcEntPhysicalModuleType }
    STATUS             current
    DESCRIPTION
            " "
   ::= { rcEntityMIBTrapPrefix 62 }

   
rcEntWorkStatusFaultTrap   NOTIFICATION-TYPE
    OBJECTS { rcNotifsTrapLocation, rcEntPhysicalID}
    STATUS             current
    DESCRIPTION
            " "
   ::= { rcEntityMIBTrapPrefix 63 }

rcEntWorkStatusOkTrap   NOTIFICATION-TYPE
    OBJECTS { rcNotifsTrapLocation, rcEntPhysicalID }
    STATUS             current
    DESCRIPTION
            " "
   ::= { rcEntityMIBTrapPrefix 64 }
   
rcEntSvcFileTransmitReqTrap   NOTIFICATION-TYPE
    OBJECTS { rcNotifsTrapLocation, rcEntPhysicalID, rcEntPhysicalModuleType, raisecomUpgradeCtrl, raisecomFTPFileType}
    STATUS             current
    DESCRIPTION
            " "
   ::= { rcEntityMIBTrapPrefix 65 }

rcEntSvcFileTransmitOkTrap   NOTIFICATION-TYPE
    OBJECTS { rcNotifsTrapLocation, rcEntPhysicalID, rcEntPhysicalModuleType, raisecomUpgradeCtrl, raisecomFTPFileType }
    STATUS             current
    DESCRIPTION
            " "
   ::= { rcEntityMIBTrapPrefix 66 }
   
rcEntGeneralAlarmLedOnTrap   NOTIFICATION-TYPE
    OBJECTS { rcNotifsTrapLocation, rcEntPhysicalID}
    STATUS             current
    DESCRIPTION
            " 
            ֶ˰忨Զ豸ϵܸ澯澯
            "
   ::= { rcEntityMIBTrapPrefix 67 }

rcEntGeneralAlarmLedOffTrap   NOTIFICATION-TYPE
    OBJECTS { rcNotifsTrapLocation, rcEntPhysicalID}
    STATUS             current
    DESCRIPTION
            "
            ֶ˰忨Զ豸ϵܸ澯澯
            "
   ::= { rcEntityMIBTrapPrefix 68 } 
  
   
rcEntDelCardTrap  NOTIFICATION-TYPE
    OBJECTS {rcNotifsTrapLocation, rcEntPhysicalID , rcEntPhysicalAddType}
    STATUS  current
    DESCRIPTION  
           	"
           	ɾ忨
           	"
     ::= { rcEntityMIBTrapPrefix 69 }   
  
   
rcEntAddCardTrap  NOTIFICATION-TYPE
    OBJECTS {rcNotifsTrapLocation, rcEntPhysicalID , rcEntPhysicalAddType}
    STATUS  current
    DESCRIPTION  
           	"
           	Ӱ忨
           	"
    ::= { rcEntityMIBTrapPrefix 70 }  
        
                   
rcEntCardMismatchTrap   NOTIFICATION-TYPE
    OBJECTS {rcNotifsTrapLocation, rcEntPhysicalID , rcEntPhysicalAddType, rcEntPhysicalModuleType, rcEntPhysicalAddCardwithOrder}
    STATUS             current
    DESCRIPTION
            "
            벻ƥ忨
            "
   ::= { rcEntityMIBTrapPrefix 101 }    
   

rcEntLossConnectTrap   NOTIFICATION-TYPE
    OBJECTS {rcNotifsTrapLocation, rcEntPhysicalID}
    STATUS             current
    DESCRIPTION
            "
            entity loss connect
            "
   ::= { rcEntityMIBTrapPrefix 111 }    


rcEntLossConnectOkTrap   NOTIFICATION-TYPE
    OBJECTS {rcNotifsTrapLocation, rcEntPhysicalID}
    STATUS             current
    DESCRIPTION
            "
            entity loss connect recover
            "
   ::= { rcEntityMIBTrapPrefix 112 }    

rcEntSoftRebootTrap   NOTIFICATION-TYPE
    OBJECTS {rcNotifsTrapLocation, rcEntPhysicalID}
    STATUS             current
    DESCRIPTION
            "
            entity loss connect
            "
   ::= { rcEntityMIBTrapPrefix 121 }    


rcEntSoftRebootOKTrap   NOTIFICATION-TYPE
    OBJECTS {rcNotifsTrapLocation, rcEntPhysicalID}
    STATUS             current
    DESCRIPTION
            "
            entity loss connect recover
            "
   ::= { rcEntityMIBTrapPrefix 122 }     
END
