Spoof the DRO scales to drive a Dividing Head for Helical Milling

Due to Precision Matthew's fame, my mill comes Monday, but my DRO won't be here till Thanksgiving or so - they have stocking and supply issues :(

The documentation for the scale says: "Pitch is 0.02mm; EPS is 5v; Output 2 Channels of TTL square wave with a phase difference of 90 (with zero position signal); current is 50mA". My invoice from PM says "Upgraded DRO (glass to magnetic)"
----lots of interpolation going on here (the pun is intentional!)

I am unfamiliar with the programming of other microcontrollers - do they have a dedicated IDE and can they use C like the Arduino? That's not a good question - low level :(
This other microcontroller seems right as you describe it, but I'll need libraries for the LCD, Keypad, and Stepper-controller, then I'll have to puzzle out it's program logic. If this alternative brain has a fair following, or uses Arduino libraries, it should be pretty straightforward.
I've already got a menu tree in mind, so I think I can go ahead and write some pseudo-code with variables and library callouts - but I've got to pick hardware before I can actually write the code.

I will look to find Clough42's ELS - have you a link to his goodies?
 
I am unfamiliar with the programming of other microcontrollers - do they have a dedicated IDE and can they use C like the Arduino? That's not a good question - low level :(
This other microcontroller seems right as you describe it, but I'll need libraries for the LCD, Keypad, and Stepper-controller, then I'll have to puzzle out it's program logic. If this alternative brain has a fair following, or uses Arduino libraries, it should be pretty straightforward.

Check out Teensy. It has extensions to Arduino IDE (Teensyduino) so it’s super easy to get started and there are a lot of libraries for the Teensy hardware. Teensy 4 has hardware quadrature decoding and there’s a library:

 
Oh sure, now I've got to decide between Arduino, Teensy, and LaunchXL.... :bang head: :beguiled:

Arduino I know, and I've actually got an extra RAMPS board with stepper drivers built in from my FLSUN Prusa I3 clone - I cannibalized one of the driver boards to add a second extruder to my 3D printer - but this board will likely not drive a NEMA 23, so it doesn't matter anyways.

Teensy looks easier, but I am uncertain how to translate a rotary encoder for a linear scale - they appear to give the same info, whether hall or optical or otherwise... it seems it doesn't matter as long as I don't exceed the wattage?

The LaunchXL seems more powerful, and the ELS page already has a lot of what I need - working out the 16 keypad and LCD shouldn't be too bad, but it has wattage conversion details (apparently for all the necessary modules)...

Wahhhh!!! :)

I'm going to make some notes and I'll be back!

At the moment though, I've got to unstuck my kitchen drain - schmutz passed the trap, and so it's off to buy a snake!
 
Teensy looks easier, but I am uncertain how to translate a rotary encoder for a linear scale - they appear to give the same info, whether hall or optical or otherwise... it seems it doesn't matter as long as I don't exceed the wattage?

Teensy is great if you come from Arduino. If linear scales give the same quadrature (two square waves 90° out of phase), which I believe most do (e.g., TTL output), then you should be fine. But for sure there are plenty of good platforms.
 
Curious what type of gear cutter you'll be using. I thought helical gears were generally cut on a universal mill (horizontal with a table that rotates). I cut some small helical gears on my Tormach, but had to mount the 4th axis on a tilt table.

Bruce
 
Curious what type of gear cutter you'll be using. I thought helical gears were generally cut on a universal mill (horizontal with a table that rotates). I cut some small helical gears on my Tormach, but had to mount the 4th axis on a tilt table.

Bruce

Haven't gotten so far as that - one step at a time I'd say. I was more thinking towards barrel-cams - just a slot on a circumference.
But, now that you mention it, if I were in such a pickle, I might end up grinding a negative-involute on an endmill - that's what we call it right? A negative of the shape that I want? I'd have to do some voodoo magic to put an involute on the flutes, and I'd use a size smaller than the target root-dimension so as to allow for cutter flex, and I'd have to take two passes minimum. With the cutter as a "point" contact, I could pivot about it without ferschnookering the already cut teeth, or binding the cutter - restrictions apply of course - but it's vaguely related to cutter-relief or lead-angle whilst cutting threads on the lathe.

For weird angles, I'm considering how to let the DH do it's pivoty thing, without binding up on the stepper motor - perhaps mount the motor to the top or something. No super crazy helix angles, but I could do helical-bevel gears :D

I suppose I could go nuts and put the works on a trunnion, then have it drive the DH, to which a Rotab is attached - then I could make all sorts of crazy things in the 2" of head clearance left! :laughing:

Seriously though - the project is mostly for barrel-cams... make a piston do a screwy motion :D
 
"ferschnookering". You have to be careful about that one. Once into the Fershnook nook of facinorous plotting, it can quickly turn into a fadoodle.
 
"ferschnookering". You have to be careful about that one. Once into the Fershnook nook of facinorous plotting, it can quickly turn into a fadoodle.

It is my general policy to avoid the fadoodle, wherever possible, as it inevitably leads to the Fubar - and you don't want the Fubar.... noooo the fubar must be avoided - one might say it is verboten. Akin to the antiquated spelling: "Verschnuke".
 
I don't have PMs DRO, so I can't be sure. If you post a pic of the scale, we can find out though.

If the signal from the scale is too fast for arduino, it might be better to use a different microcontroller. There are some with hardware built in to deal with fast signals. If it's quadrature, which you can boil down to TTL square waves, then the one Clough42 used on the ELS is a good choice. It has a hardware quadrature decoder built in that simplifies it significantly and helps prevent missed signals.


Well sir, Milly has come, and I just got done putting on the X-axis scale/reader - she works! And, having received the DRO goodies, I now have the actual gizmo to examine. I posted a pic of the back of the brains - it's an EL-400. I also posted two pics of the documentation that came with the scale/reader (it is magnetic).

It's 5v quadrature, and I believe I have the necessary pinouts to find the A and B leads.

I did find rumours of a library for Arduino - <digitalWriteFast.h> outlined HERE

My thoughts are that, if I can avoid having to use another shield ($$), or buying another microcontroller (also $$) then I won't panic as much when I purchase the Nema 23 and associated driver board.

To steal the signals, I thought about using one of those blank ports on back of the DRO display - one is a 9pin serial, and the other is a 15pin. I thought that I could find some connectors to fit (likely the 15 pin) to connect to my Arduino box. This would allow me to send X and Y, or even XYZ signals to the Arduino, and then I can select which axis I want the DH to slave - on the off chance that I want to drive my Rotab on this proportional scheme....

My question for you - as this project is effectively identical to your ELS, with some extra bits added - do you believe I am barking the correct tree here with the digitalWriteFast library, so as to use my Arduino, or do you maintain that I should use the microcontroller that you did?

Too bad there isn't just a microcontroller with quadrature encoders AND stepper drivers already on it (with room for a keypad and LCD) - seems like there would be consistent demand for that in robots and CNC and all...

Is there one? Is this the one you have recommended to me?

Am I out of my mind? :laughing:

Thanks brother!
 

Attachments

  • 20201117_173946.jpg
    20201117_173946.jpg
    5.4 MB · Views: 10
  • 20201117_174023.jpg
    20201117_174023.jpg
    3.4 MB · Views: 10
  • 20201117_174045.jpg
    20201117_174045.jpg
    3 MB · Views: 8
Back
Top