Welcome! Log In Create A New Profile

Advanced

Inductive Sensor Issue

Posted by mrshenaniganns 
Inductive Sensor Issue
June 01, 2016 10:05PM
Hello,

I am having trouble with my inductive sensor and auto leveling my printer bed. I set up the connection just like Thomas Sanladerer did in his informational video, using the same resistors he did. I get an output voltage of 3.8V when there is no metal nearby and 0.28V when metal is within the range of the sensor. I connect the sensor to where my normal z-endstop min sensor goes, but I get no change in status of the pin when testing. I use ponterface to run the M119 command to check the endstops, but when I put the metal close, I will get "OPEN" and when I pull it away, it still reads "OPEN." If I spam the M119 command, I will randomly get one "TRIGGERED" every ten clicks or so, but the majority are still "OPEN." I tried different resistors (two 15k ohm resistors) to get the voltage closer to 5V (4.8V). Even then I see no change in behavior of the z endstop status. Also, when I put back the normal mechanical endstop, I get a change in status when I engage the sensor.

What can be causing this issue? I am using a Makerfarm Prusa 8" with updated Marlin firmware, with the settings configured for my printer. FYI, I attempted using the makerfarm firmware that comes with the printer and tested to see if I can trigger the z-endstop with the inductive sensor and find the same issue.
Re: Inductive Sensor Issue
June 01, 2016 10:32PM
You may have to change the firmware to switch between a mechanical endstop and an electronic one. For a mechanical endstop the pin on the microcontroller is configured with an internal pull-up resistor to Vcc - the pin puts out a weak 5v signal and when the switch closes that gets pulled down to 0V. If you are using a sensor that puts out an active signal then you should turn the pull-up resistor off, otherwise it will interfere.
Re: Inductive Sensor Issue
June 02, 2016 07:07PM
James,

I did forget to turn off the pull-up resistor. However, even after disabling that, I get the same result. Attached is the code to turn off the resistor, which I think I am doing correctly.
Attachments:
open | download - code.PNG (27.8 KB)
Sorry, only registered users may post in this forum.

Click here to login