When you receive the notification, the parameter to your reachabilityChanged:
method will be the notification itself. To get the Reachability object, you'll need to get it from the notification by sending -[NSNotification object]
to the notification.
So something like this should work:
- (void) reachabilityChanged:(NSNotification *)note {
Reachability *reach = [note object];
if ([reach isReachable ]) {
NSLog(@"connection");
ServerFound = YES;
} else{
NSLog(@"no connection");
ServerFound = NO;
}
[self PrepareStream];
}