Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- added TempescopeControlDemo for controlling OpenTempescope from an iOS device
- Loading branch information
1 parent
74fd7d1
commit 3bae1cd
Showing
29 changed files
with
2,174 additions
and
0 deletions.
There are no files selected for viewing
511 changes: 511 additions & 0 deletions
511
...empescopeController/TempescopeControlDemo/TempescopeControlDemo.xcodeproj/project.pbxproj
Large diffs are not rendered by default.
Oops, something went wrong.
7 changes: 7 additions & 0 deletions
7
...eControlDemo/TempescopeControlDemo.xcodeproj/project.xcworkspace/contents.xcworkspacedata
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Binary file added
BIN
+26.7 KB
...xcodeproj/project.xcworkspace/xcuserdata/kenny.xcuserdatad/UserInterfaceState.xcuserstate
Binary file not shown.
10 changes: 10 additions & 0 deletions
10
...o.xcodeproj/project.xcworkspace/xcuserdata/kenny.xcuserdatad/WorkspaceSettings.xcsettings
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | ||
<plist version="1.0"> | ||
<dict> | ||
<key>HasAskedToTakeAutomaticSnapshotBeforeSignificantChanges</key> | ||
<true/> | ||
<key>SnapshotAutomaticallyBeforeSignificantChanges</key> | ||
<false/> | ||
</dict> | ||
</plist> |
96 changes: 96 additions & 0 deletions
96
...ntrolDemo.xcodeproj/xcuserdata/kenny.xcuserdatad/xcschemes/TempescopeControlDemo.xcscheme
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,96 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<Scheme | ||
LastUpgradeVersion = "0510" | ||
version = "1.3"> | ||
<BuildAction | ||
parallelizeBuildables = "YES" | ||
buildImplicitDependencies = "YES"> | ||
<BuildActionEntries> | ||
<BuildActionEntry | ||
buildForTesting = "YES" | ||
buildForRunning = "YES" | ||
buildForProfiling = "YES" | ||
buildForArchiving = "YES" | ||
buildForAnalyzing = "YES"> | ||
<BuildableReference | ||
BuildableIdentifier = "primary" | ||
BlueprintIdentifier = "B904C6A819CE3F6800C90432" | ||
BuildableName = "TempescopeControlDemo.app" | ||
BlueprintName = "TempescopeControlDemo" | ||
ReferencedContainer = "container:TempescopeControlDemo.xcodeproj"> | ||
</BuildableReference> | ||
</BuildActionEntry> | ||
</BuildActionEntries> | ||
</BuildAction> | ||
<TestAction | ||
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB" | ||
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB" | ||
shouldUseLaunchSchemeArgsEnv = "YES" | ||
buildConfiguration = "Debug"> | ||
<Testables> | ||
<TestableReference | ||
skipped = "NO"> | ||
<BuildableReference | ||
BuildableIdentifier = "primary" | ||
BlueprintIdentifier = "B904C6CC19CE3F6800C90432" | ||
BuildableName = "TempescopeControlDemoTests.xctest" | ||
BlueprintName = "TempescopeControlDemoTests" | ||
ReferencedContainer = "container:TempescopeControlDemo.xcodeproj"> | ||
</BuildableReference> | ||
</TestableReference> | ||
</Testables> | ||
<MacroExpansion> | ||
<BuildableReference | ||
BuildableIdentifier = "primary" | ||
BlueprintIdentifier = "B904C6A819CE3F6800C90432" | ||
BuildableName = "TempescopeControlDemo.app" | ||
BlueprintName = "TempescopeControlDemo" | ||
ReferencedContainer = "container:TempescopeControlDemo.xcodeproj"> | ||
</BuildableReference> | ||
</MacroExpansion> | ||
</TestAction> | ||
<LaunchAction | ||
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB" | ||
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB" | ||
launchStyle = "0" | ||
useCustomWorkingDirectory = "NO" | ||
buildConfiguration = "Debug" | ||
ignoresPersistentStateOnLaunch = "NO" | ||
debugDocumentVersioning = "YES" | ||
allowLocationSimulation = "YES"> | ||
<BuildableProductRunnable> | ||
<BuildableReference | ||
BuildableIdentifier = "primary" | ||
BlueprintIdentifier = "B904C6A819CE3F6800C90432" | ||
BuildableName = "TempescopeControlDemo.app" | ||
BlueprintName = "TempescopeControlDemo" | ||
ReferencedContainer = "container:TempescopeControlDemo.xcodeproj"> | ||
</BuildableReference> | ||
</BuildableProductRunnable> | ||
<AdditionalOptions> | ||
</AdditionalOptions> | ||
</LaunchAction> | ||
<ProfileAction | ||
shouldUseLaunchSchemeArgsEnv = "YES" | ||
savedToolIdentifier = "" | ||
useCustomWorkingDirectory = "NO" | ||
buildConfiguration = "Release" | ||
debugDocumentVersioning = "YES"> | ||
<BuildableProductRunnable> | ||
<BuildableReference | ||
BuildableIdentifier = "primary" | ||
BlueprintIdentifier = "B904C6A819CE3F6800C90432" | ||
BuildableName = "TempescopeControlDemo.app" | ||
BlueprintName = "TempescopeControlDemo" | ||
ReferencedContainer = "container:TempescopeControlDemo.xcodeproj"> | ||
</BuildableReference> | ||
</BuildableProductRunnable> | ||
</ProfileAction> | ||
<AnalyzeAction | ||
buildConfiguration = "Debug"> | ||
</AnalyzeAction> | ||
<ArchiveAction | ||
buildConfiguration = "Release" | ||
revealArchiveInOrganizer = "YES"> | ||
</ArchiveAction> | ||
</Scheme> |
27 changes: 27 additions & 0 deletions
27
...copeControlDemo.xcodeproj/xcuserdata/kenny.xcuserdatad/xcschemes/xcschememanagement.plist
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | ||
<plist version="1.0"> | ||
<dict> | ||
<key>SchemeUserState</key> | ||
<dict> | ||
<key>TempescopeControlDemo.xcscheme</key> | ||
<dict> | ||
<key>orderHint</key> | ||
<integer>0</integer> | ||
</dict> | ||
</dict> | ||
<key>SuppressBuildableAutocreation</key> | ||
<dict> | ||
<key>B904C6A819CE3F6800C90432</key> | ||
<dict> | ||
<key>primary</key> | ||
<true/> | ||
</dict> | ||
<key>B904C6CC19CE3F6800C90432</key> | ||
<dict> | ||
<key>primary</key> | ||
<true/> | ||
</dict> | ||
</dict> | ||
</dict> | ||
</plist> |
27 changes: 27 additions & 0 deletions
27
OpenTempescope/TempescopeController/TempescopeControlDemo/TempescopeRemote/AppDelegate.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
/* | ||
AppDelegate.h | ||
Released as part of the OpenTempescope project - http://tempescope.com/opentempescope/ | ||
Copyright (c) 2013 Ken Kawamoto. All right reserved. | ||
This library is free software; you can redistribute it and/or | ||
modify it under the terms of the GNU Lesser General Public | ||
License as published by the Free Software Foundation; either | ||
version 2.1 of the License, or (at your option) any later version. | ||
This library is distributed in the hope that it will be useful, | ||
but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
Lesser General Public License for more details. | ||
You should have received a copy of the GNU Lesser General Public | ||
License along with this library; if not, write to the Free Software | ||
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA | ||
*/ | ||
|
||
#import <UIKit/UIKit.h> | ||
|
||
@interface AppDelegate : UIResponder <UIApplicationDelegate> | ||
|
||
@property (strong, nonatomic) UIWindow *window; | ||
|
||
@end |
58 changes: 58 additions & 0 deletions
58
OpenTempescope/TempescopeController/TempescopeControlDemo/TempescopeRemote/AppDelegate.m
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
/* | ||
AppDelegate.m | ||
Released as part of the OpenTempescope project - http://tempescope.com/opentempescope/ | ||
Copyright (c) 2013 Ken Kawamoto. All right reserved. | ||
This library is free software; you can redistribute it and/or | ||
modify it under the terms of the GNU Lesser General Public | ||
License as published by the Free Software Foundation; either | ||
version 2.1 of the License, or (at your option) any later version. | ||
This library is distributed in the hope that it will be useful, | ||
but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
Lesser General Public License for more details. | ||
You should have received a copy of the GNU Lesser General Public | ||
License along with this library; if not, write to the Free Software | ||
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA | ||
*/ | ||
|
||
#import "AppDelegate.h" | ||
|
||
@implementation AppDelegate | ||
|
||
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions | ||
{ | ||
// Override point for customization after application launch. | ||
return YES; | ||
} | ||
|
||
- (void)applicationWillResignActive:(UIApplication *)application | ||
{ | ||
// Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. | ||
// Use this method to pause ongoing tasks, disable timers, and throttle down OpenGL ES frame rates. Games should use this method to pause the game. | ||
} | ||
|
||
- (void)applicationDidEnterBackground:(UIApplication *)application | ||
{ | ||
// Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. | ||
// If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. | ||
} | ||
|
||
- (void)applicationWillEnterForeground:(UIApplication *)application | ||
{ | ||
// Called as part of the transition from the background to the inactive state; here you can undo many of the changes made on entering the background. | ||
} | ||
|
||
- (void)applicationDidBecomeActive:(UIApplication *)application | ||
{ | ||
// Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. | ||
} | ||
|
||
- (void)applicationWillTerminate:(UIApplication *)application | ||
{ | ||
// Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. | ||
} | ||
|
||
@end |
40 changes: 40 additions & 0 deletions
40
OpenTempescope/TempescopeController/TempescopeControlDemo/TempescopeRemote/BLEBaseClass.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
// | ||
// BLEBaseClass.h | ||
// BLESerial_test_iPhone5 | ||
// | ||
// Created by 石井 孝佳 on 2013/11/12. | ||
// Copyright (c) 2013年 浅草ギ研. All rights reserved. | ||
// | ||
|
||
|
||
#import <Foundation/Foundation.h> | ||
#import <CoreBluetooth/CoreBluetooth.h> | ||
|
||
@class BLEDeviceClass; | ||
|
||
@protocol BLEDeviceClassDelegate | ||
- (void)didUpdateValueForCharacteristic:(BLEDeviceClass*)device Characteristic:(CBCharacteristic *)characteristic; | ||
@end | ||
|
||
@interface BLEDeviceClass : NSObject | ||
@property (strong) id<BLEDeviceClassDelegate> delegate; | ||
- (CBCharacteristic*)getCharacteristic:(NSString*)service_uuid characteristic:(NSString*)characteristic_uuid; | ||
- (BOOL)writeWithResponse:(CBCharacteristic*)characteristic value:(NSData*)data; | ||
- (BOOL)writeWithoutResponse:(CBCharacteristic*)characteristic value:(NSData*)data; | ||
- (BOOL)readRequest:(CBCharacteristic*)characteristic; | ||
- (BOOL)notifyRequest:(CBCharacteristic*)characteristic; | ||
|
||
- (NSString *)deviceID; | ||
@end | ||
|
||
@interface BLEBaseClass : NSObject | ||
@property (strong) NSMutableArray* Devices; | ||
|
||
- (id)init; | ||
- (BOOL)scanDevices:(NSString*)uuid; | ||
- (void)scanStop; | ||
- (BLEDeviceClass*)connectService:(NSString*)uuid; | ||
- (BLEDeviceClass*)connectAny; | ||
- (BOOL)disconnectService:(NSString*)uuid; | ||
- (void)printDevices; | ||
@end |
Oops, something went wrong.