Commit Graph

3744 Commits

Author SHA1 Message Date
Alex Voinea
f8a0d5d773
Fix lcd_print_stop function 2020-01-07 19:54:06 +02:00
Alex Voinea
df0d781c20
Merge branch 'MK3' into fix_lcd_stop 2020-01-07 19:53:55 +02:00
Alex Voinea
b05ee33fc9
Merge branch 'MK3' into MK3_BED_LEVELING_PWM 2020-01-07 07:58:32 +02:00
Yuri D'Elia
853991865c Improve raise_z_above to always raise when at Z_MIN
When check_z_endstop is set, Z_MIN_PIN is checkend regardless of the
moving direction to support Z calibration. This prevents the ability
to use _just_ SG when moving upwards.

But since we know the extruder is at Z_MIN, it's always safe to raise
irregardless, so we can dodge the issue.
2020-01-02 18:07:30 +01:00
Yuri D'Elia
5660fcffb0 Do not enqueue a E/Z moves unless requested
Do not unconditionally enqueue a Z move if no move has been requested.
Since Z is calculated using the absolute current (saved) position and
scheduled for later execution, the queue order becomes relevant.
2019-12-30 14:49:07 +01:00
Yuri D'Elia
86696156af Improve K error checking, allow to manually reset the version
Properly check K independently for each version by delegating it to la10c_value()

Handle -1 as a special case to allow manual reset.
2019-12-30 14:31:39 +01:00
Yuri D'Elia
57be14fca6 Complete all pending moves before restoring a saved print 2019-12-30 13:30:06 +01:00
Yuri D'Elia
fd0ed1f0ea Move LA reset from G28 to G80, do not reset on 0
In preparation for #2161, use MBL (G80) as a "new print" boundary
instead of just re-homing to ensure the reset is issued only once for
each print.

Similarly, do not reset the autodetection when LA is disabled via M900
K0. This can/will be used during a print if different quality settings
are used for different filling roles.
2019-12-30 11:32:27 +01:00
Yuri D'Elia
d78636c308 Do not synchronize on M900
Since the advance factor is computed per-segment in LA15, there's no
need to stop the planner. Allow changing K freely at each segment.

This allows varying quality factors for different filling roles, see:
https://github.com/supermerill/Slic3r/issues/108

During pause/resume/crashdetect or powerpanic K might temporarily be out
of sync when used this way. If this becomes an issue, we might need to
store K for each block, as done for the feedrate.
2019-12-29 23:25:16 +01:00
Yuri D'Elia
f5d382f9f4 Remove useless st_synchronize calls when unparking 2019-12-29 22:20:24 +01:00
Yuri D'Elia
186f881600 Avoid calling fsensor_update() one level earlier
Move the common checks between filament sensors out of fsensor_update().

Disable the runout check if a saved state is already present (this check
was missing in the PAT9125 variant) as this is currently not supported.

Note that the CHECK_FSENSOR looks completely redundant besides
e_active().
2019-12-29 22:08:44 +01:00
Yuri D'Elia
bd80ee88a0 Set the IN_HANDLER busy state while checking the filament 2019-12-29 21:27:42 +01:00
Yuri D'Elia
97170ed68d Do not call process_commands() within fsensor_update()
Plan moves directly to reduce the required stack size.
2019-12-27 19:37:20 +01:00
Yuri D'Elia
fe4c00fb8a Lift the extruder when checking for the filament
This avoids leaving marks on the print
2019-12-27 19:35:08 +01:00
Yuri D'Elia
301d64042b Set fsensor_watch_runout earlier to prevent re-entry
Do not set/clear fsensor_watch_runout within fsensor_oq_meassure_start
which is used outside of fsensor_update where it could have a different
starting value.

Set it within fsensor_stop_and_save_print to immediately prevent
re-entry.
2019-12-27 19:34:36 +01:00
Yuri D'Elia
a31319888c Fix fan_check_error check in usb print resume
Also check for fan_check_error == EFCE_OK in addition to EFCE_FIXED.

Reorganize the check in order to fix both #if[n]def FANCHECK cases,
as similarly done in the SDSUPPORT case a few lines below.
2019-12-23 19:12:46 +01:00
Yuri D'Elia
7b29ce29b4 Add a Linear Advance 1.0->1.5 compatibility layer
Allow existing gcode using LA10 to transparently take advantage of LA15
by using a simple linear conversion function based on experimental
results with the MK3 implementation of linear advance.

Autodetect LA10 values based on the first M900 instruction contained in
the print. In order to support printing mixed files without resetting
the printer we also reset the autodetection status when starting a new
SD print and/or when explicitly disabling LA.

Since we cannot reliably detect whether a new print is started when
printing via USB, also reset the detection status when homing in G28,
which is generally performed once at each print. Note that this doesn't
clear the previous K value, it only allows a subsequent M900 to provide
LA10 values when printed after a LA15 file.
2019-12-21 23:22:35 +01:00
Yuri D'Elia
c0ae92cd2a Remove "relative_mode", only use "axis_relative_modes"
axis_relative_modes can cleanly handle G90/G91 and M82/M83 without the
need of "relative_mode" entirely.

Change G90/G91 to simply reset all axes according to the requested
state, which avoids to check two variables in get_coordinates(),
fixing the following incorrect handling:

G91   ; all axis relative
M83   ; set extruder absolute
G1 E1 ; should be an absolute move, but still relative
2019-12-20 18:47:30 +01:00
Yuri D'Elia
8d60e4d6db Merge remote-tracking branch 'upstream/MK3' into MK3_LA15 2019-12-18 18:28:41 +01:00
Alex Voinea
f071aec747
Fix sheet minimum width on the status screen 2019-12-18 08:52:25 +03:00
3d-gussner
46c06f7eee Updated it to use Arduino_Boards v1.0.3
and linked everything to prusa3d repositories
2019-12-17 14:05:39 +01:00
Yuri D'Elia
8d490f941a Make use of the CRITICAL_SECTION macros in lcd_print_stop 2019-12-16 16:39:20 +01:00
Yuri D'Elia
0cc68228f8 Unretract when resuming a paused print 2019-12-16 16:33:11 +01:00
DRracer
955c88cf68
Merge pull request #2370 from wavexx/no_resume_while_resuming
Do not allow to resume a print twice while waiting for the hotend
2019-12-16 16:26:02 +01:00
Yuri D'Elia
faa76df2fe Fix the "Stop print" behavior from the LCD
Correctly cleanup the printer state when stopping the current print:

- Disable interrupts while aborting the planner/queue to ensure
  new serial commands are not inserted while aborting
- _Always_ call planner_abort_hard() to interrupt any pending move!
- Clear the saved_target, which might be set when calling stop
  from within a paused state. Create a new function to clear the
  paused state for future use.
- Do not disable/reset the MBL: doing so will destroy the ability to
  restart correctly using M999.
2019-12-16 15:52:37 +01:00
Yuri D'Elia
348bbbffb0 Do not allow to resume a print twice while waiting for the hotend
Clear isPrintPaused just prior to restore_print_from_ram_and_continue.
2019-12-15 22:22:44 +01:00
3d-gussner
28b66bc909
Update to prepare for new prusa3d/PF-build-env
Fixed a bug in Arduino user preferences
2019-12-15 17:27:15 +01:00
DRracer
d4fab1a713
Merge pull request #2304 from 3d-gussner/MK3-Fix_M81
Fix M81 Turn off Power Supply...
2019-12-15 11:52:56 +01:00
DRracer
c45d4f4bba
Merge pull request #2088 from rhounsell/MK3
Fix for Toshiba FlashAir (or other) SD card initialization
2019-12-15 11:46:56 +01:00
DRracer
8f13e91856
Merge pull request #2344 from prusa3d/mkbel-patch-1
Add link for doxygen generated documentation to README.md
2019-12-15 11:06:54 +01:00
DRracer
44288bfe90
Merge pull request #2309 from leptun/MK3_fix_MMU_pause_time
Fix MMU needs user attention Statistics error
2019-12-15 11:04:57 +01:00
DRracer
d6ac9e4638
Merge pull request #2342 from vintagepc/2306-hard-reset-homing-fails
Fix #2306 hard reset homing fails
2019-12-15 10:51:52 +01:00
DRracer
c122399020
Merge pull request #2270 from leptun/MK3-PFW-1024
PFW-1024
2019-12-15 10:25:37 +01:00
DRracer
d68d9c7fef
Merge pull request #2058 from leptun/MK3_fix_warnings
Fix "LANG_MODE 0" warnings
2019-12-15 09:29:27 +01:00
Alex Voinea
770fcd7c42
Merge branch 'MK3' into MK3-PFW-1024 2019-12-14 10:08:52 +02:00
DRracer
6ab3b20ce1
Merge pull request #2348 from leptun/MK3_fix_kill
Fix kill messages
2019-12-13 18:30:27 +01:00
DRracer
46120e503d
Merge pull request #2357 from prusa3d/issue-templates
Update issue templates
2019-12-13 14:12:45 +01:00
DRracer
1423de10a9
Merge pull request #2362 from leptun/MK3_Fix_Lang_64K_limit
Fix optiboot erase function after address 0xFFFF. Allows language files greater than 64K
2019-12-13 13:59:23 +01:00
DRracer
30cee7afca
Merge pull request #2353 from wavexx/lcd_pause_fixes
Fix the LCD pause (regression)
2019-12-13 13:53:29 +01:00
DRracer
838cec75ec
Merge pull request #2352 from wavexx/fix_m603_regression
Use lcd_print_stop() in M603, fix octoprint regression
2019-12-13 13:52:40 +01:00
DRracer
a1bc4cc5dc
Merge pull request #2332 from leptun/MK3_Octoprint_fIxes
Do not check for fanError if it is not enabled on resume
2019-12-13 13:47:56 +01:00
DRracer
ed3a459090
Revert "Skipped one translated sentence, because total translation size was >"
This reverts commit 5c2b573415.
2019-12-08 14:59:50 +02:00
Alex Voinea
89dfb00b04
Fix optiboot erase function after address 0xFFFF 2019-12-08 08:43:43 +02:00
Yuri D'Elia
0b9123ce24 Fix Live K, allow "Advance K" to be translated 2019-12-05 15:18:24 +01:00
Michal Fanta
564bab7308 Update issue templates 2019-12-05 11:42:42 +01:00
Yuri D'Elia
5122f79a39 Merge remote-tracking branch 'upstream/MK3' into MK3_LA15 2019-12-04 17:27:23 +01:00
3d-gussner
17e23693eb Fixed stuipid copy paste error 2019-12-04 14:21:43 +01:00
3d-gussner
0cafd10378 minor fix 2019-12-04 13:43:19 +01:00
3d-gussner
f7bfca3061 Fix merge issues 2019-12-04 13:39:56 +01:00
3d-gussner
7da1db2f25 Merge remote-tracking branch 'upstream/MK3' into MK3-Gcode_documentation 2019-12-04 13:35:09 +01:00