From aadca73b175af92b7862e1b5766893b074aec106 Mon Sep 17 00:00:00 2001 From: Sandy Noble Date: Sun, 27 May 2018 23:05:45 +0100 Subject: [PATCH 1/2] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index eb8137d..6c68d9e 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ polargraphcontroller ==================== Polargraph controller -Copyright Sandy Noble 2015. +Copyright Sandy Noble 2018. - Requires the excellent ControlP5 GUI library available from https://github.com/sojamo/controlp5. - Requires the excellent Geomerative library available from http://www.ricardmarxer.com/geomerative/. From 75fe43ddcb195ef2bf017587968e41a66f5e2467 Mon Sep 17 00:00:00 2001 From: Sandy Noble Date: Sun, 19 Aug 2018 16:48:04 +0100 Subject: [PATCH 2/2] Added handler for 5-part SYNC command. --- polargraphcontroller.pde | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/polargraphcontroller.pde b/polargraphcontroller.pde index cc75a80..93e6154 100644 --- a/polargraphcontroller.pde +++ b/polargraphcontroller.pde @@ -2383,6 +2383,16 @@ void readMachinePosition(String sync) currentMachinePos.y = b; currentMachinePos = getDisplayMachine().inMM(getDisplayMachine().asCartesianCoords(currentMachinePos)); } + else if (splitted.length == 5) + { + String currentAPos = splitted[2]; + String currentBPos = splitted[3]; + Float a = Float.valueOf(currentAPos).floatValue(); + Float b = Float.valueOf(currentBPos).floatValue(); + currentMachinePos.x = a; + currentMachinePos.y = b; + currentMachinePos = getDisplayMachine().inMM(getDisplayMachine().asCartesianCoords(currentMachinePos)); + } } void readCartesianMachinePosition(String sync) {