小编Yas*_*ash的帖子

发送数据到蓝牙打印机

我正在使用 SimpleBluetoothLibrary 访问我的蓝牙打印机。现在我可以搜索可用设备,从列表中选择蓝牙打印机,连接到打印机。这些部分已完成。但我不知道如何将数据发送到打印机进行打印作业.这是onDeviceConnected方法。我从中获得了设备地址。但我想将数据发送到打印机。

@Override
            public void onDeviceConnected(BluetoothDevice device) {
                //a device is connected so you can now send stuff to it
                mTxt.setText("Connection Status:Connected:" + device.getAddress());

                Log.d("Mac_Address", device.getAddress());


            }
Run Code Online (Sandbox Code Playgroud)

android bluetooth

3
推荐指数
1
解决办法
1万
查看次数

标签 统计

android ×1

bluetooth ×1