mirror of
https://github.com/bluekitchen/btstack.git
synced 2025-03-30 07:21:20 +00:00
events: RFCOMM_EVENT_OPEN_CHANNEL_COMPLETE -> RFCOMM_EVENT_CHANNEL_OPENED
This commit is contained in:
parent
f8f6a918bd
commit
c9eeefbc1a
@ -11,7 +11,7 @@ import com.bluekitchen.btstack.RFCOMMDataPacket;
|
||||
import com.bluekitchen.btstack.Util;
|
||||
import com.bluekitchen.btstack.event.BTstackEventState;
|
||||
import com.bluekitchen.btstack.event.HCIEventDisconnectionComplete;
|
||||
import com.bluekitchen.btstack.event.RFCOMMEventOpenChannelComplete;
|
||||
import com.bluekitchen.btstack.event.RFCOMMEventChannelOpened;
|
||||
import com.bluekitchen.btstack.event.SDPEventQueryComplete;
|
||||
import com.bluekitchen.btstack.event.SDPEventQueryRFCOMMService;
|
||||
|
||||
@ -76,9 +76,9 @@ public class SPPClientTest implements PacketHandler {
|
||||
break;
|
||||
|
||||
case w4_connected:
|
||||
if (packet instanceof RFCOMMEventOpenChannelComplete){
|
||||
RFCOMMEventOpenChannelComplete e = (RFCOMMEventOpenChannelComplete) packet;
|
||||
System.out.println("RFCOMMEventOpenChannelComplete with status " + e.getStatus());
|
||||
if (packet instanceof RFCOMMEventChannelOpened){
|
||||
RFCOMMEventChannelOpened e = (RFCOMMEventChannelOpened) packet;
|
||||
System.out.println("RFCOMMEventChannelOpened with status " + e.getStatus());
|
||||
if (e.getStatus() != 0) {
|
||||
System.out.println("RFCOMM channel open failed, status " + e.getStatus());
|
||||
} else {
|
||||
|
@ -24,7 +24,7 @@ import com.bluekitchen.btstack.event.HCIEventHardwareError;
|
||||
import com.bluekitchen.btstack.event.HCIEventInquiryComplete;
|
||||
import com.bluekitchen.btstack.event.HCIEventInquiryResultWithRssi;
|
||||
import com.bluekitchen.btstack.event.HCIEventRemoteNameRequestComplete;
|
||||
import com.bluekitchen.btstack.event.RFCOMMEventOpenChannelComplete;
|
||||
import com.bluekitchen.btstack.event.RFCOMMEventChannelOpened;
|
||||
import com.bluekitchen.btstack.event.SDPEventQueryComplete;
|
||||
import com.bluekitchen.btstack.event.SDPEventQueryRFCOMMService;
|
||||
|
||||
@ -313,8 +313,8 @@ public class MainActivity extends Activity implements PacketHandler {
|
||||
break;
|
||||
|
||||
case w4_connected:
|
||||
if (packet instanceof RFCOMMEventOpenChannelComplete){
|
||||
RFCOMMEventOpenChannelComplete e = (RFCOMMEventOpenChannelComplete) packet;
|
||||
if (packet instanceof RFCOMMEventChannelOpened){
|
||||
RFCOMMEventChannelOpened e = (RFCOMMEventChannelOpened) packet;
|
||||
if (e.getStatus() != 0) {
|
||||
addMessage("RFCOMM channel open failed, status " + e.getStatus());
|
||||
} else {
|
||||
|
Loading…
x
Reference in New Issue
Block a user