Add support for notification title. The notification buffer must contain the title and the message separated by a '\0' character.
If the buffer does not contain any \0, the whole buffer is considered to be the message of the notification. A default title will be displayed in the notification app.
This commit is contained in:
@@ -191,7 +191,6 @@ int Pinetime::Controllers::MusicService::OnCommand(uint16_t conn_handle, uint16_
|
||||
data[notifSize] = '\0';
|
||||
os_mbuf_copydata(ctxt->om, 0, notifSize, data);
|
||||
char *s = (char *) &data[0];
|
||||
NRF_LOG_INFO("DATA : %s", s);
|
||||
if (ble_uuid_cmp(ctxt->chr->uuid, (ble_uuid_t *) &msArtistCharUuid) == 0) {
|
||||
artistName = s;
|
||||
} else if (ble_uuid_cmp(ctxt->chr->uuid, (ble_uuid_t *) &msTrackCharUuid) == 0) {
|
||||
|
Reference in New Issue
Block a user