Skip to content

Commit

Permalink
Fix bug in UsbI2cBaseDevice.writeRegBuffer(). Bump version to 1.0.1
Browse files Browse the repository at this point in the history
  • Loading branch information
3cky committed Jan 28, 2020
1 parent 476a8c4 commit b0d9f02
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ allprojects {
Add library to dependencies:
```gradle
dependencies {
implementation 'com.github.3cky:usb-i2c-android:v1.0'
implementation 'com.github.3cky:usb-i2c-android:1.0.1'
}
```

Expand Down
2 changes: 1 addition & 1 deletion lib/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ apply plugin: 'com.github.dcendents.android-maven'

project.archivesBaseName='usb-i2c-android'
group='com.github.3cky'
version='1.0'
version='1.0.1'

android {
compileSdkVersion 29
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ public void writeRegBuffer(int reg, byte[] buffer, int length) throws IOExceptio
try {
accessLock.lock();
int len = Math.min(length, MAX_MESSAGE_SIZE);
buffer[0] = (byte) reg;
UsbI2cBaseAdapter.this.buffer[0] = (byte) reg;
System.arraycopy(buffer, 0, UsbI2cBaseAdapter.this.buffer, 1, len);
write(UsbI2cBaseAdapter.this.buffer, len + 1);
} finally {
Expand Down

0 comments on commit b0d9f02

Please sign in to comment.