All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v5, 2/5] test: Add CDMA MO Call Support
@ 2011-01-11  1:45 Dara Spieker-Doyle
  2011-01-13  5:25 ` Denis Kenzior
  0 siblings, 1 reply; 3+ messages in thread
From: Dara Spieker-Doyle @ 2011-01-11  1:45 UTC (permalink / raw)
  To: ofono

[-- Attachment #1: Type: text/plain, Size: 2936 bytes --]

---
 Makefile.am           |    5 ++++-
 test/cdma-dial-number |   25 +++++++++++++++++++++++++
 test/cdma-hangup      |   20 ++++++++++++++++++++
 test/cdma-list-call   |   31 +++++++++++++++++++++++++++++++
 4 files changed, 80 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 5f54efe..7bced88 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -445,7 +445,10 @@ test_scripts = test/backtrace \
 		test/set-tty \
 		test/set-gsm-band \
 		test/set-umts-band \
-		test/lockdown-modem
+		test/lockdown-modem \
+		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..0b3693e
--- /dev/null
+++ b/test/cdma-dial-number
@@ -0,0 +1,25 @@
+#!/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)
+
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..8a2e04e
--- /dev/null
+++ b/test/cdma-list-call
@@ -0,0 +1,31 @@
+#!/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)
+
-- 
1.7.0.4


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH v5, 2/5] test: Add CDMA MO Call Support
  2011-01-11  1:45 [PATCH v5, 2/5] test: Add CDMA MO Call Support Dara Spieker-Doyle
@ 2011-01-13  5:25 ` Denis Kenzior
  2011-01-13 18:18   ` Dara Spieker-Doyle
  0 siblings, 1 reply; 3+ messages in thread
From: Denis Kenzior @ 2011-01-13  5:25 UTC (permalink / raw)
  To: ofono

[-- Attachment #1: Type: text/plain, Size: 2164 bytes --]

Hi Dara,

On 01/10/2011 07:45 PM, Dara Spieker-Doyle wrote:
> ---
>  Makefile.am           |    5 ++++-
>  test/cdma-dial-number |   25 +++++++++++++++++++++++++
>  test/cdma-hangup      |   20 ++++++++++++++++++++
>  test/cdma-list-call   |   31 +++++++++++++++++++++++++++++++
>  4 files changed, 80 insertions(+), 1 deletions(-)
>  create mode 100755 test/cdma-dial-number
>  create mode 100755 test/cdma-hangup
>  create mode 100755 test/cdma-list-call

This patch does not apply:

Applying: test: Add CDMA MO Call Support
error: patch failed: Makefile.am:445
error: Makefile.am: patch does not apply
/home/denkenz/ofono-master/.git/rebase-apply/patch:32: new blank line at
EOF.
+
/home/denkenz/ofono-master/.git/rebase-apply/patch:89: new blank line at
EOF.
+
Patch failed at 0001 test: Add CDMA MO Call Support
When you have resolved this problem run "git am --resolved".
If you would prefer to skip this patch, instead run "git am --skip".
To restore the original branch and stop patching run "git am --abort".

Also:

<snip>

> 
> diff --git a/test/cdma-list-call b/test/cdma-list-call
> new file mode 100755
> index 0000000..8a2e04e
> --- /dev/null
> +++ b/test/cdma-list-call
> @@ -0,0 +1,31 @@
> +#!/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 + " "

You might want to remove this if statement.  There are no Interfaces or
Features properties in cdma.VoiceCallManager

> +		else:
> +			val = str(properties[key])
> +		print "    %s = %s" % (key, val)
> +

Regards,
-Denis

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH v5, 2/5] test: Add CDMA MO Call Support
  2011-01-13  5:25 ` Denis Kenzior
@ 2011-01-13 18:18   ` Dara Spieker-Doyle
  0 siblings, 0 replies; 3+ messages in thread
From: Dara Spieker-Doyle @ 2011-01-13 18:18 UTC (permalink / raw)
  To: ofono

[-- Attachment #1: Type: text/plain, Size: 2536 bytes --]

Hi Denis

On 01/12/2011 09:25 PM, ext Denis Kenzior wrote:
> Hi Dara,
>
> On 01/10/2011 07:45 PM, Dara Spieker-Doyle wrote:
>> ---
>>   Makefile.am           |    5 ++++-
>>   test/cdma-dial-number |   25 +++++++++++++++++++++++++
>>   test/cdma-hangup      |   20 ++++++++++++++++++++
>>   test/cdma-list-call   |   31 +++++++++++++++++++++++++++++++
>>   4 files changed, 80 insertions(+), 1 deletions(-)
>>   create mode 100755 test/cdma-dial-number
>>   create mode 100755 test/cdma-hangup
>>   create mode 100755 test/cdma-list-call
>
> This patch does not apply:
>
> Applying: test: Add CDMA MO Call Support
> error: patch failed: Makefile.am:445
> error: Makefile.am: patch does not apply
> /home/denkenz/ofono-master/.git/rebase-apply/patch:32: new blank line at
> EOF.
> +
> /home/denkenz/ofono-master/.git/rebase-apply/patch:89: new blank line at
> EOF.
> +
> Patch failed at 0001 test: Add CDMA MO Call Support
> When you have resolved this problem run "git am --resolved".
> If you would prefer to skip this patch, instead run "git am --skip".
> To restore the original branch and stop patching run "git am --abort".
>
> Also:
>
> <snip>
>
>>
>> diff --git a/test/cdma-list-call b/test/cdma-list-call
>> new file mode 100755
>> index 0000000..8a2e04e
>> --- /dev/null
>> +++ b/test/cdma-list-call
>> @@ -0,0 +1,31 @@
>> +#!/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 + " "
>
> You might want to remove this if statement.  There are no Interfaces or
> Features properties in cdma.VoiceCallManager
>
>> +		else:
>> +			val = str(properties[key])
>> +		print "    %s = %s" % (key, val)
>> +
>
> Regards,
> -Denis

Thank you, yes I'll fix this up and resubmit. The info re: naming style 
of the atom methods has been passed on to the other guys too to include 
in future/current CDMA patches.

Cheers
Dara



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2011-01-13 18:18 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-01-11  1:45 [PATCH v5, 2/5] test: Add CDMA MO Call Support Dara Spieker-Doyle
2011-01-13  5:25 ` Denis Kenzior
2011-01-13 18:18   ` Dara Spieker-Doyle

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.