examples: new network-scan-python example

This is currently not working completely ok because python doesn't
know how to free the GList of MMModem3gppNetwork elements.

  /org/freedesktop/ModemManager1/Modem/1: starting network scan...
  21403: Orange - Orange (unknown, forbidden)
  21401: vodafone ES - vodafone ES (unknown, forbidden)
  21403: Orange - Orange (unknown, forbidden)
  21403: Orange - Orange (unknown, forbidden)
  21401: vodafone ES - vodafone ES (unknown, forbidden)
  21404: Yoigo - Yoigo (unknown, forbidden)
  21401: vodafone ES - vodafone ES (unknown, forbidden)
  21404: Yoigo - Yoigo (unknown, forbidden)
  21407: Movistar - Movistar (unknown, available)
  21407: Movistar - Movistar (unknown, available)
  21407: Movistar - Movistar (unknown, current)
  free(): invalid pointer
  Aborted
This commit is contained in:
Aleksander Morgado
2019-12-13 15:38:33 +01:00
parent f9e26fb54b
commit 248cd55f0e
5 changed files with 79 additions and 1 deletions

View File

@@ -0,0 +1,17 @@
The network-scan-python program makes use of the 'libmm-glib' library through
GObject Introspection to talk to ModemManager.
The program will:
* Detect whether ModemManager is found in the bus
* Loop through each modem found in the system, running a network scan for each
The output will look like this:
$ ./network-scan-python
Note that the program requires ModemManager and libmm-glib to be installed in
the system and the introspection typelibs available in the standard paths.
Have fun!