How to configure Wifi to take priority over the Ethernet ?

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

How to configure Wifi to take priority over the Ethernet ?

ソリューションへジャンプ
1,563件の閲覧回数
amit251291
Contributor IV
Dear Team,
    Currently we are  working on IMX8QM-MEK board running with Android 9 auto. We have a scenario where we have to use both WiFi for internet connectivity on MEK and Ethernet cable to connect MEK to another Windows Machine(InterNetworking).
   
    But I have observed WiFi works fine until ethernet cable is plugged in. As soon as Ethernet cable is plugged in WiFi loses priority over the Ethernet and then internet doesn't work at all on MEK. To sum it up, internet from WiFi is not working when Ethernet cable is plugged in to MEK and other end of which is connected to Windows machine.
   
     Our requirement is to have both in working condition. How to make WiFi still be receiving internet, when Ethernet cable is connected between MEK and windows machine.
   
    Do we need to change any configuration file to achieve the requirement or we have to edit ConnectivityService of Android.
Hoping to hear from you,
0 件の賞賛
1 解決策
1,448件の閲覧回数
weidong_sun
NXP TechSupport
NXP TechSupport

Hello Amit,

      Your question is related to network prioty, which is not related i.MX8 processor. so you should tune the prioty of ethernet or WIFI in android source code.

       Open frameworks/opt/net/ethernet/java/com/android/server/ethernet/EthernetNetworkFactory.java  with gedit or vim.

find

   private final static int NETWORK_SCORE = 110;

   change 110 to be 50.

try it , please!

Have a nice day!

B.R,

Weidong

元の投稿で解決策を見る

0 件の賞賛
2 返答(返信)
1,449件の閲覧回数
weidong_sun
NXP TechSupport
NXP TechSupport

Hello Amit,

      Your question is related to network prioty, which is not related i.MX8 processor. so you should tune the prioty of ethernet or WIFI in android source code.

       Open frameworks/opt/net/ethernet/java/com/android/server/ethernet/EthernetNetworkFactory.java  with gedit or vim.

find

   private final static int NETWORK_SCORE = 110;

   change 110 to be 50.

try it , please!

Have a nice day!

B.R,

Weidong

0 件の賞賛
1,448件の閲覧回数
amit251291
Contributor IV

Thank you Wigros Sun. Solution helped us. 

0 件の賞賛