#!/usr/bin/perl -w
# $URL: svn+ssh://mrwhat@ssh.boim.com/home/mrwhat/svn/Walker/trunk/gearPlates103x113.pl $
# $Id: gearPlates103x113.pl 420 2014-04-21 16:40:47Z mrwhat $
#
# script to draw Walker parts which can be cut from 2.5mm (0.100") stock
#
#  It appears that the supplier in Tucson has 0.098" stock which is actually 2.2mm thick.
#  (This may be the same thing as the "2mm" stock at Ponoko)
#  This is a good thickness (<~= 4.5mm/2) for cranklinks, EF, BH, D-fork, and gear side plates

$preview = $#ARGV < 0;  # set to 0 for actual size code generation... will generate REAL code if given any argument

require 'laserCutPartsGroups.pl';
require 'JansenDefs.pl';

($wPx,$hPx) = &parseSizeFromFileName($0);  # get this from file name to make SURE it matches

&printLaserCutHeader($wPx,$hPx);

print "\n<desc>Outer plates for drive gear</desc>\n";
local $x = 19;
local $y = 38;
local $dy = 2*($drivePlateOR+.15);
local $ra = $irA-$fuzz*.3; # let plates be tight on A-axle standoffs
local $rGear=16;
&printGearSide($x,$y,$ra,$rGear,$drivePlateOR);   $y+=$dy;
&printGearSide($x,$y,$ra,$rGear,$drivePlateOR);   $y+=$dy/2;  $x+=0.87*$dy;
&printGearSide($x,$y,$ra,$rGear,$drivePlateOR);   $y-=$dy;
&printGearSide($x,$y,$ra,$rGear,$drivePlateOR);   $y-=$dy;
&printGearSide($x,$y,$ra,$rGear,$drivePlateOR);   $y+=$dy/2; $x+=$dy*.87;
&printGearSide($x,$y,$ra,$rGear,$drivePlateOR);   $y+=$dy;
&printGearSide($x,$y,$ra,$rGear,$drivePlateOR);

print "</g></svg>\n"; # end of drawing
