// Copyright (c) 2018, Intel Corporation.
// SPDX-License-Identifier: BSD-3-Clause

ifdef::manpage[]
ipmctl-change-sensor(1)
=======================
endif::manpage[]

NAME
----
ipmctl-change-sensor - Changes the threshold or enabled state for DCPMMs sensors

SYNOPSIS
--------
[verse]
ipmctl set [OPTIONS] -sensor (SENSORS) [TARGETS]
AlarmThreshold=(temperature) AlarmEnabled=(0|1)

DESCRIPTION
-----------
Changes the alarm threshold or enabled state for one or more DCPMMs sensors.
Use the command Show Sensor to view the current settings.

OPTIONS
-------
-f::
-force::
  Changing the sensor settings is a potentially destructive operation which
  requires confirmation from the user for each DCPMM. This option suppresses the
  confirmation.

-h::
-help::
    Displays help for the command.

-ddrt::
  Used to specify DDRT as the desired transport protocol for the current invocation of ipmctl.

-smbus::
  Used to specify SMBUS as the desired transport protocol for the current invocation of ipmctl.

NOTE: The -ddrt and -smbus options are mutually exclusive and may not be used together.

ifdef::os_build[]
-o (text|nvmxml)::
-output (text|nvmxml)::
  Changes the output format. One of: "text" (default) or "nvmxml".
endif::os_build[]

SENSORS
-------
MediaTemperature::
  The DCPMM media temperature in Celsius.

ControllerTemperature::
  The DCPMM controller temperature in Celsius.

PercentageRemaining::
  Remaining DCPMM’s life as a percentage value of factory expected
  life span.

TARGETS
-------
-dimm [DimmIDs]::
  Update specified sensors on specific DCPMMs by optionally supplying the DIMM
  target and one or more comma-separated DCPMM identifiers. The default is to
  update the specified sensors for all manageable DCPMMs.

PROPERTIES
----------
AlarmThreshold::
  The threshold value at which an alarm for the respective sensor will be triggered.
  The upper (for temperatures) or lower (for percentage remaining) alarm
  threshold of the sensor. Temperatures may be specified to a precision of 1 degree Celsius.
+
.Allowed AlarmThreshold
|===
|Sensor |Allowed AlarmThreshold values |Units

|MediaTemperature
|0-2047
|Celsius

|ControllerTemperature
|0-2047
|Celsius

|PercentageRemaining
|1-99
|%
|===

AlarmEnabled::
  Enable or disable the alarm threshold, where applicable.
  One of:
  - "0": Disable
  - "1": Enable

EXAMPLES
--------
Changes the media temperature alarm threshold to 51C on the specified DCPMM and enables
the alarm.

[verse]
ipmctl set -sensor MediaTemperature –dimm 0x0001 AlarmThreshold=51 AlarmEnabled=1

LIMITATIONS
-----------
In order to successfully execute this command:

- The caller must have the appropriate privileges.

- The specified DCPMM(s) must be manageable by the host software.

RETURN DATA
-----------
For each DCPMM, the CLI will indicate the status of the operation. If a failure occurs
when modifying multiple DCPMMs, the process will exit and not continue modifying the
remaining DCPMMs.

SAMPLE OUTPUT
-------------
[verse]
Modify (Sensor) settings on DIMM (DimmID): Success

[verse]
Modify (Sensor) settings on DIMM (DimmID): Error (Code) -
(Description)
