Getting end stops working

Since I installed and configured end stops on the y-axis it has stopped working I just get a motor “click”. Could someone who has successfully configured them to home using the farmbot software help me please.

I did the following…

I have bought these end stops https://www.digikey.com/products/en?keywords=59145-01013 and the matching magnet is https://www.digikey.com/products/en/sensors-transducers/magnets-sensor-matched/566?k=57145-000.

I installed them on the y-axis and plugged them into the ramps board to the VCC and wired signal following this thread Calibration / End-stops problem and picture (looks like a different RAMPS board???)

https://forum.farmbot.org/uploads/default/original/1X/9a356e43a8a8fde8f0f4aca2286ca5c3bc3ea521.jpg

But I saw this picture where the endstops are labelled to be plugged into different pins so unsure where to plug them

https://forum.farmbot.org/uploads/default/original/1X/df8041dcab7a9a84f288427eb5647e904609206d.jpg

My Encoders and Endstops configuration is:

I’m also not getting any log output when I try to move the Y-axis and just get the click by the Controls tab, Home Y or Calibrate Y.

I have tried turning Invert Endstops on and off to no effect.

My Y encoders are still plugged in.

I’m on OS 5.0.2.

Hey @whitecaps
Sounds like your endstops are not properly connected. Sadly the Link to your bought endstops are not working, so we can’t see how they are working (NC/NO, 2/3 wire?). To me those two pictures show the same connection points at the endstop pin section.

Maybe you could provide a picture of your endstop pins where you plugged the endstop in.

Thanks @Ascend these are the ones I bought + magnets http://nz.element14.com/hamlin/59145-010/proximity-sensor/dp/1653414?ost=59145-010&scope=partnumberlookahead&exaMfpn=true&searchref=searchlookahead&iscrfnonsku=false&ddkey=http%3Aen-NZ%2FElement14_New_Zealand%2Fw%2Fsearch

Here’s the maximum end stop installed on the Y-axis (I need to put some padding behind it to lift it of the rail will do that later).
image

In the picture above the wire on the left is connected to the green wire in the picture below and wire on right connected to the red wire. Both min and max y-axis end stops are plugged in. The ground and 5V encoder wires are connected to the + & - three pins above above. The flash on the camera created a reflection on the red wire pin plugs which are on the outside Signal pin, green wires are on the 5v pin.

Sorry poor camera.

Alright thanks, I think we can see what’s needed. Could you try to plug the green wire into ground, so that we have the endstop between ground and signal.
I’m not entirely sure if this might work for farmbot firmware, but I’m pretty sure that my 3d printers are connected like I described.

1 Like

According to the data sheet (http://www.farnell.com/datasheets/2062568.pdf?_ga=2.259125903.469500714.1505961986-1866514119.1484876924)
its a SPST-NO switch. You will need to connect the leads between signal and ground. Therefore, I agree that the green wires should be hooked to ground.

1 Like

I tried that but there’s no change. I can think that either:

a) The signal isn’t being transmitted to and from the end stops maybe a wiring problem - will test that
or
b) The firmware doesn’t work with these end stops
or
c) Something else

@Ascend and @bgmoon what end stops do you guys use, recommend?

To your points:
A): Make sure your endstops are working properly. You can check that if you measure the resistance between the two wires. When the endstop is triggered by the magnet, the resistance should be really low.
B): firmware IS working with this kind of endstops. There are many different things that could prevent your endstops from working.

@bgmoon thanks for coming in. We appreciate your help :slight_smile:

@Ascend, @bgmoon thank you for your help.

I checked the resistance for the max and min end stops on the y-axis (plugged into the RAMPS board) with my voltmeter.

With the end stop and the magnet apart its at 1 and then the resistance decreases to 0 as the magnet gets closer.

But still I am just getting a motor “click” and no movement on the y-axis.

Is there anything else I can check?

Did you try to invert the endstop signal?

Yes tried that, is there anything else I could try?

I should be able to debug on the arduino if someone could point me in the right direction i.e. recommended developer setup, how to access logs, what to look for etc.

See this post. You can look for the R81 response.

1 Like

I have hooked up my mac to the Arduino and run the serial monitor. I tested it by running the command G00 Y100. I did a test I knew would work by configuring the encoders and then configured the end stops and tested again. I hoped to see an obvious difference but I think I need more experienced eyes on the results below. Do they shed any light @Gabriel? Is there anything else I should try?

  1. With encoders configured not end stops (works)
    R08 *G00 Y100

R01 Q0
R81 XA1 XB1 YA1 YB1 ZA1 ZB1 Q0
R05 X5 Q0
R05 Y5 Q0
R05 Z5 Q0
R05 X0 Q0
R05 Y0 Q0
R05 Z0 Q0
R05 X1 Q0
R05 Y1 Q0
R05 Z1 Q0
R05 X6 Q0
R05 X4 Q0
R05 X6 Q0
R04 Q0
R82 X0 Y178 Z0 Q0
R04 Q0
R82 X0 Y155 Z0 Q0
R05 X2 Q0
R04 Q0
R82 X0 Y130 Z0 Q0
R04 Q0
R82 X0 Y107 Z0 Q0
R99 stopped
R81 XA1 XB1 YA1 YB1 ZA1 ZB1 Q0

  1. With end stops configured (no movement)
    R08 *G00 Y100

R01 Q0
R81 XA1 XB1 YA1 YB1 ZA1 ZB1 Q0
R05 X5 Q0
R05 Y5 Q0
R05 Z5 Q0
R05 X0 Q0
R05 Y0 Q0
R05 Z0 Q0
R05 X1 Q0
R05 Y1 Q0
R05 Z1 Q0
R05 X6 Q0
R05 X6 Q0
R99 stopped
R81 XA1 XB1 YA1 YB1 ZA1 ZB1 Q0
R82 X0 Y0 Z0 Q0
R84 X0 Y0 Z3 Q0
R85 X1 Y0 Z6 Q0
R99 error 0
R02 Q0
R00 Q0
R82 X0 Y0 Z0 Q0
R84 X0 Y0 Z3 Q0
R85 X1 Y1 Z6 Q0
R81 XA1 XB1 YA1 YB1 ZA1 ZB1 Q0

I would expect movement when the R81 response reads R81 XA0 XB0 YA0 YB0 ZA0 ZB0 Q0. If you have some pin jumpers, can you try connecting signal (S) to ground (-) and send the movement command again? I believe endstops are currently set up for normally closed (NC) operation. INVERT ENDSTOPS currently inverts min and max, so that the min and max endstops are switched, while keeping the values of those endstops the same.

Note I have only configured and installed the Y axis end stops. I plugged in the pin jumpers and now get
R81 XA1 XB1 YA0 YB0 ZA1 ZB1 Q0 which is what I should expect. So does this mean either the end stops are not working or there is a problem with the wiring?

I checked the wiring in a previous post (see below) but now I’m concerned I’m still missing something?
"I checked the resistance for the max and min end stops on the y-axis (plugged into the RAMPS board) with my voltmeter.

With the end stop and the magnet apart its at 1 and then the resistance decreases to 0 as the magnet gets closer."

As always I really appreciate your help!

Two things I have found out which may help.

  1. When I put the magnet for the end stop against it and issue the commands I get movement and R81 XA1 XB1 YA1 YB0 ZA1 ZB1 Q0 however the movement doesn’t stop, the stepper motor keeps going on the Y axis until I remove the magnet from touching the end stop. It’s like the magnet completed the circuit current. I tried to switch the pins from the end stop around on the RAMPS board i.e. switch the red wire to ground and the green to signal but that didn’t work got same behaviour.

  2. I don’t think this is an issue but just in case different metals could have some weird effect thought I’d mention it. The wires which came with the end stop are silver (assume aluminium) whilst the wires I have attached them on the jumper cable pin plug are brown (assume copper).

Hopefully one of those helps resolve the issue?

Hi @Ascend and @Gabriel,

I realise you guys are busy but could I get some with this pretty please. I’m not sure if the end stops work with the Farmbot so if after reading my previous two posts you agree, could you tell me of some end stops you are absolutely sure work with it?

I really appreciate the help you can given me :slight_smile: many thanks!

Sorry @whitecaps for the delay. I just lost this issue out of sight.

So your Y-Axis is running in + direction until you remove the magnet from the endstop? So this sounds like your behavior is just inverted. I think this is caused by using NO switches, and firmware is set up for using NC switches.
INVERT ENDSTOPS function doesn’t seem to help if it only changes between min and max.

I’m using really cheap endstops with NO and NC connections, but they’re connected via NC. Here is a link of mine, shouldn’t be hard to find some in your country: https://www.amazon.de/10-Stück-Mikroschalter-Wechselschalter-polig/dp/B00BXHN0J2/ref=pd_sim_107_2?_encoding=UTF8&psc=1&refRID=KSDHCZEG6SAGZ3YD2SFK

1 Like

Awesome thanks @Ascend