[[iPhone_Dev]]
[[ここ:http://www.iphone3.0sdk.com/]]や
[[ここ:http://iphonesdkdev.blogspot.com/2009/03/sample-source-code-iphone-os-30-peer-to.html]]によれば、
SDK 3.0 から Bluetooth を利用した Peer To Peer の接続が可能らしい。
>
Just saw a sample source code from the apple dev forum to sharing the testing the p2p bluetooth
What you need to do is to create a new project from OpenGL ES Application of iPhone OS 3.0 SDK template called it BluetoothSample
and past the codes as below and test, it should work on 2 iPhone 3G and iPod Touch 2nd gen only.
Then you need to add GameKit framework to build and go
<
BluetoothSampleAppDelegate.h
//
// BluetoothSampleAppDelegate.h
// BluetoothSample
//
#import "EAGLView.h"
#import <GameKit/GameKit.h>
@interface BluetoothSampleAppDelegate : NSObject {
UIWindow *window;
EAGLView *glView;
BluetoothSampleAppDelegate.m Select all
//
// BluetoothSampleAppDelegate.m
// BluetoothSample
//
#import "BluetoothSampleAppDelegate.h"
@implementation BluetoothSampleAppDelegate
@synthesize picker;
@synthesize session;