On 14 Jul 2011 at 14:38, Fulko Hew wrote:
> On Thu, Jul 14, 2011 at 1:56 PM, Robert Story <[email protected]>
> wrote:
> Another option is to define a separate object for mute.. the
> atvantage being
> that they can unmute and the gain will still be at it's previous
> level..
>
> Excellent point, and great idea!
>
>
> gainControl OBJECT-TYPE
> SYNTAXINTEGER (0..1000)
> MAX-ACCESSread-write
> STATUScurrent
> DESCRIPTION"The 'gainControl' variable allows you to set the
> gain of the device between 0 and 100dB in units
> tenths of a dB (i.e. 111 == 11.1dB).
> Note: Some systems may not allow that level of
> granularity and may round off any actual value
> provided. e.g. 0.5dB increments. In that case
> the variable when read, will indicate the actual
> value in operation, not the value requested.
>
> See also 'muteControl' for controlling the actual
> output."
> UNITS"tenths of a dB"
> DEFVAL { -1 }
>
> ::= { parentNode 1 }
>
> muteControl OBJECT-TYPE
> SYNTAXINTEGER {
> muted (1),
> un-muted (2)
> }
> MAX-ACCESSread-write
> STATUScurrent
> DESCRIPTION"The 'muteControl' variable allows you to
> enable/disable the output independently of
> the value of 'gainControl'."
> DEFVAL { un-muted }
>
> ::= { parentNode 2 }
Thank you, Fulko and Robert, to give some answers for my questions.
I think this approach is the best among the others. In my case,
unfortunately, I can't follow it, because of the device under
control logic.
It's an audio amplifier and implements a gain level control similar
to a "rotary encoder" with a switch: you turn the encoder right and
the gain increases; turn the encoder left and the gain decreases up
to a minimum. Continue turning it left to close the switch and mute
the amplifier.
In this case, when the amplifier is muted, there's no idea about the
last gain level to restore when the switch is open again turning the
encoder right. I think the approach with two OIDs can be adapted to
an amplifier with a rotary encoder for the gain level control and a
*separate* switch for the mute.
Thank you again for your comments.
------------------------------------------------------------------------------ AppSumo Presents a FREE Video for the SourceForge Community by Eric Ries, the creator of the Lean Startup Methodology on "Lean Startup Secrets Revealed." This video shows you how to validate your ideas, optimize your ideas and identify your business strategy. http://p.sf.net/sfu/appsumosfdev2dev
_______________________________________________ Net-snmp-coders mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/net-snmp-coders
