Re: USSD interface for ModemManager





2010/3/10 Pablo Martí Gamboa <pmarti warp es>


2010/3/10 Dan Williams <dcbw redhat com>

On Tue, 2010-03-09 at 17:34 -0800, Dan Williams wrote:
> On Tue, 2010-03-09 at 13:45 +0100, Pablo Martí Gamboa wrote:
> > Hi Dan, Marcel and others,
> >
> >
> > we would like to extend the ModemManager API so that it can handle
> > USSD commands. The USSD API of oFono [0] looks quite nice IMHO and I'd
> > like to propose a similar API:
>
> I'd actually change two things; this API (and by extension the ofono
> one) doesn't allow clients to respond to a USSD request that is pending
> when they start up.  Say your app sends the request, then crashes or
> something.  When it's crashed, the network sends the response.  Now your
> app can't get the response when it starts back up and handle it, it
> would have to cancel the USSD session and send the request again.

I tossed this into the MM introspection/ directory with my proposed
changes; keeping the changes or dropping them doesn't make a huge
difference to me, I just thought it was a slightly more robust way of
doing the API.  Updated spec HTML attached for your review.

Looks good to me, thanks!


Hmm, seems I made up my mind too fast. There is one wart in the proposed API

Initiate/Reply doesn't return anything, it will set the Network{Request,Notification} property which in turn will fire the MmPropertiesChanged signal. I think that's a slightly cumbersome way of getting the reply. IMHO both methods (Initiate and Reply) should return a string. Our UI code has enough callbacks me thinks, having to listen for the MmPropertiesChanged signal to get the response of an USSD command seems wrong to me. MmPropertiesChanged is nice, but has a completely different use case (a low level internal interaction might result on an important property change -say Enabled- and the UI is notified)

Thoughts ?

Pablo
 
 

> >
> > --

> > Pablo Martí
> > http://www.linkedin.com/in/pmarti || http://www.warp.es
> > python -c "print '706d6172746940776172702e6573'.decode('hex')"
> >
> >
>
>
> _______________________________________________
> NetworkManager-list mailing list
> NetworkManager-list gnome org
> http://mail.gnome.org/mailman/listinfo/networkmanager-list




--
Pablo Martí
http://www.linkedin.com/in/pmarti || http://www.warp.es
python -c "print '706d6172746940776172702e6573'.decode('hex')"




--
Pablo Martí
http://www.linkedin.com/in/pmarti || http://www.warp.es
python -c "print '706d6172746940776172702e6573'.decode('hex')"



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