1 2 3 4 5 6 7 8 9 10
// // CommunicationProtocol.h // DUREX Vendor Control // // Created by Imanol Barba on 5/23/14. // Copyright (c) 2014 Emmoco. All rights reserved. // #import <Foundation/Foundation.h>
11
#define MAX_STRING_LENGTH ((int)200)
12 13 14 15 16 17 18 19 20 21 22 23
#define MAX_RETRIES ((int)3) @interface CommunicationProtocol : NSObject -(Boolean) waitForMessageAvailable: (Boolean) status; -(Boolean) writeMessage: (NSString*) message; -(NSString*) readMessage; -(Boolean) establishConnection; +(id) sharedProtocol; @property Boolean messageAvailable; @end