Sunday, 1 July 2018

Deckel FP2 restoration Year 1966, Serial # 5151

Almost two years since I got the machine, and many hours later, the restore is complete. Thanks to www.metalworker.eu, Bruce and some other helpful fellows at https://www.practicalmachinist.com/vb/deckel-maho-aciera-abene-mills/deckel-fp2-1966-restoration-321812/

The machine runs incredibly quiet and is an absolute pleasure to use!



Saturday, 30 June 2018

Surface Speeds - for the Deckel FP2


No more fiddling with a calculator


RPM settings and corresponding surface speeds

Ranges are for HSS tools, extracted from the SO single lip cutter grinder manual. For me, this this is a good starting point for simple cutters. Modern geometries are specified by the manufacturer.

More reading
http://www.stahl-online.de/wp-content/uploads/2013/10/MB137_Zerspanen_von_Stahl.pdf

Sunday, 3 June 2018

Lathe V Ways Calculation for fitting Tailstock and Carriage _/\_

While rebuilding the Chipmaster, the problem of aligning the carriage bed ways ( bottom slide ) and top slide arise, from what information I can find these have to be at right angles. The bottom slide is worn bananas, so a simple spotting technique, on the bed might cause a lot of headache later to align the cross slide. So I decided to align the tail stock base first, and then use it on the lathe to check which original sufaces on the crosslide are closest to allignment, to be used on the mill setup.  I will then cleanup the V groves at the bottom, and do the final spot checking on the lathe beds. So the approach requires three steps.
1) Align the tail-stock on the mill, and touch-up the V slot, and flat surface. Machine one outside surface parallel to the V-Groves. Final fit on the lathe with transfer spotting.

2) Find the best reference surface on the carriage with the fitted tail-stock base as guide. Or bolt an adjustable bar to the back, where the taper attachment usually attaches.

3) Machine the cross-slide base V and flat ways, aligned to identified surface. Fit with transfer bluing.

The calculation for the depth of the V slots require similar math to that used for dovetail calculations. I used two 14 mm end mills as gauge pins, the bottom circle is used for measuring the depth, when the base is upside down on the mill, since I want to do the machining in one setup.

Height with14mm gauge pin in V slot, should be z higher than flat surface          
              
On the drawing, the top two 14mm gauge pins are used to  measure the_ /\_ ways, the
bottom gauge pin is used to measure height over the flat surface, for a level tail stock base.          
              
map the flat surface to find low points, add z, mill out v until this height is reached          
mill down flat surface         






                 measured    38,515    across pins
c1,c2,c3    r    7   
                 a    24,515    measured-2r
                 b    4,949747468   
                 c    2,050252532    r-b
                2d    14,61550506   
                d    7,307752532   
                h    9,358005063    c+d
               w    18,71601013    2*height
               e    9,899494937   
              c3    center    0,541489873    e-h
              z    7,541489873    r+c3 center

Sunday, 20 May 2018

Quadrature decoder ideas for glass scales and rotary encoders on Arduino and AVR

Ever wonder how the Heidenhain glass scales, can measure at increments of 0,5 µm? if the graduation on the scale is only 20um? If you come from the digital world, there are four transitions so the minimum should be 4um.
This mystery made me read up on the Heidenhain signals 1VPP or 11 µAPP ( 1VSS, 11 µASS ) These are analog signals, if you read the older literature it becomes clear that photo sensitive devices are used to generate the current, the 1Vpp signals are probably pre-loaded with a 90ohm resistor. 
Vernier scales are similar, so are modulation techniques like QAM, QPSK. With glass scales there is no amplitude or phase modulation on top of the carrier, only two orthogonal signals, the rotational relationship between the two base-band signals (I/Q) translates to position, speed and velocity. 
So what advantages do analog signals have over digital? The states are infinite, limited only by noise. But how to extract infinite states from two orthogonal signals? Run them through an AD converter and calculate the angle., this will work but the system response is limited by conversion rate and calculation performance.

Investigating further I stumbled on CORDIC https://en.wikipedia.org/wiki/CORDIC

With a search for CORDIC Quardrature decoder, I found various other methods of Sine/Cosine to Digital Conversion
http://www.ichaus.de/upload/pdf/WP7en_High-Precision_Interpolation_140124.pdf

  Flash Conversion

 Vector -Tracking Conversion

 SAR Conversion with Sample-and- Hold Stage

 Continuous -Sampling A/D Conversion
Out of pure curiosity, I will implement the continuous sampling conversion with CORDIS lookup on the Arduino, and perhaps try the vector tracking conversion on the Attiny2313
Should this work, I will try to convert my Sino Digital scales to analog and see what accuracy I can achieve. Perhaps even build a Heidenhain scale interface for the Touch DRO Project.

Resources 

CORDIC


https://eprints.soton.ac.uk/267873/1/tcas1_cordic_review.pdf

https://www.mikrocontroller.net/articles/AVR-CORDIC

Linear interpolation

https://www.mikrocontroller.net/articles/AVR_Arithmetik/Sinus_und_Cosinus_(Lineare_Interpolation) 

Fast Sampling on AVR
http://yaab-arduino.blogspot.com/2015/02/fast-sampling-from-analog-input.html


http://wiki.linuxcnc.org/cgi-bin/wiki.pl?ResolverToQuadratureConverter


Tuesday, 15 May 2018

Useful code snips for working with XML, CSV, and other flat file formats in perl, groovy, python, java, c, c++

Lock files in Windows batch scripts, avoid more than one instance running

REM Check if another instance is running, and exit if true
IF EXIST ".lock" exit 0

echo Batch file start at %time% %date% by %username%.> .lock

REM Script processing starts here

REM Script processing ends here
del .lock


Replace XML tag data with Perl

use strict;
use warnings;
use XML::Twig;

for ( glob "*.xml" ) {
        print "process file $_\n";

XML::Twig->new(
    pretty_print  => 'indented',
    twig_handlers => {
         PaymentAmount => sub {
            $_->set_text( '0' )->flush
        },
    },
)->parsefile_inplace( $_, 'orig_*' );

Groovy and Tokenize or Split

While using tokenize() if you want to discard fields or lines with no data might work as such,

List myList =  inputStream.getText().tokenize("\n\r")

it can not be used if you want to retain the offset format of CSV or pipe delimited fields, since it will not yield the entries with no data.

As example the second field will be discarded. "Line1"|"""|"Name"

Here we will need to use split

List lHeader = sHeader.split("\\|")

Another odd behavior is if you split with a pipe without escapes, "|", split returns an array of characters. This is probably documented, but I did not have the time yet to read all the documentation and can not find any reference to this behavior.

Sunday, 15 April 2018

Howto on the Horizontal Milling Machine - My notes

Comparing a Deckel FP2 to metal shapers, makes me think they are related, part of the evolution of machine tools. Still want to build the clapper box to fit the deckel...

The problem with the quagga or dodo is they have been extinct for a long time, how they once lived and roamed, we know from information passed down by generations. Very similar to me is the concept of the vertical milling machine, almost extinct; and not a lot of information around on how to use it!?

With the old fossil standing in front of you, and me time traveling with my leather apron, old classics humming on the valve amplifier, I force myself to only use the vertical head, and start thinking how to cut angles as example, it becomes clear; a simple but very useful geometry.

Since very little information is available online, I hope to collect a useful how to guide for starters, and perhaps also gather some expert advice in the field.

In a previous post I presented my idea to cut oil groves with a cutting jig, the jig has to have three sides with angles. How to do this with the vertical head, without sine bar? It would be possible with a swivel base vice if the cutter was very slim and long, not ideal or even possible, sequence of operation becomes important. But on a horizontal setup this becomes easy. Set the angle on the base, flip the part upright, cut the first angle, lay it flat for cut two, flip it over and cut third side. Or reverse the order no problem. Only have a short stubby cutter? also no problem.


Saturday, 14 April 2018

Simple Arduino based DRO design ideas

My thinking is to create modular units, a display controller with 4 inputs to display the three axis and RPM. It should be small and later connect to Linux CNC

Displays

Pollin WDC2704
Pollin Hyundai HP12542R-DYO

TM1638

https://github.com/rjbatista/tm1638-library

Quadrature encoder
HCTL2000
Attiny2313
https://github.com/usedbytes/i2c_encoder


VFD Contol
https://wapl.es/cnc/2015/12/04/huanyang-linuxcnc-2.7-speed-control.html


The Arduino nano does not have enough pins to address 4 Quadrature counter IC's, IO expander Atmega32 or 8255?

http://www.torretje.nl/files/p8255optim.ino

Decide on a bus RS232? I2C?

Sunday, 8 April 2018

Oil grooves for sliding surfaces on Machine Tools / Ölschmiernuten für Gleitführungen an Werkzeugmaschienen

My ongoing quest to restore the Deckel FP2, Chipmaster and Eagle surface grinder, makes you deep dive into Machine tool design frequently.

Once the castings where back with shiny new precision ground sliding ways, the question comes do I improve on some of the shortcomings, like no oil grooves? Or leave it factory standard? Well this is probably one of the main reasons why I decided invested in old machine tools, the new machines from china also require a fair amount of work to perform consistently and last for some time.... Might as well spend the time on an old machine tool and in the process learn the trade.

Well back  to the topic at hand, how to cut the oil grooves inside dovetails? There are various tidbits on the web giving advice, but nothing seemed elegant and time efficient. As example one could spend a lot of time with a precision setup on the manual milling machine to engrave oil grooves. Or a setup on a CNC. Or use a hand held dremel like tool, or use a custom ground scraping tool.


When you consider the options, it becomes apparent why a lot of old machines, have very simple oil grooves like elongated Z's,  straight connected 0's, long straight slots with perpendicular grooves similar to I. A few examples shown below.


Image result for oil grove machine tool

Image result for oil grove machine tool

But we know better, there is a great book by M Weck ( Werkzeugmaschinen 2 - Konstruktion und Berechnung ) Pg 245 it shows some examples and the form which shows best performance, a trapezoidal zig zag form (figure 1 below) When you think about what happens to the viscus fluid while the slides are sliding across one another back and forth, this almost acts as a staged pump.  The pumping action helping the spread of oil, since it can not run back along the inclined grooves. The one thing my research did not find is the best angle for the inclined grooves. The angle needs to satisfy two opposing requirements, retain as much oil to evenly spread on the opposing slide, 2. feed oil to the next stage. My starting point is 25͒͒͒͒͒͒°, lets see how this goes.



Image result for oil grove machine tool


Now once the form is selected, the down side is this form probably is the most complex to produce. This made me go in search of methods we used before machine tools, and the result is a simple tongue and grove planer with a special ground tip.  Below take one on such a tool, for 60° dovetails. The angle might vary on your specific requirement, but I can see a use in inverted V slides used on the lathe and in square columns used in the Deckel.


Sunday, 11 March 2018

Engraving a cylinder with graduations to be used as machine tool / lathe dial.


Using gcmc to generate the gcode, this becomes a trivial exercise in more modern programming techniques.

feedrate(400.0mm);

sf = 10.0mm;    /* Scaling factor */
diameter = 80.0mm;      /* Scaling factor */

n = 0;

for (c=0deg; c<360deg ; c=c+3.6deg ) {
// message(">>>> ", c, " ",c%36);

 if ( ( c % 36 ) == 0deg || ( c % 36 ) == 36deg) {
 message("--- ", n);
 vl  = typeset(to_string(n), FONT_HSANS_1);
 vl = scale(vl, [sf / (2.0*pi()), sf]);
 n = n + 10;
 goto([diameter/2,-,0.0mm,-,-,c]);
 move([-,-,14.0mm,-,-,-]);

 }
 elif ( ( c % 36 ) == 18deg ) {
 message("--  ", c);
 goto([diameter/2,-,0.0mm,-,-,c]);
 move([-,-,10.0mm,-,-,-]);
 }
 elif ( ( c % 36 ) != 0deg || ( c % 36 ) != 18deg  ) {
 message("-   ", c);
 goto([diameter/2,-,0.0mm,-,-,c]);
 move([-,-,7.0mm,-,-,-]);
 }
}

Interesting site with lathe dial reductions to suit different lead screws.
http://www.modelengineeringwebsite.com/Mini_handwheel_1.html

Typical operations implemented for the mini CNC Lathe


Linux CNC forum resource with  handy macros
https://forum.linuxcnc.org/41-guis/26550-lathe-macros

Threading
http://wiki.linuxcnc.org/cgi-bin/wiki.pl?Lathe_Code

 
Engraving numbers on cylinders
https://forum.linuxcnc.org/20-g-code/27169-g-code-to-engrave-numbers-on-cylinders?limitstart=0


Mini Lathe CNC Conversion

The requirements is simple, for my Deckel and Eagle restore I need to make new dials and dial fasteners. The dial fasteners are simple and a knurled part will probably do, but I want it to look as original as possible. These are plastic rings about 80mm diameter with formed surface resembling a toothed drive belt pulley. I need to make four of these, setup in the dividing head and mill all of them at once, then slice them up and cut the internal thread, was my initial thinking. 

But wait I have a ball screw, steppers and a  mini lathe, a small 7 x10 branded  Rotwerk.

This seemed like the ideal opportunity to finally convert the little lathe to CNC.

I need a fourth axis. So the spindle has to double as A Axis. This was done with big 120tooth HTD 3M pulley which is attached directly on the spindle.

Converting the Z axis or bed slide was simple, just replace the lead screw with the ball screw and stepper mount.

The A Axis is a bit more challenging, but also a fairly quick job.

Next configuring Linux CNC, wiring the parallel port and stepper drivers. all this was accomplished in less than two hours.

I will post some pictures shortly.

Chipmaster Gear Cutting

  Calculate all the possible gear combinations for the gear selector to cut a 15TPI thread: Imperial TPI C 5 24 20 Imperial TPI ...