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

    Filament Sensor

    Scheduled Pinned Locked Moved
    Filament Monitor
    5
    15
    808
    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.
    • davidewenundefined
      davidewen @achrn
      last edited by

      @achrn
      Thanks for the response.

      Yes, this is a switch that pressed = filament, unpressed = no filament.

      When I physically press and release the lever, the LED light shows up on the switch, but in Duet Web using M591 D0, I get the same status when the switch is in either state.
      Here's my gcode: M591 D0 P1 C"io0.in" S1
      I've also tried M591 D0 P2 C"io0.in" S1

      So P1 or P2 gives me a response in console, but the state doesn't change when the switch does.

      Here's a video showing the switch in both states and the LED on the switch lighting.
      IMG_0107 (trimmed)-1.mp4

      Here's the console response with the switch in both states.
      console.txt

      1 Reply Last reply Reply Quote 0
      • alankilianundefined
        alankilian
        last edited by alankilian

        @davidewen

        On the io_0 connector, try jumpering io0.in to ground and run M591 D0
        Then, jumper it to +5 Volts and run M591 D0 again.

        Post the results.

        If you see proper responses from M591 D0, they your sensor or wiring is not functioning.

        If you do not see the proper results, then your configuration or your Duet board is not functioning.

        SeemeCNC Rostock Max V3 converted to V3.2 with a Duet2 Ethernet Firmware 3.2 and SE300

        davidewenundefined 1 Reply Last reply Reply Quote 0
        • achrnundefined
          achrn
          last edited by

          Do you have a multimeter to put on the signal wire and see what the voltage is being presented to the duet as the switch switches?

          I found a schematic on the web (of doubtful provenance) thats suggested the switch would be high when filament present.

          davidewenundefined 1 Reply Last reply Reply Quote 0
          • davidewenundefined
            davidewen
            last edited by

            @alankilian

            I'm in the middle of a long print.
            I will test when it is finished.

            1 Reply Last reply Reply Quote 0
            • davidewenundefined
              davidewen @achrn
              last edited by

              @achrn

              5v which I suspected.
              I have it wired to the 5v on io0 pin header

              Wiring is:
              V to 5v on io0
              G to G on io0
              S to io0.in
              (I'm assuming this is correct and that it's not supposed to be wired to the io0.out)

              kb58undefined achrnundefined 2 Replies Last reply Reply Quote 0
              • kb58undefined
                kb58 @davidewen
                last edited by

                @davidewen using X.in is correct.

                Scratch-built 350mmx350mm coreXY, linear rails, ballscrews, 3 Z axis, Duet3 6HC, v3.3, Tool Board v1.1, BondTech LGX + Mosquito hot end

                1 Reply Last reply Reply Quote 0
                • achrnundefined
                  achrn @davidewen
                  last edited by

                  @davidewen said in Filament Sensor:

                  @achrn

                  5v which I suspected.

                  And does it drop to 0V when the filament is absent?

                  1 Reply Last reply Reply Quote 0
                  • davidewenundefined
                    davidewen @alankilian
                    last edited by

                    @alankilian

                    Jump:
                    G to io0.in

                    Result:
                    M591 D0
                    Simple filament sensor on pin io0.in, disabled, output high when no filament, filament present: yes

                    Jump:
                    5v to io0.in

                    Result:
                    M591 D0
                    Simple filament sensor on pin io0.in, disabled, output high when no filament, filament present: no

                    So, based on your post, my wiring is incorrect.

                    alankilianundefined 1 Reply Last reply Reply Quote 0
                    • alankilianundefined
                      alankilian @davidewen
                      last edited by alankilian

                      @davidewen

                      OK, that's good news, it shows that your board and configuration are working properly.

                      Now connect the sensor and measure the voltage between io0.in and ground on the Duet.

                      Press the switch, what is the voltage?
                      Release the switch, what is the voltage?

                      If the voltage does not change, you can measure the voltage between S and G on the PCB of your switch.

                      If it changes on the PCB but not at the Duet, you've got a bad connector or wire.

                      If it does not change on the PCB, follow the traces on either the NO or NC terminals on the switch back to the Power and Ground connections on the connector and see if there's a break somewhere.

                      SeemeCNC Rostock Max V3 converted to V3.2 with a Duet2 Ethernet Firmware 3.2 and SE300

                      1 Reply Last reply Reply Quote 1
                      • davidewenundefined
                        davidewen
                        last edited by

                        @alankilian

                        Thanks for your help Alan.
                        The wiring was incorrect. Now that I have it correct, it's working.

                        1 Reply Last reply Reply Quote 2
                        • First post
                          Last post
                        Unless otherwise noted, all forum content is licensed under CC-BY-SA