Skip to content

Commit 2bd9b91

Browse files
WallaceSitWallaceSit
authored andcommitted
2.1.29 Release
v2.1.29 • Try improving “other tags are still found in the Em4325 selectTag page” problem by adding selecting 4 more bits and by post filtering • Remove some unused codes
1 parent d6a347d commit 2bd9b91

File tree

8 files changed

+30
-17
lines changed

8 files changed

+30
-17
lines changed

app/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ android {
77
minSdkVersion 19
88
targetSdkVersion 30
99
versionCode 31
10-
versionName "2.1.28"
10+
versionName "2.1.29"
1111
}
1212
}
1313

app/src/main/java/com/csl/cs108ademoapp/InventoryRfidTask.java

Lines changed: 24 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -368,10 +368,10 @@ void inventoryHandler_tag() {
368368
extra2Bank = 2;
369369
data2_offset = 0;
370370
}
371-
if (strTid.contains("E2806894") == false) {
371+
/*if (strTid.contains("E2806894") == false) {
372372
MainActivity.mCs108Library4a.appendToLog("HelloK: Skip the record without strExtra1 E2806894: " + strEpc);
373373
return;
374-
}
374+
}*/
375375
}
376376
} else if (MainActivity.mDid.matches("E2806894C") || MainActivity.mDid.matches("E2806894d")) {
377377
if (strEpc.length() >= 4) {
@@ -382,10 +382,10 @@ void inventoryHandler_tag() {
382382
if (strExtra1 != null || MainActivity.mDid.matches("E2806894d")) {
383383
if (!(strExtra1 != null && strExtra1.length() == 8 && strExtra1.contains("E2806894"))) {
384384
matched = false;
385-
if (MainActivity.mDid.matches("E2806894d")) {
385+
/*if (MainActivity.mDid.matches("E2806894d")) {
386386
MainActivity.mCs108Library4a.appendToLog("HelloK: Skip the record without strExtra1 E2806894: " + strEpc);
387387
return;
388-
}
388+
}*/
389389
}
390390
}
391391
if (matched) {
@@ -396,6 +396,26 @@ void inventoryHandler_tag() {
396396
}
397397
}
398398
}
399+
400+
MainActivity.mCs108Library4a.appendToLog("strTidCompared = " + strMdid + ", MainActivity.mDid = " + MainActivity.mDid + ", strExtra1 = " + strExtra1 + ", strExtra2 = " + strExtra2);
401+
if (strMdid != null) {
402+
String strTidCompared = strMdid;
403+
if (strTidCompared.indexOf("E28011") == 0) strTidCompared = "E28011";
404+
if (strTidCompared.matches("E282402")) { }
405+
else if (strTidCompared.matches("E282403")) { }
406+
else if (strTidCompared.matches("E282405")) { }
407+
else if (strTidCompared.matches("E2806894") && MainActivity.mDid.matches("E2806894C")) { }
408+
else { //if (strMdid.matches("E280B0"))
409+
boolean bMatched = false;
410+
if (strExtra1 != null && strExtra1.indexOf(strTidCompared) == 0) {
411+
bMatched = true; MainActivity.mCs108Library4a.appendToLog("strExtra1 contains strTidCompared");
412+
} else if (strExtra2 != null && strExtra2.indexOf(strTidCompared) == 0) {
413+
bMatched = true; MainActivity.mCs108Library4a.appendToLog("strEXTRA2 contains strTidCompared");
414+
}
415+
if (bMatched == false) return;
416+
}
417+
}
418+
399419
rssi = rx000pkgData.decodedRssi;
400420
phase = rx000pkgData.decodedPhase;
401421
chidx = rx000pkgData.decodedChidx;

app/src/main/java/com/csl/cs108ademoapp/adapters/ColdChainAdapter.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ public Fragment getItem(int index) {
2626
fragment2 = fragment;
2727
break;
2828
case 0:
29-
fragment = InventoryRfidiMultiFragment.newInstance(true,"E280B");
29+
fragment = InventoryRfidiMultiFragment.newInstance(true,"E280B0");
3030
fragment0 = fragment;
3131
break;
3232
default:

app/src/main/java/com/csl/cs108ademoapp/fragments/InventoryRfidiMultiFragment.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -401,7 +401,7 @@ void startInventoryTask() {
401401
extra2Bank = 3;
402402
extra2Offset = 0x120;
403403
extra2Count = 1;
404-
} else if (mDid.indexOf("E280B") == 0) {
404+
} else if (mDid.indexOf("E280B0") == 0) {
405405
extra1Bank = 3;
406406
extra1Offset = 188;
407407
extra1Count = 2;

cs108library4a/build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ android {
66
minSdkVersion 19
77
targetSdkVersion 30
88
versionCode 31
9-
versionName "2.1.21"
10-
buildConfigField 'String', 'VERSION_NAME', "\"2.1.21\""
9+
versionName "2.1.22"
10+
buildConfigField 'String', 'VERSION_NAME', "\"2.1.22\""
1111

1212
testInstrumentationRunner 'androidx.test.runner.AndroidJUnitRunner'
1313
}

cs108library4a/src/main/java/com/csl/cs108library4a/BleConnector.java

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -160,8 +160,6 @@ public void onServicesDiscovered(BluetoothGatt gatt, int status) {
160160
if (true) appendToLog("status=" + status + ". restart discoverServices"); mBluetoothGatt.discoverServices();
161161
} else {
162162
UUID UUID_READER_SERVICE = UUID.fromString("00009800-0000-1000-8000-00805f9b34fb");
163-
if (serviceUUID2p1 != 1) UUID_READER_SERVICE = UUID.fromString("00009802-0000-1000-8000-00805f9b34fb");
164-
appendToLog("serviceUD1D2p1 = " + serviceUUID2p1);
165163
mReaderStreamOutCharacteristic = getCharacteristic(UUID_READER_SERVICE, UUID_READER_STREAM_OUT_CHARACTERISTIC);
166164
mReaderStreamInCharacteristic = getCharacteristic(UUID_READER_SERVICE, UUID_READER_STREAM_IN_CHARACTERISTIC);
167165
appendToLog("mReaderStreamOutCharacteristic flag = " + mReaderStreamOutCharacteristic.getProperties());

cs108library4a/src/main/java/com/csl/cs108library4a/BluetoothConnector.java

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -166,11 +166,7 @@ boolean isMatchBluetoothIcToWrite(Cs108Connector.Cs108ReadData cs108ReadData) {
166166
if (cs108ReadData.dataValues.length - 2 < length) length = cs108ReadData.dataValues.length - 2;
167167
System.arraycopy(cs108ReadData.dataValues, 2, mBluetoothIcVersion, 0, length);
168168
if (mBluetoothIcVersion[0] == 3) icsModel = 463;
169-
else if (mBluetoothIcVersion[0] == 1) {
170-
if (mBluetoothIcVersion[1] == 0 && mBluetoothIcVersion[2] < 10) icsModel = 710;
171-
else icsModel = 108;
172-
appendToLog("New Checkpoint with icsModel = " + icsModel);
173-
}
169+
else if (mBluetoothIcVersion[0] == 1) icsModel = 108;
174170
mBluetoothIcVersionUpdated = true;
175171
if (true) appendToLog("mBluetoothIcVersionUpdated is true");
176172
}

cs108library4a/src/main/java/com/csl/cs108library4a/ReaderDevice.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -211,7 +211,6 @@ public void setRssi(double rssi) {
211211
}
212212

213213
public int getServiceUUID2p1() { return serviceUUID2p1; }
214-
public void setServiceUUID2p1(int serviceUUID2p1) { this.serviceUUID2p1 = serviceUUID2p1; }
215214

216215
public int getPhase() { return phase; }
217216
public void setPhase(int phase) { this.phase = phase; }

0 commit comments

Comments
 (0)