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

    run a gcode file on duet3d 5mini+ from rpi python

    Scheduled Pinned Locked Moved
    General Discussion
    3
    4
    129
    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.
    • shenouda13undefined
      shenouda13
      last edited by shenouda13

      Hi guys,

      I am new to the duet, I have connected a duet3D Mini 5+ to a raspberry pi 4 through usb cable. I am trying to send a command to the duet in python to run a gcode file (macro) on duet3d 5mini+. Any suggestion on how to do that? thanks

      jay_s_ukundefined 1 Reply Last reply Reply Quote 0
      • jay_s_ukundefined
        jay_s_uk @shenouda13
        last edited by

        @marco13 please stop raising multiple threads for the same issue

        Owns various duet boards and is the main wiki maintainer for the Teamgloomy LPC/STM32 port of RRF. Assume I'm running whatever the latest beta/stable build is

        shenouda13undefined 1 Reply Last reply Reply Quote 0
        • shenouda13undefined
          shenouda13 @jay_s_uk
          last edited by shenouda13

          @jay_s_uk I believe this is a different question

          Falcounetundefined 1 Reply Last reply Reply Quote 0
          • Falcounetundefined
            Falcounet @shenouda13
            last edited by

            @marco13 You can send M98 gcode command:

            import serial
             
            with serial.Serial('/dev/ttyACM0') as ser:
                ser.setRTS(True)
                ser.write(b'M98 P"yourmacro.g"\n')
            

            See https://docs.duet3d.com/User_manual/Reference/Gcodes#m98-call-macrosubprogram

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