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

Output pin floating after tool selection in laser mode

Scheduled Pinned Locked Moved
Laser Cutters
2
4
248
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
    radiomodell
    last edited by 4 May 2020, 11:01

    My board is a Duet2 Ethernet. Firmware is 3.01-RC11.
    A solid state relais controls 220V sockets for spindel and laser power. It is configured to heater3 pin in laser and in CNC mode.
    PWM signal for laser is configured to heater6 pin.

    Here is the piece of code I use to switch to laser mode:

    M453 C"nil" ; deselect CNC-Mode Pin. May be it was configured.
    M950 P0 C"exp.heater3" ; select heater 3 pin to control solid state relais. M42 P0 S255 -> laser power supply on, M42 P0 S0 laser off
    M42 P0 S0 ; set laser power off
    M452 C"exp.heater6" R500 S1 Q20000 ; laser PWM signal on heater6 pin, PWM frequency 20000Hz
    ;
    ; Tools
    M140 H-1 ; Heizbett aus
    M563 P0 D-1 H-1 ; Tool0 abwählen
    M563 P1 D-1 H-1 ; Tool1 abwählen
    M563 P0 S"Laser" ; Define tool 0
    G10 P0 X-7 Y-45 Z-68.5 ; Set tool 0 axis offsets vs. Headposition -68.5 Z-Achse Nullpunkt (Laser Fokus)
    T0 ; Select Tool 0 (laser)
    M42 P0 S0 ; This line was added as workaround to avoid floating signal after selecting tool.

    Lines 12 and 13 were added to set tool head offset.
    After adding line 12 and 13 to configuration I noticed floating signal on heater3 pin from time to time.
    As a workaround I redefined power state in line 14.
    I would have expected that command in line 3 already sets signal on heater3.pin to zero level.
    It seems that a tool change command makes heater3 pin floating.

    Does anyone else see these effects?

    1 Reply Last reply Reply Quote 0
    • undefined
      DeltaCon
      last edited by 4 May 2020, 21:53

      @radiomodell said in Output pin floating after tool selection in laser mode:

      M452 C"exp.heater6" R500 S1 Q20000

      Sorry to hijack your question, you obviously are a bit further on the path to a working laser than me...
      I have RRF 3.01-RC11 loaded onto a Maestro board and am working towards a correct configuration for my dedicated laser CNC machine. I was looking into the M452 command, but the gcode wiki does not mention any parameters, so I was stuck on where to assign the laser pin to the tool. I thought i needed to look at the M563 command, because that defines the tools... Am I mistaken? What doe sthe R500 mean in you M452 command above?

      If you think trial and error is dangerous, try routine. That's even more so!

      1 Reply Last reply Reply Quote 0
      • undefined
        radiomodell
        last edited by radiomodell 5 May 2020, 09:16 5 May 2020, 09:10

        @DeltaCon My reference in G-Code around Duet is this Wiki. This is the full list of comands.
        If you search in RepRapFirmeware3 overview you get hints regarding changes against RepRapFirmware 2.

        The laser PWM pin is assigned in M452 command. Use "C" parameter to select pin. A list of pin names on Maestro board you find here.

        An example: M452 C"exp.pa21" Q2000 R255.
        This command adds pin "exp.pa21" to laser PWM line. PWM frequency is set to 2000 by Q parameter. R parameter sets the value of max laser power in S parameter in G1 commands.
        G1 X20 Y 40 S127 will move laser with half power.
        Hope it is not too confusing.

        Laser will only fire when moving by G1 command with the power set by S-parameter.

        The laser power supply in my machine is controlled by "exp.heater3".

        I change R parameter to adjust Laser power to different materials. It is faster than recreating G-code file with external software und upload to Duet.

        undefined 1 Reply Last reply 5 May 2020, 18:55 Reply Quote 0
        • undefined
          DeltaCon @radiomodell
          last edited by 5 May 2020, 18:55

          @radiomodell
          Thanks, this is splendid! I mostly revert to https://reprap.org/wiki/G-code#M452:_Select_Laser_Printer_Mode for gcode reference, but it seems incomplete when it comes to lasering. I can use your info. thanks a lot!

          If you think trial and error is dangerous, try routine. That's even more so!

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