Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problem: Spindle stop for tool change, while still in motion, before operation completes. #1375

Closed
ikhwan-ma opened this issue Nov 9, 2024 · 11 comments

Comments

@ikhwan-ma
Copy link

Wiki Search Terms

spindle stopped unexpectedly before tool change

Controller Board

6-pack External

Machine Description

Gantry router with external HBS860H all closed loop, dual X motor, single Y, single Z, Fuling/Fohlinn DB600 VFD 3.7KW, 3.5KW 8pole ATC spindle.

Input Circuits

No response

Configuration file

board: 6 Pack External
name: 6 Pack Ext XXYZ Fuling ATC
meta: Last changed 22/10/2024
use_line_numbers: true

stepping:
  engine: I2S_STREAM
  idle_ms: 255
  pulse_us: 4
  dir_delay_us: 1
  disable_delay_us: 0

axes:
  shared_stepper_disable_pin: NO_PIN
  x:
    steps_per_mm: 320.000
    max_rate_mm_per_min: 5000.000
    acceleration_mm_per_sec2: 200.000
    max_travel_mm: 850.000
    soft_limits: true
    homing:
      cycle: 2
      positive_direction: true
      mpos_mm: 0.000
      feed_mm_per_min: 100.000
      seek_mm_per_min: 500.000
      settle_ms: 500
      seek_scaler: 1.100
      feed_scaler: 1.100

    motor0:
      limit_neg_pin: gpio.34
      limit_pos_pin: NO_PIN
      limit_all_pin: NO_PIN
      hard_limits: false
      pulloff_mm: 3.000
      standard_stepper:
        step_pin: I2SO.2
        direction_pin: I2SO.1
        disable_pin: I2SO.0

    motor1:
      limit_neg_pin: gpio.39
      limit_pos_pin: NO_PIN
      limit_all_pin: NO_PIN
      hard_limits: false
      pulloff_mm: 3.000
      standard_stepper:
        step_pin: I2SO.5
        direction_pin: I2SO.4
        disable_pin: I2SO.7

  y:
    steps_per_mm: 320.000
    max_rate_mm_per_min: 5000.000
    acceleration_mm_per_sec2: 200.000
    max_travel_mm: 650.000
    soft_limits: true
    homing:
      cycle: 2
      positive_direction: true
      mpos_mm: 0.000
      feed_mm_per_min: 100.000
      seek_mm_per_min: 500.000
      settle_ms: 500
      seek_scaler: 1.100
      feed_scaler: 1.100

    motor0:
      limit_neg_pin: NO_PIN
      limit_pos_pin: gpio.32
      limit_all_pin: NO_PIN
      hard_limits: false
      pulloff_mm: 3.000
      standard_stepper:
        step_pin: I2SO.10
        direction_pin: I2SO.9
        disable_pin: I2SO.8
    
    
  z:
    steps_per_mm: 320.000
    max_rate_mm_per_min: 5000.000
    acceleration_mm_per_sec2: 200.000
    max_travel_mm: 90.000
    soft_limits: true
    homing:
      cycle: 1
      positive_direction: true
      mpos_mm: 0.000
      feed_mm_per_min: 100.000
      seek_mm_per_min: 250.000
      settle_ms: 500
      seek_scaler: 1.100
      feed_scaler: 1.100

    motor0:
      limit_neg_pin: NO_PIN
      limit_pos_pin: gpio.33
      limit_all_pin: NO_PIN
      hard_limits: false
      pulloff_mm: 3.000
      standard_stepper:
        step_pin: I2SO.13
        direction_pin: I2SO.12
        disable_pin: I2SO.15
        
probe:
  pin: gpio.36:low
  toolsetter_pin: gpio.14:low
  check_mode_start: true
  hard_stop: false
  
control:
  safety_door_pin: gpio.13:low
  # safety_door_pin pair with probe overtravel sw
  cycle_start_pin: gpio.12
  feed_hold_pin: gpio.15
        
i2so:
  bck_pin: gpio.22
  data_pin: gpio.21
  ws_pin: gpio.17

spi:
  miso_pin: gpio.19
  mosi_pin: gpio.23
  sck_pin: gpio.18

sdcard:
  card_detect_pin: NO_PIN
  cs_pin: gpio.5

start:
  must_home: true
  
coolant:
  flood_pin: i2so.25
  mist_pin: i2so.24
  delay_ms: 0

user_outputs:
  #P0 - ATC tool release
  digital0_pin: i2so.27
  #P1 - TLO Probe Blower
  digital1_pin: i2so.26

10V:
  output_pin: gpio.26
  forward_pin: gpio.4
  reverse_pin: gpio.16
  pwm_hz: 5000
  enable_pin: NO_PIN
  direction_pin: NO_PIN
  disable_with_s0: false
  s0_with_disable: true
  spinup_ms: 10000
  spindown_ms: 10000
  tool_num: 0
  speed_map: 0=0.000% 3600=20.000% 18000=100.000%
  off_on_alarm: false
  atc: atc_manual

atc_manual:
  safe_z_mpos_mm: -1.0000
  probe_seek_rate_mm_per_min: 300.0000
  probe_feed_rate_mm_per_min: 100.0000
  change_mpos_mm: -750.000 -315.000 -1.000
  ets_mpos_mm: -425.000 -75.000 -70.000
  ets_rapid_z_mpos_mm: -10.0000

Startup Messages

*** Connecting to tcp://192.168.1.201:23
*** Fetching device status
> 
ok
*** Fetching device firmware version
*** Fetching device status codes
*** Fetching device state
*** Fetching device settings
*** Connected to FluidNC 3.9.1
> $ss
[MSG:INFO: FluidNC v3.9.1 https://github.com/bdring/FluidNC]
[MSG:INFO: Compiled with ESP32 SDK:v4.4.7-dirty]
[MSG:INFO: Local filesystem type is littlefs]
[MSG:INFO: Configuration file:6P Ext XXYZ FUL.yaml]
[MSG:DBG: Running after-parse tasks]
[MSG:DBG: Checking configuration]
[MSG:INFO: Machine 6 Pack Ext XXYZ Fuling ATC]
[MSG:INFO: Board 6 Pack External]
[MSG:INFO: I2SO BCK:gpio.22 WS:gpio.17 DATA:gpio.21]
[MSG:INFO: SPI SCK:gpio.18 MOSI:gpio.23 MISO:gpio.19]
[MSG:INFO: SD Card cs_pin:gpio.5 detect:NO_PIN freq:8000000]
[MSG:INFO: Stepping:I2S_STREAM Pulse:4us Dsbl Delay:0us Dir Delay:1us Idle Delay:255ms]
[MSG:INFO: User Digital Output: 0 on Pin:I2SO.27]
[MSG:INFO: User Digital Output: 1 on Pin:I2SO.26]
[MSG:INFO: Axis count 3]
[MSG:INFO: Axis X (-850.000,0.000)]
[MSG:INFO:   Motor0]
[MSG:INFO:     standard_stepper Step:I2SO.2 Dir:I2SO.1 Disable:I2SO.0]
[MSG:INFO:  X Neg Limit gpio.34]
[MSG:INFO:   Motor1]
[MSG:INFO:     standard_stepper Step:I2SO.5 Dir:I2SO.4 Disable:I2SO.7]
[MSG:INFO:  X2 Neg Limit gpio.39]
[MSG:INFO: Axis Y (-650.000,0.000)]
[MSG:INFO:   Motor0]
[MSG:INFO:     standard_stepper Step:I2SO.10 Dir:I2SO.9 Disable:I2SO.8]
[MSG:INFO:  Y Pos Limit gpio.32]
[MSG:INFO: Axis Z (-90.000,0.000)]
[MSG:INFO:   Motor0]
[MSG:INFO:     standard_stepper Step:I2SO.13 Dir:I2SO.12 Disable:I2SO.15]
[MSG:INFO:  Z Pos Limit gpio.33]
[MSG:INFO: safety_door_pin gpio.13:low]
[MSG:INFO: feed_hold_pin gpio.15]
[MSG:INFO: cycle_start_pin gpio.12]
[MSG:INFO: Kinematic system: Cartesian]
[MSG:INFO: Connecting to STA SSID:ASF]
[MSG:INFO: Connecting.]
[MSG:INFO: Connecting..]
[MSG:INFO: Connected - IP is 192.168.1.201]
[MSG:INFO: WiFi on]
[MSG:INFO: Start mDNS with hostname:http://fluidnc.local/]
[MSG:INFO: HTTP started on port 80]
[MSG:INFO: Telnet started on port 23]
[MSG:INFO: ATC:atc_manual]
[MSG:INFO: 10V Spindle Ena:NO_PIN Out:gpio.26 Dir:NO_PIN Fwd:gpio.4 Rev:gpio.16 Freq:5000Hz Period:8191 ATC:atc_manual]
[MSG:INFO: Flood coolant I2SO.25]
[MSG:INFO: Mist coolant I2SO.24]
[MSG:INFO: Probe gpio.36:low]
[MSG:INFO: Toolsetter gpio.14:low]
ok
INFO: WiFi on
INFO: Start mDNS with hostname:http://fluidnc.local/
INFO: HTTP started on port 80
INFO: Telnet started on port 23
INFO: ATC:atc_manual
INFO: 10V Spindle Ena:NO_PIN Out:gpio.26 Dir:NO_PIN Fwd:gpio.4 Rev:gpio.16 Freq:5000Hz Period:8191 ATC:atc_manual
INFO: Flood coolant I2SO.25
INFO: Mist coolant I2SO.24
INFO: Probe gpio.36:low
INFO: Toolsetter gpio.14:low

User Interface Software

UGS 2.1.9

What happened?

The spindle stopped before the operation completes. I've uploaded a video to youtube.

The part has a round and oblong shape to pocket. In the youtube video link, I initially combined the 2 object into 1 pocket operation. So there are 2 tool change in the video. Last operation is chamfering.

In the gcode & output attached, I separated the 2 objects to run into separate pocket operations, having in total 3 tool changes. Last operation is chamfering. I did this to see if the spindle stopped in each intermediate tool change, but it only happens while in the oblong shape pocket operation. It did not happen in the round pocket operation.

toolchange-trial-part

The video can be seen here

GCode File

N100 (Exported by FreeCAD)
N110 (Post Processor: grbl_post)
N120 (Output Time:2024-11-09 10:52:23.858986)
N130 (Begin preamble)
N140 G17 G90
N150 G21
N160 (Begin operation: Fixture)
N170 (Path: Fixture)
N180 G54
N190 (Finish operation: Fixture)
N200 (Begin operation: TC: 6mm_2F_EndMill002)
N210 (Path: TC: 6mm_2F_EndMill002)
N220 (TC: 6mm_2F_EndMill002)
N230 (Begin toolchange)
N240 M6 T2
N250 M3 S14500
N260 G4 P10
N270 (Finish operation: TC: 6mm_2F_EndMill002)
N280 (Begin operation: Pocket_Shape)
N290 (Path: Pocket_Shape)
N300 (Pocket_Shape)
N310 G0 Z5.000
N320 G0 X-31.821 Y28.179
N330 G0 Z3.000
N340 G1 X-31.821 Y28.179 Z-3.000 F450.000
N350 G3 X-36.127 Y29.353 Z-3.000 I-3.179 J-3.179 K0.000 F1650.000
N360 G3 X-39.353 Y23.873 Z-3.000 I1.127 J-4.353 K0.000 F1650.000
N370 G3 X-33.873 Y20.647 Z-3.000 I4.353 J1.127 K0.000 F1650.000
N380 G3 X-31.821 Y28.179 Z-3.000 I-1.127 J4.353 K0.000 F1650.000
N390 G0 Z5.000
N400 G0 X-32.883 Y27.117 Z5.000
N410 G0 X-32.883 Y27.117 Z3.000
N420 G1 X-32.883 Y27.117 Z-3.000 F450.000
N430 G3 X-35.751 Y27.899 Z-3.000 I-2.117 J-2.117 K0.000 F1650.000
N440 G3 X-37.899 Y24.249 Z-3.000 I0.751 J-2.899 K0.000 F1650.000
N450 G3 X-34.249 Y22.101 Z-3.000 I2.899 J0.751 K0.000 F1650.000
N460 G3 X-32.883 Y27.117 Z-3.000 I-0.751 J2.899 K0.000 F1650.000
N470 G0 Z5.000
N480 G0 X-33.945 Y26.055 Z5.000
N490 G0 X-33.945 Y26.055 Z3.000
N500 G1 X-33.945 Y26.055 Z-3.000 F450.000
N510 G3 X-35.374 Y26.445 Z-3.000 I-1.055 J-1.055 K0.000 F1650.000
N520 G3 X-36.445 Y24.626 Z-3.000 I0.374 J-1.445 K0.000 F1650.000
N530 G3 X-34.626 Y23.555 Z-3.000 I1.445 J0.374 K0.000 F1650.000
N540 G3 X-33.945 Y26.055 Z-3.000 I-0.374 J1.445 K0.000 F1650.000
N550 G0 Z5.000
N560 G0 Z5.000
N570 (Finish operation: Pocket_Shape)
N580 (Begin operation: TC: 8mm_2F_EndMill)
N590 (Path: TC: 8mm_2F_EndMill)
N600 (TC: 8mm_2F_EndMill)
N610 (Begin toolchange)
N620 M6 T4
N630 M3 S15500
N640 G4 P10
N650 (Finish operation: TC: 8mm_2F_EndMill)
N660 (Begin operation: Pocket_Shape001)
N670 (Path: Pocket_Shape001)
N680 (Pocket_Shape001)
N690 G0 Z5.000
N700 G0 X60.992 Y-24.008
N710 G0 Z3.000
N720 G1 X60.992 Y-24.008 Z-3.000 F450.000
N730 G1 X60.869 Y-24.000 Z-3.000 F1650.000
N740 G1 X-10.869 Y-24.000 Z-3.000 F1650.000
N750 G1 X-10.992 Y-24.008 Z-3.000 F1650.000
N760 G1 X-11.000 Y-24.131 Z-3.000 F1650.000
N770 G1 X-11.000 Y-30.869 Z-3.000 F1650.000
N780 G1 X-10.992 Y-30.992 Z-3.000 F1650.000
N790 G1 X-10.869 Y-31.000 Z-3.000 F1650.000
N800 G1 X60.869 Y-31.000 Z-3.000 F1650.000
N810 G1 X60.992 Y-30.992 Z-3.000 F1650.000
N820 G1 X61.000 Y-30.869 Z-3.000 F1650.000
N830 G1 X61.000 Y-24.131 Z-3.000 F1650.000
N840 G1 X60.992 Y-24.008 Z-3.000 F1650.000
N850 G0 Z5.000
N860 G0 X59.000 Y-26.000 Z5.000
N870 G0 X59.000 Y-26.000 Z3.000
N880 G1 X59.000 Y-26.000 Z-3.000 F450.000
N890 G1 X-9.000 Y-26.000 Z-3.000 F1650.000
N900 G1 X-9.000 Y-29.000 Z-3.000 F1650.000
N910 G1 X59.000 Y-29.000 Z-3.000 F1650.000
N920 G1 X59.000 Y-26.000 Z-3.000 F1650.000
N930 G0 Z5.000
N940 G0 Z5.000
N950 (Finish operation: Pocket_Shape001)
N960 (Begin operation: TC: 4mm_chamfer90deg)
N970 (Path: TC: 4mm_chamfer90deg)
N980 (TC: 4mm_chamfer90deg)
N990 (Begin toolchange)
N1000 M6 T3
N1010 M3 S12000
N1020 G4 P10
N1030 (Finish operation: TC: 4mm_chamfer90deg)
N1040 (Begin operation: Deburr)
N1050 (Path: Deburr)
N1060 (Deburr)
N1070 G0 Z5.000
N1080 G0 X-28.500 Y25.000
N1090 G0 Z3.000
N1100 G1 X-28.500 Y25.000 Z-2.000 F350.000
N1110 G3 X-28.500 Y25.000 Z-2.000 I-6.500 J0.000 K0.000 F950.000
N1120 G0 Z5.000
N1130 G0 Z5.000
N1140 G0 X-11.000 Y-21.000
N1150 G0 Z3.000
N1160 G1 X-11.000 Y-21.000 Z-2.000 F350.000
N1170 G3 X-14.000 Y-24.000 Z-2.000 I0.000 J-3.000 K0.000 F950.000
N1180 G1 X-14.000 Y-31.000 Z-2.000 F950.000
N1190 G3 X-11.000 Y-34.000 Z-2.000 I3.000 J0.000 K0.000 F950.000
N1200 G1 X61.000 Y-34.000 Z-2.000 F950.000
N1210 G3 X64.000 Y-31.000 Z-2.000 I0.000 J3.000 K0.000 F950.000
N1220 G1 X64.000 Y-24.000 Z-2.000 F950.000
N1230 G3 X61.000 Y-21.000 Z-2.000 I-3.000 J0.000 K0.000 F950.000
N1240 G1 X-11.000 Y-21.000 Z-2.000 F950.000
N1250 G0 Z5.000
N1260 G0 Z5.000
N1270 (Finish operation: Deburr)
N1280 (Begin postamble)
N1290 M5
N1300 G17 G90
N1310 M2

Other Information

This is the UGS output from the gcode above..

*** Connecting to tcp://192.168.1.201:23
*** Fetching device status

ok
*** Fetching device firmware version
*** Fetching device status codes
*** Fetching device state
*** Fetching device settings
*** Connected to FluidNC 3.9.1

$J=G21G91Z10F1000
ok
$J=G21G91Z10F1000
ok
$J=G21G91Z10F1000
ok
$J=G21G91Z10F1000
ok
G90 X0 Y0
ok
$J=G21G91X-10F1000
ok
$J=G21G91X-10F1000
ok
$J=G21G91Y10F1000
ok
$J=G21G91Y10F1000
ok
N100
N110
N120
N130
N140G17G90
N150G21
N160
N170
N180G54
ok
ok
ok
ok
ok
ok
ok
ok
N190
N200
N210
N220
N230
N240M6T2
N250M3S14500
N260G4P10
N270
N280
N290
N300
N310G0Z5.000
N320G0X-31.821Y28.179
N330G0Z3.000
ok
ok
ok
ok
ok
ok
[MSG:INFO: 10V spindle changed to tool:2 using ATC:atc_manual]
ok
N340G1X-31.821Y28.179Z-3.000F450.000
[MSG:DBG: Macro line: G53G0Z-1.000]
[MSG:DBG: Macro line: G53G0Z-1.000]
[MSG:DBG: Macro line: G53G0X-750.000Y-315.000Z-1.000]
[MSG:DBG: Macro line: G4P0 0.1]
[MSG:DBG: Macro line: (MSG: Install tool #2 then resume to continue)]
[MSG:INFO: MSG, Install tool #2 then resume to continue]
[MSG:DBG: Macro line: M0]
[MSG:DBG: Macro line: G53G0Z-1.000]
[MSG:DBG: Macro line: G53G0Z-1.000]
[MSG:DBG: Macro line: G53G0X-425.000Y-75.000]
[MSG:DBG: Macro line: G53 G38.2 Z-70.000 F300.000]
[PRB:-425.000,-75.000,-41.037:1]
[MSG:DBG: Macro line: G53 G38.2 Z-70.000 F100.000]
[PRB:-425.000,-75.000,-41.025:1]
[MSG:DBG: Macro line: G53G0Z-1.000]
[MSG:DBG: job sent]
ok
ok
ok
ok
ok
ok
ok
N350G3X-36.127Y29.353Z-3.000I-3.179J-3.179K0.000F1650.000
ok
ok
N360G3X-39.353Y23.873Z-3.000I1.127J-4.353K0.000F1650.000
ok
N370G3X-33.873Y20.647Z-3.000I4.353J1.127K0.000F1650.000
ok
N380G3X-31.821Y28.179Z-3.000I-1.127J4.353K0.000F1650.000
N390G0Z5.000
ok
N400G0X-32.883Y27.117Z5.000
N410G0X-32.883Y27.117Z3.000
ok
N420G1X-32.883Y27.117Z-3.000F450.000
ok
ok
N430G3X-35.751Y27.899Z-3.000I-2.117J-2.117K0.000F1650.000
ok
ok
N440G3X-37.899Y24.249Z-3.000I0.751J-2.899K0.000F1650.000
ok
N450G3X-34.249Y22.101Z-3.000I2.899J0.751K0.000F1650.000
ok
N460G3X-32.883Y27.117Z-3.000I-0.751J2.899K0.000F1650.000
N470G0Z5.000
ok
N480G0X-33.945Y26.055Z5.000
N490G0X-33.945Y26.055Z3.000
ok
N500G1X-33.945Y26.055Z-3.000F450.000
ok
ok
N510G3X-35.374Y26.445Z-3.000I-1.055J-1.055K0.000F1650.000
ok
ok
N520G3X-36.445Y24.626Z-3.000I0.374J-1.445K0.000F1650.000
ok
N530G3X-34.626Y23.555Z-3.000I1.445J0.374K0.000F1650.000
ok
N540G3X-33.945Y26.055Z-3.000I-0.374J1.445K0.000F1650.000
N550G0Z5.000
ok
N560G0Z5.000
N570
N580
N590
N600
N610
N620M6T4
ok
N630M3S15500
N640G4P10
N650
N660
N670
N680
N690G0Z5.000
ok
N700G0X60.992Y-24.008
ok
N710G0Z3.000
ok
ok
ok
ok
ok
ok
N720G1X60.992Y-24.008Z-3.000F450.000
[MSG:INFO: 10V spindle changed to tool:4 using ATC:atc_manual]
ok
[MSG:DBG: Macro line: G53G0Z-1.000]
[MSG:DBG: Macro line: M5]
[MSG:DBG: Macro line: G53G0Z-1.000]
[MSG:DBG: Macro line: G53G0X-750.000Y-315.000Z-1.000]
[MSG:DBG: Macro line: G4P0 0.1]
[MSG:DBG: Macro line: (MSG: Install tool #4 then resume to continue)]
[MSG:INFO: MSG, Install tool #4 then resume to continue]
[MSG:DBG: Macro line: M0]
[MSG:DBG: Macro line: G53G0Z-1.000]
[MSG:DBG: Macro line: G53G0Z-1.000]
[MSG:DBG: Macro line: G53G0X-425.000Y-75.000]
[MSG:DBG: Macro line: G53 G38.2 Z-70.000 F300.000]
[PRB:-425.000,-75.000,-41.037:1]
[MSG:DBG: Macro line: G53 G38.2 Z-70.000 F100.000]
[PRB:-425.000,-75.000,-41.022:1]
[MSG:DBG: Macro line: G53G0Z-1.000]
[MSG:DBG: Macro line: M3]
[MSG:DBG: job sent]
ok
ok
ok
ok
N730G1X60.869Y-24.000Z-3.000F1650.000
ok
ok
ok
N740G1X-10.869Y-24.000Z-3.000F1650.000
ok
ok
N750G1X-10.992Y-24.008Z-3.000F1650.000
ok
N760G1X-11.000Y-24.131Z-3.000F1650.000
ok
N770G1X-11.000Y-30.869Z-3.000F1650.000
ok
N780G1X-10.992Y-30.992Z-3.000F1650.000
ok
N790G1X-10.869Y-31.000Z-3.000F1650.000
ok
N800G1X60.869Y-31.000Z-3.000F1650.000
ok
N810G1X60.992Y-30.992Z-3.000F1650.000
ok
N820G1X61.000Y-30.869Z-3.000F1650.000
ok
N830G1X61.000Y-24.131Z-3.000F1650.000
ok
N840G1X60.992Y-24.008Z-3.000F1650.000
N850G0Z5.000
ok
N860G0X59.000Y-26.000Z5.000
ok
N870G0X59.000Y-26.000Z3.000
ok
N880G1X59.000Y-26.000Z-3.000F450.000
ok
ok
N890G1X-9.000Y-26.000Z-3.000F1650.000
ok
N900G1X-9.000Y-29.000Z-3.000F1650.000
ok
N910G1X59.000Y-29.000Z-3.000F1650.000
ok
N920G1X59.000Y-26.000Z-3.000F1650.000
N930G0Z5.000
ok
N940G0Z5.000
N950
N960
N970
N980
N990
ok
N1000M6T3
N1010M3S12000
N1020G4P10
ok
N1030
N1040
N1050
N1060
N1070G0Z5.000
ok
ok
N1080G0X-28.500Y25.000
ok
ok
N1090G0Z3.000
ok
ok
ok
ok
[MSG:INFO: 10V spindle changed to tool:3 using ATC:atc_manual]
ok
N1100G1X-28.500Y25.000Z-2.000F350.000
[MSG:DBG: Macro line: G53G0Z-1.000]
[MSG:DBG: Macro line: M5]
[MSG:DBG: Macro line: G53G0Z-1.000]
[MSG:DBG: Macro line: G53G0X-750.000Y-315.000Z-1.000]
[MSG:DBG: Macro line: G4P0 0.1]
[MSG:DBG: Macro line: (MSG: Install tool #3 then resume to continue)]
[MSG:INFO: MSG, Install tool #3 then resume to continue]
[MSG:DBG: Macro line: M0]
[MSG:DBG: Macro line: G53G0Z-1.000]
[MSG:DBG: Macro line: G53G0Z-1.000]
[MSG:DBG: Macro line: G53G0X-425.000Y-75.000]
[MSG:DBG: Macro line: G53 G38.2 Z-70.000 F300.000]
[PRB:-425.000,-75.000,-41.041:1]
[MSG:DBG: Macro line: G53 G38.2 Z-70.000 F100.000]
[PRB:-425.000,-75.000,-41.025:1]
[MSG:DBG: Macro line: G53G0Z-1.000]
[MSG:DBG: Macro line: M3]
[MSG:DBG: job sent]
ok
ok
ok
ok
ok
ok
ok
N1110G3X-28.500Y25.000Z-2.000I-6.500J0.000K0.000F950.000
N1120G0Z5.000
ok
N1130G0Z5.000
ok
N1140G0X-11.000Y-21.000
N1150G0Z3.000
ok
N1160G1X-11.000Y-21.000Z-2.000F350.000
ok
ok
ok
N1170G3X-14.000Y-24.000Z-2.000I0.000J-3.000K0.000F950.000
ok
ok
N1180G1X-14.000Y-31.000Z-2.000F950.000
ok
N1190G3X-11.000Y-34.000Z-2.000I3.000J0.000K0.000F950.000
ok
N1200G1X61.000Y-34.000Z-2.000F950.000
ok
N1210G3X64.000Y-31.000Z-2.000I0.000J3.000K0.000F950.000
ok
N1220G1X64.000Y-24.000Z-2.000F950.000
ok
N1230G3X61.000Y-21.000Z-2.000I-3.000J0.000K0.000F950.000
ok
N1240G1X-11.000Y-21.000Z-2.000F950.000
N1250G0Z5.000
N1260G0Z5.000
ok
N1270
N1280
N1290M5
N1300G17G90
N1310M2
ok
ok
ok
ok
ok
ok
ok

**** Finished sending file in 00:04:12 ****

ok
[MSG:INFO: Program End]
ok

@ikhwan-ma ikhwan-ma changed the title Problem: Spindle stopped for tool change, while in motion, before operation completes. Problem: Spindle stop for tool change, while still in motion, before operation completes. Nov 9, 2024
@bdring
Copy link
Owner

bdring commented Nov 9, 2024

This is hard to reproduce on my test fixtures.

There should probably be a protocol_buffer_sync(...) here to complete all buffered gcode.

Probably right before spindle->stop();

if (gc_state.selected_tool != gc_state.tool) {
            bool stopped_spindle;
            Spindles::Spindle::switchSpindle(gc_state.selected_tool, Spindles::SpindleFactory::objects(), spindle, stopped_spindle);
            if (stopped_spindle) {
                spindle->stop();  // stop the new spindle
                gc_state.spindle_speed = 0.0;
                gc_block.modal.spindle = SpindleState::Disable;
            }
            spindle->tool_change(gc_state.selected_tool, false, false);
            ...

@ikhwan-ma
Copy link
Author

ikhwan-ma commented Nov 10, 2024 via email

@bdring
Copy link
Owner

bdring commented Nov 10, 2024

We are discussing it here. There are some fixes on a PR. I still need to test multiple spindle systems and macro users.

https://discord.com/channels/780079161460916227/1304881649439473748

@bdring
Copy link
Owner

bdring commented Nov 10, 2024

Try this pull request.

#1374

@ikhwan-ma
Copy link
Author

ikhwan-ma commented Nov 11, 2024 via email

@ikhwan-ma
Copy link
Author

Try this pull request.

#1374

I need some help with this.

@bdring
Copy link
Owner

bdring commented Nov 12, 2024

I'll create a pre release with the new code. Is that the help you need?

@ikhwan-ma
Copy link
Author

ikhwan-ma commented Nov 12, 2024 via email

@bdring
Copy link
Owner

bdring commented Nov 12, 2024

Pre-release is done.

https://github.com/bdring/FluidNC/releases/tag/v3.9.2-pre1

Get it via Github or the Web Installer (be sure to enable pre-releases)

@ikhwan-ma
Copy link
Author

ikhwan-ma commented Nov 12, 2024 via email

@ikhwan-ma
Copy link
Author

ikhwan-ma commented Nov 13, 2024

Happy to report that the 'early stop' spindle bug is gone. There's something else that i thought was part of the erratic problem from the current 3.9.1 release, but persist in the 3.9.2 pre-release. I'll keep an eye for the current state of update and notify if there any other problem.

I'll open another issue later base on my findings. Perhaps another video too to document the tool change procedure.

Thanks for this! I'll make a donation soon as a token of gratitude for all your work guys..

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants