AlertService.h
891 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
//
// AlertService.h
// FMP_Proj
//
// Created by ken on 14-7-7.
// Copyright (c) 2014年 ken. All rights reserved.
//
#import <Foundation/Foundation.h>
#import <AudioToolbox/AudioToolbox.h>
#import "IAlert.h"
#import "DefaultAlert.h"
#import "MTKBleManager.h"
//00001802-0000-1000-8000-00805F9B34FB Immediate Alert Service uuid
extern NSString *const kAlertServiceUUIDString;
//00002A06-0000-1000-8000-00805F9B34FB
extern NSString *const kAlertLevelCharacteristicUUIDString;
typedef enum{
kAlertHighLevel=2,
kAlertMediumLevel=1,
kAlertNoLevel=0,
}AlertLevel;
@interface AlertService : NSObject{
DefaultAlert *defaultAlert;
}
+ (id) sharedInstance: (CBPeripheralManager *)peripheralManager;
- (void) initService;
- (void) alertFunc: (int8_t)value;
- (void) stopAlert;
//-(void)removeService;
@property (nonatomic) CBMutableCharacteristic *myCharacteristic;
@end