implemented wiiuse_os_read for mac

This commit is contained in:
Lysann Schlegel
2012-11-10 23:26:56 +01:00
parent 8c2f22089a
commit 7e502b66d6
2 changed files with 140 additions and 16 deletions

View File

@@ -42,15 +42,6 @@
#import "../wiiuse_internal.h"
#if 0
#if defined(MAC_OS_X_VERSION_10_7) && MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_7
#define WIIUSE_MAC_OS_X_VERSION_10_7_OR_ABOVE 1
#else
#define WIIUSE_MAC_OS_X_VERSION_10_7_OR_ABOVE 0
#endif
#endif
@interface WiiuseWiimote : NSObject<IOBluetoothL2CAPChannelDelegate> {
wiimote* wm; // reference to the C wiimote struct
@@ -59,6 +50,9 @@
IOBluetoothL2CAPChannel* interruptChannel;
IOBluetoothUserNotification* disconnectNotification;
NSMutableArray* receivedData; // a queue os NSData*
NSLock* receivedDataLock;
}
- (id) initWithPtr: (wiimote*) wm device: (IOBluetoothDevice*) device;
@@ -66,6 +60,7 @@
- (IOReturn) connect;
- (void) disconnect;
- (int) read;
- (int) writeBuffer: (byte*) buffer length: (NSUInteger) length;
@end