加速度呈现验证通过,速度view层档位呈现验证通过,速度正常和超速预警呈现验证通过
This commit is contained in:
@@ -141,8 +141,9 @@ public class TrafficDataView extends ConstraintLayout {
|
||||
@Override
|
||||
public void onAutopilotAcc(float carAcc) {
|
||||
Log.d(TAG, "加速度:" + carAcc);
|
||||
BigDecimal acc = new BigDecimal(String.valueOf(carAcc)).setScale(2);
|
||||
accTextView.setText(String.valueOf(acc));
|
||||
java.text.DecimalFormat myformat=new java.text.DecimalFormat("0.00");
|
||||
String accStr = myformat.format(carAcc);
|
||||
accTextView.setText("a: " + accStr);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@@ -75,7 +75,7 @@
|
||||
android:layout_marginLeft="@dimen/dp_42"
|
||||
android:layout_marginTop="@dimen/dp_190"
|
||||
android:text="a: "
|
||||
android:textAlignment="center"
|
||||
android:textAlignment="viewStart"
|
||||
android:textColor="#fff"
|
||||
android:textSize="@dimen/dp_40"
|
||||
app:layout_constraintLeft_toLeftOf="@+id/brakeStatus"
|
||||
|
||||
Reference in New Issue
Block a user