virtual boolean onWrite( LGATTWriteRequest & request );
virtual boolean onWrite( LGATTWriteRequest & request );
You need to override this method to handle a write action coming from the central device. You may store sendData or ACK after onRead() returns, Always respond the write request by calling ackOK() and ackFail() before this function returns. Otherwise it will lead to an undefined behavior.
|
Parameters |
Description |
|
LGATTWriteRequest & request |
Refer to LGATTWriteRequest. |
true: Successful.
false: Failed.
LGATTServer.h