RE: About DBus Interface specification



Dear all,

Thank for your reply,

Before working further on ModemManager, I read your spec and do some testing
with simple python script. It seems I misunderstand something. I don't think
ModemManager doesn't install properly in my workstation because I can access
Internet perfectly. Would you be so kind as to view my script to see what's
going wrong.

Here is my testing script for testing "Read Type property of
org.freedesktop.ModemManager.Modem interface"
=====================================================
#!/usr/bin/env python
import dbus
bus = dbus.SystemBus()
proxy = bus.get_object("org.freedesktop.ModemManager", "/org/freedesktop/
ModemManager")
manager = dbus.Interface(proxy, "org.freedesktop.ModemManager")
devices = manager.EnumerateDevices()
for d in devices:
	dev_proxy = bus.get_object("org.freedesktop. ModemManager", d)
	prop_iface = dbus.Interface(dev_proxy,
"org.freedesktop.DBus.Properties")
	dev_iface = dbus.Interface(dev_proxy,
"org.freedesktop.ModemManager.Modem")
	#info = dev_iface.GetInfo()
	_type = prop_iface.Get("org.freedesktop.ModemManager.Modem", "Type")
	print "%s" % _type

==> the output say: dbus.exceptions.DBusException:
org.freedesktop.DBus.Error.ServiceUnknow: The name
org.freedesktop.ModemManager was not provided by any .service files
=======================================================
Now if I change all ModemManager words into NetworkManager, the interpreter
don't complain above error anymore but: dbus.exceptions.DBusException:
org.freedesktop.Dbus.Error.InvalidArgs: No such property Type




Could you please give me some code example to work with ModemManager? 

Thanks and best regards,
Toan Nguyen

-----Original Message-----
From: Dan Williams [mailto:dcbw redhat com] 
Sent: Tuesday, March 23, 2010 11:04 AM
To: Nguyen Canh Toan
Cc: networkmanager-list gnome org
Subject: RE: About DBus Interface specification

On Wed, 2010-03-24 at 06:10 -0700, Nguyen Canh Toan wrote:
> Dear Mr.Dan,
> 
> I've read your recently uploaded spec and found it very different from
what
> you uploaded before. However, I don't find any spec about
sending/receiving
> SMS any more. I have also searched the mail-list and understood that at
this
> time, you don't provide a full SMS functionality. 

That part of the spec is:

http://projects.gnome.org/NetworkManager/developers/mm-spec-04.html#org.free
desktop.ModemManager.Modem.Gsm.SMS

> At present, my project needs those SMS functions. It would be very helpful
> of you if you could direct me how to use ModemManager(also NetworkManager)
> in order to make SMS functionality perform properly in the real world. I
> will certainly try my best to give contribution to your source repository.

At the moment though, only SMS sending is actually implemented for most
cards and in a generic fashion.  We've been concentrating on making the
actual data connections work as well as possible before moving on to the
SMS bits :(  Any help in this area would be appreciated though.  Other
implementations of the ModemManager specification like Wader (the actual
modem-manager program is only one implementation) do implement the full
SMS spec.

Dan

> Yours faithfully,
> Toan Nguyen
> 
> -----Original Message-----
> From: Dan Williams [mailto:dcbw redhat com] 
> Sent: Tuesday, March 23, 2010 3:06 AM
> To: Nguyen Canh Toan
> Cc: networkmanager-list gnome org
> Subject: Re: About DBus Interface specification
> 
> On Fri, 2010-03-19 at 22:11 -0700, Nguyen Canh Toan wrote: 
> > Dear Dan,
> > 
> >  
> > 
> > Thank for your works about DBus Interface specification
> > http://www.bgiw.org/~dan/mm-spec.html
> > 
> >  
> > 
> > But when writing client application, I found it provide not enough
> > information. For example, 
> > 
> > With org.freedesktop.ModemManager.Modem Interface. I cannot find DBus
> > name also Object path in order to make methods call GetInfo() 
> 
> So that interface is actually provided by ModemManager, not by
> NetworkManager.  NetworkManager acts as the central controller daemon
> that coordinates between various pieces of hardware, while most specific
> hardware is driven by it's own service (wpa_supplicant, ModemManager,
> etc).
> 
> I've uploaded the generated spec to:
> 
> http://projects.gnome.org/NetworkManager/developers/mm-spec-04.html
> 
> It's the spec from git master though, so some of the stuff like
> AccessTechnology and SetAllowedMode hasn't shown up in a release quite
> yet.
> 
> Dan
> 
> 
> 
> 




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]