Wiki

Clone wiki

compass / Message Exchange Protocol

Overview

I call it HRT ♡. HRT stands for Human Readable Text. ♡ stands for a heart. Pun intended.

Design decisions

As noted in overview, this is text-based, human-readable protocol enabling the following properties:

  • Outgoing message can be read before sending it, or written manually without any software involved
  • Incoming message is understandable by human, without any software involved

Definition

  • location = title latitude,longitude
  • title = any string, might include spaces
  • latitude = double in text representation, any precision, radix character is . (dot)
  • longitude = same as latitude

Title is optional. Any text after longitude should be ignored.

Example:

Kiev 50.462077,30.526421

Highlights

  • Description of protocol is complete, it doesnt imply anything which is not described above
  • It doesnt imply that there might be whitespaces between lat and lon: there might not be
  • It doesnt imply that there might be more that one whitespace between title and lat,lon: there might not be
  • Et cetera

Main goals

  • You can enter any location manually
  • You dont have to input valid XML to do so
  • You can see what youre sending
  • You can read what youve received
  • You can add note (title) to a location

Extensions

As stated in protocol description, any text after longitude is need to be ignored, this allows to implement extentions to the SMS messages sent out by CC by adding arbitrary text to the end of actual message.

Distress message consists of the following: "SOS" - 3 characters, whitespace - 1 char, "lat,lon" - 23 characters at the most, 27 characters overall. The rest of the 160 SMS symbols might be used for protocol extensions, but note that some bookmarks might have more than 3 characters in title and distress message might be extended in the future.

Therefore 60 characters are reserved for CC and 100 for protocol extensions. Overall layout is the following:

cc-distress-message.png

Alien URIs suport

maps.google.com

URI scheme: https://maps.google.com/maps?q=XXXX.YYYYYY+ZZZZ.QQQQQQ

  • XXXX.YYYYYY - latitude
  • ZZZZ.QQQQQQ - longitude

Maximum URL length: 54 characters

(www.)openstreetmap.org

URI scheme: http://www.openstreetmap.org/?mlat=XXXX.YYYYYY&mlon=ZZZZ.QQQQQQ

  • XXXX.YYYYYY - latitude
  • ZZZZ.QQQQQQ - longitude

Maximum URL length: 63 characters

Updated