No announcement yet.

TTL Logic circuit - Metal Mill.

  • Filter
  • Time
  • Show
Clear All
new posts

  • TTL Logic circuit - Metal Mill.

    I've run into a design issue with the CNC metal mill.

    A little background first: The CNC controller talks to the computer via a parallel port I/O card. There are two optical limits for each axis (for a total of six), but the comm card only has five inputs. In order to get around this, the previous designers joined three of the optical limits together using a diode for each. This is all good and fine except that the optical outputs are normally high (+5V). When the limit is reached, the output goes low (0V).

    The way I understand it (and I could be wrong) is that in order for the circuit to function all three limits need to be reached before the logic goes false. If the motors are running into the limits, by the time the last one reaches the limit and sends the False signal back, the axis gears would have been stripped and damage would occur.

    However, if I'm wrong then the combined limit would be used to tell the software when all three axis have reached a zero position, and the circuit will work as is.

    I'm thinking that if each of the axis either a 3-input XOR circuit will do the trick or three invert circuits. I would like to get some thoughts from those who may have more experience with TTL and some other ideas??

  • #2
    We can always test the input for the limit switches first to see what the program wants. I am guessing that there will only be three limit switch inputs that are used X Y Z. Two optical sensor series in each axis. This is what I would do to save on I/O. It really comes down to what the program is looking for.
    Last edited by ron_ron; 01-22-2019, 07:38 PM.


    • #3
      That's brilliant, Ron. However, the normal state is high so they would have to be in series...

      I fully agree that whatever the program wants is what we have to give. Jim A. is working on getting a PC configured...


      • #4
        I think to prevent damage is to consider a backup set of switches that detect extreme travel (past the optical limits) and trip the motors directly. thus not depend on software.


        • #5
          Found this on the opical limit switches.. I guess it makes sense.

          Why Home Switches?

          Suppose you have no home switches. Every time you shut off the mill it loses track of its position. I used to go through this drill. If a servo faults, if I hit the E-Stop, or if I just wanted to shut down for the night, I would have to come back and find a way to precisely realign the machine with where it should be. This typically meant getting out the edge finder and trying to locate some feature of the part I was making. Ugh! What a lot of time was wasted.

          When you have home switches, you simple press the "Ref" button to reference an axis, or "Ref All" to reference all axes. When you do this, Mach knows to move the mill axis in the positive direction until exact instant the home switch closes and then back off slightly until it opens again. At that point, it knows that is the machine's 0 on that axis. At least it knows that is the spot to the accuracy of whatever kind of switch is being used. In this case, these IH optical switches are known to be good to a couple of tenths, which is pretty darned good!

          He used a 330 Ohm resistor to sink the output to negative so that it reads correctly. I will test this out next time I'm at the space...


          • #6
            Good work Mquintana!
            Yes I did mean to have then in series. lol


            • #7
              Mauricio Mquintana are you still stuck on this problem?
              If so I can try and see if a guy I know that does industrial automation would be willing to help.


              • #8
                No, I actually forgot how a diode and a multimeter work. The issue is resolved. Thank you Ron and Garret for your help and suggestions.