aboutsummaryrefslogtreecommitdiff
path: root/libmm-glib/mm-manager.c
AgeCommit message (Collapse)Author
2024-12-01api: Add Cell Broadcast supportGuido Günther
Add access to the modem's CellBroadcast interface and to fetch Cell Broadcast messages. Closes: https://gitlab.freedesktop.org/mobile-broadband/ModemManager/-/issues/253 Signed-off-by: Guido Günther <agx@sigxcpu.org>
2021-11-16libmm-glib: fix license in sourcesAleksander Morgado
The libmm-glib library is LGPLv2+, not GPLv2+.
2021-10-13docs,libmm-glib: add SAR user-level apilvmaorui
2021-09-07libmm-glib,manager: fix warning with -Wdiscarded-qualifiersAleksander Morgado
In file included from /usr/include/glib-2.0/glib.h:50, from ../libmm-glib/mm-common-helpers.h:18, from ../libmm-glib/mm-manager.c:27: /usr/include/glib-2.0/glib/ghash.h:68:61: note: expected ‘gpointer’ {aka ‘void *’} but argument is of type ‘const char *’ 68 | gpointer key, | ~~~~~~~~~~~~~~~~^~~ ../libmm-glib/mm-manager.c:81:43: warning: passing argument 2 of ‘g_hash_table_insert’ discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers] 81 | g_hash_table_insert (lookup_hash, "org.freedesktop.ModemManager1.Modem.Simple", GSIZE_TO_POINTER (MM_TYPE_MODEM_SIMPLE)); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ In file included from /usr/include/glib-2.0/glib.h:50, from ../libmm-glib/mm-common-helpers.h:18, from ../libmm-glib/mm-manager.c:27:
2021-05-22libmm-glib: setup common helper to register DBus errorsAleksander Morgado
2021-04-29api,modem: new Modem3gpp.ProfileManager interfaceAleksander Morgado
This new interface allows modems to expose the list of available connection profiles stored in the device and edit or delete them; as long as the underlying device/protocol allows it.
2019-10-28docs,libmm-glib: provide per-version indicesAleksander Morgado
2019-01-13libmm-glib,manager: use g_async_initable_new_finish() explicitlyAleksander Morgado
We're running g_async_initable_new_async() ourselves in mm_manager_new(), so our finish() method should call g_async_initable_new_finish() explicitly. There's no change in the logic here, as the generated mm_gdbus_object_manager_client_new_finish() was already doing this implicitly.
2019-01-13libmm-glib,manager: simplify object creationAleksander Morgado
The G_OBJECT() casts accept NULL safely.
2019-01-13libmm-glib,manager: cleanup internal proxy on name owner updatesAleksander Morgado
The MMManager object keeps an internal proxy object for the Manager interface, and we must make sure we cleanup this object any time the MM daemon is restarted. Otherwise, the MMManager may end up trying to use a stale proxy associated to a previous run of the daemon, and e.g. not showing properly the runtime version info. E.g., in this sequence with the example python tester, the runtime version of the daemon was valid only for the first time the daemon runs, and if the daemon is restarted, mm_manager_get_version() would keep returning NULL. $ ./modem-watcher-python [ModemWatcher] ModemManager service not available in bus [ModemWatcher] ModemManager 1.9.990 service is available in bus [ModemWatcher] Dell Inc. (DW5821e Snapdragon X20 LTE) modem managed by ModemManager [None]: /org/freedesktop/ModemManager1/Modem/0 [ModemWatcher] ModemManager service not available in bus [ModemWatcher] ModemManager None service is available in bus [ModemWatcher] Dell Inc. (DW5821e Snapdragon X20 LTE) modem managed by ModemManager [None]: /org/freedesktop/ModemManager1/Modem/0 [ModemWatcher] ModemManager service not available in bus [ModemWatcher] ModemManager None service is available in bus [ModemWatcher] Dell Inc. (DW5821e Snapdragon X20 LTE) modem managed by ModemManager [None]: /org/freedesktop/ModemManager1/Modem/0
2019-01-03api,manager: new InhibitDevice() methodAleksander Morgado
This new method allows users of the ModemManager API to take full control of a given device. Unlike other operations in the API, the inhibition is maintained as long as the caller exists in the bus, or until the same caller uninhibits the device. https://gitlab.freedesktop.org/mobile-broadband/ModemManager/issues/98
2018-12-07libmm-glib: fix mm_manager_scan() operationAleksander Morgado
The reporting of the operation result was reversed in the async method.
2018-12-07libmm-glib: fix mm_manager_set_logging() operationAleksander Morgado
The reporting of the operation result was reversed in the async method.
2018-12-04api,manager: new 'Version' propertyAleksander Morgado
This string shows the runtime version of the ModemManager daemon. https://gitlab.freedesktop.org/mobile-broadband/ModemManager/issues/94
2018-12-04libmm-glib,manager: fix manager interface proxy creationAleksander Morgado
We were re-using the GDBusObjectManagerClientFlags set in the MMManager object as GDBusProxyFlags for the Manager1 interface proxy object, and that was completely broken. Instead of setting "DO_NOT_AUTO_START" in the proxy, we were actually setting "DO_NOT_LOAD_PROPERTIES"...
2018-01-25*: Spelling fixesVille Skyttä
2017-06-23libmm-glib,manager: port mm_manager_scan_devices to use GTaskBen Chan
2017-06-23libmm-glib,manager: port mm_manager_set_logging to use GTaskBen Chan
2016-09-29core: allow disabling auto-scan and notifying ports one by one via APIAleksander Morgado
This commit enables a new core ModemManager daemon option, so that automatic detection of available modems is totally disabled: '--no-auto-scan'. Note that this option also replaces the previously used '--test-no-auto-scan' option, which was only used during tests. Along with the new ModemManager option, a new ReportKernelEvent() method in the API is defined, which allows notifying the daemon of which interfaces it should be accessing, as well as the main details of each interface. The only mandatory parameters in the new method are 'action' (add/remove), 'name' (the name of the interface) and 'subsystem' (the subsystem of the interface). The mmcli tool has support for using the new api method via several new options: * The '--report-kernel-event' option allows specifying device ports one by one, and is a direct mapping of the ReportKernelEvent() method: $ sudo mmcli --report-kernel-event="action=add,name=wwan0,subsystem=net" $ sudo mmcli --report-kernel-event="action=add,name=cdc-wdm0,subsystem=usbmisc" * The '--report-kernel-event-auto-scan' option uses udev monitoring to notify events automatically to the daemon. This allows to operate in a way equivalent to the default daemon operation (with implicit auto-scan). Worth noting that the ReportKernelEvent() method is only usable when '--no-auto-scan' is explicitly used in the daemon. An error will be reported if the method is tried while standard udev monitoring is enabled (implicit if auto scan isn't explicitly disabled in the daemon). If mmcli is going to be used only to report 'real time' events, an optional '--initial-kernel-events=[PATH]' may be given in the ModemManager call to automatically process a set of port kernel events one by one on boot. The file may e.g. contain: action=add,name=wwan0,subsystem=net action=add,name=cdc-wdm0,subsystem=usbmisc
2015-08-02fixes: added voice support in libmm-glib MMManager, also fixed wrong number ↵Riccardo Vangelisti
of parameters in mm-call-list class init
2013-09-09libmm-glib: support for the 'OMA' interfaceAleksander Morgado
2013-08-21libmm-glib: handle the new 'Signal' interfaceAleksander Morgado
2013-06-18api,introspection: avoid exposing the Contacts interfaceAleksander Morgado
There is no implementation of the Contacts interface yet, just avoid exposing it for now. https://bugzilla.gnome.org/show_bug.cgi?id=701989
2013-04-29mm-glib: use correct enum typeYunlian Jiang
2013-02-06libmm-glib,manager: add missing logic to ensure the proxy is createdAleksander Morgado
2013-02-06libmm-glib,manager: don't fail creation if the ModemManager process is not foundAleksander Morgado
A 'GDBusObjectManagerClient' for a service for which there is no current name-owner is a perfectly valid and useful object. For example, we could then connect to the 'notify::name-owner' property to follow the life cycle of the ModemManager process. So, don't tie the successful creation of a 'MMManager' to the successful creation of the internal GDBusProxy for the 'Manager1' interface. If there is no current name owner, the GDBusProxy wouldn't be created, and instead we would completely fail the 'MMManager' creation.
2013-02-06libmm-glib: fix error reporting when 'MMManager' is createdAleksander Morgado
2012-11-27libmm-glib,manager: client creation may fail, avoid explicit MM_MANAGER() castAleksander Morgado
2012-11-15libmm-glib,manager: register DBus error associations in advanceAleksander Morgado
In order to have a proper conversion between DBus error names and GErrors for our known domains, the associations need to be registered before any DBus call attempt. Given that the high-level API of libmm-glib has its entry point always in the MMManager, just register them as soon as the first such object is created.
2012-11-07libmm-glib,manager: avoid unref of unset cancellablesAleksander Morgado
2012-10-04libmm-glib: remove the `libmm-common.h' headerAleksander Morgado
Both the ModemManager daemon and the mmcli will now include `libmm-glib.h' only. We also handle two new special `_LIBMM_INSIDE_MM' and `LIBMM_INSIDE_MMCLI' symbols, which if included before the `libmm-glib.h' library allow us to: * Don't include the libmm-glib high level API in the ModemManager daemon, as the object names would clash with those in the core. * Define some of the methods of helper objects to be included only if compiling ModemManager daemon or the mmcli.
2012-10-04libmm-glib,manager: minor indentation fixesAleksander Morgado
2012-10-04libmm-glib,firmware: new `MMModemFirmware' type to handle the Firmware interfaceAleksander Morgado
2012-10-02libmm-glib,time: `MMModemTime' is now a real objectAleksander Morgado
Not just a typedef of the gdbus-codegen generated `MmGdbusModemTime'.
2012-10-02libmm-glib,simple: `MMModemSimple' is now a real objectAleksander Morgado
Not just a typedef of the gdbus-codegen generated `MmGdbusModemSimple'.
2012-10-02libmm-glib,messaging: `MMModemMessaging' is now a real objectAleksander Morgado
Not just a typedef of the gdbus-codegen generated `MmGdbusModemMessaging'.
2012-10-02libmm-glib,location: `MMModemLocation' is now a real objectAleksander Morgado
Not just a typedef of the gdbus-codegen generated `MmGdbusModemLocation'.
2012-10-02libmm-glib,cdma: `MMModemCdma' is now a real objectAleksander Morgado
Not just a typedef of the gdbus-codegen generated `MmGdbusModemCdma'.
2012-10-02libmm-glib,3gpp-ussd: `MMModem3gppUssd' is now a real objectAleksander Morgado
Not just a typedef of the gdbus-codegen generated `MmGdbusModem3gppUssd'.
2012-10-02libmm-glib,3gpp: `MMModem3gpp' is now a real objectAleksander Morgado
Not just a typedef of the gdbus-codegen generated `MmGdbusModem3gpp'.
2012-10-01libmm-glib,modem: `MMModem' is now a real objectAleksander Morgado
Not just a typedef of the gdbus-codegen generated `MmGdbusModem'.
2012-10-01libmm-glib,object: `MMObject' is now a real objectAleksander Morgado
Not just a typedef of the gdbus-codegen generated `MmGdbusObject'.
2012-10-01libmm-glib,manager: cleanup object implementationAleksander Morgado
2012-10-01libmm-glib,manager: allow specifying the generated proxy types ourselvesAleksander Morgado
2012-07-31cli,libmm-glib: provide mm_manager_(peek|get)_proxy()Aleksander Morgado
peek() doesn't increase the reference count of the proxy object, while get() does it.
2012-07-31cli,libmm-glib: set default timeout on manager DBus proxyBen Chan
This patch fixes mmcli to set the default timeout on the manager proxy interface (MmGdbusOrgFreedesktopModemManager1) instead of MMManager itself. The later is not a GDBusProxy object.
2012-03-15libmm-glib: setup build of the libmm-glib libraryAleksander Morgado
The library will contain a small layer of code on top of the proxies and object manager client generated by gdbus-codegen. Therefore, the headers auto-generated from the DBus introspection XMLs need to be distributed along with the libmm-glib specific headers.