summaryrefslogtreecommitdiffstats
path: root/README.md
diff options
context:
space:
mode:
authorChristopher Peplin <chris.peplin@rhubarbtech.com>2014-03-20 14:44:58 -0400
committerChristopher Peplin <chris.peplin@rhubarbtech.com>2014-03-20 14:44:58 -0400
commit19b53e4dada2d696c3291bd77dd736cd5d3415bf (patch)
treed6d9be298f7d3ddbd3dc2cf31a6491e8928cb3f7 /README.md
parent6642105e16f6b52e51f08c376fbc349634588193 (diff)
Require byte arrays in JSON hex strings to have 2 chars per byte.
Diffstat (limited to 'README.md')
-rw-r--r--README.md6
1 files changed, 5 insertions, 1 deletions
diff --git a/README.md b/README.md
index dcfee281..01ca5f39 100644
--- a/README.md
+++ b/README.md
@@ -40,7 +40,9 @@ is sent as a JSON object, separated by newlines. The format of each object is:
**data** - up to 8 bytes of data from the CAN message's payload, represented as
a hexidecimal number in a string. Many JSON parser cannot handle 64-bit
- integers, which is why we are not using a numerical data type.
+ integers, which is why we are not using a numerical data type. Each byte in
+ the string *must* be represented with 2 characters, e.g. `0x1` is `0x01` - the
+ complete string must have an even number of characters.
## Diagnostic Messages
@@ -79,6 +81,8 @@ with this command format:
**payload** - (optional) up to 7 bytes of data for the request's payload
represented as a hexidecimal number in a string. Many JSON parser cannot
handle 64-bit integers, which is why we are not using a numerical data type.
+ Each byte in the string *must* be represented with 2 characters, e.g. `0x1`
+ is `0x01` - the complete string must have an even number of characters.
**parse_payload** - (optional, false by default) if true, the complete payload in the
response message will be parsed as a number and returned in the 'value' field of