Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Sign in
Toggle navigation
A
AnchorCollect
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
hywang
AnchorCollect
Commits
a6536e2d
Commit
a6536e2d
authored
Oct 09, 2022
by
hywang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1.用阿里云的仓库
parent
387f4f1d
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
19 additions
and
1 deletion
+19
-1
BtService.java
app/src/main/java/com/phlx/anchorcollect/bt/BtService.java
+3
-0
build.gradle
build.gradle
+15
-0
gradle.properties
gradle.properties
+1
-1
No files found.
app/src/main/java/com/phlx/anchorcollect/bt/BtService.java
View file @
a6536e2d
...
@@ -5,6 +5,7 @@ import android.bluetooth.BluetoothDevice;
...
@@ -5,6 +5,7 @@ import android.bluetooth.BluetoothDevice;
import
android.content.Intent
;
import
android.content.Intent
;
import
android.os.IBinder
;
import
android.os.IBinder
;
import
android.util.Log
;
import
android.util.Log
;
import
android.widget.Toast
;
import
androidx.annotation.NonNull
;
import
androidx.annotation.NonNull
;
import
androidx.annotation.Nullable
;
import
androidx.annotation.Nullable
;
...
@@ -20,6 +21,7 @@ import cn.wandersnail.bluetooth.BTManager;
...
@@ -20,6 +21,7 @@ import cn.wandersnail.bluetooth.BTManager;
import
cn.wandersnail.bluetooth.ConnectCallback
;
import
cn.wandersnail.bluetooth.ConnectCallback
;
import
cn.wandersnail.bluetooth.Connection
;
import
cn.wandersnail.bluetooth.Connection
;
import
cn.wandersnail.bluetooth.EventObserver
;
import
cn.wandersnail.bluetooth.EventObserver
;
import
cn.wandersnail.commons.util.ToastUtils
;
import
me.goldze.mvvmhabit.bus.RxBus
;
import
me.goldze.mvvmhabit.bus.RxBus
;
public
class
BtService
extends
Service
implements
EventObserver
{
public
class
BtService
extends
Service
implements
EventObserver
{
...
@@ -68,6 +70,7 @@ public class BtService extends Service implements EventObserver {
...
@@ -68,6 +70,7 @@ public class BtService extends Service implements EventObserver {
String
data
=
new
String
(
value
);
String
data
=
new
String
(
value
);
Log
.
e
(
TAG
,
"onRead: "
+
data
);
Log
.
e
(
TAG
,
"onRead: "
+
data
);
// ToastUtils.showShort("onRead: " + data);
String
weightData
=
data
.
substring
(
data
.
indexOf
(
"wn"
)
+
3
,
data
.
indexOf
(
"kg"
)
-
2
);
String
weightData
=
data
.
substring
(
data
.
indexOf
(
"wn"
)
+
3
,
data
.
indexOf
(
"kg"
)
-
2
);
EventMsg
eventMsg
=
new
EventMsg
();
EventMsg
eventMsg
=
new
EventMsg
();
...
...
build.gradle
View file @
a6536e2d
...
@@ -4,6 +4,14 @@ buildscript {
...
@@ -4,6 +4,14 @@ buildscript {
repositories
{
repositories
{
google
()
google
()
maven
{
url
'http://maven.aliyun.com/nexus/content/groups/public/'
}
maven
{
url
'https://maven.aliyun.com/nexus/content/groups/public/'
}
maven
{
url
'https://maven.aliyun.com/repository/public/'
}
maven
{
url
'https://maven.aliyun.com/repository/central'
}
maven
{
url
'https://maven.aliyun.com/repository/google'
}
maven
{
url
'https://maven.aliyun.com/repository/gradle-plugin'
}
jcenter
()
jcenter
()
mavenCentral
()
mavenCentral
()
maven
{
url
'https://jitpack.io'
}
maven
{
url
'https://jitpack.io'
}
...
@@ -21,6 +29,13 @@ buildscript {
...
@@ -21,6 +29,13 @@ buildscript {
allprojects
{
allprojects
{
repositories
{
repositories
{
google
()
google
()
maven
{
url
'http://maven.aliyun.com/nexus/content/groups/public/'
}
maven
{
url
'https://maven.aliyun.com/nexus/content/groups/public/'
}
maven
{
url
'https://maven.aliyun.com/repository/public/'
}
maven
{
url
'https://maven.aliyun.com/repository/central'
}
maven
{
url
'https://maven.aliyun.com/repository/google'
}
maven
{
url
'https://maven.aliyun.com/repository/gradle-plugin'
}
jcenter
()
jcenter
()
mavenCentral
()
mavenCentral
()
maven
{
url
'https://jitpack.io'
}
maven
{
url
'https://jitpack.io'
}
...
...
gradle.properties
View file @
a6536e2d
...
@@ -16,4 +16,4 @@ org.gradle.jvmargs=-Xmx2048m
...
@@ -16,4 +16,4 @@ org.gradle.jvmargs=-Xmx2048m
# https://developer.android.com/topic/libraries/support-library/androidx-rn
# https://developer.android.com/topic/libraries/support-library/androidx-rn
android.useAndroidX
=
true
android.useAndroidX
=
true
# Automatically convert third-party libraries to use AndroidX
# Automatically convert third-party libraries to use AndroidX
android.enableJetifier
=
true
android.enableJetifier
=
true
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment