From: TrillGates Date: Tue, 6 Jul 2021 10:12:45 +0000 (+0800) Subject: update apk values. X-Git-Url: http://git.snicker.com.cn/?a=commitdiff_plain;h=cd81a524ea1076e1313ec88eeb4090aa384af362;p=icworkservice.git update apk values. --- diff --git a/app/IcL02WorkService/release/IcL02WorkService_V59_202106301150_release.apk b/app/IcL02WorkService/release/IcL02WorkService_V59_202106301150_release.apk deleted file mode 100644 index 22b6403..0000000 Binary files a/app/IcL02WorkService/release/IcL02WorkService_V59_202106301150_release.apk and /dev/null differ diff --git a/app/IcL02WorkService/release/IcL02WorkService_V59_202107061808_release.apk b/app/IcL02WorkService/release/IcL02WorkService_V59_202107061808_release.apk new file mode 100644 index 0000000..f29894a Binary files /dev/null and b/app/IcL02WorkService/release/IcL02WorkService_V59_202107061808_release.apk differ diff --git a/app/IcL02WorkService/release/output.json b/app/IcL02WorkService/release/output.json index 6d243c9..b627960 100644 --- a/app/IcL02WorkService/release/output.json +++ b/app/IcL02WorkService/release/output.json @@ -1 +1 @@ -[{"outputType":{"type":"APK"},"apkData":{"type":"MAIN","splits":[],"versionCode":1,"versionName":"1.1","enabled":true,"outputFile":"IcL02WorkService_V59_202106301150_release.apk","fullName":"IcL02WorkServiceRelease","baseName":"IcL02WorkService-release"},"path":"IcL02WorkService_V59_202106301150_release.apk","properties":{}}] \ No newline at end of file +[{"outputType":{"type":"APK"},"apkData":{"type":"MAIN","splits":[],"versionCode":1,"versionName":"1.1","enabled":true,"outputFile":"IcL02WorkService_V59_202107061808_release.apk","fullName":"IcL02WorkServiceRelease","baseName":"IcL02WorkService-release"},"path":"IcL02WorkService_V59_202107061808_release.apk","properties":{}}] \ No newline at end of file diff --git a/app/src/main/aidl/com/ic/aidl/ped/IPedAidlInterface.aidl b/app/src/main/aidl/com/ic/aidl/ped/IPedAidlInterface.aidl index ba08675..a98500d 100644 --- a/app/src/main/aidl/com/ic/aidl/ped/IPedAidlInterface.aidl +++ b/app/src/main/aidl/com/ic/aidl/ped/IPedAidlInterface.aidl @@ -9,8 +9,8 @@ interface IPedAidlInterface { * Demonstrates some basic types that you can use as parameters * and return values in AIDL. */ - void updatePedCount(int count); - void updateCalorie(float count); + void updatePedCount(in int count); + void updateCalorie(in float count); void updatePedRecord(in List record); } diff --git a/app/src/main/aidl/com/ic/aidl/ped/IPedRemoteService.aidl b/app/src/main/aidl/com/ic/aidl/ped/IPedRemoteService.aidl index 684d231..a876160 100644 --- a/app/src/main/aidl/com/ic/aidl/ped/IPedRemoteService.aidl +++ b/app/src/main/aidl/com/ic/aidl/ped/IPedRemoteService.aidl @@ -10,11 +10,11 @@ interface IPedRemoteService { * Demonstrates some basic types that you can use as parameters * and return values in AIDL. */ - void registerCallback(IPedAidlInterface cb); - void unregisterCallback(IPedAidlInterface cb); + void registerCallback(in IPedAidlInterface cb); + void unregisterCallback(in IPedAidlInterface cb); void queryPedCount(); void queryPedRecord(); - void syncPedHeightSetting(int height); - void syncPedWeightSetting(int weight); + void syncPedHeightSetting(in int height); + void syncPedWeightSetting(in int weight); } diff --git a/app/src/main/aidl/com/ic/aidl/ped/RecordParcelable.java b/app/src/main/aidl/com/ic/aidl/ped/RecordParcelable.java index d393032..bfd29ef 100644 --- a/app/src/main/aidl/com/ic/aidl/ped/RecordParcelable.java +++ b/app/src/main/aidl/com/ic/aidl/ped/RecordParcelable.java @@ -16,23 +16,12 @@ public class RecordParcelable implements Parcelable { date = ""; } - public RecordParcelable(int number, String distance, String calorie, String date) { - this.number = number; - this.distance = distance; - this.calorie = calorie; - this.date = date; - } - public RecordParcelable(Parcel p) { - this.number = p.readInt(); - this.distance = p.readString(); - this.calorie = p.readString(); - this.date = p.readString(); - } - - @Override - public int describeContents() { - return 0; + protected RecordParcelable(Parcel in) { + number = in.readInt(); + distance = in.readString(); + calorie = in.readString(); + date = in.readString(); } @Override @@ -43,12 +32,18 @@ public class RecordParcelable implements Parcelable { dest.writeString(date); } - public static final Parcelable.Creator CREATOR - = new Parcelable.Creator() { + @Override + public int describeContents() { + return 0; + } + + public static final Creator CREATOR = new Creator() { + @Override public RecordParcelable createFromParcel(Parcel in) { return new RecordParcelable(in); } + @Override public RecordParcelable[] newArray(int size) { return new RecordParcelable[size]; } diff --git a/app/src/main/java/com/ic/work/WorkService.java b/app/src/main/java/com/ic/work/WorkService.java index 18a172a..3150e4a 100644 --- a/app/src/main/java/com/ic/work/WorkService.java +++ b/app/src/main/java/com/ic/work/WorkService.java @@ -45,7 +45,6 @@ import org.threeten.bp.LocalDateTime; import org.threeten.bp.ZoneId; import static com.ic.work.utils.ICWorkConstants.EventType.STEP_RECORD; -import static com.ic.work.utils.ICWorkConstants.EventType.STOP_ALL_TASK; import static com.ic.work.utils.ICWorkConstants.EventType.TEST_A9_BLOOD; import static com.ic.work.utils.ICWorkConstants.EventType.TEST_AK_BLOOD; import static com.ic.work.utils.ICWorkConstants.EventType.TEST_STEP; @@ -208,17 +207,9 @@ public class WorkService extends Service { } } - - /** - * 如果有任务在执行了,那么就是繁忙的。 - * 防止上层多次调用获取数据的动作。 - */ - private boolean mIsBusy = false; - - @Subscribe(threadMode = ThreadMode.MAIN) public void onTaskFinishedEvent(TaskFinishedEvent event) { - mIsBusy = false; + } /** @@ -234,17 +225,6 @@ public class WorkService extends Service { public void onMessageEvent(ThreadPoolEvent event) { int eventType = event.getEventType(); IcLog.i(TAG, "onMessageEvent EventType " + eventType); - if (eventType == STOP_ALL_TASK) { - ThreadPoolManager.getInstance().remove(); - mIsBusy = false; - return; - } - if (mIsBusy) { - IcLog.d(TAG, "task is running.."); - return; - } - //进来了就繁忙了,除非是停止了,也就是4的Case,停止检测 - mIsBusy = true; switch (eventType) { case TEST_STEP://脚步 ThreadPoolManager.getInstance().execute(new PedRunnable(mApp.getApplicationContext(), diff --git a/app/src/main/java/com/ic/work/hardware/PedRunnable.java b/app/src/main/java/com/ic/work/hardware/PedRunnable.java index df5db66..af5fc6c 100644 --- a/app/src/main/java/com/ic/work/hardware/PedRunnable.java +++ b/app/src/main/java/com/ic/work/hardware/PedRunnable.java @@ -7,7 +7,6 @@ import com.ic.work.event.PedCountEvent; import com.ic.work.event.TaskFinishedEvent; import com.ic.work.utils.HardwareUtils; import com.ic.work.utils.ICLogger; -import com.ic.work.utils.IcLog; import org.greenrobot.eventbus.EventBus; @@ -22,7 +21,7 @@ public class PedRunnable extends PedBaseRunnable implements Runnable { @Override public void run() { int ped = HardwareUtils.getNdkStepCountValue(); - IcLog.i(TAG, "Get Ped Count" + ped); + ICLogger.i("Get Ped Count" + ped); //发送给主线程。主线更新数据UI String calorieValue = getCalorieValue(ped); try { diff --git a/app/src/main/java/com/ic/work/process/PedProcess.java b/app/src/main/java/com/ic/work/process/PedProcess.java index 7605608..9748a6c 100644 --- a/app/src/main/java/com/ic/work/process/PedProcess.java +++ b/app/src/main/java/com/ic/work/process/PedProcess.java @@ -93,6 +93,8 @@ public class PedProcess { } public void sendPedRecord(List record) { + ICLogger.d("record == > " + record); + ICLogger.d("record size == > " + record.size()); int N = 0; try { N = mCallbacks.beginBroadcast();