-- ****************************************************************************
-- ****************************************************************************
--
--  File: MX-FXS-MIB.my
--
--  Package: MediatrixMibs
--
-- ****************************************************************************
-- ****************************************************************************
--
--      Copyright(c) 2001-2005 Mediatrix Telecom, Inc.
--      Copyright(c) 2007 Media5 Corporation ("Media5")
--
--  NOTICE:
--   This document contains information that is confidential and proprietary to
--   Media5.
--
--   Media5 reserves all rights to this document as well as to the
--   Intellectual Property of the document and the technology and know-how that
--   it includes and represents.
--
--   This publication cannot be reproduced, neither in whole nor in part, in any
--   form whatsoever without prior written approval by Media5.
--
--   Media5 reserves the right to revise this publication and make
--   changes at any time and without the obligation to notify any person and/or
--   entity of such revisions and/or changes.
--
-- ****************************************************************************
-- ****************************************************************************

MX-FXS-MIB
DEFINITIONS ::= BEGIN

IMPORTS
        MODULE-IDENTITY,
        OBJECT-TYPE,
        Unsigned32
    FROM SNMPv2-SMI
        MODULE-COMPLIANCE,
        OBJECT-GROUP
    FROM SNMPv2-CONF
        mediatrixConfig
    FROM MX-SMI
        MxEnableState,
        MxDigitMap
    FROM MX-TC;

fxsMIB MODULE-IDENTITY
    LAST-UPDATED "200908050000Z"
    ORGANIZATION "Mediatrix Telecom"
    CONTACT-INFO "Mediatrix Telecom
                  4229, Garlock Street
                  Sherbrooke (Quebec)
                  Canada
                  Phone: (819) 829-8749
                  "
    DESCRIPTION  "This MIB provides Foreign eXchange Station (FXS) parameters."
    -- ************************************************************************
    -- Revision history
    -- ************************************************************************
    REVISION    "200908050000Z"
    DESCRIPTION "Added fxsCallingNumberCriteria and
                 fxsCallingNumberTransformation"
    REVISION    "200907240000Z"
    DESCRIPTION "Added fxsFskMarkoutBits"
    REVISION    "200901260000Z"
    DESCRIPTION "Modified fxsPolarityAndDenialBehavior description and
                 added fxsPowerDropOnDisconnectDuration"
    REVISION    "200811270000Z"
    DESCRIPTION "Added fxsEpSpecificLoopCurrentTable"
    REVISION    "200705180000Z"
    DESCRIPTION "Addition of fxsPolarityAndDenialBehavior and the consequent
                 deprecation of fxsReversalOnIdleEnable"
    REVISION    "200612210000Z"
    DESCRIPTION "Addition of fxsBlankAnonymousCallerId"
    REVISION    "200602130000Z"
    DESCRIPTION "Addition of fxsReversalOnIdleEnable"
    REVISION    "200601300000Z"
    DESCRIPTION "Addition of fxsCalleeHangupSupervision and
                 fxsCalleeHangupDelay"
    REVISION    "200511070000Z"
    DESCRIPTION "Added fxsLoopCurrentDropEnable."
    REVISION    "200503300000Z"
    DESCRIPTION "Modified the description of fxsEmergencyBypassEnable and
                 fxsEmergencyBypassDialDelay."
    REVISION    "200501270000Z"
    DESCRIPTION "Added range to fxsEmergencyBypassTimeout."
    REVISION    "200411240000Z"
    DESCRIPTION "Added fxsEmergencyBypassDialDelay"
    REVISION    "200409270000Z"
    DESCRIPTION "Added fxsEmergencyBypassEnable, fxsEmergencyBypassTimeout and
                 fxsEmergencyBypassDialMap"
    REVISION    "200208300000Z"
    DESCRIPTION "Updated fxsLoopCurrent DESCRIPTION to remove reference to
                 explicit hardware platform."
    REVISION    "200208220000Z"
    DESCRIPTION "Updated range of fxsLoopCurrent and augmented description."
    REVISION    "200111050000Z"
    DESCRIPTION "Added fxsFlashHookDetectionDelayMin and fxsFlashHookDetectionDelayMax."
    REVISION    "200108290000Z"
    DESCRIPTION "Creation"
    ::= { mediatrixConfig 40 }

fxsMIBObjects     OBJECT IDENTIFIER ::= { fxsMIB 1 }
fxsConformance    OBJECT IDENTIFIER ::= { fxsMIB 2 }


    fxsByPassEnable OBJECT-TYPE
        SYNTAX      INTEGER {
                             disable(0),
                             enable(1)
                            }
        MAX-ACCESS  read-write
        STATUS      current
        DESCRIPTION "Enable the bypass service.

                     disable : The port with the bypass service is never
                               redirected on the bypass line.

                     enable : When the port with the bypass service is unusable
                              (ifAdminUsageState is idle-unusable), it will be
                              redirected to the bypass line. When this port
                              becomes usable again (ifAdminUsageState is idle),
                              the redirection is stopped within 10 seconds if
                              the bypass line is unused or 10 seconds after
                              the termination of the call.

                     NOTE: The control of the bypass service is only possible
                           when the unit is powered on. When power is off, the
                           bypass service is always enabled."
        DEFVAL      { enable }
        ::= { fxsMIBObjects 1 }

    fxsLoopCurrent OBJECT-TYPE
        SYNTAX Unsigned32 (20..50)
        MAX-ACCESS read-write
        STATUS current
        DESCRIPTION "Current flowing through the current detector that
                     permits the detection of the on-hook and off-hook states.
                     The loop current is in mA.

                     Some hardware platforms may support less than the available
                     range.

                     Please refer to the documentation shipped with your device
                     for more details."
        DEFVAL { 30 }
        ::= { fxsMIBObjects 2 }

    fxsFlashHookDetectionDelayMin OBJECT-TYPE
        SYNTAX Unsigned32 (10..1200)
        MAX-ACCESS read-write
        STATUS current
        DESCRIPTION "Minimum time in ms the hook switch must remain pressed
                     to perform a flash hook."
        DEFVAL { 100 }
        ::= { fxsMIBObjects 3 }

    fxsFlashHookDetectionDelayMax OBJECT-TYPE
        SYNTAX Unsigned32 (10..1200)
        MAX-ACCESS read-write
        STATUS current
        DESCRIPTION "Maximum time in ms the hook switch can remain pressed
                     to perform a flash hook."
        DEFVAL { 1200 }
        ::= { fxsMIBObjects 4 }

    fxsLoopCurrentDropEnable OBJECT-TYPE
        SYNTAX      MxEnableState
        MAX-ACCESS read-write
        STATUS current
        DESCRIPTION "Instructs the FXS unit to suppress loop current on its ports
                     when they cannot be used or when the IP connection
                     is lost.

                     disable: Loop current is unaffected by the port usability.

                     enable : Loop current is interrupted on the port as
                              soon as it enters an unusable state, or if the unit's
                              IP network connection is lost."

        DEFVAL { disable }
        ::= { fxsMIBObjects 50 }

    fxsCalleeHangupSupervision OBJECT-TYPE
        SYNTAX  MxEnableState
        MAX-ACCESS  read-write
        STATUS      current
        DESCRIPTION "Determines whether call clearing occurs as soon as the called user
                     is the first to hang up a received call.  This variable has no
                     effect when the user acts as the calling party.

                     disable: The unit signals the end of the call as soon as the user
                              hangs up.

                     enable: When the user is the first to hang up on a received call, the unit
                             waits for the amount of time provisioned in the fxsCalleeHangupDelay
                             variable before signaling the end of the call."
        DEFVAL      { disable }
        ::= { fxsMIBObjects 75 }

    fxsCalleeHangupDelay OBJECT-TYPE
        SYNTAX Unsigned32 (1..300)
        MAX-ACCESS read-write
        STATUS current
        DESCRIPTION "The amount of time, in seconds, the unit waits after the
                     called user hangs up before signaling the end of the call.

                     This delay is effective only when the fxsCalleeHangupSupervision variable is
                     enabled and the user is the called party.  When the user acts as the
                     calling party, the call ends as soon as the user hangs up."
        DEFVAL { 60 }
        ::= { fxsMIBObjects 100 }

    fxsReversalOnIdleEnable OBJECT-TYPE
        SYNTAX  MxEnableState
        MAX-ACCESS  read-write
        STATUS      deprecated
        DESCRIPTION "This object is deprecated. Therefore, agents may or may not implement it.
                     Use fxsPolarityAndDenialBehavior instead.

                             The Reversal on Idle feature is used because of an inability by some
                     customer's CPE to react to busy tone. This problem can be overcome by
                     applying polarity reversal when the circuit is not busy . The reversal
                     allows the CPE to effect release of a circuit under line lockout conditions
                     or the other party clearing. When a customer's line is in the idle, line
                     lockout or blocked state, the polarity of the customer's line is reversed.
                     When the customer's line is seized to originate a call, or ring current is
                     applied to terminate a call, the line polarity is returned to normal.
                     On release, line polarity is returned to the reversed condition.

                     When activated, this feature replaces the default behaviour of the unit
                     which is to briefly remove power from the line to signal that the remote party
                     has hung up.

                     disable: Do not perform line reversal when the line enters the idle
                              condition.

                     enable: Activates the Reversal on Idle feature as described above."
        DEFVAL      { disable }
        ::= { fxsMIBObjects 125 }

    fxsPolarityAndDenialBehavior  OBJECT-TYPE
        SYNTAX      INTEGER {
                             noReversal(0),
                             reversalOnIdle(1),
                             reversalOnEstablished(2)
                            }
        MAX-ACCESS  read-write
        STATUS      current
        DESCRIPTION "Determines how the line polarity is used to signal the beginning and end of a call.

                     noReversal :
                        Polarity reversal is not used. A short power drop is made at the end of a call when
                        the call is disconnected by the remote party. The drop duration can be configured
                        in the variable fxsPowerDropOnDisconnectDuration.

                     reversalOnIdle :
                        Activates the Reversal on Idle feature.  When a customer's line is in the idle,
                        line lockout or blocked state, the polarity of the customer's line is reversed.
                        When the customer's line is seized to originate a call, or the ring current is
                        applied to terminate a call, the line polarity is returned to normal.
                        On release, the line polarity is returned to the reversed condition.

                     reversalOnEstablished :
                        Activates the Reversal on Established option.  The polarity remains normal
                        (voltage on the phone line stays positive) when you pick up the phone, dial,
                        and when the device is ringing.  As soon as the other party picks up the phone,
                        the unit reverses the line polarity.  When the unit receives a hang-up signal or
                        the caller hangs up the phone, the voltage returns to its positive state."
        DEFVAL      { noReversal }
        ::= { fxsMIBObjects  135 }

    fxsPowerDropOnDisconnectDuration OBJECT-TYPE
        SYNTAX Unsigned32 (100..5000)
        MAX-ACCESS read-write
        STATUS current
        DESCRIPTION "Determines the power drop duration that is made at the end
                     of a call when the call is disconnected by the remote party.

                     This value is expressed in milliseconds (ms).

                     This variable only has an effect when the variable
                     fxsPolarityAndDenialBehavior is set to 'noReversal'."
        DEFVAL { 1000 }
        ::= { fxsMIBObjects 140 }

    fxsBlankAnonymousCallerId OBJECT-TYPE
        SYNTAX  MxEnableState
        MAX-ACCESS  read-write
        STATUS      current
        DESCRIPTION "Instructs the FXS unit to blank out the name portion of the received
                     caller ID whenever 'anonymous' (case insensitive) is used to identify
                     the originator of the call.

                     disable: The anonymous string is passed on to the telephone and displayed
                              to identify the calling party.

                     enable: The anonymous string is blanked out before caller ID data is sent
                             to the telephone."
        DEFVAL      { disable }
        ::= { fxsMIBObjects 150 }

    fxsFskMarkoutBits OBJECT-TYPE
        SYNTAX Unsigned32 (0..5280)
        MAX-ACCESS read-write
        STATUS current
        DESCRIPTION "Determines the number of markout bits that are added after
                     the checksum in FSK signals sent to the phone when it's on hook.

                     The Bellcore 202 standard specifies that there can be up to 5280 bits.

                     The ETSI doesn't specify any markout bits.

                     This variable's semantics are different depending on protocol
                     and/or hardware platforms. Please refer to the documentation
                     for more details."
        DEFVAL { 200 }
        ::= { fxsMIBObjects 155 }

    fxsCallingNumberCriteria OBJECT-TYPE
        SYNTAX      OCTET STRING (SIZE(0..255))
        MAX-ACCESS  read-write
        STATUS      current
        DESCRIPTION "Expression that the calling number must match in
                     order to apply the transformation specified in
                     fxsCallingNumberTransformation.

                     The criteria must be a regular expression."
        DEFVAL      { "" }
        ::=  {  fxsMIBObjects  160  }

    fxsCallingNumberTransformation OBJECT-TYPE
        SYNTAX      OCTET STRING (SIZE(0..255))
        MAX-ACCESS  read-write
        STATUS      current
        DESCRIPTION "Transformation applied on the calling number if it matches
                     the expression specified in fxsCallingNumberCriteria.

                     '\0' to '\9' are replaced by the corresponding group in
                     the regular expresion specified in fxsCallingNumberCriteria."
        DEFVAL      { "" }
        ::=  {  fxsMIBObjects  161  }

    -- ************************************************************************
    --   Endpoint Specific Loop Current Table
    -- ************************************************************************

    fxsEpSpecificLoopCurrentTable OBJECT-TYPE
        SYNTAX      SEQUENCE OF FxsEpSpecificLoopCurrentEntry
        MAX-ACCESS  not-accessible
        STATUS      current
        DESCRIPTION "Table that contains loop current configuration indexed by
                     endpoint number."
        ::= { fxsMIBObjects 190 }

        fxsEpSpecificLoopCurrentEntry OBJECT-TYPE
            SYNTAX      FxsEpSpecificLoopCurrentEntry
            MAX-ACCESS  not-accessible
            STATUS      current
            DESCRIPTION "Endpoint specific loop current parameter entries."
            INDEX       {
                            ifIndex
                        }
            ::= { fxsEpSpecificLoopCurrentTable 1 }

            FxsEpSpecificLoopCurrentEntry ::= SEQUENCE
                {
                    fxsEpSpecificLoopCurrentOverrideEnable  MxEnableState,
                    fxsEpSpecificLoopCurrentOverride        Unsigned32
                }

            fxsEpSpecificLoopCurrentOverrideEnable OBJECT-TYPE
                SYNTAX  MxEnableState
                MAX-ACCESS  read-write
                STATUS      current
                DESCRIPTION "Defines whether or not a specific loop current configuration
                             must be used for this endpoint.

                             disable: The endpoint loop current configuration is defined
                                      by the variable fxsLoopCurrent.

                             enable: The endpoint loop current configuration is defined
                                     by the variable fxsEpSpecificLoopCurrentOverride and
                                     the value in fxsLoopCurrent is ignored."
                DEFVAL      { disable }
                ::= { fxsEpSpecificLoopCurrentEntry 10 }

            fxsEpSpecificLoopCurrentOverride OBJECT-TYPE
                SYNTAX Unsigned32 (20..50)
                MAX-ACCESS read-write
                STATUS current
                DESCRIPTION "Current flowing through the current detector that
                             permits the detection of the on-hook and off-hook states.
                             The loop current is in mA.

                             Some hardware platforms may support less than the available
                             range.

                             Please refer to the documentation shipped with your device
                             for more details."
                DEFVAL { 30 }
                ::= { fxsEpSpecificLoopCurrentEntry 20 }


    -- *************************************************************************
    -- fxsEmergencyBypass
    -- *************************************************************************
    fxsEmergencyBypass    OBJECT IDENTIFIER ::= { fxsMIBObjects 200 }

    fxsEmergencyBypassEnable OBJECT-TYPE
        SYNTAX      MxEnableState
        MAX-ACCESS  read-write
        STATUS      current
        DESCRIPTION "Enables/Disables bypass for emergency calls.

                     disable: Bypass for emergency calls is disabled.

                     enable : Bypass for emergency calls is enabled. If dialed digits
                              match those defined in the fxsEmergencyBypassDialMap
                              variable, the unit switches to bypass mode and makes
                              the call on the PSTN side.

                     Note that the bypass functionality only applies for
                     digits dialed on FXS port 1

                     This variable's semantics are different depending on protocol and/or
                     hardware platforms.
                     Please refer to the documentation shipped with your device for more details."

        DEFVAL { disable }
        ::= { fxsEmergencyBypass 50 }

    fxsEmergencyBypassTimeout OBJECT-TYPE
        SYNTAX      Unsigned32 (1..3600)
        MAX-ACCESS  read-write
        STATUS      current
        DESCRIPTION "Indicates how long the unit will stay in bypass mode
                     waiting for an incoming call after the outgoing call on
                     the PSTN side is finished.

                     This value is expressed in seconds (s)."

        DEFVAL { 120 }
        ::= { fxsEmergencyBypass 100 }

    fxsEmergencyBypassDialMap OBJECT-TYPE
        SYNTAX  MxDigitMap
        MAX-ACCESS  read-write
        STATUS      current
        DESCRIPTION "A string composing a digit map that will be
                     considered valid to make the unit switch to bypass mode.

                     The string must follow the syntax described in
                     the digitMapMIB entry description."

        DEFVAL      { "" }
        ::= { fxsEmergencyBypass 150 }

    fxsEmergencyBypassDialDelay OBJECT-TYPE
        SYNTAX      Unsigned32 (1..10)
        MAX-ACCESS  read-write
        STATUS      current
        DESCRIPTION "Indicates how long the unit will wait before playing
                     emergency digits on the PSTN side once in bypass mode.

                     This value is expressed in seconds (s).

                     This variable's semantics are different depending on protocol and/or
                     hardware platforms.
                     Please refer to the documentation shipped with your device for more details."

        DEFVAL { 3 }
        ::= { fxsEmergencyBypass 200 }



    -- ************************************************************************
    -- Conformance information
    -- ************************************************************************
    fxsCompliances OBJECT IDENTIFIER ::= { fxsConformance 1 }

    fxsComplVer1 MODULE-COMPLIANCE
        STATUS      current
        DESCRIPTION
            "This is the list of conformance groups to support FXS parameters."
        MODULE -- This Module
            MANDATORY-GROUPS {
                                fxsGroupVer1,
                                fxsEmergencyBypassGroupVer1
                             }
        ::= { fxsCompliances 1 }

    -- ************************************************************************
    -- MIB variable grouping
    -- ************************************************************************
    fxsGroups OBJECT IDENTIFIER ::= { fxsConformance 5 }

    fxsGroupVer1 OBJECT-GROUP
        OBJECTS {
                    fxsByPassEnable,
                    fxsLoopCurrent,
                    fxsFlashHookDetectionDelayMin,
                    fxsFlashHookDetectionDelayMax,
                    fxsLoopCurrentDropEnable,
                    fxsCalleeHangupSupervision,
                    fxsCalleeHangupDelay,
                    fxsReversalOnIdleEnable,
                    fxsPolarityAndDenialBehavior,
                    fxsPowerDropOnDisconnectDuration,
                    fxsBlankAnonymousCallerId,
                    fxsFskMarkoutBits,
                    fxsCallingNumberCriteria,
                    fxsCallingNumberTransformation
                }
        STATUS      current
        DESCRIPTION "This group holds the objects to define FXS specific parameters."
        ::= { fxsGroups 5 }


    fxsEmergencyBypassGroupVer1 OBJECT-GROUP
        OBJECTS {
                    fxsEmergencyBypassEnable,
                    fxsEmergencyBypassTimeout,
                    fxsEmergencyBypassDialMap,
                    fxsEmergencyBypassDialDelay
                }
        STATUS      current
        DESCRIPTION "This group holds the objects to define emergency bypass specific parameters."
        ::= { fxsGroups 10 }
END
