Sub SendAlertToPebble(ThisAppsName As String, Header As String, Body As String)
Dim I As Intent,P As Phone, JSON As String ' , JSON As JSONGenerator , M As Map , alist As List
I.Initialize("com.getpebble.action.SEND_NOTIFICATION", "")
'SendAlertToPebble: [{"body":"TEST","title":"LCARS"}]
'alist.Initialize
'M.Initialize
'M.put("title", Header)
'M.put("body", Body)
'alist.Add(M)
'JSON.Initialize2(alist)
JSON = "[{""body"":""" & Body & """,""title"":""" & Header & """}]"
I.putExtra("messageType", "PEBBLE_ALERT")
I.putExtra("sender", ThisAppsName)
I.putExtra("notificationData", JSON )
'Log("SendAlertToPebble: " & JSON.ToString)
P.SendBroadcastIntent(I)
End Sub