Преглед на файлове

Don't call fsensor_st_next_block repeatedly during the last step

Rely on st_block_begin to perform a single call instead of calling
block_chunk for each advance tick in the last step
Yuri D'Elia преди 5 години
родител
ревизия
1bed8cfa94
променени са 1 файла, в които са добавени 1 реда и са изтрити 1 реда
  1. 1 1
      Firmware/stepper.cpp

+ 1 - 1
Firmware/stepper.cpp

@@ -965,7 +965,7 @@ FORCE_INLINE void advance_isr_scheduler() {
         while(--max_ticks);
 
 #ifdef FILAMENT_SENSOR
-        if (!current_block || (abs(fsensor_counter) >= fsensor_chunk_len))
+        if (abs(fsensor_counter) >= fsensor_chunk_len)
         {
             fsensor_st_block_chunk(fsensor_counter);
             fsensor_counter = 0;