Skip to content

Commit

Permalink
feat: Add num GNSS antennas, antenna CFs to feedback email
Browse files Browse the repository at this point in the history
  • Loading branch information
barbeau committed Feb 11, 2021
1 parent 84b299a commit 1e2b229
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
8 changes: 7 additions & 1 deletion GPSTest/src/main/java/com/android/gpstest/util/UIUtils.java
Original file line number Diff line number Diff line change
Expand Up @@ -356,8 +356,14 @@ public static void sendEmail(Context context, String email, String location, Dev
// Automatic gain control
body.append(Application.get().getString(R.string.capability_title_automatic_gain_control, PreferenceUtils.getCapabilityDescription(Application.getPrefs().getInt(Application.get().getString(R.string.capability_key_measurement_automatic_gain_control), PreferenceUtils.CAPABILITY_UNKNOWN))));
}

// GNSS Antenna Info
body.append(Application.get().getString(R.string.capability_title_gnss_antenna_info, PreferenceUtils.getCapabilityDescription(SatelliteUtils.isGnssAntennaInfoSupported(locationManager))));
String gnssAntennaInfo = Application.get().getString(R.string.capability_title_gnss_antenna_info, PreferenceUtils.getCapabilityDescription(SatelliteUtils.isGnssAntennaInfoSupported(locationManager)));
body.append(gnssAntennaInfo);
if (gnssAntennaInfo.equals(Application.get().getString(R.string.capability_value_supported))) {
body.append(Application.get().getString(R.string.capability_title_num_antennas, PreferenceUtils.getInt(Application.get().getString(R.string.capability_key_num_antenna), -1)));
body.append(Application.get().getString(R.string.capability_title_antenna_cfs, PreferenceUtils.getString(Application.get().getString(R.string.capability_key_antenna_cf))));
}

if (!TextUtils.isEmpty(BuildUtils.getPlayServicesVersion())) {
body.append("\n" + BuildUtils.getPlayServicesVersion());
Expand Down
2 changes: 2 additions & 0 deletions GPSTest/src/main/res/values/do_not_translate.xml
Original file line number Diff line number Diff line change
Expand Up @@ -187,6 +187,8 @@
<string name="capability_title_supported_sbas">Supported SBAS: %1$s\n</string>
<string name="capability_title_sbas_cf">SBAS CFs: %1$s\n</string>
<string name="capability_title_got_fix">Got fix: %1$b\n</string>
<string name="capability_title_num_antennas">Number GNSS antennas: %1$d\n</string>
<string name="capability_title_antenna_cfs">GNSS antenna CFs: %1$s\n</string>

<string name="capability_value_unknown">UNKNOWN</string>
<string name="capability_value_not_supported">NOT_SUPPORTED</string>
Expand Down

0 comments on commit 1e2b229

Please sign in to comment.