{"id":47,"date":"2010-12-29T19:37:40","date_gmt":"2010-12-29T19:37:40","guid":{"rendered":"http:\/\/charlie-roberts.com\/Control\/?page_id=47"},"modified":"2010-12-29T19:37:40","modified_gmt":"2010-12-29T19:37:40","slug":"getting-custom-interfaces-on-your-device","status":"publish","type":"page","link":"http:\/\/charlie-roberts.com\/Control\/?page_id=47","title":{"rendered":"Getting Custom Interfaces On Your Device"},"content":{"rendered":"<p><strong>Getting JSON interfaces into Control<\/strong><\/p>\n<p>The easiest way to load your interfaces into Control is by placing them on a web server where Control can access them. Most operating systems come with a web server built into them. If you enable this web server and place your JSON files into the web server directories you can then access the files by pressing the + button at the top of the Interfaces tab. You&#8217;ll then be prompted to enter the URL of your interface file; if you&#8217;re on a home wifi network this will look similiar to the following:<\/p>\n<p>192.168.1.2\/~yourusername\/yourInterfaceName.js<\/p>\n<p>Once you enter the URL it should load immediately and will be saved for future use. It&#8217;s useful to add a button to refresh this file; that way you can make changes to the interface and see them on your phone just by pressing the refresh button. A typical button to refresh would be as follows:<\/p>\n<p><code><br \/>\n    {<br \/>\n        \"name\": \"refreshButton\",<br \/>\n        \"type\": \"Button\",<br \/>\n        \"x\": 0,<br \/>\n        \"y\": .85,<br \/>\n        \"width\": .15,<br \/>\n        \"height\": .15,<br \/>\n        \"mode\": \"momentary\",<br \/>\n        \"color\": \"#000000\",<br \/>\n        \"stroke\": \"#aaaaaa\",<br \/>\n        \"ontouchstart\": \"interfaceManager.refreshInterface()\",<br \/>\n    },<br \/>\n<\/code><\/p>\n<p>You can also push interfaces to Control using OSC. With Control launched, send the message \/pushInterface to the ip address Control is running on with the string of JSON as an argument. This only works for strings of less then 16 KB; larger interfaces won&#8217;t successfully transfer via this method.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Getting JSON interfaces into Control The easiest way to load your interfaces into Control is by placing them on a web server where Control can access them. Most operating systems come with a web server built into them. If you enable this web server and place your JSON files into the web server directories you [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"parent":32,"menu_order":0,"comment_status":"open","ping_status":"open","template":"","meta":{"_bbp_topic_count":0,"_bbp_reply_count":0,"_bbp_total_topic_count":0,"_bbp_total_reply_count":0,"_bbp_voice_count":0,"_bbp_anonymous_reply_count":0,"_bbp_topic_count_hidden":0,"_bbp_reply_count_hidden":0,"_bbp_forum_subforum_count":0,"footnotes":""},"class_list":["post-47","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"http:\/\/charlie-roberts.com\/Control\/index.php?rest_route=\/wp\/v2\/pages\/47","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/charlie-roberts.com\/Control\/index.php?rest_route=\/wp\/v2\/pages"}],"about":[{"href":"http:\/\/charlie-roberts.com\/Control\/index.php?rest_route=\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"http:\/\/charlie-roberts.com\/Control\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/charlie-roberts.com\/Control\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=47"}],"version-history":[{"count":1,"href":"http:\/\/charlie-roberts.com\/Control\/index.php?rest_route=\/wp\/v2\/pages\/47\/revisions"}],"predecessor-version":[{"id":48,"href":"http:\/\/charlie-roberts.com\/Control\/index.php?rest_route=\/wp\/v2\/pages\/47\/revisions\/48"}],"up":[{"embeddable":true,"href":"http:\/\/charlie-roberts.com\/Control\/index.php?rest_route=\/wp\/v2\/pages\/32"}],"wp:attachment":[{"href":"http:\/\/charlie-roberts.com\/Control\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=47"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}