aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMadhav <madhavadas@google.com>2020-11-06 02:30:34 +0000
committerAleksander Morgado <aleksander@aleksander.es>2021-03-23 08:49:30 +0000
commit6dd34b79653319528f23de76d8134cf477ec2c96 (patch)
tree6450542dd4fa96270475c9871fdd4751218e9a18
parenta21233c7abde5572bc40494d1cb9b38976bf8f1c (diff)
api,sar: add D-Bus interface to support SAR
Add a new D-Bus interface to support dynamic SAR across multiple platforms. The new interface exposes methods to configure sar power levels, handle the communications with the modem, and let the platform code be agnostic to modem type.
-rw-r--r--introspection/all.xml1
-rw-r--r--introspection/org.freedesktop.ModemManager1.Modem.Sar.xml66
2 files changed, 67 insertions, 0 deletions
diff --git a/introspection/all.xml b/introspection/all.xml
index 57c28d05..a3afac49 100644
--- a/introspection/all.xml
+++ b/introspection/all.xml
@@ -16,6 +16,7 @@
<xi:include href="org.freedesktop.ModemManager1.Modem.Location.xml"/>
<xi:include href="org.freedesktop.ModemManager1.Modem.Time.xml"/>
<xi:include href="org.freedesktop.ModemManager1.Modem.Firmware.xml"/>
+ <xi:include href="org.freedesktop.ModemManager1.Modem.Sar.xml"/>
<xi:include href="org.freedesktop.ModemManager1.Modem.Signal.xml"/>
<xi:include href="org.freedesktop.ModemManager1.Modem.Oma.xml"/>
diff --git a/introspection/org.freedesktop.ModemManager1.Modem.Sar.xml b/introspection/org.freedesktop.ModemManager1.Modem.Sar.xml
new file mode 100644
index 00000000..1c96617a
--- /dev/null
+++ b/introspection/org.freedesktop.ModemManager1.Modem.Sar.xml
@@ -0,0 +1,66 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+
+<!--
+ ModemManager 1.0 Interface Specification
+
+ Copyright (C) 2020 Google, Inc.
+-->
+
+<node name="/" xmlns:doc="http://www.freedesktop.org/dbus/1.0/doc.dtd">
+
+ <!--
+ org.freedesktop.ModemManager1.Modem.Sar:
+ @short_description: The ModemManager dynamic SAR interface.
+
+ The SAR interface defines operations and properties for dynamic SAR.
+ -->
+ <interface name="org.freedesktop.ModemManager1.Modem.Sar">
+
+ <!--
+ Enable:
+ @enable: %TRUE to enable dynamic SAR and %FALSE to disable it.
+
+ Enable or disable dynamic SAR.
+
+ When enabled, the modem's output power level can be dynamically updated
+ by the host.
+
+ When disabled, the modem's output power level is dynamically updated
+ exclusively by the device.
+ -->
+ <method name="Enable">
+ <arg name="enable" type="b" direction="in" />
+ </method>
+
+ <!--
+ SetPowerLevel:
+ @level: Index of the SAR power level mapping table.
+
+ Set current dynamic SAR power level for all antennas on the device.
+
+ Please check with your modem vendor for detailed description on the
+ number of levels and corresponding power output for each level.
+
+ The index set here will apply to all antennas on the system.
+ -->
+ <method name="SetPowerLevel">
+ <arg name="level" type="u" direction="in" />
+ </method>
+
+ <!--
+ State:
+
+ Boolean indicating whether dynamic SAR is currently enabled.
+ -->
+ <property name="State" type="b" access="read" />
+
+ <!--
+ PowerLevel:
+
+ Current index of the SAR power level mapping table that is being used
+ for setting the output power of all antennas on the system.
+ -->
+ <property name="PowerLevel" type="u" access="read" />
+
+ </interface>
+</node>