Jackpot down -calling for help from the braintrust please

Hi all,

A while back I decided to build FluidNC for the 8MB build here. It worked well until I tried to add the pendant. In that process I updated to 3.7.14. I was also using WebUI v3 at that point.

In the true spirit of “If it ain’t broke, fix it until it is”, I tried to load up the most current version 3.7.16, custom compiled for 8MB, with the pendant, and using WebUI v3. Now,

  • It cannot home the y-axis without the ESP32 resetting.
  • It cannot finish a job. My first impression was that it was hanging in/after curves. But it has been hanging even earlier in jobs most recently.

Before I asked for help here.

  • I erased and reflashed 3.7.16 from the Web Installer through Chrome (unmodified version.)
  • I added my config.yaml with the pendant sections commented out. The behavior is the same.
  • The ESP32 starts throwing low memory errors, stalls several times, then eventually the board resets.
board: Jackpot TMC2209
name: LowRider
meta: 11-29-2023 mod 040724

stepping: 
  engine: I2S_static
  idle_ms: 255
  pulse_us: 4
  dir_delay_us: 1
  disable_delay_us: 0
  segments: 12

uart1:
  txd_pin: gpio.0
  rxd_pin: gpio.4
  rts_pin: NO_PIN
  baud: 115200
  mode: 8N1
    
    
# uart2: 
#   txd_pin: gpio.13
#   rxd_pin: gpio.14
#   rts_pin: NO_PIN
#   cts_pin: NO_PIN
#   baud: 1000000
#   mode: 8N1

# uart_channel2:
#     uart_num: 2
#     report_interval_ms: 75
    
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: 
  cs_pin: gpio.5
  card_detect_pin: NO_PIN
  frequency_hz: 20000000

kinematics: 
  Cartesian: 

axes: 
  shared_stepper_disable_pin: NO_PIN
  shared_stepper_reset_pin: NO_PIN
  x: 
    steps_per_mm: 50.000000
    max_rate_mm_per_min: 9000.000000
    acceleration_mm_per_sec2: 200.000000
    max_travel_mm: 760.000000
    soft_limits: true
    homing: 
      cycle: 3
      allow_single_axis: true
      positive_direction: false
      mpos_mm: 0.000000
      feed_mm_per_min: 300.000000
      seek_mm_per_min: 1500.000000
      settle_ms: 500
      seek_scaler: 1.100000
      feed_scaler: 1.100000

    motor0: 
      limit_neg_pin: gpio.25
      limit_pos_pin: NO_PIN
      limit_all_pin: NO_PIN
      hard_limits: false
      pulloff_mm: 4.000000
      tmc_2209: 
        addr: 0
        cs_pin: NO_PIN
        uart_num: 1
        step_pin: I2SO.2
        direction_pin: I2SO.1
        disable_pin: I2SO.0
        r_sense_ohms: 0.110000
        run_amps: 0.680000
        hold_amps: 0.500000
        microsteps: 8
        toff_disable: 0
        toff_stealthchop: 5
        use_enable: false
        run_mode: StealthChop
        homing_mode: StealthChop
        stallguard: 0
        stallguard_debug: false
        toff_coolstep: 3

  y: 
    steps_per_mm: 50.000000
    max_rate_mm_per_min: 9000.000000
    acceleration_mm_per_sec2: 200.000000
    max_travel_mm: 1690.000000
    soft_limits: true
    homing: 
      cycle: 2
      allow_single_axis: true
      positive_direction: false
      mpos_mm: 0.000000
      feed_mm_per_min: 300.000000
      seek_mm_per_min: 1500.000000
      settle_ms: 500
      seek_scaler: 1.100000
      feed_scaler: 1.100000

    motor0: 
      limit_neg_pin: gpio.33
      limit_pos_pin: NO_PIN
      limit_all_pin: NO_PIN
      hard_limits: false
      pulloff_mm: 4.000000
      tmc_2209: 
        addr: 1
        cs_pin: NO_PIN
        uart_num: 1
        step_pin: I2SO.5
        direction_pin: I2SO.4
        disable_pin: I2SO.7
        r_sense_ohms: 0.110000
        run_amps: 0.680000
        hold_amps: 0.500000
        microsteps: 8
        toff_disable: 0
        toff_stealthchop: 5
        use_enable: false
        run_mode: StealthChop
        homing_mode: StealthChop
        stallguard: 0
        stallguard_debug: false
        toff_coolstep: 3

    motor1: 
      limit_neg_pin: gpio.35
      limit_pos_pin: NO_PIN
      limit_all_pin: NO_PIN
      hard_limits: false
      pulloff_mm: 4.500000
      tmc_2209: 
        addr: 3
        cs_pin: I2SO.14
        uart_num: 1
        step_pin: I2SO.13
        direction_pin: I2SO.12
        disable_pin: I2SO.15
        r_sense_ohms: 0.110000
        run_amps: 0.680000
        hold_amps: 0.500000
        microsteps: 8
        toff_disable: 0
        toff_stealthchop: 5
        use_enable: false
        run_mode: StealthChop
        homing_mode: StealthChop
        stallguard: 0
        stallguard_debug: false
        toff_coolstep: 3

  z: 
    steps_per_mm: 200.000000
    max_rate_mm_per_min: 1200.000000
    acceleration_mm_per_sec2: 80.000000
    max_travel_mm: 300.000000
    soft_limits: false
    homing: 
      cycle: 1
      allow_single_axis: true
      positive_direction: true
      mpos_mm: 0.000000
      feed_mm_per_min: 300.000000
      seek_mm_per_min: 800.000000
      settle_ms: 500
      seek_scaler: 1.100000
      feed_scaler: 1.100000

    motor0: 
      limit_neg_pin: NO_PIN
      limit_pos_pin: gpio.32
      limit_all_pin: NO_PIN
      hard_limits: false
      pulloff_mm: 5.100000
      tmc_2209: 
        addr: 2
        cs_pin: NO_PIN
        uart_num: 1
        step_pin: I2SO.10
        direction_pin: I2SO.9
        disable_pin: I2SO.8
        r_sense_ohms: 0.110000
        run_amps: 0.680000
        hold_amps: 0.500000
        microsteps: 8
        toff_disable: 0
        toff_stealthchop: 5
        use_enable: false
        run_mode: StealthChop
        homing_mode: StealthChop
        stallguard: 0
        stallguard_debug: false
        toff_coolstep: 3

    motor1: 
      limit_neg_pin: NO_PIN
      limit_pos_pin: gpio.34
      limit_all_pin: NO_PIN
      hard_limits: false
      pulloff_mm: 3.400000
      tmc_2209: 
        addr: 3
        cs_pin: I2SO.19
        uart_num: 1
        step_pin: I2SO.18
        direction_pin: I2SO.17
        disable_pin: I2SO.16
        r_sense_ohms: 0.110000
        run_amps: 0.680000
        hold_amps: 0.500000
        microsteps: 8
        toff_disable: 0
        toff_stealthchop: 5
        use_enable: false
        run_mode: StealthChop
        homing_mode: StealthChop
        stallguard: 0
        stallguard_debug: false
        toff_coolstep: 3

control: 
  safety_door_pin: NO_PIN
  reset_pin: NO_PIN
  feed_hold_pin: NO_PIN
  cycle_start_pin: NO_PIN
  macro0_pin: NO_PIN
  macro1_pin: NO_PIN
  macro2_pin: NO_PIN
  macro3_pin: NO_PIN
  fault_pin: NO_PIN
  estop_pin: NO_PIN

coolant: 
  flood_pin: gpio.2
  mist_pin: gpio.16
  delay_ms: 0

probe: 
  pin: gpio.36:low
  toolsetter_pin: NO_PIN
  check_mode_start: true

macros: 
  startup_line0: 
  startup_line1: 
  macro0: 
  macro1: 
  macro2: 
  macro3: 
  after_homing: 
  after_reset: 
  after_unlock: 

start: 
  must_home: false
  deactivate_parking: false
  check_limits: false

parking: 
  enable: false
  axis: Z
  target_mpos_mm: -5.000000
  rate_mm_per_min: 800.000000
  pullout_distance_mm: 5.000000
  pullout_rate_mm_per_min: 250.000000

user_outputs: 
  analog0_pin: NO_PIN
  analog1_pin: NO_PIN
  analog2_pin: NO_PIN
  analog3_pin: NO_PIN
  analog0_hz: 5000
  analog1_hz: 5000
  analog2_hz: 5000
  analog3_hz: 5000
  digital0_pin: gpio.26
  digital1_pin: NO_PIN
  digital2_pin: NO_PIN
  digital3_pin: NO_PIN
  digital4_pin: NO_PIN
  digital5_pin: NO_PIN
  digital6_pin: NO_PIN
  digital7_pin: NO_PIN


NoSpindle: 

Laser:
  pwm_hz: 5000
  output_pin: gpio.27
  enable_pin: NO_PIN
  disable_with_s0: false
  s0_with_disable: true
  tool_num: 0
  speed_map: 0=0.000% 1000=100.000%
  off_on_alarm: true

arc_tolerance_mm: 0.002000
junction_deviation_mm: 0.010000
verbose_errors: false
report_inches: false
enable_parking_override_control: false
use_line_numbers: false
planner_blocks: 32

Firmware: 3.7.16 (unmodified), WebUIv3, 68% used on flash, 2MB of 29GB on SD. Running STA mode, seems stable.

These are the errors from the terminal window in WebUIv3:

<Run|MPos:170.640,145.140,-43.090|FS:814,0|Ov:100,100,100|SD:13.86,/sd/plexi2LR3Jackpot.gcode>
[MSG:WARN: Low memory: 10468 bytes]
[MSG:WARN: Low memory: 7976 bytes]
[MSG:WARN: Low memory: 5864 bytes]
[MSG:WARN: Low memory: 3432 bytes]
<Run|MPos:146.040,141.000,-46.895|FS:406,0|SD:23.82,/sd/plexi2LR3Jackpot.gcode>
<Run|MPos:140.860,141.500,-48.300|FS:600,0|SD:24.81,/sd/plexi2LR3Jackpot.gcode>

I’m happy to answer any questions or try any ideas.

Thanks.

Try going back to v2 UI as a test? If that solves it log it as a bug on github and cross your fingers.

Good suggestion and probably easier that what I did. I set up another ESP32, same firmware version from the web installer, same WebUIv3, same config, same macros. I did everything I could to ensure it was set up exactly the same way. Viola, it works and has run the job “air cutting” 3 times without the low memory errors. I even added a tool change to the file on the third run and it executed the tool change code as well.

I need to uncomment the pendant code and put a few hours on the new ESP32 before declaring it good, but at least it feels like progress.

Then to troubleshoot the problematic board to see if I screwed something up.

1 Like

When I’ve run into problems like this in the past, I used the erase.sh file from the FluidNC distribution to wipe the ESP32 and start over. That usually works for the really weird stuff. There’s probably a more elegant way.

If you want to debug the troublesome board, post a log of what you see in fluidterm when trying to boot the board.

I second the suggestion to erase the ESP32 and install a fresh copy.

The webinstaller has the erase built in, if you choose the option.

Yeah - I chose the erase option. Thanks all. Before I mess with the old board I may try to dump some info from FluidTerm. Maybe it will reveal something. I think I saw a verbose switch I may throw to see if that helps as well.

Is it possible to be connected via FluidTerm during a job?

Very interesting. Uncomment the 10 lines above and the Low Memory error returns. How I just need to see if I can repair it without having to reflash the ESP32 again.

I disabled the code for the pendant, and it appears fully functional again. Is it possible that the ESP32 in the pendant is conflicting with the code on the Jackpot?

I’ll try re-flashing the pendant.

@dgkeith237
I have used 3.7.14, 3.7.15 and 3.7.16 with my pendant.

This is what I added to my config file:

uart2:
  txd_pin: gpio.14
  rxd_pin: gpio.13
  rts_pin: NO_PIN
  cts_pin: NO_PIN
  baud: 1000000
  mode: 8N1
  
uart_channel2:
  uart_num: 2
  report_interval_ms: 75

1 Like

I used that exact same configuration in my test setup and it is working fine for me as well.

Thanks all. Before I mess with re-flashing, I’ll switch the txd and rxd pins and flip the connector over. Looking at the commented lines, that appears to be the only difference.

DK

Or you could flip them in the config and leave the connector alone.

I have two of these pendants working, and late yesterday tried with a 2nd jackpot to confirm both work fine with the 2nd Jackpot.

I feel compelled to clarify.

The pendant appears to work fine. It’s only after I start running a job that I start getting low memory errors on the Jackpot/ESP32, reflected on the terminal pane in WebUiv3…

Otherwise, it runs jobs fine without the lines above commented. It only generates the low memory errors when the lines are uncommented and the pendant is working.

Once the reported memory gets too low, the board soft resets, and it doesn’t load the config properly. At that point, if I reset it, the board boots fine until I run another job.

I’ll try switching the pins in the config first.

If the pendant works you don’t need to switch pins.

Are you using STA mode? If so, there are some settings you need to apply.
A static IP will help a lot.

I’m using a static IP, reserved in my router. Unfortunately, I won’t have much time to troubleshoot the thing until this weekend. (My kid’s car broke down and we spent the evening fixing it. A little unplanned father/son time. :grinning:)

I just realized I wasn’t clear above. In my config txd_pin: gpio13 and in your config txd_pin: gpio14

I have no idea why using pin 13 or 14 for txd/rxd would be so specific, but I can switch them to match your config and ensure that they function. Not sure if that will affect the problem. Its just takes a while to test, as the low memory errors aren’t showing up until I’m 5ish mins into a job.

Well - this appears to be solved. Thanks all.

I turned the machine on and checked that the pendant connected. Then I swapped the pins I was using for the txd_pin and the rxd_pin in config.yaml. After restarting with the new config, I checked and the pendant would not connect. I flipped the connector over and it reconnected. I have since run the same file I was using to test for low memory errors and it runs fine.

So for my setup,

# uart2: 
   txd_pin: gpio.14
   rxd_pin: gpio.13
   rts_pin: NO_PIN
   cts_pin: NO_PIN
   baud: 1000000
   mode: 8N1

 uart_channel2:
     uart_num: 2
     report_interval_ms: 75

Works without throwing the low memory errors, but

 uart2: 
   txd_pin: gpio.13
   rxd_pin: gpio.14
   rts_pin: NO_PIN
   cts_pin: NO_PIN
   baud: 1000000
   mode: 8N1

 uart_channel2:
     uart_num: 2
     report_interval_ms: 75

Throws low memory errors when the pendant is connected and working.

I pulled the pin diagrams for ESP32 DevkitC, and I don’t see a relevant difference between those two pins, but :person_shrugging: at some point I need to get back to using the machine.

I just wanted to record this issue for future reference if anyone else experiences it.

Interesting find.

For what it’s worth- I also use GPIO 14 for TxD and GPIO 13 for RxD with my two pendants.
No memory errors.

I may try next week to see if the errors when configured the other way is repeatable on my test setup.

I know there are some interesting limitations with ESP pin assignments.