Duet3D Logo Duet3D
    • Tags
    • Documentation
    • Order
    • Register
    • Login

    Inductive sensor NPN NO not working

    Scheduled Pinned Locked Moved Solved
    General Discussion
    2
    7
    550
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • jlimburgundefined
      jlimburg
      last edited by

      Hi all, and apologies if this has already been answered. I believe i did a thorough search but may have missed something.
      I connected an inductive sensor to my Duet Wifi, revision 1.04C running firmware 3.3, VIN 24V. The sensor is a NPN NO with 6-36V. I connected the wires according to the wiki, brown and black to VIN / Ground, respectively, and blue to the Z probe input pin in the Z Probe terminal.

      Here are my FW settings:
      ; Endstops
      M574 X1 S1 P"xstop" ; configure switch-type (e.g. microswitch) endstop for low end on X via pin xstop
      M574 Y1 S1 P"ystop" ; configure switch-type (e.g. microswitch) endstop for low end on Y via pin ystop
      M574 Z1 S2 ;P"zstop" ; configure Z-probe endstop for low end on Z

      ; Z-Probe
      M558 P1 C"!zprobe.in" H5 F300 T6000
      G31 P7 X100 Y100 Z-0

      I tried M558 with P5 as described in the wiki but that just shows '0' in the Z Probe field no matter if the probe LED is on or not. If i use P1 i at least get something, the Z Probe indictor show 6-7 when warm (?) so i can trigger on 7 and that works. The issue is that the 6-7 value is not reliable, on startup it show 30-50 and then slowly wanders down to 6, sometimes 7 even when there is no proximity to the bed.
      My Z-Probe output is connected directly, no diode or resistors since i have 1.04C they should not be required.

      I measured the Z-Probe output with a multimeter and it has 0V when there is no proximity to the bed and 0.5V when the bed is near and the probe LED is on.

      Any help with this would be appreciated!

      fcwiltundefined 1 Reply Last reply Reply Quote 0
      • fcwiltundefined
        fcwilt @jlimburg
        last edited by

        @jlimburg

        Try adding a ^ character to the C parameter of the M558.

        0.5 volts isn't high enough to give a solid logic high.

        I think the ^ character will enable the pullup on the input.

        Check the voltage readings to see if it made a difference.

        Frederick

        Printers: a E3D MS/TC setup and a RatRig Hybrid. Using Duet 3 hardware running 3.4.6

        jlimburgundefined 1 Reply Last reply Reply Quote 0
        • jlimburgundefined
          jlimburg @fcwilt
          last edited by

          @fcwilt Thanks, i tried that, unfortunately it made no difference. I am starting to think my sensor is faulty. I'll order another one and try that.

          fcwiltundefined 1 Reply Last reply Reply Quote 0
          • fcwiltundefined
            fcwilt @jlimburg
            last edited by

            @jlimburg said in Inductive sensor NPN NO not working:

            @fcwilt Thanks, i tried that, unfortunately it made no difference. I am starting to think my sensor is faulty. I'll order another one and try that.

            It could be. I had a cheap Chinese inductive unit that worked fine at first but failed in the same way.

            I since have been getting my sensors from this place. They have actual specs for their products. 😉

            AutomationDirect

            Frederick

            Printers: a E3D MS/TC setup and a RatRig Hybrid. Using Duet 3 hardware running 3.4.6

            jlimburgundefined 1 Reply Last reply Reply Quote 0
            • jlimburgundefined
              jlimburg @fcwilt
              last edited by

              @fcwilt Thanks for sharing the link! I'll order a couple from them 🙂

              jlimburgundefined 1 Reply Last reply Reply Quote 0
              • jlimburgundefined
                jlimburg @jlimburg
                last edited by

                @jlimburg Well, here goes, i am wearing my silly hat! I had the wires switched on the sensor, switching output and ground. Interesting that the sensor LED still lit up. Fixed it, sensor works, Z-Probe now show 0 when the bed is away and 798 when the sensor LED comes on. Sorry for wasting people's time 😞

                fcwiltundefined 1 Reply Last reply Reply Quote 1
                • fcwiltundefined
                  fcwilt @jlimburg
                  last edited by

                  @jlimburg said in Inductive sensor NPN NO not working:

                  @jlimburg Well, here goes, i am wearing my silly hat! I had the wires switched on the sensor, switching output and ground. Interesting that the sensor LED still lit up. Fixed it, sensor works, Z-Probe now show 0 when the bed is away and 798 when the sensor LED comes on. Sorry for wasting people's time 😞

                  Glad to hear it is working.

                  Frederick

                  Printers: a E3D MS/TC setup and a RatRig Hybrid. Using Duet 3 hardware running 3.4.6

                  1 Reply Last reply Reply Quote 0
                  • dc42undefined dc42 has marked this topic as solved
                  • gloomyandyundefined gloomyandy referenced this topic
                  • First post
                    Last post
                  Unless otherwise noted, all forum content is licensed under CC-BY-SA