Install¶
Edit the Build.gradle
file and add the following dependencies.
dependencies {
implementation 'cn.shanyaliux.serialport:serialport:4.2.0'
}
If you need to use 4.1.6
and below, do as follows:
Add
JitPack
repository Add theJitPack
repository to your build fileallprojects { repositories { ... maven { url 'https://jitpack.io' } } }
add dependencies
dependencies { implementation 'com.gitee.Shanya:SerialPortSample:4.1.6' //Chinese warehouse implementation 'com.github.Shanyaliux:SerialPortSample:4.1.6' //Foreign warehouse }