Permalink
Browse files

First commit

  • Loading branch information...
dhmspector committed Dec 5, 2009
0 parents commit d8f99d12ccb749eb4d86bec1c5f9f6680a938e4a
Showing with 9,247 additions and 0 deletions.
  1. +20 −0 Classes/CoreLocationTestAppDelegate.h
  2. +37 −0 Classes/CoreLocationTestAppDelegate.m
  3. +13 −0 Classes/FlipsideView.h
  4. +32 −0 Classes/FlipsideView.m
  5. +25 −0 Classes/FlipsideViewController.h
  6. +54 −0 Classes/FlipsideViewController.m
  7. +14 −0 Classes/MainView.h
  8. +32 −0 Classes/MainView.m
  9. +70 −0 Classes/MainViewController.h
  10. +371 −0 Classes/MainViewController.m
  11. +122 −0 Classes/Reachability/Reachability.h
  12. +585 −0 Classes/Reachability/Reachability.m
  13. +536 −0 FlipsideView.xib
  14. BIN Graphics/01-refresh.png
  15. BIN Graphics/103-map.png
  16. BIN Graphics/71-compass.png
  17. BIN Graphics/74-location.png
  18. BIN Graphics/Airport.png
  19. BIN Graphics/WWAN5.png
  20. BIN Graphics/map-marker.png
  21. BIN Graphics/red.png
  22. BIN Graphics/stop-32.png
  23. BIN Graphics/tack.png
  24. BIN Graphics/tack_small.png
  25. BIN Graphics/target.png
  26. BIN Graphics/target_small.png
  27. +1,224 −0 MainView.xib
  28. +183 −0 MainWindow.xib
  29. 0 README
  30. +34 −0 SensorToy-Info.plist
  31. BIN SensorToy.png
  32. +392 −0 SensorToy.xcodeproj/project.pbxproj
  33. +487 −0 SensorToy.xcodeproj/spector.pbxuser
  34. +1,491 −0 SensorToy.xcodeproj/spector.perspectivev3
  35. +14 −0 SensorToy_Prefix.pch
  36. BIN build/CoreLocationTest.build/CoreLocationTest.pbxindex/categories.pbxbtree
  37. BIN build/CoreLocationTest.build/CoreLocationTest.pbxindex/cdecls.pbxbtree
  38. BIN build/CoreLocationTest.build/CoreLocationTest.pbxindex/decls.pbxbtree
  39. BIN build/CoreLocationTest.build/CoreLocationTest.pbxindex/files.pbxbtree
  40. BIN build/CoreLocationTest.build/CoreLocationTest.pbxindex/imports.pbxbtree
  41. BIN build/CoreLocationTest.build/CoreLocationTest.pbxindex/pbxindex.header
  42. BIN build/CoreLocationTest.build/CoreLocationTest.pbxindex/protocols.pbxbtree
  43. BIN build/CoreLocationTest.build/CoreLocationTest.pbxindex/refs.pbxbtree
  44. BIN build/CoreLocationTest.build/CoreLocationTest.pbxindex/strings.pbxstrings/control
  45. BIN build/CoreLocationTest.build/CoreLocationTest.pbxindex/strings.pbxstrings/strings
  46. BIN build/CoreLocationTest.build/CoreLocationTest.pbxindex/subclasses.pbxbtree
  47. BIN build/CoreLocationTest.build/CoreLocationTest.pbxindex/symbols0.pbxsymbols
  48. BIN ...nTest.build/Debug-iphonesimulator/CoreLocationTest.build/CoreLocationTest-all-target-headers.hmap
  49. BIN ...tionTest.build/Debug-iphonesimulator/CoreLocationTest.build/CoreLocationTest-generated-files.hmap
  50. BIN ...nTest.build/Debug-iphonesimulator/CoreLocationTest.build/CoreLocationTest-own-target-headers.hmap
  51. BIN ...tionTest.build/Debug-iphonesimulator/CoreLocationTest.build/CoreLocationTest-project-headers.hmap
  52. +15 −0 build/CoreLocationTest.build/Debug-iphonesimulator/CoreLocationTest.build/CoreLocationTest.dep
  53. BIN build/CoreLocationTest.build/Debug-iphonesimulator/CoreLocationTest.build/CoreLocationTest.hmap
  54. +15 −0 build/CoreLocationTest.build/Debug-iphonesimulator/CoreLocationTest.build/CoreLocationTest~.dep
  55. +6 −0 ...ld/Debug-iphonesimulator/CoreLocationTest.build/Objects-normal/i386/CoreLocationTest.LinkFileList
  56. BIN ...ld/Debug-iphonesimulator/CoreLocationTest.build/Objects-normal/i386/CoreLocationTestAppDelegate.o
  57. BIN ...ocationTest.build/Debug-iphonesimulator/CoreLocationTest.build/Objects-normal/i386/FlipsideView.o
  58. BIN ...t.build/Debug-iphonesimulator/CoreLocationTest.build/Objects-normal/i386/FlipsideViewController.o
  59. BIN ...oreLocationTest.build/Debug-iphonesimulator/CoreLocationTest.build/Objects-normal/i386/MainView.o
  60. BIN ...nTest.build/Debug-iphonesimulator/CoreLocationTest.build/Objects-normal/i386/MainViewController.o
  61. BIN build/CoreLocationTest.build/Debug-iphonesimulator/CoreLocationTest.build/Objects-normal/i386/main.o
  62. +15 −0 build/CoreLocationTest.build/Debug-iphonesimulator/CoreLocationTest.build/SensorToy.dep
  63. +408 −0 build/CoreLocationTest.build/Debug-iphonesimulator/CoreLocationTest.build/build-state.dat
  64. +364 −0 build/CoreLocationTest.build/Debug-iphonesimulator/CoreLocationTest.build/build-state~.dat
  65. +20 −0 build/Debug-iphoneos/SensorToy.app.dSYM/Contents/Info.plist
  66. BIN build/Debug-iphoneos/SensorToy.app.dSYM/Contents/Resources/DWARF/SensorToy
  67. BIN build/Debug-iphoneos/SensorToy.app/01-refresh.png
  68. BIN build/Debug-iphoneos/SensorToy.app/103-map.png
  69. BIN build/Debug-iphoneos/SensorToy.app/71-compass.png
  70. BIN build/Debug-iphoneos/SensorToy.app/74-location.png
  71. +1 −0 build/Debug-iphoneos/SensorToy.app/CodeResources
  72. BIN build/Debug-iphoneos/SensorToy.app/FlipsideView.nib
  73. BIN build/Debug-iphoneos/SensorToy.app/Info.plist
  74. BIN build/Debug-iphoneos/SensorToy.app/MainView.nib
  75. BIN build/Debug-iphoneos/SensorToy.app/MainWindow.nib
  76. +1 −0 build/Debug-iphoneos/SensorToy.app/PkgInfo
  77. +25 −0 build/Debug-iphoneos/SensorToy.app/ResourceRules.plist
  78. BIN build/Debug-iphoneos/SensorToy.app/SensorToy.png
  79. +84 −0 build/Debug-iphoneos/SensorToy.app/_CodeSignature/CodeResources
  80. BIN build/Debug-iphoneos/SensorToy.app/embedded.mobileprovision
  81. BIN build/Debug-iphoneos/SensorToy.app/map-marker.png
  82. BIN build/Debug-iphoneos/SensorToy.app/tack.png
  83. BIN build/Debug-iphoneos/SensorToy.app/tack_small.png
  84. BIN build/Debug-iphoneos/SensorToy.app/target.png
  85. BIN build/Debug-iphoneos/SensorToy.app/target_small.png
  86. +18 −0 build/Debug-iphonesimulator/CoreLocationTest.app.dSYM/Contents/Info.plist
  87. BIN build/Debug-iphonesimulator/CoreLocationTest.app.dSYM/Contents/Resources/DWARF/CoreLocationTest
  88. BIN build/Debug-iphonesimulator/CoreLocationTest.app/CoreLocationTest
  89. BIN build/Debug-iphonesimulator/CoreLocationTest.app/FlipsideView.nib
  90. BIN build/Debug-iphonesimulator/CoreLocationTest.app/Info.plist
  91. BIN build/Debug-iphonesimulator/CoreLocationTest.app/MainView.nib
  92. BIN build/Debug-iphonesimulator/CoreLocationTest.app/MainWindow.nib
  93. +1 −0 build/Debug-iphonesimulator/CoreLocationTest.app/PkgInfo
  94. +18 −0 build/Debug-iphonesimulator/SensorToy.app.dSYM/Contents/Info.plist
  95. BIN build/Debug-iphonesimulator/SensorToy.app.dSYM/Contents/Resources/DWARF/SensorToy
  96. BIN build/Debug-iphonesimulator/SensorToy.app/FlipsideView.nib
  97. BIN build/Debug-iphonesimulator/SensorToy.app/Info.plist
  98. BIN build/Debug-iphonesimulator/SensorToy.app/MainView.nib
  99. BIN build/Debug-iphonesimulator/SensorToy.app/MainWindow.nib
  100. +1 −0 build/Debug-iphonesimulator/SensorToy.app/PkgInfo
  101. BIN build/Debug-iphonesimulator/SensorToy.app/SensorToy
  102. BIN ...SensorToy.build/Debug-iphoneos/SensorToy.build/Objects-normal/armv6/CoreLocationTestAppDelegate.o
  103. BIN build/SensorToy.build/Debug-iphoneos/SensorToy.build/Objects-normal/armv6/FlipsideView.o
  104. BIN build/SensorToy.build/Debug-iphoneos/SensorToy.build/Objects-normal/armv6/FlipsideViewController.o
  105. BIN build/SensorToy.build/Debug-iphoneos/SensorToy.build/Objects-normal/armv6/MainView.o
  106. BIN build/SensorToy.build/Debug-iphoneos/SensorToy.build/Objects-normal/armv6/MainViewController.o
  107. BIN build/SensorToy.build/Debug-iphoneos/SensorToy.build/Objects-normal/armv6/Reachability.o
  108. +7 −0 build/SensorToy.build/Debug-iphoneos/SensorToy.build/Objects-normal/armv6/SensorToy.LinkFileList
  109. BIN build/SensorToy.build/Debug-iphoneos/SensorToy.build/Objects-normal/armv6/main.o
  110. BIN build/SensorToy.build/Debug-iphoneos/SensorToy.build/SensorToy-all-target-headers.hmap
  111. BIN build/SensorToy.build/Debug-iphoneos/SensorToy.build/SensorToy-generated-files.hmap
  112. BIN build/SensorToy.build/Debug-iphoneos/SensorToy.build/SensorToy-own-target-headers.hmap
  113. BIN build/SensorToy.build/Debug-iphoneos/SensorToy.build/SensorToy-project-headers.hmap
  114. +48 −0 build/SensorToy.build/Debug-iphoneos/SensorToy.build/SensorToy.dep
  115. BIN build/SensorToy.build/Debug-iphoneos/SensorToy.build/SensorToy.hmap
  116. BIN build/SensorToy.build/Debug-iphoneos/SensorToy.build/SensorToy.xcent
  117. +18 −0 build/SensorToy.build/Debug-iphoneos/SensorToy.build/SensorToy~.dep
  118. +1,105 −0 build/SensorToy.build/Debug-iphoneos/SensorToy.build/build-state.dat
  119. +474 −0 build/SensorToy.build/Debug-iphoneos/SensorToy.build/build-state~.dat
  120. BIN ...Toy.build/Debug-iphonesimulator/SensorToy.build/Objects-normal/i386/CoreLocationTestAppDelegate.o
  121. BIN build/SensorToy.build/Debug-iphonesimulator/SensorToy.build/Objects-normal/i386/FlipsideView.o
  122. BIN ...ensorToy.build/Debug-iphonesimulator/SensorToy.build/Objects-normal/i386/FlipsideViewController.o
  123. BIN build/SensorToy.build/Debug-iphonesimulator/SensorToy.build/Objects-normal/i386/MainView.o
  124. BIN build/SensorToy.build/Debug-iphonesimulator/SensorToy.build/Objects-normal/i386/MainViewController.o
  125. +6 −0 .../SensorToy.build/Debug-iphonesimulator/SensorToy.build/Objects-normal/i386/SensorToy.LinkFileList
  126. BIN build/SensorToy.build/Debug-iphonesimulator/SensorToy.build/Objects-normal/i386/main.o
  127. BIN build/SensorToy.build/Debug-iphonesimulator/SensorToy.build/SensorToy-all-target-headers.hmap
  128. BIN build/SensorToy.build/Debug-iphonesimulator/SensorToy.build/SensorToy-generated-files.hmap
  129. BIN build/SensorToy.build/Debug-iphonesimulator/SensorToy.build/SensorToy-own-target-headers.hmap
  130. BIN build/SensorToy.build/Debug-iphonesimulator/SensorToy.build/SensorToy-project-headers.hmap
  131. +15 −0 build/SensorToy.build/Debug-iphonesimulator/SensorToy.build/SensorToy.dep
  132. BIN build/SensorToy.build/Debug-iphonesimulator/SensorToy.build/SensorToy.hmap
  133. +15 −0 build/SensorToy.build/Debug-iphonesimulator/SensorToy.build/SensorToy~.dep
  134. +407 −0 build/SensorToy.build/Debug-iphonesimulator/SensorToy.build/build-state.dat
  135. +407 −0 build/SensorToy.build/Debug-iphonesimulator/SensorToy.build/build-state~.dat
  136. BIN build/SensorToy.build/SensorToy.pbxindex/categories.pbxbtree
  137. BIN build/SensorToy.build/SensorToy.pbxindex/cdecls.pbxbtree
  138. BIN build/SensorToy.build/SensorToy.pbxindex/decls.pbxbtree
  139. BIN build/SensorToy.build/SensorToy.pbxindex/files.pbxbtree
  140. BIN build/SensorToy.build/SensorToy.pbxindex/imports.pbxbtree
  141. BIN build/SensorToy.build/SensorToy.pbxindex/pbxindex.header
  142. BIN build/SensorToy.build/SensorToy.pbxindex/protocols.pbxbtree
  143. BIN build/SensorToy.build/SensorToy.pbxindex/refs.pbxbtree
  144. BIN build/SensorToy.build/SensorToy.pbxindex/strings.pbxstrings/control
  145. BIN build/SensorToy.build/SensorToy.pbxindex/strings.pbxstrings/strings
  146. BIN build/SensorToy.build/SensorToy.pbxindex/subclasses.pbxbtree
  147. BIN build/SensorToy.build/SensorToy.pbxindex/symbols0.pbxsymbols
  148. +17 −0 main.m
@@ -0,0 +1,20 @@
+//
+// CoreLocationTestAppDelegate.h
+// CoreLocationTest
+//
+// Created by David HM Spector on 12/3/09.
+// Copyright Zeitgeist Information Systems 2009. All rights reserved.
+//
+
+@class MainViewController;
+
+@interface CoreLocationTestAppDelegate : NSObject <UIApplicationDelegate> {
+ UIWindow *window;
+ MainViewController *mainViewController;
+}
+
+@property (nonatomic, retain) IBOutlet UIWindow *window;
+@property (nonatomic, retain) MainViewController *mainViewController;
+
+@end
+
@@ -0,0 +1,37 @@
+//
+// CoreLocationTestAppDelegate.m
+// CoreLocationTest
+//
+// Created by David HM Spector on 12/3/09.
+// Copyright Zeitgeist Information Systems 2009. All rights reserved.
+//
+
+#import "CoreLocationTestAppDelegate.h"
+#import "MainViewController.h"
+
+@implementation CoreLocationTestAppDelegate
+
+
+@synthesize window;
+@synthesize mainViewController;
+
+
+- (void)applicationDidFinishLaunching:(UIApplication *)application {
+
+ MainViewController *aController = [[MainViewController alloc] initWithNibName:@"MainView" bundle:nil];
+ self.mainViewController = aController;
+ [aController release];
+
+ mainViewController.view.frame = [UIScreen mainScreen].applicationFrame;
+ [window addSubview:[mainViewController view]];
+ [window makeKeyAndVisible];
+}
+
+
+- (void)dealloc {
+ [mainViewController release];
+ [window release];
+ [super dealloc];
+}
+
+@end
@@ -0,0 +1,13 @@
+//
+// FlipsideView.h
+// CoreLocationTest
+//
+// Created by David HM Spector on 12/3/09.
+// Copyright Zeitgeist Information Systems 2009. All rights reserved.
+//
+
+@interface FlipsideView : UIView {
+
+}
+
+@end
@@ -0,0 +1,32 @@
+//
+// FlipsideView.m
+// CoreLocationTest
+//
+// Created by David HM Spector on 12/3/09.
+// Copyright Zeitgeist Information Systems 2009. All rights reserved.
+//
+
+#import "FlipsideView.h"
+
+@implementation FlipsideView
+
+
+- (id)initWithFrame:(CGRect)frame {
+ if (self = [super initWithFrame:frame]) {
+ // Initialization code
+ }
+ return self;
+}
+
+
+- (void)drawRect:(CGRect)rect {
+ // Drawing code
+}
+
+
+- (void)dealloc {
+ [super dealloc];
+}
+
+
+@end
@@ -0,0 +1,25 @@
+//
+// FlipsideViewController.h
+// CoreLocationTest
+//
+// Created by David HM Spector on 12/3/09.
+// Copyright Zeitgeist Information Systems 2009. All rights reserved.
+//
+
+@protocol FlipsideViewControllerDelegate;
+
+
+@interface FlipsideViewController : UIViewController {
+ id <FlipsideViewControllerDelegate> delegate;
+}
+
+@property (nonatomic, assign) id <FlipsideViewControllerDelegate> delegate;
+- (IBAction)done;
+
+@end
+
+
+@protocol FlipsideViewControllerDelegate
+- (void)flipsideViewControllerDidFinish:(FlipsideViewController *)controller;
+@end
+
@@ -0,0 +1,54 @@
+//
+// FlipsideViewController.m
+// CoreLocationTest
+//
+// Created by David HM Spector on 12/3/09.
+// Copyright Zeitgeist Information Systems 2009. All rights reserved.
+//
+
+#import "FlipsideViewController.h"
+
+
+@implementation FlipsideViewController
+
+@synthesize delegate;
+
+
+- (void)viewDidLoad {
+ [super viewDidLoad];
+ self.view.backgroundColor = [UIColor viewFlipsideBackgroundColor];
+}
+
+
+- (IBAction)done {
+ [self.delegate flipsideViewControllerDidFinish:self];
+}
+
+
+/*
+ // Override to allow orientations other than the default portrait orientation.
+ - (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation {
+ // Return YES for supported orientations
+ return (interfaceOrientation == UIInterfaceOrientationPortrait);
+ }
+ */
+
+- (void)didReceiveMemoryWarning {
+ // Releases the view if it doesn't have a superview.
+ [super didReceiveMemoryWarning];
+
+ // Release any cached data, images, etc that aren't in use.
+}
+
+- (void)viewDidUnload {
+ // Release any retained subviews of the main view.
+ // e.g. self.myOutlet = nil;
+}
+
+
+- (void)dealloc {
+ [super dealloc];
+}
+
+
+@end
@@ -0,0 +1,14 @@
+//
+// MainView.h
+// CoreLocationTest
+//
+// Created by David HM Spector on 12/3/09.
+// Copyright Zeitgeist Information Systems 2009. All rights reserved.
+//
+
+#import <UIKit/UIKit.h>
+
+
+@interface MainView : UIView {
+}
+@end
@@ -0,0 +1,32 @@
+//
+// MainView.m
+// CoreLocationTest
+//
+// Created by David HM Spector on 12/3/09.
+// Copyright Zeitgeist Information Systems 2009. All rights reserved.
+//
+
+#import "MainView.h"
+
+@implementation MainView
+
+
+- (id)initWithFrame:(CGRect)frame {
+ if (self = [super initWithFrame:frame]) {
+ // Initialization code
+ }
+ return self;
+}
+
+
+- (void)drawRect:(CGRect)rect {
+ // Drawing code
+}
+
+
+- (void)dealloc {
+ [super dealloc];
+}
+
+
+@end
@@ -0,0 +1,70 @@
+//
+// MainViewController.h
+// CoreLocationTest
+//
+// Created by David HM Spector on 12/3/09.
+// Copyright Zeitgeist Information Systems 2009. All rights reserved.
+//
+
+#import "FlipsideViewController.h"
+#import <MapKit/MapKit.h>
+#import <MapKit/MKAnnotation.h>
+#import <MapKit/MKReverseGeocoder.h>
+#import <CoreLocation/CoreLocation.h>
+#import "Reachability.h" // Apple's "reachability code"
+
+#define kOne32ndCompassDivision 11.25
+
+@interface MainViewController : UIViewController <FlipsideViewControllerDelegate, MKReverseGeocoderDelegate, MKMapViewDelegate, UIAccelerometerDelegate, CLLocationManagerDelegate> {
+ // the MapKit parts
+ IBOutlet UILabel *currentLocation;
+ IBOutlet UILabel *currentElevation;
+ IBOutlet UILabel *currentHeading;
+ IBOutlet UILabel *currentSpeed;
+ IBOutlet UISwitch *coreLocationSwitch;
+ IBOutlet UILabel *lastUpdateTime;
+ IBOutlet UILabel *whichNetwork;
+ IBOutlet UIButton *showInfo;
+ IBOutlet MKMapView *mapView;
+
+ // The Accelerometers Parts
+ IBOutlet UILabel *xLabel;
+ IBOutlet UILabel *yLabel;
+ IBOutlet UILabel *zLabel;
+ IBOutlet UIProgressView *xBar;
+ IBOutlet UIProgressView *yBar;
+ IBOutlet UIProgressView *zBar;
+
+ NetworkStatus remoteHostStatus;
+ NetworkStatus internetConnectionStatus;
+ NetworkStatus localWiFiConnectionStatus;
+
+
+ MKPlacemark *mPlacemark;
+ MKReverseGeocoder *geoCoder;
+ UIAccelerometer *accelerometer;
+ CLLocationManager *locationManager;
+ NSDateFormatter *dateFormatter;
+
+ BOOL loc_service_active;
+
+}
+
+/*
+@property (nonatomic, retain) UILabel *currentLocation;
+@property (nonatomic, retain) UILabel *currentElevation;
+ @property (nonatomic, retain) UILabel *currentHeading;
+ @property (nonatomic, retain) UILabel *currentSpeed;
+ @property (nonatomic, retain) UILabel *lastUpdateTime;
+@property (nonatomic, retain) UISwitch *coreLocationSwitch;
+@property (nonatomic, retain) MKMapView *mapView;
+@property (nonatomic, retain) MKPlacemark *mPlacemark;
+@property (nonatomic, retain) MKReverseGeocoder *geoCoder;
+*/
+
+- (IBAction)toggleCoreLocation;
+- (IBAction) showUserLocation;
+- (IBAction) toggleMapType;
+
+
+@end
Oops, something went wrong.

0 comments on commit d8f99d1

Please sign in to comment.