Navigation

    Duet3D Logo

    Duet3D

    • Register
    • Login
    • Search
    • Categories
    • Tags
    • Documentation
    • Order

    M112 and G28 Through USB and Fetching Current Position

    CNC
    3
    4
    59
    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.
    • jurasamo
      jurasamo last edited by

      Hi,

      we are developing a machine using your electronics and we are facing an issue, if we send a G28 thought USB (Serial Port) and we send a M112 before it ends, that M112 don't work, it waits until the G28 ends to send the Emergency Stop, is there anyway to interrupt that G28 ?

      Other question is if we can fetch the current position of the head, our application is not a 3D Printer, is a CNC so the movements are slow, and our customer wants to see the actual position in a visualizer, but we don't know how to know the exact position os the head, because if we send the M114 we get the end of the movement.

      Thanks for your help,

      Regards,

      jurasamo 1 Reply Last reply Reply Quote 1
      • jurasamo
        jurasamo @jurasamo last edited by

        Hi again,

        any help would be appreciated,

        Thanks,
        
        1 Reply Last reply Reply Quote 0
        • jay_s_uk
          jay_s_uk last edited by

          Try M999 instead

          Owns various duet boards and is the main wiki maintainer for the Teamgloomy LPC/STM32 port of RRF

          1 Reply Last reply Reply Quote 0
          • fcwilt
            fcwilt last edited by

            Hi,

            With v3 firmware, at least 3.1.1 and 3.2.0 you have access to the firmware Object Model.

            For example move.axes[0].machinePosition gives the current position for axis 0.

            If you enable TELNET using...

            M586 S1 P2 T0

            ...you can use the following to send that data to a TELNET client connected to your printer.

            M118 L0 P4 S{"move.axes[0].machinePosition = " ^ move.axes[0].machinePosition}

            If axis 0 is positioned at 10 then the result on the client is...

            move.axes[0].machinePosition = 10.000

            If you create a file in the system folder called daemon.g and it contained that M118 command the TELNET client would receive a message once per second.


            What I don't know is if this would work when the firmware was executing a job file.

            Frederick

            Printers: A FT-5 with the 713 upgrade bits. A custom MarkForged style. A small Utilmaker style and a CoreXY from kits. Various hotends. Using Duets (2 and 3) running 3.4.1

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