Skip to content

Commit

Permalink
Merge pull request #25 from omnt/rel/0.4
Browse files Browse the repository at this point in the history
Create Release 0.4
  • Loading branch information
PeterHasse authored Oct 29, 2024
2 parents 0b9b316 + 4831b74 commit 48fdada
Show file tree
Hide file tree
Showing 90 changed files with 6,026 additions and 2,603 deletions.
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/bug.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
name: Bug Report
about: Use this template for creating bug report.
title: "[BUG] - BUG_DESCRIPTION"
title: "BUG_DESCRIPTION"
labels: bug
assignees: ""
---
Expand Down
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/feature.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
name: Feature Request
about: Use this template for creating feature request.
title: "[FEATURE] - FEATURE_DESCRIPTION"
title: "FEATURE_DESCRIPTION"
labels: feature
assignees: ""
---
Expand Down
21 changes: 20 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,22 @@
# OpenMobileNetworkToolkit Changelog
## Release [0.4] - Stralsund

### Added
- WiFi Data logging and display on the home screen
- New Quick View on home screen for Cell Information
- Import / Export application settings

### Changed
- code clean up around soon to be deprecated functions
- refactored code that causes warnings
- refactored data model for cell information
- Bump lib dependencies
- Bump gradle version

### Fixed
- Fix crash where no UICC or Cell is available
- Wrong value in Wifi RSSI filed

# OpenMobileNetworkToolkit Changelog
## Release [0.3.1]

Expand All @@ -7,7 +26,7 @@
### Changed
- Use [TelephonyCallback](https://developer.android.com/reference/android/telephony/TelephonyCallback) instead of [PhoneStateListener](https://developer.android.com/reference/android/telephony/PhoneStateListener)
- Bump gradle to 8.5.0
- Bump lib depencies
- Bump lib decencies
- disable Radio Settings if Carrier Permissions are not available
- minor documentation update

Expand Down
13 changes: 9 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,26 @@

OMNT provides tooling to researchers and developers of mobile communication networks like 3GPP 2/3/4/5G.
The main objective of OMNT is the collection of measurement data on the mobile network like RSSI, RSRQ, RSRP, GNSS position, Cell ID, PLNM and much more.
On top of those passive measurements on the radio environment and network parameters, OMNT can also run a iPerf3 server / client for bandwidth, latency and jitter evaluation as well as
On top of those passive measurements on the radio environment and network parameters, OMNT can also run an iPerf3 server / client for bandwidth, latency and jitter evaluation as well as
round-trip-time and jitter evaluation via ICMP (Ping). Measurement data can be stored locally and / or send to an InfluxDB 2.x server.
Measurement results can be visualized e.g. via provided Graphana Dashboards or be further processed e.g. with python.
Besides its measurement capabilities, OMNT provides a deep insight in the state of the phone e.g. software versions, connectivity states, SIM card content and much more.
Measurement results can be visualized e.g. via provided Grafana Dashboards or be further processed e.g. with python.
Besides its measurement capabilities, OMNT provides a deep insight into the state of the phone e.g. software versions, connectivity states, SIM card content and much more.
Network related Carrier Settings can be configured (if the app is granted the corresponding privileges).
Also, OMNT provides access to different "secret" settings in Android phones.

The current state of the app can be described as "research software", it fits our needs but does not aim to be complete or bug free.
Use the app at your own risk. If you find it useful for your research, please cite the app in publications.


* [Quick Start HowTo](docs/quick-start.md)
* [User Manual](docs/OpenMobileNetworkToolkit.md)
* [Signing HowTo](docs/signing.md)

## Requirements

OMNT currently supports Android 11 (API Level 30) and is tested up to Android 15 (API Level 35). While it would be technical possible to support lower API levels,
it would be a lot of work and would require some duplicate implementations. If you can, try to update your phone to the latest software update. If there is no recent enough
firmware from you phone vendor you might have luck with LineageOS or other after market firmware.

## Why use this app

* As apps like OMNT can can access a lot of private information. It is important for users to be able to make sure that those data is not
Expand Down
24 changes: 16 additions & 8 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,8 @@ android {
applicationId "de.fraunhofer.fokus.OpenMobileNetworkToolkit"
minSdk 31
targetSdk 34
versionCode 3
versionName "0.3"
versionCode 4
versionName "0.4"
resValue("string", "git_hash", getGitHash())

testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
Expand Down Expand Up @@ -84,6 +84,13 @@ android {
compileOptions {
sourceCompatibility JavaVersion.VERSION_11
targetCompatibility JavaVersion.VERSION_11
tasks.withType(JavaCompile).tap {
configureEach {
options.compilerArgs << "-Xlint:deprecation" << "-Xlint:unchecked"
}
}


}
buildFeatures {
viewBinding true
Expand Down Expand Up @@ -116,32 +123,33 @@ spdxSbom {

dependencies {
implementation 'androidx.preference:preference:1.2.1'
implementation 'androidx.work:work-runtime:2.9.0'
implementation 'androidx.work:work-runtime:2.9.1'
def room_version = "2.6.1"

implementation "androidx.room:room-runtime:$room_version"
annotationProcessor "androidx.room:room-compiler:$room_version"
implementation 'androidx.appcompat:appcompat:1.7.0'
implementation 'com.google.guava:guava:33.2.1-jre'
implementation 'androidx.concurrent:concurrent-futures:1.2.0'
implementation 'androidx.activity:activity:1.9.0'
implementation 'androidx.fragment:fragment:1.8.1'
implementation 'androidx.activity:activity:1.9.3'
implementation 'androidx.fragment:fragment:1.8.4'
implementation 'androidx.appcompat:appcompat:1.7.0'
implementation 'com.google.android.material:material:1.12.0'
implementation 'androidx.constraintlayout:constraintlayout:2.1.4'
implementation 'androidx.navigation:navigation-fragment:2.7.7'
implementation 'androidx.navigation:navigation-ui:2.7.7'
implementation 'androidx.navigation:navigation-fragment:2.8.3'
implementation 'androidx.navigation:navigation-ui:2.8.3'
implementation 'androidx.swiperefreshlayout:swiperefreshlayout:1.1.0'
testImplementation 'junit:junit:4.13.2'
androidTestImplementation 'androidx.test.ext:junit:1.2.1'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.6.1'
implementation 'androidx.preference:preference-ktx:1.2.1'
implementation 'androidx.recyclerview:recyclerview:1.3.2'
implementation 'androidx.recyclerview:recyclerview-selection:1.1.0'
implementation 'com.influxdb:influxdb-client-java:7.1.0'
implementation 'com.influxdb:influxdb-client-java:7.2.0'
implementation 'com.google.android.gms:play-services-location:21.3.0'
implementation 'com.github.anastr:speedviewlib:1.6.1'
implementation "androidx.viewpager2:viewpager2:1.1.0"
implementation "androidx.compose.material3:material3:1.3.0"
}

configurations.implementation {
Expand Down
1 change: 1 addition & 0 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.HIDE_OVERLAY_WINDOWS" />
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE"/>
<uses-permission
android:name="android.permission.READ_PRIVILEGED_PHONE_STATE"
tools:ignore="ProtectedPermissions" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@
import android.content.Context;
import android.os.Bundle;
import android.os.PersistableBundle;
import android.telephony.CarrierConfigManager;
import android.telephony.TelephonyManager;
import android.util.Log;
import android.view.LayoutInflater;
Expand All @@ -28,15 +27,12 @@
import androidx.cardview.widget.CardView;
import androidx.fragment.app.Fragment;

import com.google.android.material.textfield.TextInputLayout;

import java.util.Arrays;
import java.util.HashMap;
import java.util.Iterator;
import java.util.Map;

public class CarrierSettingsFragment extends Fragment {
String TAG = "CarrierSettingsFragment";
final String TAG = "CarrierSettingsFragment";
Context context;
TelephonyManager tm;

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
package de.fraunhofer.fokus.OpenMobileNetworkToolkit;

import android.app.Dialog;
import android.content.DialogInterface;
import android.os.Bundle;
import android.widget.Toast;

import androidx.appcompat.app.AlertDialog;
import androidx.fragment.app.DialogFragment;

import de.fraunhofer.fokus.OpenMobileNetworkToolkit.Preferences.SharedPreferencesGrouper;
import de.fraunhofer.fokus.OpenMobileNetworkToolkit.SettingPreferences.ClearPreferencesListener;

public class ClearPreferencesFragment extends DialogFragment {
private ClearPreferencesListener listener;

public void setClearPreferencesListener(ClearPreferencesListener listener) {
this.listener = listener;
}
public Dialog onCreateDialog(Bundle savedInstanceState) {
// Use the Builder class for convenient dialog construction.
AlertDialog.Builder builder = new AlertDialog.Builder(getActivity());
builder.setMessage(R.string.clear_preferences_message)
.setPositiveButton(R.string.yes, new DialogInterface.OnClickListener() {
public void onClick(DialogInterface dialog, int id) {
SharedPreferencesGrouper.getInstance(getContext()).clearConfig();
listener.onPreferenceChanged();
Toast.makeText(getContext(), "All Config Cleared!", Toast.LENGTH_SHORT).show();
}
})
.setNegativeButton(R.string.no, new DialogInterface.OnClickListener() {
public void onClick(DialogInterface dialog, int id) {
Toast.makeText(getContext(), "Canceled", Toast.LENGTH_SHORT).show();
}
});
// Create the AlertDialog object and return it.
return builder.create();
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,22 @@

package de.fraunhofer.fokus.OpenMobileNetworkToolkit.DataProvider;

public class BatteryInformation {
import android.content.Context;
import android.widget.TableLayout;

public class BatteryInformation extends Information {
private int scale;
private int level;
private int charge_type;

public BatteryInformation() {
super();
}
public BatteryInformation(long timeStamp, int scale, int level, int charge_type) {
super(timeStamp);
this.scale = scale;
this.level = level;
this.charge_type = charge_type;
}
public int getScale() {
return scale;
}
Expand Down Expand Up @@ -40,4 +51,6 @@ public void setCharge_type(int charge_type) {
public double getPercent() {
return level * 100 / (double) scale;
}


}
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
package de.fraunhofer.fokus.OpenMobileNetworkToolkit.DataProvider;

import android.content.Context;
import android.util.Log;
import android.widget.TableLayout;

import org.json.JSONObject;

import de.fraunhofer.fokus.OpenMobileNetworkToolkit.BuildConfig;

public class BuildInformation extends Information {
private final String TAG = "BuildInformation";

public BuildInformation() {
super();
}

public BuildInformation(long timeStamp) {
super(timeStamp);
}

public String getBuildType() {
return BuildConfig.BUILD_TYPE;
}

public int getVersionCode() {
return BuildConfig.VERSION_CODE;
}

public String getVersionName() {
return BuildConfig.VERSION_NAME;
}

public String getApplicationId() {
return BuildConfig.APPLICATION_ID;
}

public boolean isDebug() {
return BuildConfig.DEBUG;
}

public JSONObject toJSON(){

JSONObject json = new JSONObject();
try {
json.put("BuildType", getBuildType());
json.put("VersionCode", getVersionCode());
json.put("VersionName", getVersionName());
json.put("ApplicationId", getApplicationId());
json.put("Debug", isDebug());
} catch (Exception e) {
Log.d(TAG,e.toString());
}
return json;
}

}
Loading

0 comments on commit 48fdada

Please sign in to comment.