1
2
3
4
5
6
7
8
9
10
11
12
| package com.example.serial;
|
| public class AdcControl {
| static {
| System.loadLibrary("serial");
| }
| public static native int openComport(String path, long baudRate, int dataBits, int parity, int stopBits, int flowControl);
| public static native int closeComport();
|
| public static native int sendToPort(String operate, String channel);
| public static native String recvFromPort(int len, int timeout);
| }
|
|