Download RN4020 Bluetooth Low Energy Module User's Guide

Transcript
Application Examples
FIGURE 3-7:
WRITING VALUES TO PRIVATE CHARACTERISTICS
Notification on a private characteristic can also be enabled. The RN4020 module
will notify the host of the start of notification by the following status message,
which means the configuration of characteristic
0x111213141516171819101A1B1C1D1E1F has been written as 0x0001 (little
endian); therefore, the notification has been started.
WC,001F,0100
Once the notification has been started, the value of the private characteristic is
updated from the RN4020 module, and the updated value is displayed in the
BTLE BROWSER APP.
Use the following commands to update the value of the private characteristic:
SUW, 111213141516171819101A1B1C1D1E1F,AB90
// Set value 0x90AB to characteristic
// 0x111213141516171819101A1B1C1D1E1F
SHW,001E,EFCD
// Set value 0xCDEF to handle 0x001E, which is associated
// with characteristic 0x111213141516171819101A1B1C1D1E1F
The value of the private characteristic
0x111213141516171819101A1B1C1D1E1F will be updated automatically to
0x90AB and 0xCDEF, respectively, as shown in Figure 3-8.
 2014 Microchip Technology Inc.
DS70005191B-page 91