Send connman mailing list submissions to
        [email protected]

To subscribe or unsubscribe via the World Wide Web, visit
        https://lists.01.org/mailman/listinfo/connman
or, via email, send a message with subject or body 'help' to
        [email protected]

You can reach the person managing the list at
        [email protected]

When replying, please edit your Subject line so it is more specific
than "Re: Contents of connman digest..."


Today's Topics:

   1. Re: How difficult to build ConnMan, oFono on OpenWrt? (Jonas Bonn)
   2. Re: How difficult to build ConnMan, oFono on OpenWrt? (Jonas Bonn)
   3. Re: The role of connection manager (Jonas Bonn)
   4. Re: How difficult to build ConnMan, oFono on OpenWrt? (JH)
   5. Re: The role of connection manager (JH)


----------------------------------------------------------------------

Message: 1
Date: Tue, 26 Feb 2019 21:18:17 +0100
From: Jonas Bonn <[email protected]>
To: JH <[email protected]>, Denis Kenzior <[email protected]>
Cc: [email protected]
Subject: Re: How difficult to build ConnMan, oFono on OpenWrt?
Message-ID: <[email protected]>
Content-Type: text/plain; charset=utf-8; format=flowed



On 26/02/2019 20:46, JH wrote:
>> Perhaps something is wrong with your environment and the configure magic 
>> cannot find the needed pkgconfig file.
> 
> There is a /usr/lib/x86_64-linux-gnu/pkgconfig/glib-2.0.pc, how could
> the configure script not find it?
> 

What does the following command give you?

pkg-config --print-variables glib-2.0

/Jonas


------------------------------

Message: 2
Date: Tue, 26 Feb 2019 21:20:44 +0100
From: Jonas Bonn <[email protected]>
To: JH <[email protected]>, Denis Kenzior <[email protected]>
Cc: [email protected]
Subject: Re: How difficult to build ConnMan, oFono on OpenWrt?
Message-ID: <[email protected]>
Content-Type: text/plain; charset=utf-8; format=flowed



On 26/02/2019 21:18, Jonas Bonn wrote:
> 
> 
> On 26/02/2019 20:46, JH wrote:
>>> Perhaps something is wrong with your environment and the configure 
>>> magic cannot find the needed pkgconfig file.
>>
>> There is a /usr/lib/x86_64-linux-gnu/pkgconfig/glib-2.0.pc, how could
>> the configure script not find it?
>>
> 
> What does the following command give you?
> 
> pkg-config --print-variables glib-2.0

Or perhaps this is more relevant:

pkg-config --modversion glib-2.0

/Jonas


------------------------------

Message: 3
Date: Tue, 26 Feb 2019 21:43:36 +0100
From: Jonas Bonn <[email protected]>
To: JH <[email protected]>, connman <[email protected]>
Subject: Re: The role of connection manager
Message-ID: <[email protected]>
Content-Type: text/plain; charset=utf-8; format=flowed



On 26/02/2019 20:21, JH wrote:
> Hi,
> 
> Does ConnMan provide C API to setup WiFi and LTE connection? Or it is
> not necessary to use API but use configuration in main.conf?

Both connman and ofono are primarily controlled via DBus.  The 
configuration file may get you most of what you want, but you still need 
to configure the access point, set up a context for fallback to 
UMTS/GSM, etc and this pretty much requires a bit of setup via dbus.

Calling DBus methods from C is no big deal.  If your setup is simple, 
though, you might be able to get away with just using the connmanctl 
utility on the command line to do whatever minimal setup you need.  It 
all depends on the use case.

> 
> I am currently debating with my colleague about if it is necessary to
> use connection manager in a small embedded Linux device with network
> interfaces of LTE, WiFi and BLE. To cut the long story short, I
> strongly proposed to use ConnMan and my colleague is against it, his
> argument was connection manager should only be used in desktop not for
> embedded system, he wanted to set up WiFi directly from
> wpa_supplicant, run LTE connection directly from modem gpio. From my
> point of view, set up WiFi directly from wpa_supplicant is fine, but
> switch on / off LTE directly from gpio could cause serious
> consequences, the application should never interact LTE directly
> through low level of GPIO, it'll likely to break the integrity of the
> kernel and Linux system where other parts of the kernel or system
> access the modem via ioctl communication. The manager will make the
> final call. As an embedded developer, none of us have experience in
> connection manager, appreciate your comments.

So most modems expose one or more serial ports (real or virtual) that 
can be used for sending commands to them; these are primarily 
AT-commands, but there are other protocols around.  There really aren't 
many ioctls in play, though, in the common case.

Whether you have GPIO's involved is a matter of system design, but these 
generally sit on some reset-line of the modem and that's about it.

You are right, though, in that you don't want multiple clients messing 
about with the modem state concurrently.  Best to leave that to one 
agent and let other clients talk to the agent.  That's where ofono comes 
into play:  ofono manages your modem so you (or connman) can control it 
at a higher level of abstraction.

What connman gets you, primarily, is sane routing depending on 
availability of the various types of connection.  If WiFi isn't 
available, connman can ask ofono to bring up the LTE connection and set 
that up as the primary route.  When WiFi becomes available, it can move 
the default route to that.  And so on... depending on your requirements.

Aside from that, your question isn't easy to answer.  Do you need 
connman?  It depends.  Do you need ofono?  It depends.  Do connman and 
ofono work well on small embedded devices?  Absolutely.  Given the 
nature of your questions, however, I have a hunch that a connection 
manager of some sort is what you want.

/Jonas


> 
> Thank you.
> 
> JH
> _______________________________________________
> connman mailing list
> [email protected]
> https://lists.01.org/mailman/listinfo/connman
> 


------------------------------

Message: 4
Date: Wed, 27 Feb 2019 07:47:59 +1100
From: JH <[email protected]>
To: Jonas Bonn <[email protected]>
Cc: Denis Kenzior <[email protected]>, [email protected]
Subject: Re: How difficult to build ConnMan, oFono on OpenWrt?
Message-ID:
        <CAA=hcWTG+SNgHHbUtoJFUeeNVmjEqL=dwsh0v9ru+vbj-xq...@mail.gmail.com>
Content-Type: text/plain; charset="UTF-8"

Sorry, my bad, the pkg-config for glib-2.0 is indeed broken

Thanks Jonas


------------------------------

Message: 5
Date: Wed, 27 Feb 2019 11:03:36 +1100
From: JH <[email protected]>
To: Jonas Bonn <[email protected]>
Cc: connman <[email protected]>
Subject: Re: The role of connection manager
Message-ID:
        <CAA=hcWS6HtFcfUA7o0w0A5OrwUfgYvxSPsNJscmg2Fqdpg3S=w...@mail.gmail.com>
Content-Type: text/plain; charset="UTF-8"

On 2/27/19, Jonas Bonn <[email protected]> wrote:
> Both connman and ofono are primarily controlled via DBus.  The
> configuration file may get you most of what you want, but you still need
> to configure the access point, set up a context for fallback to
> UMTS/GSM, etc and this pretty much requires a bit of setup via dbus.

Right, I am learning right now how to set up ConnMan configuration
file and how to interact with dbus.

> Calling DBus methods from C is no big deal.  If your setup is simple,
> though, you might be able to get away with just using the connmanctl
> utility on the command line to do whatever minimal setup you need.  It
> all depends on the use case.

We are using C++ in our application, I don't think I need interact
dbus for switching network interface from LTE to WiFi, I believe the
ConnMan will do it automatically.

The only thing I need in program is to set up WiFi client connection
based on the input of SSID and password or set up an AP. If that can
be done in C API, , calling C API will be much easier than calling
shell command line. Is it right place to learn C API examples in
tools/dbugs-test.c and other test files in that directory?

> So most modems expose one or more serial ports (real or virtual) that
> can be used for sending commands to them; these are primarily
> AT-commands, but there are other protocols around.  There really aren't
> many ioctls in play, though, in the common case.

Yes, we are using USB serial line. You are right, we are not using
ioctls, I was referring to kernel or other system processes use
ioctls.

> Whether you have GPIO's involved is a matter of system design, but these
> generally sit on some reset-line of the modem and that's about it.

We are actually toggling LTE modem power key and reset key to set up
LTE through the gpio. Several times I have noticed the crash of
missing the device /dev/ttyUSB0, it is my suspicious either something
is not set up properly between the driver and kernel, or the toggling
LTE power key / reset messed up, but my colleague was not convinced
that could cause the problem.

> You are right, though, in that you don't want multiple clients messing
> about with the modem state concurrently.  Best to leave that to one
> agent and let other clients talk to the agent.  That's where ofono comes
> into play:  ofono manages your modem so you (or connman) can control it
> at a higher level of abstraction.

Good to know, I am going to build and to install both connman and ofono.

> What connman gets you, primarily, is sane routing depending on
> availability of the various types of connection.  If WiFi isn't
> available, connman can ask ofono to bring up the LTE connection and set
> that up as the primary route.  When WiFi becomes available, it can move
> the default route to that.  And so on... depending on your requirements.

That is actually a key requirement for our application I am straggling
to achieve it. My colleague argued we should do it manually using
scripts, I think that is more than just networking interface scripts.

> Aside from that, your question isn't easy to answer.  Do you need
> connman?  It depends.  Do you need ofono?  It depends.  Do connman and
> ofono work well on small embedded devices?  Absolutely.  Given the
> nature of your questions, however, I have a hunch that a connection
> manager of some sort is what you want.

Well, you have already answered and explained well to my questions,
your advice boosted my determination to use the ConnMan, my apology to
make lots of noises in this mailing list already, I might have to ask
more questions during building package, configuration and integration,
I am happy to play a testing role if you don't mind.

Thank you so much Jonas

JH


------------------------------

Subject: Digest Footer

_______________________________________________
connman mailing list
[email protected]
https://lists.01.org/mailman/listinfo/connman


------------------------------

End of connman Digest, Vol 40, Issue 14
***************************************

Reply via email to