Adding a microswitch to Carl Wilson’s Arduino Controlled Indexer – MEW249 refers

Adding a microswitch to Carl Wilson’s Arduino Controlled Indexer – MEW249 refers

Home Forums Help and Assistance! (Offered or Wanted) Adding a microswitch to Carl Wilson’s Arduino Controlled Indexer – MEW249 refers

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #603658
    Greensands
    Participant
      @greensands

      I have made up the Carl Wilson's Arduino controlled indexer as described in MEW249 and have been using it for machining Hex bar stock on my 3-axis stepper motor controlled milling machine. So far, so good but I would like to be able to fit a microswitch on the X axis of the mill in order to auto advance the Arduino by the required 60 degrees in place of (or in parallel with) manual activation of the On-Off-On Mom switch provided by Carl. .Can anyone suggest how this might be done as early tests have not proved to be successful.

      #34041
      Greensands
      Participant
        @greensands
        #603674
        Huub
        Participant
          @huub

          I am not familiar with the Carl Wilson's Arduino controlled indexer!

          You could use UGS, a gcode sender that has user defined buttons. The button can be linked to a line of gcode that could rotate the table 60°. UGS is compatible to a lot of grbl versions.

          I control my rotary table using an ESP32 controller running grbl_ESP32_R (or grbl_ESP32). These grbl versions can send a command as a respond to a switch being pressed. The command could be a gcode that instructs the table to rotate 60°.

          #603742
          John Haine
          Participant
            @johnhaine32865

            If you have a stepper power feed on the x axis as well, then GRBL can move the x axis back and forth and drive the divider too, controlled with a few lines of gcode from UGS.

            #603920
            SillyOldDuffer
            Moderator
              @sillyoldduffer

              Maybe, but I can't find my copy of MEW249. Is Carl's code and wiring available on the web?

              Carl does the change manually with an on/off/on momentary switch. I don't know of an off-the-shelf switch that does that but they're quite likely to exist if you know where to look!

              Might be easier to make a wiper switch to fit on the lathe. I think it's easier to do off/on/off and have the Arduino invert the logic.

              A contact mounted on the saddle, which is earthed, passes over an insulated contact held at 5V via a resistor, causing a pin the Arduino to register logic 1,0,1:

              wiperswitch.jpg

              Main problem is likely to be debouncing and cleaning up the signal presented to the Arduino. Unfortunately, good earths by sparky electrician standards are often a heap of filth in telecommunications! Trouble is microcontrollers are switched by low voltages and react in microseconds. They easily detect that most mechanical switches don't make or break cleanly and bounce many times over tens of milliseconds. They also react to any other low level electrical noise present.

              Step one is to try the circuit without a debounce capacitor. If operation is unreliable, try adding a capacitor between 0.01 and 0.1 microfarads. It may be necessary to experiment. With luck the capacitor stores enough charge to fill short negative spikes so the Arduino never sees them, and also decouples any AC on the line to ground, but it's a mild bodge. More elaborate filtering and debouncing may be necessary.

              Mucky signals are the bane of microcontrollers. Might even be the reason why what's already been tried isn't working.

              Dave

              Edited By SillyOldDuffer on 02/07/2022 13:16:26

              #603922
              John Haine
              Participant
                @johnhaine32865

                easybutton.h is your friend…

                #603944
                Robert Atkinson 2
                Participant
                  @robertatkinson2

                  You should be able to just put a push putton or microswitch in parallel with the relevant side of the existing on-off-on toggle switch.
                  What problem do you have?

                  If it's random operation try using screened cable to connect the switch.

                  Robert G8RPI.

                  #603948
                  Greensands
                  Participant
                    @greensands

                    Have now been able to get the microswitch circuit working as required, Not sure what the original problem was as all that was required is to wire the microswitch across the On-Off-On Mom switch and bring it out to the front panel via a 3.5mm jack plug as seen in the photo. Net result is that the RT is now activated through 60 degrees at the end of each pass along the X-Dirn to complete the Hex cut

                  Viewing 8 posts - 1 through 8 (of 8 total)
                  • Please log in to reply to this topic. Registering is free and easy using the links on the menu at the top of this page.

                  Latest Replies

                  Viewing 25 topics - 1 through 25 (of 25 total)
                  Viewing 25 topics - 1 through 25 (of 25 total)

                  View full reply list.