From e2dd898bd991e53098903628efff3adf98d9a880 Mon Sep 17 00:00:00 2001
From: Andy Pugh <andy@bodgesoc.org>
Date: Tue, 1 Feb 2011 21:32:33 +0000
Subject: [PATCH 3/3] changes to Tormach sample config

Signed-off-by: Andy Pugh <andy@bodgesoc.org>
---
 configs/tormach/custom_postgui.hal |    2 +-
 configs/tormach/pcnc-1100.hal      |   14 +++++++-------
 2 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/configs/tormach/custom_postgui.hal b/configs/tormach/custom_postgui.hal
index 8e6e21c..5752158 100644
--- a/configs/tormach/custom_postgui.hal
+++ b/configs/tormach/custom_postgui.hal
@@ -2,7 +2,7 @@
 # The commands in this file are run after the AXIS GUI (including PyVCP panel)
 # starts
 # This file will not be overwritten when you run stepconf again
-net togout toggle.0.out not.0.in gearchange.0.sel pyvcp.highgear-led
+net togout toggle.0.out not.0.in gearchange.0.sel-2 pyvcp.highgear-led
 net logear not.0.out pyvcp.lowgear-led
 net gearswap toggle.0.in pyvcp.gearchange-button
 
diff --git a/configs/tormach/pcnc-1100.hal b/configs/tormach/pcnc-1100.hal
index 42ee7ad..1dab262 100644
--- a/configs/tormach/pcnc-1100.hal
+++ b/configs/tormach/pcnc-1100.hal
@@ -39,17 +39,17 @@ net spindle-ccw motion.spindle-reverse or2.0.in1
 # Spindle gear selection code.
 loadrt toggle count=1
 loadrt not count=1
-loadrt gearchange count=1
+loadrt gearchange num_gears=3
 addf toggle.0 servo-thread
 addf not.0 servo-thread
 addf gearchange.0 servo-thread
 setp toggle.0.debounce 0
-setp gearchange.0.min1 300
-setp gearchange.0.max1 1750
-setp gearchange.0.min2 750
-setp gearchange.0.max2 4450
-setp gearchange.0.scale2 2.5
-# we're not controlling the direction with the gearchanger, so reverse isn't set
+setp gearchange.0.min-1 250
+setp gearchange.0.max-1 2050
+setp gearchange.0.min-2 625
+setp gearchange.0.max-2 5120
+setp gearchange.0.scale-2 2.5
+# we're not controlling the direction with the gearchanger, so positive ratios
 # and the dir-in and dir-out pins aren't linked
 net spindle-speed-raw motion.spindle-speed-out gearchange.0.speed-in
 net spindle-speed gearchange.0.speed-out stepgen.4.velocity-cmd
-- 
1.7.0.4

