maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Maemo 5 / Fremantle (https://talk.maemo.org/forumdisplay.php?f=40)
-   -   [Solved] How do I prevent N900 from connecting to my Dummy Network? (https://talk.maemo.org/showthread.php?t=60868)

eitama 2010-08-22 14:09

[Solved] How do I prevent N900 from connecting to my Dummy Network?
 
Hello peeps,

Edit : Solved the problem with Matan's help and some gconfing...
Updated the WIKI, and the solution is also here.

I have configured a dummy network with gconftool-2 as explained in the wiki.
Everything is working great, when I plug the USB, I have internet via my Windows PC, and the dummy network gets connected so apps realize they have internet.

When I Disconnect USB, the Dummy network disconnects, so far, so good.

The problem : The phone is set to Connect Automatically to "Any Connection" and I want to keep it that way, but I want it to skip using the Dummy Network.
I tried setting it as "auto_connect = false" but to no avail.

Any ideas?

Cheers,
Eitam.

Matan 2010-08-22 14:31

Re: [Help Needed] How do I prevent N900 from connecting to my Dummy Network?
 
There is no way to achieve what you want with the GUI. But with the command line you can select any subset of connection types. The gconv key /system/osso/connectivity/network_type/auto_connect contains the list connection types that N900 connects automatically to. Just remove DUMMY from that list.

eitama 2010-08-22 14:32

Re: [Help Needed] How do I prevent N900 from connecting to my Dummy Network?
 
Quote:

Originally Posted by Matan (Post 794976)
There is no way to achieve what you want with the GUI. But with the command line you can select any subset of connection types. The gconv key /system/osso/connectivity/network_type/auto_connect contains the list connection types that N900 connects automatically to. Just remove DUMMY from that list.

I don't mind messing with CLI, thats not the problem, I just can't achieve connectivity right now unless I click a connection manually.
I'll try what you suggested and report back.

Cheers!

eitama 2010-08-22 14:35

Re: [Help Needed] How do I prevent N900 from connecting to my Dummy Network?
 
Quote:

Originally Posted by Matan (Post 794976)
There is no way to achieve what you want with the GUI. But with the command line you can select any subset of connection types. The gconv key /system/osso/connectivity/network_type/auto_connect contains the list connection types that N900 connects automatically to. Just remove DUMMY from that list.

Hmmm, 2 questions :
1. I can't find the list, are you sure it's supposed to be here :
Code:

Nokia-N900:~# gconftool-2 -g /system/osso/connectivity/network_type/auto_connect
[*]

2. How often is this list created? I need to know how to maintain it, (i'll write a script)

Edit : hmm, ok I found some info, using gconftool -R, but I am having problems deleting or changing, the key just stays there even though I am trying to remove it.
To me it looks like there is a rule with priority 90 that says autoconnect * wildcards, I wanna delete it.

So I tried :
Code:

Nokia-N900:~# gconftool -R /system/osso/connectivity/ui/auto_connect
 /system/osso/connectivity/ui/auto_connect/60_wlan:
  network_types = [WLAN_INFRA]
  label = conn_set_fi_conn_set_wlan
  not_found_banner = conn_ib_net_no_saved_wlan_iaps
  gettext_catalog = osso-connectivity-ui
 /system/osso/connectivity/ui/auto_connect/65_gprs:
  network_types = [GPRS]
  label = %s
 /system/osso/connectivity/ui/auto_connect/90_any:
  network_types =[*]
  label = conn_set_fi_conn_set_any
  not_found_banner = conn_ib_net_no_saved_iaps
  gettext_catalog = osso-connectivity-ui
 /system/osso/connectivity/ui/auto_connect/01_always_ask:
  network_types = []
  label = conn_set_fi_conn_set_always_ask
  gettext_catalog = osso-connectivity-ui
Nokia-N900:~# gconftool --recursive-unset /system/osso/connectivity/ui/auto_connect/90_any
Nokia-N900:~#

Don't worry I backed it up, but if I run the recursive get again, it's still there!!!


Code:

Nokia-N900:~# gconftool -R /system/osso/connectivity/ui/auto_connect
 /system/osso/connectivity/ui/auto_connect/60_wlan:
  network_types = [WLAN_INFRA]
  label = conn_set_fi_conn_set_wlan
  not_found_banner = conn_ib_net_no_saved_wlan_iaps
  gettext_catalog = osso-connectivity-ui
 /system/osso/connectivity/ui/auto_connect/65_gprs:
  network_types = [GPRS]
  label = %s
 /system/osso/connectivity/ui/auto_connect/90_any:
  network_types =[*]
  label = conn_set_fi_conn_set_any
  not_found_banner = conn_ib_net_no_saved_iaps
  gettext_catalog = osso-connectivity-ui
 /system/osso/connectivity/ui/auto_connect/01_always_ask:
  network_types = []
  label = conn_set_fi_conn_set_always_ask
  gettext_catalog = osso-connectivity-ui
Nokia-N900:~#


Matan 2010-08-22 14:45

Re: [Help Needed] How do I prevent N900 from connecting to my Dummy Network?
 
The * means any network type. Replace it with a list of types you want, such as [WLAN_INFRA,GPRS].

eitama 2010-08-22 15:08

Re: [Help Needed] How do I prevent N900 from connecting to my Dummy Network?
 
Quote:

Originally Posted by Matan (Post 794995)
The * means any network type. Replace it with a list of types you want, such as [WLAN_INFRA,GPRS].

Sadly it is not working, after doing :
Code:

gconftool-2 -s /system/osso/connectivity/network_type/auto_connect "[WLAN_INFRA,GPRS]"
It goes into always ask mode.

I inspected to values when setting wifi / gprs via UI, and the values are correct, is there a chance it is not expecting more then 1 value in the backend?

eitama 2010-08-22 15:21

Re: [Help Needed] How do I prevent N900 from connecting to my Dummy Network?
 
Ok! Solved it!
Thanks Matan! your help was awesome.

The exact command is :
Code:

gconftool -s /system/osso/connectivity/network_type/auto_connect -t list --list-type string "[WLAN_INFRA,GPRS]"
Updated the WIKI

Updating the 1st post now.

Cheers mate!

jem555 2010-10-23 13:20

Re: [Solved] How do I prevent N900 from connecting to my Dummy Network?
 
Hi everybody!

One question, is there any way to tell it to use WLAN_INFRA + only one gprs-ap??...
The problem is that there are more grps aps (ie MMS) and it tries to
connect to anyone randomly and the idea is to exclude those.

any help?
thanks!!!


All times are GMT. The time now is 19:37.

vBulletin® Version 3.8.8