Created
July 21, 2015 23:35
-
-
Save redaphid/5dc1830a0318c0632e60 to your computer and use it in GitHub Desktop.
The Tentacle Message Formats
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"options": { | |
"port" : "/dev/tty.usbmodem14110000.1", | |
"broadcastPins" : true, | |
"broadcastInterval": 2500, | |
"pins": [ | |
{"action" : "digitalWrite", "number" : 7}, | |
{"action" : "analogRead", "number" : 15} | |
] | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"type": "object", | |
"required": [ | |
"pins" | |
], | |
"properties": { | |
"pins": { | |
"title": "Pin Configuration", | |
"type": "array", | |
"default": [], | |
"items": { | |
"type": "object", | |
"properties": { | |
"number": { | |
"title": "Number", | |
"type": "integer", | |
"minimum": 0 | |
}, | |
"action": { | |
"title": "Action", | |
"type": "string", | |
"enum": [ | |
"digitalRead" , | |
"digitalWrite" , | |
"analogRead", | |
"analogWrite", | |
"servoWrite", | |
"pwmWrite", | |
"i2cWrite", | |
"i2cRead", | |
"ignore" | |
] | |
} | |
}, | |
"required": [ | |
"number", | |
"action" | |
] | |
} | |
}, | |
"broadcastPins" : { | |
"title" : "Broadcast Pins?", | |
"type": "boolean", | |
"default": false | |
}, | |
"broadcastInterval" : { | |
"title" : "Broadcast Interval (ms)", | |
"type" : "number", | |
"default" : 2000, | |
"minimum": 15 | |
} | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"devices": "ff12c403-04c7-4e63-9073-2e3b1f8e4450", | |
"payload": { | |
"pins": [ | |
{ "action" : "analogRead", "number": 16}, | |
{ "action" : "digitalWrite", "number": 13, "value": 1}, | |
] | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"type": "object", | |
"required": [ | |
"pins" | |
], | |
"properties": { | |
"customData" : { | |
"type": "string" | |
}, | |
"pins": { | |
"title": "Pin Configuration", | |
"type": "array", | |
"default": [], | |
"items": { | |
"type": "object", | |
"properties": { | |
"number": { | |
"title": "Number", | |
"type": "integer", | |
"minimum": 0, | |
"default": 13 | |
}, | |
"action": { | |
"title": "Action", | |
"type": "string", | |
"enum": [ | |
"digitalRead" , | |
"digitalWrite" , | |
"analogRead", | |
"analogWrite", | |
"servoWrite", | |
"pwmWrite", | |
"i2cWrite", | |
"i2cRead" | |
] | |
}, | |
"value": { | |
"type": "integer", | |
"default": 1 | |
} | |
}, | |
"required": [ | |
"number", | |
"action" | |
] | |
} | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment