简体   繁体   English

如何处理应用中的不良信号问题或增强信号

[英]how to handle poor signal issue in application or boost signals

is there any way to handle poor signal problem in application hoe boost network signal? 在应用中增强网络信号时,有什么方法可以解决信号差的问题? isee appp in playstore like https://play.google.com/store/apps/details?id=com.bosscellular.curtis and https://play.google.com/store/apps/details?id=com.alportela.apptoola.network_booster but dont know how they work how to boost signal progeamically any one know? Playee中的isee appp,例如https://play.google.com/store/apps/details?id=com.bosscellular.curtishttps://play.google.com/store/apps/details?id=com.alportela .apptoola.network_booster,但不知道它们如何工作,如何通过信号增强信号增强能力? below is my code which return only network strength but i want to Boost signal strength what do i do? 以下是我的代码,该代码仅返回网络强度,但我想增强信号强度我该怎么办?

    private static final int EXCELLENT_LEVEL = 51;
private static final int GOOD_LEVEL = 50;



ProgressBar progressBar;
TextView textView;

@Override
public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.main);
    progressBar = (ProgressBar) findViewById(R.id.signalLevel);
    textView = (TextView) findViewById(R.id.signalLevelInfo);
Toast.makeText(getApplication(), "Please try again \n Your Connection Signal are Low",      
          Toast.LENGTH_SHORT).show();

    startSignalLevelListener();

}





private void setSignalLevel(int level) {
    int progress = (int) ((((float) level) / 31.0) * 100);
    String signalLevelString = getSignalLevelString(progress);

    progressBar.setProgress(progress);

    textView.setText(signalLevelString);

    Log.i("signalLevel ", "" + progress);
}

private String getSignalLevelString(int level) {
    String signalLevelString = "Weak";

    if (level >= EXCELLENT_LEVEL)
    {
        signalLevelString = "High";
    progressBar.getProgressDrawable().setColorFilter(Color.GREEN, Mode.OVERLAY );
    }

    else if (level <= GOOD_LEVEL)
    {
        signalLevelString = "Weak";
        progressBar.getProgressDrawable().setColorFilter(Color.RED,  Mode.OVERLAY );

    }


    return signalLevelString;
}

private void stopListening() {
    TelephonyManager tm = (TelephonyManager) getSystemService(TELEPHONY_SERVICE);

    tm.listen(phoneStateListener, PhoneStateListener.LISTEN_NONE);
}


private void startSignalLevelListener() {
    TelephonyManager tm = (TelephonyManager) getSystemService(TELEPHONY_SERVICE);
    int events = PhoneStateListener.LISTEN_SIGNAL_STRENGTH
            | PhoneStateListener.LISTEN_DATA_ACTIVITY |

            PhoneStateListener.LISTEN_DATA_CONNECTION_STATE |

            PhoneStateListener.LISTEN_SERVICE_STATE;

    tm.listen(phoneStateListener, events);
}

private final PhoneStateListener phoneStateListener = new PhoneStateListener() {



    @Override
    public void onSignalStrengthChanged(int asu) {


        setSignalLevel(asu);

        super.onSignalStrengthChanged(asu);
    }
};

You cannot truly boost your signal strength through software; 您无法通过软件真正提高信号强度。 it is dependent on many variables that are well beyond a software application--including radio firmware, device hardware, proximity to a wireless site, radio interference, and environmental factors. 它取决于许多远远超出软件应用程序的变量,包括无线电固件,设备硬件,与无线站点的距离,无线电干扰和环境因素。

The applications you referenced appear to just toggle airplane mode on and off, which would force a device to immediately rescan for a new connection. 您引用的应用程序似乎只是打开和关闭飞行模式,这将迫使设备立即重新扫描以寻找新的连接。 Any "signal boost" that results from these apps is because the device located a stronger signal (likely by connecting to a different wireless site) when the mobile radio was reactivated. 这些应用程序产生的任何“信号增强”是因为当重新激活移动无线电时,设备定位到了更强的信号(可能是通过连接到其他无线站点)。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM