Commit Graph

91 Commits

Author SHA1 Message Date
Yuri D'Elia 6f6cef65b5 Revert "Correctly handle direction for the filament sensor"
This reverts commit aae03ad83e.
2019-05-26 16:41:37 +02:00
Yuri D'Elia bddc3e84ab Use WRITE_NC directly in the isr 2019-05-25 21:52:06 +02:00
Yuri D'Elia aae03ad83e Correctly handle direction for the filament sensor 2019-05-25 21:51:59 +02:00
Yuri D'Elia 935a798236 Speedup advance_spread for common divisors 2019-05-25 21:51:52 +02:00
Yuri D'Elia fa7ecfc38e Check for serial roughtly in the middle of the stepper isr 2019-05-25 18:41:28 +02:00
Yuri D'Elia 282b502393 Improve the distribution of the advance steps 2019-05-24 17:08:32 +02:00
Yuri D'Elia aae5cce28f Use the nominal frequency to merge ticks 2019-05-24 17:08:32 +02:00
Yuri D'Elia c6dbcc494f Typo 2019-05-24 17:08:32 +02:00
Yuri D'Elia a1be8b6784 Initialize current_adv_steps correctly
Initialize at 0 both on startup and on reset on regular (non-LA)
segments to avoid cumulating errors.
2019-05-24 17:08:32 +02:00
Yuri D'Elia 707849e6c4 Use a define instead of hard-coding a divider 2019-05-24 17:08:32 +02:00
Yuri D'Elia a2fa8e5313 Rewrite the advance_isr scheduler 2019-05-24 17:08:32 +02:00
Yuri D'Elia 2d3fe3197c Move calc_timer into speed_lookup_table for planner reuse 2019-05-24 17:08:32 +02:00
Yuri D'Elia 520cb491b2 Move speed lookup defs into a separate source 2019-05-24 17:08:32 +02:00
Yuri D'Elia ebdc5e35e7 Remove two more OCR1A direct manipulations
Use _NEXT_ISR and st_reset_timer to correctly reinitialize and
re-schedule the advance ticks.
2019-05-24 17:08:32 +02:00
Yuri D'Elia cbf1a85ec3 Switch original LA implementation with LA1.5
This discards several Prusa optimizations for LA1.0.
We'll re-implement those later if needed.

Debugging is turned on.
2019-05-24 17:08:32 +02:00
Yuri D'Elia bf0c60dd45 Factor-out some repetition into fsensor_step 2019-05-24 17:08:32 +02:00
Ondrej Tuma b7fe43bf68 Deleted bad cols/rows definitions for translation. 2019-05-07 12:52:23 +02:00
Marek Bel 28f1e309a2 Fix compiler warning: 'old_x_max_endstop' defined but not used
Fix compiler warning: 'old_y_max_endstop' defined but not used
2019-03-05 17:44:47 +01:00
Robert Pelnar eea755496b Conditional translation for SYSTEM_TIMER_2 because we want to have posibility to switch between old/new implementation.
Timing functions (millis, micros and delay) replaced in whole source, defined in Marlin.h.
This commit enables original implementation (SYSTEM_TIMER_2 undefined)
Verified with passed complete wizard process.
2019-01-27 22:48:51 +01:00
Robert Pelnar 434a723151 Timing functions 'micros' and 'delay' replaced in whole source with 'micros2' and 'delay2' 2019-01-27 17:37:27 +01:00
Robert Pelnar 9f86a334c6 Lang - text "endstops hit: " removed from dictionary 2018-11-22 17:53:51 +01:00
Robert Pelnar a0e4acead3 lang - removed unused code and some service messages changed to "not translated" 2018-11-01 14:07:16 +01:00
PavelSindler 940f436a5f merge MK3_dev into MK3 2018-10-22 20:25:29 +02:00
Marek Bel 1585dc66b0 Merge remote-tracking branch 'prusa3d/MK3_dev' into simplify_EEPROM_M500
Known limitation: Unable to compile.
2018-10-08 15:58:49 +02:00
Robert Pelnar c2f535b619 Filament sensor - fix invalid calculation of fsensor_counter in LA stepper.
+decreased additional check sensitivity/sctrictness
2018-09-26 18:59:07 +02:00
Marek Bel 3f28632443 Use cs.axis_steps_per_unit from ConfigurationStore. 2018-09-24 14:54:41 +02:00
PavelSindler 03fffae4c3 finda runout sensor can be turned on/off from menu 2018-08-27 05:20:42 +02:00
Robert Pelnar c4281b0b36 Status screen redesign - fix of flickering and text wraping on status screen
printf formating, saved flash, reduced code size
2018-08-20 00:27:45 +02:00
Robert Pelnar 71f1a1f6db MMU - communication, check after start, code cleaning 2018-08-07 20:37:59 +02:00
Robert Pelnar 60b4db15e0 FSensor - M600 fix + cond. translation + tunning filter and params 2018-07-22 16:14:13 +02:00
Robert Pelnar 268d2634f0 LCD menu optimalization - lcd and menu
removed unused code and conditional translation
2018-07-16 02:13:52 +02:00
Robert Pelnar 066c044396 fixed tmc2130_wr_CHOPCONF
backlash - initial implementation (disabled by default)
removed menu "W25x20CL init"
splashscreen displayed before entering optiboot
2018-07-11 20:02:46 +02:00
Robert Pelnar fcfb4cdcae New ML support - menu tunning, startup
+config headers (bool - true/false replaced with 0/1)
+fixed include hierarchy
+removed comments
2018-06-10 16:04:32 +02:00
Robert Pelnar 2cf20c8c99 New ML support - migration - fix_source_1.sh script (replace 'MSG_xx' with '_T(MSG_xx)')
+ output + fixed source
2018-05-23 16:37:08 +02:00
Robert Pelnar bd587faab9 New ML support - migration - replaced source, removed original ML support files (backup) 2018-05-22 03:20:03 +02:00
MRprusa3d 0b6644915a
Add files via upload 2018-04-25 18:47:19 +00:00
Robert Pelnar 339d2ebdef Z-axis stealth mode
XYZcal fix
2018-04-03 18:26:39 +02:00
Robert Pelnar baade7db61 Removed unused files (ST7565R-dogm, digipot)
renamed functions digipot_init and digipot_current
fixed cond. trans. (menus)
fixed variant files - MK25, MK3
2018-03-29 23:01:13 +02:00
Robert Pelnar ac1a56b493 Merge branch 'MK25' into MK3 2018-03-13 20:43:19 +01:00
Robert Pelnar a6f900fd3c Merge remote-tracking branch 'upstream/MK25' into MK25
# Please enter a commit message to explain why this merge is necessary,
# especially if it merges an updated upstream into a topic branch.
#
# Lines starting with '#' will be ignored, and an empty message aborts
# the commit.
2018-03-06 15:11:50 +01:00
bubnikv 11e7eb27ee Merge remote-tracking branch 'remotes/origin/M221_fix' into MK3_fast_dbg 2018-03-05 19:13:07 +01:00
Robert Pelnar c5175e97ec Pinout, conditional translation and variant file for MK2 2018-02-21 15:19:34 +01:00
Robert Pelnar 57499dc6a0 M350 for E axis (8, 16, 32, 64, 128 microsteps) 2018-02-15 15:40:49 +01:00
bubnikv dd2468d306 Avoid the stepper interrupt being missed by extending the tick time
beyond the current time. This is a trick borrwed from upstream Marlin.

In debug mode, watch for the missed stepper interrupt ticks where the interrupts
are missed by more than 20% of the 10kHz stepper interrupt repeat rate,
and show the statistics (number of missed ticks and by how many micro
seconds was the interrupt missed, and what was the maximum missed
interrupt delay) on the display and send it to the serial line.
2018-02-15 11:44:19 +01:00
PavelSindler 0c98ec5f6b selftest, max endstops undefined, initialization of extruder fan, y offset from extruder 2018-02-06 17:01:09 +01:00
bubnikv 9acd41a942 Reworked the stepper routine:
1) The computational load is spread more evenly along the stepper ISR
ticks by moving some of the timer and linear advance calculation from
the block initialization into the 1st tick of the steady phase
of the trapezoid.

2) Reworked planning of the Linear Advance ISR ticks to fit
the time slot allocated for the main stepper ISR tick. This is achieved
by grouping the Linear Advance extruder ticks by a power of two to tick
the Linear Advance interrupts at a maximum 7kHz. Also some
of the extruder ticks are performed just after the XYZ ticks
and if the remaining time slot for the Linear Advance ticks is too short,
all the Linear Advance steps are ticked inside the main stepper ISR invocation.

3) Added some calls to MSerial.checkRx() if the stepper ISR routine
is delayed for too long by the additional LinearAdvance ticks.

This implementation differs significantly from the original implementation
by @Sebastianv650, as this implementation tries to follow the exact
timing of the XYZ axes with the drawback of possibly ticking the extruder
faster than it could handle, while the original implementation
by @Sebastianv650 ticks the extruder slower with the drawback of possibly
spreading the XYZ ticks, thus introducing jerk in the cartesian movement.
2018-02-02 22:55:50 +01:00
bubnikv 160cdccae1 Merge remote-tracking branch 'remotes/origin/MK3_stepper_blocking' into MK3_fast_dbg 2018-01-20 17:31:26 +01:00
bubnikv 815dfcb14b Implemented a stepper timer reset after a long blocking cli()
or DISABLE_STEPPER_DRIVER_INTERRUPT().
If this is not done, the stepper interrupt would likely overflow,
leading to a maximum 32ms delay before the stepper interrupt wakes up.
In addition, the stepper timer overflow error would be reported
by the debug builds.
2018-01-20 15:39:21 +01:00
bubnikv 17a8e2db01 Documented the interrupt blocking by a main thread by its maximum time.
Added a debug output to serial line on stepper timer overflow.
2018-01-20 14:58:30 +01:00
bubnikv 1eac2b4ccb Fixed a regression error from the last commit regarding Z homing.
Removed unused Z_LATE_ENABLE symbol.
2018-01-15 12:00:28 +01:00