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

USB CNC Pendant project

Scheduled Pinned Locked Moved
CNC
8
27
1.9k
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.
  • undefined
    o_lampe @hurzhurz
    last edited by 1 Jan 2024, 10:34

    @hurzhurz Unfortunately the WHB04B-6 is sold out, so I couldn't find more info about it.
    I was wondering if your firmware supports analog joysticks, too? (if only for variable jogging speed)

    As a sidenote: I'd rename Duet in Duet3D where ever applicable for better matching search results in github.

    undefined 1 Reply Last reply 1 Jan 2024, 13:13 Reply Quote 0
    • undefined
      hurzhurz @o_lampe
      last edited by 1 Jan 2024, 13:13

      @o_lampe Depends on where you look for the WHB04B-6.
      I got mine from Amazon DE, where it is still available with Prime-Shipping: https://www.amazon.de/RATTMMOTOR-Fernbedienung-Handsteuerung-Drehmaschinen-Graviermaschine/dp/B096TNP5NF/
      And AliExpress is a possible source, too.

      I have not implemented joysticks, but if they present themselves as HID devices, it should not be hard to do that.
      Well, at least for button presses...
      I'm not sure what's the best way to implement continuous movements via G-codes, as of course, you surely want it to stop as soon as possible, after the joystick (or a long pressed key) is released.

      I'm not sure if I want to rename it, but you have a point.
      I have now added a small repository description that contains "Duet3D".

      1 Reply Last reply Reply Quote 0
      • undefined
        hurzhurz
        last edited by hurzhurz 2 Aug 2024, 22:29 2 Jan 2024, 21:13

        Maybe some news:

        • Just for fun, I have implemented support for the PlayStation 3 controller
        • The limitation for the mentioned LogiLink Numpad is removed, so any keyboard can be used. But the key mapping might be less ideal on other devices.

        And I have also made an attempt to implement some kind of continuous mode (move as long as button is pressed).

        This can be found in a different branch: https://github.com/hurzhurz/Duet-USB-CNC-Pendant/tree/continuous EDIT: already merged into master branch
        And here is documented how it works: https://github.com/hurzhurz/Duet-USB-CNC-Pendant/blob/master/doc/ContinuousMode.md

        It uses the daemon.g to generate the actual movement commands. This is a bit hacky, but at least, it seems to work...

        1 Reply Last reply Reply Quote 5
        • undefined
          IlI_Cnc
          last edited by IlI_Cnc 1 Sept 2024, 23:54 9 Jan 2024, 23:52

          I was thinking in getting one of those pendants, but I don't know a lot of the duet3d programming yet. Can you tell me how to get it to work? like, where do I put the files or what I need to do? I kinda need a crash course in the duet environment to be honest.
          Also Aliexpress is running Summer sale so you could get the pendant easily
          If I get one I can maybe help test stuff if I'm available too

          undefined undefined 2 Replies Last reply 10 Jan 2024, 10:47 Reply Quote 0
          • undefined
            oliof @IlI_Cnc
            last edited by 10 Jan 2024, 10:47

            @IlI_Cnc the only thing you would need on the Duet side is to enable the serial connection (if you use a paneldue that's already happened). You do this by adding M575 P1 B57600 S1 to your config.g

            <>RatRig V-Minion Fly Super5Pro RRF<> V-Core 3.1 IDEX k*****r <> RatRig V-Minion SKR 2 Marlin<>

            1 Reply Last reply Reply Quote 0
            • undefined
              hurzhurz @IlI_Cnc
              last edited by 10 Jan 2024, 11:42

              @IlI_Cnc For the Duet side, the most important part is to enable the PanelDue port via M575, like @oliof already said.
              In addition, you may want to create macro files to define what should happen when you press on the various buttons of the pendant.
              If you press a button, you should be able to see in the console in the Duet Web Control which file it tried to execute und you have to create, to give that button a function.

              And to flash the Raspberry Pico, you can simply take the compiled firmware.uf2 file from my GitHub repository.
              You need to connect the Pico via USB to your computer. But while plugging it in, you have to press the BOOTSEL button.
              There should then appear a new drive. Just copy firmware.uf2 on that drive.

              undefined 1 Reply Last reply 10 Jan 2024, 15:42 Reply Quote 0
              • undefined
                Hannah
                last edited by 10 Jan 2024, 15:34

                THX, I'll build this instead of the old wired version

                1 Reply Last reply Reply Quote 0
                • undefined
                  chimaeragh @hurzhurz
                  last edited by 10 Jan 2024, 15:42

                  @hurzhurz Will this work with the 4 axis version, WHB04B-4? I don't need to control that many axes and it seems to be half the cost of the 6-axis on AliExpress
                  WHB04B-4

                  Duet 2 Wifi, Ooznest Workbee CNC 1510

                  undefined 1 Reply Last reply 10 Jan 2024, 16:55 Reply Quote 0
                  • undefined
                    oliof
                    last edited by oliof 1 Oct 2024, 15:47 10 Jan 2024, 15:47

                    Great work @hurzhurz. It would be cool to see if you (or anyone else) could adopt the FluidNC M5Dial Pendant as well.

                    <>RatRig V-Minion Fly Super5Pro RRF<> V-Core 3.1 IDEX k*****r <> RatRig V-Minion SKR 2 Marlin<>

                    undefined 1 Reply Last reply 10 Jan 2024, 17:06 Reply Quote 0
                    • undefined
                      hurzhurz @chimaeragh
                      last edited by 10 Jan 2024, 16:55

                      @chimaeragh said in USB CNC Pendant project:

                      @hurzhurz Will this work with the 4 axis version, WHB04B-4? I don't need to control that many axes and it seems to be half the cost of the 6-axis on AliExpress

                      I can't tell for sure, but I think the chances are good that the 4 axis version works as well.
                      For the most part, I used the protocol description from the LinuxCNC driver: https://github.com/LinuxCNC/linuxcnc/tree/master/src/hal/user_comps/xhc-whb04b-6
                      I think I read a comment somewhere that the WHB04B-4 was used successful with the LinuxCNC WHB04B-6 driver by someone.
                      And I can't imagine that there would be a difference needed in the protocol.

                      Though it could be that the dongle of the 4 axis version has a different USB PID. But that would be trivial to fix.

                      1 Reply Last reply Reply Quote 1
                      • undefined
                        hurzhurz @oliof
                        last edited by 10 Jan 2024, 17:06

                        @oliof said in USB CNC Pendant project:

                        Great work @hurzhurz. It would be cool to see if you (or anyone else) could adopt the FluidNC M5Dial Pendant as well.

                        Thanks!

                        The FluidNC M5Dial Pendant looks like another neat solution!
                        And as it is already made to communicate via serial / G-code commands, it should probably be not that hard to adapt.
                        Most work should be needed for the part with the status display for coordinates etc.

                        1 Reply Last reply Reply Quote 0
                        • undefined
                          IlI_Cnc
                          last edited by 10 Jan 2024, 20:47

                          I'm waiting for parts and the pendant now, when they arrive and I'll try to get everything working and post if everything works fine.
                          Thanks for the help

                          1 Reply Last reply Reply Quote 0
                          • undefined
                            IlI_Cnc
                            last edited by 15 Jan 2024, 23:32

                            In case i want to connect with a IO port what should i do with the activation part?

                            Also, since in my board (Duet 3 6XD) seems to have a different panel due pinout what should i wire the usb to?panel.png

                            undefined 1 Reply Last reply 16 Jan 2024, 11:58 Reply Quote 0
                            • undefined
                              hurzhurz @IlI_Cnc
                              last edited by 16 Jan 2024, 11:58

                              @IlI_Cnc You actually have two ports on your board where a PanelDue can be connected, the 10-pin "PANEL DUE" connector and the 5-pin IO_0 connector.
                              Both share the same serial interface (that you can enable with M575 P1 B57600 S1).
                              The 10-pin connector is used if you want to use the SD card slot on the PanelDue.
                              https://docs.duet3d.com/en/User_manual/Connecting_hardware/Display_PanelDue

                              I would suggest using the IO_0 connector like shown in my wiring diagramm on GitHub.

                              1 Reply Last reply Reply Quote 0
                              • undefined
                                ajmartins
                                last edited by 16 Feb 2024, 14:16

                                Hi, just start to saying amazing project, and thanks for sharing ;), now one little problem... i tried to use continuous mode, but im getting some errors.

                                Error: Failed to read code from macro daemon.g: Failed to evaluate "global.run_daemon": unknown value 'global.run_daemon'

                                If i take that part, then i get another error when trying to use Continuous mode, another thing, how do i get the values to appear on the WHB04B-6?

                                Error: Failed to read code from macro pendant-continuous-run.g: Failed to evaluate "{exists(param.A)} && {exists(param.F)} && {exists(param.D)}": unknown value 'param.A'

                                Error: Failed to read code from macro pendant-continuous-loop.g: Failed to evaluate "global.pendant_continuous_ttl>0": unknown value 'global.pendant_conti'

                                undefined 1 Reply Last reply 16 Feb 2024, 15:32 Reply Quote 0
                                • undefined
                                  hurzhurz @ajmartins
                                  last edited by 16 Feb 2024, 15:32

                                  @ajmartins The errors look like these two lines might be missing in your config.g, can you check that?:

                                  M98 P"pendant-continuous-init.g"
                                  global run_daemon=true
                                  

                                  Or you can run them manually in the console once for testing.

                                  And about your other question, doesn't your WHB04B-6 show the coordinates on the LCD?
                                  It should work automatically...

                                  1 Reply Last reply Reply Quote 0
                                  • undefined
                                    ajmartins
                                    last edited by ajmartins 16 Feb 2024, 15:34

                                    Yes, i added both lines to config.g, i tried manully running and i get the other error i sent.

                                    If i run M98 P"pendant-continuous-init.g", the system just stalls and i need to reset the board.

                                    Should i put both lines in the end of config file?

                                    undefined 1 Reply Last reply 16 Feb 2024, 16:42 Reply Quote 0
                                    • undefined
                                      ajmartins @ajmartins
                                      last edited by 16 Feb 2024, 16:42

                                      @ajmartins Well more tests, added both lines to the end of config file, and now at least i dont get any errors when restarting the board.

                                      But when trying to make a continuous move, i still get the error:

                                      Error: Failed to read code from macro pendant-continuous-run.g: Failed to evaluate "{exists(param.A)} && {exists(param.F)} && {exists(param.D)}": unknown value 'param.A'

                                      undefined 1 Reply Last reply 16 Feb 2024, 17:23 Reply Quote 0
                                      • undefined
                                        hurzhurz @ajmartins
                                        last edited by 16 Feb 2024, 17:23

                                        @ajmartins Which version of RepRapFirmware have you installed?
                                        I'm wondering if the macro parameters or the exists() function for them is "too new".
                                        On my machine I'm running 3.4.6. And from the changelog I guess that at least 3.3 could be required.

                                        undefined 1 Reply Last reply 16 Feb 2024, 17:35 Reply Quote 0
                                        • undefined
                                          ajmartins @hurzhurz
                                          last edited by ajmartins 16 Feb 2024, 17:35

                                          @hurzhurz Im running the same, 3.4.6.

                                          ff5b9b81-21e0-42b3-90f5-ea45b33458e3-image.png
                                          3fc54038-24d2-40f6-b953-20ec0b8c49a2-image.png

                                          undefined 1 Reply Last reply 16 Feb 2024, 17:44 Reply Quote 0
                                          • First post
                                            Last post
                                          Unless otherwise noted, all forum content is licensed under CC-BY-SA