[PATCH] stemodem: Fix for MT call not working when caller id is hidden.
by Marit Henriksen
From: Marit Henriksen <marit.henriksen(a)stericsson.com>
In *ECAV, the number will not be included if caller id is hidden.
Set it to an empty string in that case.
---
drivers/stemodem/voicecall.c | 10 +++++++---
1 files changed, 7 insertions(+), 3 deletions(-)
diff --git a/drivers/stemodem/voicecall.c b/drivers/stemodem/voicecall.c
index b9d91d2..d900666 100644
--- a/drivers/stemodem/voicecall.c
+++ b/drivers/stemodem/voicecall.c
@@ -442,10 +442,14 @@ static void ecav_notify(GAtResult *result, gpointer user_data)
if (status == CALL_STATUS_DIALING ||
status == CALL_STATUS_WAITING ||
status == CALL_STATUS_INCOMING) {
+ /*
+ * If caller uses hidden id, the number and
+ * number type might not be present. Don't
+ * look for type if number is not present.
+ */
if (!g_at_result_iter_next_string(&iter, &num))
- return;
-
- if (!g_at_result_iter_next_number(&iter, &num_type))
+ num = "";
+ else if (!g_at_result_iter_next_number(&iter, &num_type))
return;
}
--
1.7.1
11 years, 9 months
Voice call audio routing
by Nicola Mfb
While testing an e169 huawei card I was able to make voice calls and
hear something with aplay and /dev/ttyUSB1.
On the openmoko/freerunner is a matter of HW switches, on the n900
IIRC is done with pulseaudio.
I guess that voice call audio routing is not in oFono plans, if I'm
correct is there a reference project (may be not depending deeply on
meego) that abstracts that task in an extensible/pluggable way?
Regards
Niko
11 years, 9 months
[PATCH 0/4] Emergency Calls
by Andras Domokos
Steps in handling emergency calls:
- subscribe to modem online notifications
- emergency call detected (phone number is an emergency number)
- increment emergency mode
- advertise "Emergency" property change on D-Bus (first call)
- set modem online (minimal setup) if mode was offline
- adevertise "Online" property change on D-Bus
- if modem is not online postpone making the call, otherwise make
the emergency call
- when modem online notification comes and there is postponed emergency call
request, make the emergency call
- when an emergency call ends decrement emergency mode
- set modem to pre emergency call state (last call)
- advertise "Online" property change on D-Bus (if any)
- advertise "Emergency" property change on D-Bus (last call)
Andras Domokos (3):
modem: add Emergency property
modem: move dial request_cb function
voicecall: add emergency call handling
src/dbus.c | 7 ++
src/modem.c | 207 ++++++++++++++++++++++++++++++++++++++++++++++++++++++-
src/ofono.h | 5 ++
src/voicecall.c | 186 ++++++++++++++++++++++++++++++++++++++++---------
4 files changed, 369 insertions(+), 36 deletions(-)
11 years, 9 months
[PATCH] test: add a script for STK conformance tests
by Lucas, GuillaumeX
From: Guillaume Lucas <guillaumex.lucas(a)intel.com>
To be able to run STK conformance tests at ofono
level, we need to have a STK agent registered. The
test-stk-conformance script provided here do that.
This script is for conformance so all the data input
of the agent are displayed to be able to check them.
The existing test-stk-menu is usable only when there
is a STK menu provided by the (U)SIM card.
---
test/test-stk-conformance | 226 +++++++++++++++++++++++++++++++++++++++++++++
1 files changed, 226 insertions(+), 0 deletions(-)
create mode 100755 test/test-stk-conformance
diff --git a/test/test-stk-conformance b/test/test-stk-conformance
new file mode 100755
index 0000000..bb28e40
--- /dev/null
+++ b/test/test-stk-conformance
@@ -0,0 +1,226 @@
+#!/usr/bin/python
+
+import gobject
+
+import sys
+import dbus
+import dbus.service
+import dbus.mainloop.glib
+import os
+
+class GoBack(dbus.DBusException):
+ _dbus_error_name = "org.ofono.Error.GoBack"
+
+class EndSession(dbus.DBusException):
+ _dbus_error_name = "org.ofono.Error.EndSession"
+
+class Busy(dbus.DBusException):
+ _dbus_error_name = "org.ofono.Error.Busy"
+
+class StkAgent(dbus.service.Object):
+ exit_on_release = True
+
+ def set_exit_on_release(self, exit_on_release):
+ self.exit_on_release = exit_on_release
+
+ @dbus.service.method("org.ofono.SimToolkitAgent",
+ in_signature="", out_signature="")
+ def Release(self):
+ print "Release"
+ if self.exit_on_release:
+ mainloop.quit()
+
+ @dbus.service.method("org.ofono.SimToolkitAgent",
+ in_signature="sya(sy)n", out_signature="y")
+ def RequestSelection(self, title, icon, items, default):
+ print "Title: (%s)" % (title)
+ print "Icon: (%d)" % (icon)
+ index = 0;
+ for item in items:
+ print "%d. %s (icon: %d)" % (index, item[0], item[1])
+ index += 1
+
+ print "\nDefault: %d" % (default)
+ select = raw_input("Enter Selection (t, b):")
+
+ if select == 'b':
+ raise GoBack("User wishes to go back")
+ elif select == 't':
+ raise EndSession("User wishes to terminate session")
+ else:
+ return int(select);
+
+ @dbus.service.method("org.ofono.SimToolkitAgent",
+ in_signature="syb", out_signature="")
+ def DisplayText(self, title, icon, urgent):
+ print "DisplayText (%s)" % (title)
+ print "Icon: (%d)" % (icon)
+ print "Urgent: (%d)" % (urgent)
+ userin = raw_input("Press return to clear ('t' terminates, "
+ "'b' goest back, 'n' busy):")
+
+ if userin == 'b':
+ raise GoBack("User wishes to go back")
+ elif userin == 't':
+ raise EndSession("User wishes to terminate session")
+ elif userin == 'n':
+ raise Busy("User wishes to simulate busy screen")
+
+ @dbus.service.method("org.ofono.SimToolkitAgent",
+ in_signature="sysyyb", out_signature="s")
+ def RequestInput(self, title, icon, default, min_chars, max_chars,
+ hide_typing):
+ print "Title: (%s)" % (title)
+ print "Icon: (%d)" % (icon)
+ print "Default: (%s)" % (default)
+ print "Hide typing: (%s)" % (hide_typing)
+ print "Enter characters, min: %d, max: %d:" % (min_chars,
+ max_chars)
+ userin = raw_input("")
+
+ return userin
+
+ @dbus.service.method("org.ofono.SimToolkitAgent",
+ in_signature="sysyyb", out_signature="s")
+ def RequestDigits(self, title, icon, default, min_chars, max_chars,
+ hide_typing):
+ print "Title: (%s)" % (title)
+ print "Icon: (%d)" % (icon)
+ print "Default: (%s)" % (default)
+ print "Hide typing: (%s)" % (hide_typing)
+ print "Enter digits, min: %d, max: %d:" % (min_chars,
+ max_chars)
+ userin = raw_input("'t' terminates, 'b' goes back:");
+
+ if userin == 'b':
+ raise GoBack("User wishes to go back")
+ elif userin == 't':
+ raise EndSession("User wishes to terminate session")
+ else:
+ return userin
+
+ @dbus.service.method("org.ofono.SimToolkitAgent",
+ in_signature="sy", out_signature="s")
+ def RequestKey(self, title, icon):
+ print "Title: (%s)" % (title)
+ print "Icon: (%d)" % (icon)
+ key = raw_input("Enter Key (t, b):")
+
+ if key == 'b':
+ raise GoBack("User wishes to go back");
+ elif key == 't':
+ raise EndSession("User wishes to terminate session");
+ else:
+ return key
+
+ @dbus.service.method("org.ofono.SimToolkitAgent",
+ in_signature="sy", out_signature="s")
+ def RequestDigit(self, title, icon):
+ print "Title: (%s)" % (title)
+ print "Icon: (%d)" % (icon)
+ key = raw_input("Enter Digit (t, b):")
+
+ if key == 'b':
+ raise GoBack("User wishes to go back");
+ elif key == 't':
+ raise EndSession("User wishes to terminate session");
+ else:
+ return key
+
+ @dbus.service.method("org.ofono.SimToolkitAgent",
+ in_signature="sy", out_signature="b")
+ def RequestConfirmation(self, title, icon):
+ print "Title: (%s)" % (title)
+ print "Icon: (%d)" % (icon)
+ key = raw_input("Enter Confirmation (t, b, y, n):")
+
+ if key == 'b':
+ raise GoBack("User wishes to go back");
+ elif key == 't':
+ raise EndSession("User wishes to terminate session");
+ elif key == 'y':
+ return True
+ else:
+ return False
+
+ @dbus.service.method("org.ofono.SimToolkitAgent",
+ in_signature="sy", out_signature="b")
+ def ConfirmCallSetup(self, info, icon):
+ print "Information: (%s)" % (info)
+ print "Icon: (%d)" % (icon)
+ key = raw_input("Enter Confirmation (t, y, n):")
+
+ if key == 't':
+ raise EndSession("User wishes to terminate session");
+ elif key == 'y':
+ return True
+ else:
+ return False
+
+ @dbus.service.method("org.ofono.SimToolkitAgent",
+ in_signature="ssy", out_signature="")
+ def PlayTone(self, tone, title, icon):
+ print "PlayTone: (%s, %s, %d)" % (tone, title, icon)
+ userin = raw_input("Press enter to end playing (t):")
+
+ if userin == 't':
+ raise EndSession("User wishes to terminate session")
+
+ @dbus.service.method("org.ofono.SimToolkitAgent",
+ in_signature="ssy", out_signature="")
+ def LoopTone(self, tone, title, icon):
+ print "LoopTone: (%s, %s, %d)" % (tone, title, icon)
+ userin = raw_input("Press enter to end playing (t):")
+
+ if userin == 't':
+ raise EndSession("User wishes to terminate session")
+
+ @dbus.service.method("org.ofono.SimToolkitAgent",
+ in_signature="", out_signature="")
+ def Cancel(self):
+ print "Cancel"
+
+def property_changed(name, value):
+ print "SimToolkit property: '%s' changed to '%s'" % (name, value)
+
+def stdin_handler(fd, condition):
+ s = os.read(fd.fileno(), 160).rstrip()
+
+ if s == 't':
+ stk.UnregisterAgent(path)
+ mainloop.quit()
+
+ return True
+
+if __name__ == '__main__':
+ dbus.mainloop.glib.DBusGMainLoop(set_as_default=True)
+
+ bus = dbus.SystemBus()
+ manager = dbus.Interface(bus.get_object("org.ofono", "/"),
+ "org.ofono.Manager")
+
+ modems = manager.GetModems()
+
+ for path, properties in modems:
+ if "org.ofono.SimToolkit" not in properties["Interfaces"]:
+ continue
+
+ stk = dbus.Interface(bus.get_object('org.ofono', path),
+ 'org.ofono.SimToolkit')
+
+ stk.connect_to_signal("PropertyChanged", property_changed)
+
+ properties = stk.GetProperties()
+
+ path = "/test/agent"
+ agent = StkAgent(bus, path)
+
+ stk.RegisterAgent(path)
+
+ gobject.io_add_watch(sys.stdin, gobject.IO_IN, stdin_handler)
+
+ print "STK Agent is now registered"
+ print "Use t + <return> to quit the program when there is no session on going"
+
+ mainloop = gobject.MainLoop()
+ mainloop.run()
--
1.7.0.4
---------------------------------------------------------------------
Intel Corporation SAS (French simplified joint stock company)
Registered headquarters: "Les Montalets"- 2, rue de Paris,
92196 Meudon Cedex, France
Registration Number: 302 456 199 R.C.S. NANTERRE
Capital: 4,572,000 Euros
This e-mail and any attachments may contain confidential material for
the sole use of the intended recipient(s). Any review or distribution
by others is strictly prohibited. If you are not the intended
recipient, please contact the sender and delete all copies.
11 years, 9 months
[PATCH v2] ifx: Adding modem selftest to Infineon modem
by Robertino Benis
Hi all,
This is a second attempt to submit a patch that triggers Infineon
modem selftest during ofono boot. Patch addresses issues raised
by Marcel from the previous submission.
Thank you,
-- r.
---
plugins/ifx.c | 87 +++++++++++++++++++++++++++++++++++++++++++++++++++++----
1 files changed, 81 insertions(+), 6 deletions(-)
diff --git a/plugins/ifx.c b/plugins/ifx.c
index 2f4c65b..3647dbc 100644
--- a/plugins/ifx.c
+++ b/plugins/ifx.c
@@ -71,6 +71,8 @@
#define GPRS3_DLC 4
#define AUX_DLC 5
+#define IFX_SELF_TESTS_TIMEOUT 5
+
static char *dlc_prefixes[NUM_DLC] = { "Voice: ", "Net: ", "GPRS1: ",
"GPRS2: ", "GPRS3: ", "Aux: " };
@@ -80,6 +82,18 @@ static const char *dlc_nodes[NUM_DLC] = { "/dev/ttyGSM1", "/dev/ttyGSM2",
static const char *none_prefix[] = { NULL };
static const char *xdrv_prefix[] = { "+XDRV:", NULL };
+static const char *empty_prefix[] = { "", NULL };
+
+struct ifx_self_tests {
+ char *test_desc;
+ char *at_cmd;
+};
+
+static const struct ifx_self_tests mst[] = {
+ { "RTC GTI Test", "at@rtc:rtc_gti_test_verify_32khz()" },
+ { "Device Version Test", "at@vers:device_version_id()" },
+ { NULL, NULL }
+};
struct ifx_data {
GIOChannel *device;
@@ -99,6 +113,8 @@ struct ifx_data {
int audio_loopback;
struct ofono_sim *sim;
gboolean have_sim;
+ guint self_test_timeout;
+ int self_test_idx;
};
static void ifx_debug(const char *str, void *user_data)
@@ -545,6 +561,64 @@ static gboolean mux_timeout_cb(gpointer user_data)
return FALSE;
}
+static gboolean self_test_timeout_cb(gpointer user_data)
+{
+ struct ofono_modem *modem = user_data;
+ struct ifx_data *data = ofono_modem_get_data(modem);
+
+ ofono_error("Modem %s: TIMED OUT",
+ mst[data->self_test_idx].test_desc);
+
+ g_source_remove(data->self_test_timeout);
+ data->self_test_timeout = 0;
+
+ shutdown_device(data);
+ ofono_modem_set_powered(modem, FALSE);
+
+ return FALSE;
+}
+
+static void ifx_self_test_cb(gboolean ok, GAtResult *result,
+ gpointer user_data)
+{
+ struct ofono_modem *modem = user_data;
+ struct ifx_data *data = ofono_modem_get_data(modem);
+
+ if (data->self_test_timeout > 0) {
+ g_source_remove(data->self_test_timeout);
+ data->self_test_timeout = 0;
+ }
+
+ if (!ok) {
+ ofono_error("Modem %s: FAIL",
+ mst[data->self_test_idx].test_desc);
+ shutdown_device(data);
+ ofono_modem_set_powered(modem, FALSE);
+
+ return;
+ }
+
+ data->self_test_idx++;
+
+ if (mst[data->self_test_idx].at_cmd != NULL) {
+ g_at_chat_send(data->dlcs[AUX_DLC],
+ mst[data->self_test_idx].at_cmd,
+ empty_prefix, ifx_self_test_cb, modem, NULL);
+
+ data->self_test_timeout = g_timeout_add_seconds(
+ IFX_SELF_TESTS_TIMEOUT, self_test_timeout_cb, modem);
+
+ } else { /* Enable MUX Channels */
+ data->frame_size = 1509;
+ g_at_chat_send(data->dlcs[AUX_DLC],
+ "AT+CMUX=0,0,,1509,10,3,30,,", NULL,
+ mux_setup_cb, modem, NULL);
+
+ data->mux_init_timeout = g_timeout_add_seconds(5,
+ mux_timeout_cb, modem);
+ }
+}
+
static int ifx_enable(struct ofono_modem *modem)
{
struct ifx_data *data = ofono_modem_get_data(modem);
@@ -598,15 +672,16 @@ static int ifx_enable(struct ofono_modem *modem)
g_at_chat_send(chat, "ATE0 +CMEE=1", NULL,
NULL, NULL, NULL);
- data->frame_size = 1509;
+ /* Execute Modem Self tests */
- g_at_chat_send(chat, "AT+CMUX=0,0,,1509,10,3,30,,", NULL,
- mux_setup_cb, modem, NULL);
+ data->dlcs[AUX_DLC] = chat;
+ data->self_test_idx = 0;
- data->mux_init_timeout = g_timeout_add_seconds(5, mux_timeout_cb,
- modem);
+ g_at_chat_send(data->dlcs[AUX_DLC], mst[data->self_test_idx].at_cmd,
+ empty_prefix, ifx_self_test_cb, modem, NULL);
- data->dlcs[AUX_DLC] = chat;
+ data->self_test_timeout = g_timeout_add_seconds(IFX_SELF_TESTS_TIMEOUT,
+ self_test_timeout_cb, modem);
return -EINPROGRESS;
}
--
1.7.0.4
11 years, 9 months
[PATCH -v3 1/5] modem: only unref pending if it is a powered pending
by Gustavo F. Padovan
---
src/modem.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/src/modem.c b/src/modem.c
index 52e647b..d6ab316 100644
--- a/src/modem.c
+++ b/src/modem.c
@@ -804,7 +804,7 @@ void ofono_modem_set_powered(struct ofono_modem *modem, ofono_bool_t powered)
modem->timeout = 0;
}
- if (modem->pending != NULL) {
+ if (modem->powered_pending != powered && modem->pending != NULL) {
DBusMessage *reply;
if (powered == modem->powered_pending)
--
1.7.3.2
11 years, 9 months
[PATCH v2] TODO: Add CDMA Voicecall Support Tasks
by Dara Spieker-Doyle
---
TODO | 58 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
1 files changed, 58 insertions(+), 0 deletions(-)
diff --git a/TODO b/TODO
index 8d771d6..cbcdac5 100644
--- a/TODO
+++ b/TODO
@@ -484,3 +484,61 @@ Miscellaneous
Priority: Medium
Complexity: C2
Owner: Sjur Brændeland <sjur.brandeland(a)stericsson.com>
+
+CDMA Voicecall
+==============
+
+- Add support for Mobile Originated and Mobile Terminated Voice Call over
+ a CDMA network. This includes management of call state and providing
+ appropriate values for the LineIdentification in each case.
+
+ Priority: High
+ Complexity: C2
+ Owner: Dara Spieker-Doyle <dara.spieker-doyle(a)nokia.com>
+
+- Add support for Three-Way Calling over a CDMA network. Three-Way Calling
+ provides the subscriber with the capability to add a third party to an
+ established two-party call, so that all three parties may communicate in a
+ three-way call.
+
+ In CDMA mode, the originating subscriber of a current conversation can
+ request for a third party to be added to a conversation by sending a Flash
+ With Information Message (FWIM) with dialed digits to the network. Upon
+ setting up a two-way conversation with the added party, the originating
+ subscriber can request to establish a three-way conversation by sending
+ another Flash With Information Message. Upon receiving the second Flash With
+ Information Message, the MSC reconnects the original party to the
+ conversation thus completing the setup of a three-way conversation.
+
+ CDMA Three-Way Calling is described by Figure B-5 in 3GPP2 C.S0005-E Version
+ 2.0.
+
+ Priority: High
+ Complexity: C2
+ Owner: Dara Spieker-Doyle <dara.spieker-doyle(a)nokia.com>
+
+- Add support for Call Waiting over a CDMA network. Call Waiting (CW) provides
+ notification of an incoming call to an originating subscriber, while the
+ subscriber's call is in the 2-way state. Subsequently, the originating
+ subscriber can either answer or ignore the incoming call. If the originating
+ subscriber answers the second call, it may alternate between the two calls.
+
+ In CDMA mode, the originating subscriber of a current conversation will
+ receive either a Flash With Information Message or an Alert With Information
+ Message from the network if there is an additional mobile terminated voice
+ call incoming. The originating subscriber can change conversation parties by
+ sending a Flash With Information Message to the network and the MSC will
+ toggle the speech path between the two conversations.
+
+ CDMA Call Waiting is described by Figure B-6 in 3GPP2 C.S0005-E Version
+ 2.0.
+
+ Priority: High
+ Complexity: C2
+ Owner: Dara Spieker-Doyle <dara.spieker-doyle(a)nokia.com>
+
+- Support sending DTMF tones over CDMA network.
+
+ Priority: High
+ Complexity: C2
+ Owner: Dara Spieker-Doyle <dara.spieker-doyle(a)nokia.com>
--
1.7.0.4
11 years, 9 months
Read/Write EFcfis/EFcphs-cff files-v4
by Jeevaka Badrappan
Hi,
This patch reads and writes the call forwarding unconditional status
from and to the SIM depending on the SIM file availability. New property
needs to be added due to the fact that number won't be available from the
cphs-cff file.
Incase of SIM, EFcphs-cff file holds call forwarding status and it is
represented as a flag. In case of USIM(EFcfis), we have the status flag
and also number.So, adding new property for status and using the existing
VoiceUnconditional with number will work for both SIM and USIM cases.
Other option is to have 2 properties, "VoiceUnconditional" and "Number".
"VoiceUnconditional" will have the status of the call forwarding( "enabled",
"disabled") whereas the "Number" property will have the call forwared number.
offline-online state transitions results in caching the call forwaring status
every time. To avoid this, call forwarding atom is moved to the post sim and
its moved also due to the fact that call forwarding status doesn't change in roaming.
Regards,
Jeevaka
Jeevaka Badrappan (7):
call-forwarding: Read/Write cfis/cphs-cff
ifx: Move call forwarding to post sim
isigen: Move call forwarding to post sim
plugins/n900: Move call forwarding to post sim
phonesim: Move call forwarding to post sim
doc: Add new property to call forwarding
TODO: Marking the Read/Write EFcfis task as done
TODO | 9 --
doc/call-forwarding-api.txt | 5 +
doc/features.txt | 5 +
plugins/ifx.c | 2 +-
plugins/isigen.c | 2 +-
plugins/n900.c | 2 +-
plugins/phonesim.c | 3 +-
src/call-forwarding.c | 246 ++++++++++++++++++++++++++++++++++++++++++-
8 files changed, 260 insertions(+), 14 deletions(-)
11 years, 9 months
[PATCH] test/list-modems : print Strength as an integer
by "Benoît Monin"
org.ofono.NetworkRegistration property Strength is an integer,
so print it as such.
---
test/list-modems 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/test/list-modems b/test/list-modems
index 557efd5..8c075ac 100755
--- a/test/list-modems
+++ b/test/list-modems
@@ -51,7 +51,8 @@ for path, properties in modems:
elif key in ["MobileNetworkCodeLength",
"VoicemailMessageCount",
"MicrophoneVolume",
- "SpeakerVolume"]:
+ "SpeakerVolume",
+ "Strength"]:
val = int(properties[key])
elif key in ["MainMenu"]:
val = ", ".join([ text + " (" + str(int(icon)) +
--
1.7.0.3
11 years, 9 months
[PATCH v2 9/9] test: Add CDMA MO Call Support
by Dara Spieker-Doyle
---
Makefile.am | 5 ++++-
test/cdma-dial-number | 24 ++++++++++++++++++++++++
test/cdma-hangup | 20 ++++++++++++++++++++
test/cdma-list-call | 30 ++++++++++++++++++++++++++++++
4 files changed, 78 insertions(+), 1 deletions(-)
create mode 100755 test/cdma-dial-number
create mode 100755 test/cdma-hangup
create mode 100755 test/cdma-list-call
diff --git a/Makefile.am b/Makefile.am
index 9949bcc..d0d269a 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -434,7 +434,10 @@ test_scripts = test/backtrace \
test/test-push-notification \
test/test-smart-messaging \
test/send-vcard \
- test/set-tty
+ test/set-tty \
+ test/cdma-list-call \
+ test/cdma-dial-number \
+ test/cdma-hangup
if TEST
testdir = $(pkglibdir)/test
diff --git a/test/cdma-dial-number b/test/cdma-dial-number
new file mode 100755
index 0000000..e62018f
--- /dev/null
+++ b/test/cdma-dial-number
@@ -0,0 +1,24 @@
+#!/usr/bin/python
+
+import sys
+import dbus
+
+bus = dbus.SystemBus()
+
+manager = dbus.Interface(bus.get_object('org.ofono', '/'),
+ 'org.ofono.Manager')
+
+if len(sys.argv) > 2:
+ path = sys.argv[1]
+ number = sys.argv[2]
+else:
+ modems = manager.GetModems()
+ path, properties = modems[0]
+ number = sys.argv[1]
+
+print "Using modem %s" % path
+
+manager = dbus.Interface(bus.get_object('org.ofono', path),
+ 'org.ofono.cdma.VoiceCallManager')
+
+manager.Dial(number, "")
\ No newline at end of file
diff --git a/test/cdma-hangup b/test/cdma-hangup
new file mode 100755
index 0000000..f8e631e
--- /dev/null
+++ b/test/cdma-hangup
@@ -0,0 +1,20 @@
+#!/usr/bin/python
+
+import sys
+import dbus
+
+bus = dbus.SystemBus()
+
+manager = dbus.Interface(bus.get_object('org.ofono', '/'),
+ 'org.ofono.Manager')
+
+if len(sys.argv) > 2:
+ path = sys.argv[1]
+else:
+ modems = manager.GetModems()
+ path, properties = modems[0]
+
+manager = dbus.Interface(bus.get_object('org.ofono', path),
+ 'org.ofono.cdma.VoiceCallManager')
+
+manager.Hangup()
diff --git a/test/cdma-list-call b/test/cdma-list-call
new file mode 100755
index 0000000..9f9fdbc
--- /dev/null
+++ b/test/cdma-list-call
@@ -0,0 +1,30 @@
+#!/usr/bin/python
+
+import dbus
+
+bus = dbus.SystemBus()
+
+manager = dbus.Interface(bus.get_object('org.ofono', '/'),
+ 'org.ofono.Manager')
+
+modems = manager.GetModems()
+
+for path, properties in modems:
+ print "[ %s ]" % (path)
+
+ if "org.ofono.cdma.VoiceCallManager" not in properties["Interfaces"]:
+ continue
+
+ mgr = dbus.Interface(bus.get_object('org.ofono', path),
+ 'org.ofono.cdma.VoiceCallManager')
+
+ properties = mgr.GetProperties()
+
+ for key in properties.keys():
+ if key in ["Interfaces", "Features"]:
+ val = ""
+ for i in properties[key]:
+ val += i + " "
+ else:
+ val = str(properties[key])
+ print " %s = %s" % (key, val)
\ No newline at end of file
--
1.7.0.4
11 years, 9 months