Commit Graph

3124 Commits

Author SHA1 Message Date
vintagepc
b449e248a1 Fix printf()s 2020-03-31 17:48:56 -04:00
vintagepc
0c383e20b3 Pull in changes from #5 2020-03-31 17:33:08 -04:00
vintagepc
f1cba64e56 Merge remote-tracking branch 'upstream/MK3' into #2472-#2356-belt-test-stealth-mode 2020-03-31 17:03:10 -04:00
3d-gussner
e481013126
Reset all stats during Shipping prep (#2563)
* Reset all stats during Shipping prep
Last print stats were missing

* keep old indentation

Co-authored-by: D.R.racer <drracer@drracer.eu>
2020-03-30 17:01:46 +02:00
DRracer
8196a5f165
Merge pull request #2565 from 3d-gussner/MK3_EEPROM-fix1
EEPROM_BACKLIGHT_TIMEOUT min is 1 sec
2020-03-30 16:58:22 +02:00
3d-gussner
957bfd89e3 Merge remote-tracking branch 'upstream/MK3' into MK3_Dcodes_move 2020-03-30 16:56:59 +02:00
3d-gussner
6da401be56 Move few D-codes command from Marlin_main to Dcodes
D80, D81 and D106 have been added to `Marlin_main.cpp` but all other D-codes moved to `Dcodes.cpp/.h`
2020-03-30 16:53:58 +02:00
3d-gussner
aa9aa14472 Version to 1.0.1 2020-03-30 16:24:20 +02:00
3d-gussner
9abc79d89c EEPROM_BACKLIGHT_TIMEOUT min is 1 sec 2020-03-30 16:16:07 +02:00
DRracer
368ee0857b
Merge pull request #2564 from 3d-gussner/MK3_EEPROM-fix1
Typo in some hex default values
2020-03-30 16:15:26 +02:00
Alex Voinea
f13269d8a9
Code cleanup 2020-03-30 16:50:50 +03:00
Alex Voinea
104f81cd27
Fix case sensitive include 2020-03-30 15:42:30 +03:00
Alex Voinea
988ba6d8b0
Fix DEBUG_BUILD 2020-03-30 15:38:01 +03:00
3d-gussner
0f9aa00eaf Typo in some hex default values 2020-03-30 10:36:13 +02:00
DRracer
5106831ba2
Merge pull request #2526 from leptun/MK3_decouple_XYZE_relative_mode
Mk3 decouple XYZE relative modes
2020-03-26 18:58:20 +01:00
DRracer
587b051b1f
Merge pull request #2492 from vintagepc/belt-test-fixes-no-reorg
Belt test improvements (No display alteration)
2020-03-26 18:53:40 +01:00
DRracer
b95d7365c8
Merge branch 'MK3' into remove-unnecessary-delay 2020-03-26 18:45:34 +01:00
DRracer
a4b8f52269
Merge pull request #2466 from vintagepc/#2464-fix-runout-for-unknown-filament
#2464 fix runout for unknown filament (also fixes #1993, #2301)
2020-03-26 18:43:05 +01:00
DRracer
c085ecaa11
Merge pull request #2264 from leptun/MK3_fix_selftest_Z_crash2
PFW-1048: fix selftest Z crash. Use stallGuard when testing Z
2020-03-26 18:22:35 +01:00
Alex Voinea
d0c51b9e73
int -> bool 2020-03-26 19:06:35 +02:00
DRracer
65228a046e
Merge pull request #2520 from MRprusa3d/PFW-x001bPR
FS PCB auto-detect
2020-03-26 17:36:18 +01:00
D.R.racer
818efb4fa2 updated messages + slight refactoring to save some bytes 2020-03-26 15:07:48 +01:00
D.R.racer
34ac2917ae fix. warning "Macro expansion producing 'defined' has undefined
behavior"
update screen layout comments
2020-03-26 14:40:47 +01:00
3d-gussner
32c95d5455 Merge branch 'MK3' into MK3_Dcodes_case_sensitive 2020-03-26 14:08:55 +01:00
3d-gussner
2ceec597a5 Fix typo 2020-03-26 14:08:35 +01:00
3d-gussner
9b394dcbe6 Update to Version 1.0 2020-03-26 13:55:23 +01:00
3d-gussner
82cd1f9f84 Typo. thanks @leptun 2020-03-25 17:44:43 +01:00
3d-gussner
4c518545f1 Updated the documentation
copy past from Marlin_main.cpp doxygen documentation d-codes
2020-03-25 17:33:10 +01:00
3d-gussner
0d00db1c33 Some D-codes are case sensitive 2020-03-25 17:26:27 +01:00
3d-gussner
95a24320f7 Added language factory reset
and some other minor fixes
2020-03-23 17:10:40 +01:00
3d-gussner
7cd5d83089 Added S/P to Default/FactoryReset
S = Statistics
P = shipping Prepare
2020-03-23 16:54:35 +01:00
3d-gussner
6be66fcfcd fix some typos 2020-03-23 15:47:59 +01:00
Alex Voinea
6979555fab
more comments 2020-03-23 16:30:51 +02:00
3d-gussner
bb43fa9878 typo dedine doesn't work 2020-03-23 14:51:40 +01:00
3d-gussner
0067dc0d9d Merge branch 'MK3' into MK3_EEPROM_doc 2020-03-23 14:15:35 +01:00
3d-gussner
f4037b9cb4 Fixes after testing 2020-03-23 14:13:24 +01:00
Alex Voinea
5c4b3eea87
Struct comments 2020-03-23 14:57:03 +02:00
DRracer
73349033d5
Merge pull request #2469 from wavexx/fix_current_pos_init
Initialize current_position correctly during startup
2020-03-23 12:26:32 +01:00
3d-gussner
fc793b59d7 changed default values for bowden length after test 2020-03-23 12:02:57 +01:00
DRracer
5a6148670a
Merge pull request #2494 from DRracer/create-mod-filetime-sort
Use combined creation/modification file time stamps for sorting
2020-03-23 11:53:52 +01:00
3d-gussner
32bff79fd6 minor changes + added EEPROM_FREE_NRx ...
Some EEPROM allocations do not use the hole allocated space:

- EEPROM_FARM_NUMBER is only numeric 000-999 and only uses 2 bytes to store the Farm number BUT allocated 3 bytes. Added EEPROM_FREE_NR1 as free space that can be used
- EEPROM_CRASH_DET just changes 1 byte to save it status [on/off] but allocated 5 bytes. Added EEPROM_FREE_NR2 to EEPROM_FREE_NR5 as free space that can be used
2020-03-23 11:40:07 +01:00
Alex Voinea
ea1a2bb362
Documentation update 2020-03-23 12:37:56 +02:00
DRracer
468b0e210c
Merge pull request #2372 from leptun/MK3_fix_verbosity
Fix SUPPORT_VERBOSITY
2020-03-23 10:53:39 +01:00
DRracer
0f32c46307
Merge pull request #2371 from 3d-gussner/MK3_Fix_Language_Debug
MK3 fix language debug
2020-03-23 10:53:14 +01:00
3d-gussner
0c65505741 Added PRUSA3DFW at 0x0000 2020-03-23 07:23:36 +01:00
3d-gussner
1b0c86cb51 minor fix 2020-03-22 15:23:41 +01:00
3d-gussner
2778fa9aa0 Added author and version of document 2020-03-22 15:22:14 +01:00
3d-gussner
b178252eb9 Added Italic and Bold to highlight some settings 2020-03-22 15:18:45 +01:00
3d-gussner
028a27021b All done...
hope not I forgot one. I will re-test all `D3 Axyyyy Cz` before creating a PR.
2020-03-22 14:08:21 +01:00
3d-gussner
2591f8d593 Added and tested more...
... have to take a short break
2020-03-20 12:36:26 +01:00
3d-gussner
c8fc5b2fed Simpler tabel syntax 2020-03-20 10:44:12 +01:00
3d-gussner
4d40ed67f6 remove LF 2020-03-12 12:36:48 +01:00
3d-gussner
2818316366 Started EEPROM Table doxygen documentation 2020-03-12 12:34:33 +01:00
MRprusa3d
ff479afd88 version for testing / final review 2020-03-10 15:51:48 +01:00
MRprusa3d
f71bbfe95e tresholds specification, steady delay 2020-03-10 00:11:17 +01:00
Alex Voinea
890c137298
Initialize all axis as absolute at the beginning. 2020-03-05 11:29:16 +02:00
Alex Voinea
5fcf18718f
Decouple XYZ relative from E relative. 2020-03-05 11:22:35 +02:00
MRprusa3d
f09323a78f heaters-checking update 2020-03-03 14:57:45 +01:00
MRprusa3d
0eaa4edfee configuration update 2020-03-02 21:18:11 +01:00
MRprusa3d
2a9504b20a !!! for testing only !!!
filament sensor auto-detection
2020-03-02 19:07:23 +01:00
MRprusa3d
ec5e54de25 state fixing 2020-03-02 17:52:25 +01:00
vintagepc
e06beb61c3 Ditch charswitch, show ... for measuring 2020-02-21 18:14:13 -05:00
DRracer
2e18a48b87 Version changed (3.9.0-RC1 build 3272) 2020-02-17 16:47:56 +01:00
DRracer
f234ef2104 Use combined creation/modification file time stamps for sorting 2020-02-14 09:09:15 +01:00
vintagepc
1aaefffdb0 Change to raise_z_above() 2020-02-13 07:37:27 -05:00
vintagepc
5abee3d3e5 Better display handling 2020-02-11 19:44:26 -05:00
vintagepc
278bb032d7 Change to raise_z_above() 2020-02-11 18:37:26 -05:00
vintagepc
a4458fb57b Removed duplicate #defines
cleaned up display routine
2020-02-11 18:33:40 -05:00
vintagepc
e4b1a1e9c4
Remove delay for belttest, similar to #2439
There's a separate PR to remove the first delay in the selftest. (#2439). Mirroring that to the belt test function, which I suspect also inherited it.
2020-02-09 21:39:48 -05:00
vintagepc
721b27fcb6
Reorg/cleanup
Removed unused progress variable
reorganized flow to avoid early returns (ensures forced high power mode is disabled regardless of outcome)
2020-02-08 12:33:23 -05:00
vintagepc
1384e783bf
Force high power mode when running belt test 2020-02-07 16:14:33 -05:00
DRracer
a10b7f3963
Merge pull request #2470 from leptun/MK3_Adjusted_mintemp
Adjusted hotend, bed and Ambient mintemp values
2020-02-07 08:54:50 +01:00
Yuri D'Elia
f1618bfbd6 Initialize current_position correctly during startup
Just after setting up the w2m matrix, call "clamp_to_software_endstops"
on the current_position (initially [0,0,0]) to move it to the effective
minimal position, which is usually [0,0,non-zero] due to MIN_Z and the
negative probe offset.

This is required to calculate correctly the first relative move:
planning X+10 would unexpectedly calculate a Z shift otherwise.
2020-02-06 22:41:47 +01:00
Yuri D'Elia
9e45b5d41e Improve PAT9125 filament / optical quality checks
Tune the "soft" filament recheck to be more in-line with the latest
changes. Relax the thresholds so that a poorly tracking filament
that managed to trigger a recheck can still pass as long as /some/
motion is detected.

Hide the unused fsensor_oq_result() behind the FSENSOR_QUALITY define,
which is likely broken currently anyway.

Cleanup and simplify all the OQ defines.
2020-02-06 18:27:44 +01:00
Yuri D'Elia
853bb79b6b Return correct status from pat9125_update_bs 2020-02-06 16:39:08 +01:00
Yuri D'Elia
bd0544fe9e FS: Use two different speeds when checking for runout
When doing a PAT9125 "soft check", use two different speeds between
retraction and extrusion. This increases the chances that we can
track the surface.
2020-02-06 15:27:22 +01:00
Yuri D'Elia
3be859ece9 FS: Improve reliability on speeds with poor optical tracking
Depending on the filament surface and moving speed, the PAT9125 sensor
can stop being able to track movement.

In such cases, instead of triggering false errors and/or relying on
previous states, read and use the exposure data off the sensor and
increase error counts only for poorly exposed images instead, which
is a good indicator of a far-away (or missing!) tracking surface.
2020-02-06 15:27:22 +01:00
Yuri D'Elia
cdc17e8da1 Read all 12 bits correctly from PAT9125 DELTA_* registers
Widen ucXL/ucYL/ucXYH types to 16 bits, since the following shifts
will otherwise truncate the results.
2020-02-06 14:39:04 +01:00
Yuri D'Elia
3af35844e1 Remove redundant check (always trigger the fsensor isr)
Since fsensor_st_block_chunk is already called on fsensor_chunk_size
boundaries, there's no need to check a second time.
2020-02-06 14:39:04 +01:00
Yuri D'Elia
1eddc40ed4 Comment existing code 2020-02-06 14:39:04 +01:00
Yuri D'Elia
e84f82a675 Rewrite filament sensor PAT9125 error handling
Rewrite the logic behind the "chunking"/error count behind the PAT9125.

Basic idea: check the _direction_ of movement returned by the optical
sensor and compare it to the direction of the stepper. To avoid doing
this continuosly (and because the optical sensor doesn't necessarily
have the accuracy to track small distances), do so in chunks.

Each time a chunk doesn't match the expected direction, increase the
error count.

Several improvements were done to the previous code:

- Increase the chunk window: this ensures that a filament with
  poor response returns an usable direction, while also moving the
  average return values from the sensor in the middle of the 12 bits
  available for maximum effectiveness.
- Since the returned values are more reliable, reduce the error count
  (1.25mm*4 = ~5mm before runout detection)
- Track _both_ positive and negative movement, although only trigger
  errors during extrusion (necessary due to several assumptions made
  in the mmu/unloading code)
- Do not reset the counters for each block: accumulate distances
  correctly, allowing detection of any block lenght.
2020-02-06 14:37:46 +01:00
vintagepc
34f43d7389
Update mmu.cpp
Fix runout if filament is unknown
2020-02-05 21:41:31 -05:00
Yuri D'Elia
5c4235b886 Correctly reset the PAT9125 filament counters
When the error count is cleared, the cumulative deltas as well as the
segment lenght which is kept inside the stepper isr need to be reset.

Introduce a helper function fsensor_reset_err_cnt to clear all the
required variables in one place which can be used in most cases
(the only exceptions being quality measument).

Introduce a new function st_reset_fsensor to also clear the segment
lenght within the isr.
2020-02-05 16:21:27 +01:00
Yuri D'Elia
6fbd632c84 Isolate all PAT9125-specific code, fix build on !MK3 variants
- Hide all prototypes related to PAT9125 to force all callers
  to check for the proper sensor, since the handling differences
  are substantial
- Remove unneeded lenght accounting from the stepper isr as as
  consequence.
- Keep detailed soft failure counts for the MK3 on the "last print
  failures" status screen, but fix build on variants without a PAT9125
  by fixing the lcd stats function.
2020-02-05 16:20:12 +01:00
Yuri D'Elia
d47363d85a Update the filament axis resolution when E resolution is changed
The filament sensor "chunk lenght" needs to be updated every time the
E axis resolution is changed in order to trigger at the same distance.

Introduce a new function fsensor_set_axis_steps_per_unit() and use
it consistent during init, in M92 and M350.
2020-02-05 16:20:12 +01:00
Yuri D'Elia
ce74b746f1 FS: Trigger a runout with repeated soft-failures (clog?) 2020-02-05 16:20:12 +01:00
Yuri D'Elia
8fb8ff4bf4 Include fsensor recovery stats in the last print stats 2020-02-05 16:20:12 +01:00
Yuri D'Elia
e8ce5e140e FS: Detect runout earlier 2020-02-05 16:20:12 +01:00
DRracer
4774b44e21
Merge pull request #2461 from leptun/MK3_FIX_MINTEMP_FIXED
HEATER -> HOTEND
2020-02-04 16:35:07 +01:00
Alex Voinea
f1ccfd481a
HEATER -> HOTEND 2020-02-04 17:30:44 +02:00
DRracer
d4d1f051ba
Merge pull request #2149 from leptun/MK3_TONE
PFW-1056: Re-enable Tone on timer4
2020-02-04 11:04:15 +01:00
Alex Voinea
3ae5fa70ca
Fix comments 2020-02-03 19:20:43 +02:00
Alex Voinea
1f482adf55
Improved lcd_menu_statistics() implementation 2020-02-03 18:40:46 +02:00
DRracer
007395acb4
Merge pull request #2458 from wavexx/la15_compat
Adjust E-jerk in LA10 compatibility mode
2020-02-03 15:57:21 +01:00
Yuri D'Elia
453f5dd874 Adjust E-jerk in LA10 compatibility mode
When upgrading K values of a LA1.0 print, also adjust E-jerk settings
(<2) if permissible according to current accell limits. The same is also
true when jerk is set mid-print via 'M205 E'.

Existing values are always restored when switching to another
compatibility mode.

TODO: Since this is stateful, we will need to save the current print
mode / acceleration and jerk in the eeprom for this to survive a power
panic (see prusa3d#2456).
2020-02-03 15:42:27 +01:00
Yuri D'Elia
4b85664b27 Raise default extruder jerk to 4.5
This should be the new default for LA1.5 for direct drive printers and
newer PrusaSlicer profiles too (hopefully).
2020-02-03 15:42:27 +01:00
DRracer
796dcd6a3d
Merge pull request #2457 from wavexx/la15_fixes
Linear Advance 1.5 fixes
2020-02-03 15:27:02 +01:00
DRracer
685c8156b6
Merge pull request #2451 from wavexx/fix_printstats_reset
Do not clear last print fail stats prematurely
2020-02-03 11:21:41 +01:00
Yuri D'Elia
47db75d5fd Fix overflow and infloop with LA15 and low step rates
When calculating the advance tick interval, be sure to check for integer
overflow. Very low step rates can result in values exceeding uint16_t
causing premature LA tick delivery.

An overflow resulting in zero would also block in an infinite loop
within advance_spread().

Even though such rates are worthless in terms of compensation and often
result in 0 extra ticks as well, do not disable LA for the block (as
doing so would reset the count for short segments) and do not check for
zero in multiple paces either.

Saturate the interval instead, delaying any further tick to the next
block.
2020-02-02 22:49:39 +01:00
Yuri D'Elia
3bbc143821 Fix build with LA_LIVE_K
Do not check for LA_LIVE_K in messages.c (Configuration_adv.h is not
included here).

Rely on the linker to drop the symbol when LA_LIVE_K is disabled.
2020-02-02 18:02:37 +01:00
DRracer
d6522a643c
Update ultralcd.cpp
indent
2020-01-31 16:57:18 +01:00
DRracer
fd42361236
Update ultralcd.cpp
do delay(2000) everytime, even if IR_SENSOR_ANALOG
2020-01-31 16:55:40 +01:00
DRracer
10d468cceb
Merge branch 'MK3' into remove-unnecessary-delay 2020-01-31 16:51:27 +01:00
DRracer
d30960b8e8
Merge pull request #2431 from MRprusa3d/PFW-x001
selfTest workflow optimalization
2020-01-31 16:49:41 +01:00
3d-gussner
a355fdd00d
And another one
sorry
2020-01-31 15:40:07 +01:00
3d-gussner
b466dad1d7
Fix copy paste issues D2 D5
Fixed copy paste
2020-01-31 15:27:19 +01:00
Yuri D'Elia
84ecf96be5 Do not clear last print fail stats prematurely
M24 was always cleaning the last print failstats. But because M24 is
used to restore a print after power failure (by setting the seek
offset), it would also reset the stats incorrectly after resuming.

Check for the file index position and reset the stats only when a print
is started from the beginning of the file.

Apply the same logic to M32 and similarly handle the LA10->15 conversion
(do not re-apply the adjustment for a resumed print).
2020-01-31 15:08:24 +01:00
3d-gussner
857f9d8d9e Hard reset and readded change 2020-01-31 14:47:44 +01:00
DRracer
d70a147af5
Merge pull request #2436 from leptun/MK3_PSU_DELTA_cleanup
Do not clear axis known position when Z is set to silent
2020-01-31 09:08:14 +01:00
DRracer
0b62ed3325
Merge pull request #2450 from leptun/MK3_FIX_MINTEMP_FIXED
Show correct fixed message
2020-01-31 09:03:11 +01:00
DRracer
1ceadcb162
Merge pull request #2448 from wavexx/save_restore_fix
Save and restore fixes
2020-01-30 16:41:01 +01:00
Alex Voinea
886c2fdc4e
Show correct fixed message 2020-01-30 17:24:32 +02:00
DRracer
1b7677c768
Merge pull request #2394 from wavexx/fsensor_no_recursion
Avoid more recursive behavior in fsensor_update
2020-01-30 14:18:07 +01:00
Yuri D'Elia
1db024f17a Always raise the extruder 25mm during power recovery
Avoids oozed material (drooping more than ~1mm) to scrape and
potentially detach the print.
2020-01-30 13:12:12 +01:00
Yuri D'Elia
571906a494 Do not update saved_target if there's no current_block
There is a chance that current_block can be NULL despite
the queue being non-empty. This can happen early after a block has been
queued, but before the isr has picked it up for processing, and/or when
the current block is at the last step and is being discarded.

Check for current_block directly to avoid this race.
2020-01-30 13:12:12 +01:00
DRracer
48a0532e37
Merge pull request #2447 from leptun/MK3_BED_LEVELING_PWM
Turn off bed while probing during MBL
2020-01-30 11:18:34 +01:00
leptun
8c2902a660
Revert "Mesh bed leveling testing"
This reverts commit 28e812d91f.
2020-01-29 23:07:53 +02:00
Alex Voinea
b86aafb56e
Documentation 2020-01-29 23:07:24 +02:00
Alex Voinea
755230e2e7
fix small mistake 2020-01-29 23:07:24 +02:00
Alex Voinea
a5198e32a3
Just keep the current state. ON or OFF. No switching allowed 2020-01-29 23:07:24 +02:00
Yuri D'Elia
02d1525445 Display "POWER PANIC DETECTED" when possible
Both during early init and in uvlo_tiny, display "POWER PANIC DETECTED"
if enough charge is left.

This is not worth doing in regular uvlo_, as we want to give full
priority to the X motor
2020-01-29 21:08:56 +01:00
Yuri D'Elia
2b46fdac2d Only trigger a quick reset if there's a pending saved state
Thanks to @leptun
2020-01-29 17:56:26 +01:00
Alex Voinea
99e81812ce
Merge branch 'MK3' into MK3_BED_LEVELING_PWM 2020-01-29 17:56:10 +02:00
Alex Voinea
4fd913ddf3
Remove commented out code 2020-01-29 17:45:47 +02:00
Yuri D'Elia
b46dc59fad Refuse to start a print if power is lost before arming uvlo
If power has been lost during startup already a falling edge would be
skipped, causing the print to continue and lose its state without
being able to save again.

Check for a low line after arming the interrupt and simply wait
for reset.
2020-01-29 16:06:54 +01:00
Yuri D'Elia
200cdde1af Setup the UVLO interrupt later during initialization
Do not allow uvlo_tiny() to trigger before the previous print has
already been recovered.

A quick repeated power failure could cause uvlo_tiny to overwrite
the Z position before it has been correctly recovered.
2020-01-28 21:50:12 +01:00
DRracer
3e70b73a1f Remove unnecessary delay in lcd_selftest, which occured there as a result of merge. 2020-01-27 19:02:15 +01:00
Yuri D'Elia
3da20db024 Really poweroff Z motors when PSU_Delta is defined
enable/disable_z behave differently when PSU_Delta is defined.

During powerpanic and kill however we do *really* need to save energy
and poweroff the motors.

Rename enable/disable_z as poweron/poweroff_z and define some aliases so
that we can use the low-level function where needed.
2020-01-27 18:50:17 +01:00
Yuri D'Elia
5d88573711 Save/restore hotend temperatures above 255C in PowerPanic
Use 2 bytes to store extruder temperature during UVLO.

Re-use the storage of EEPROM_UVLO_TINY_Z_MICROSTEPS which has been freed
by previous changes.

Fixes #2303
2020-01-27 14:59:18 +01:00
Yuri D'Elia
50a9fe003a Bump the unparking speed to 50mm/s (same as M600 recovery) 2020-01-27 11:08:28 +01:00
Yuri D'Elia
eb2ca78167 Rewrite uvlo handling for accurate Z re/positioning
- In both uvlo_ and uvlo_tiny, calculate Z usteps properly and adjust
  the Z position to a true fullstep before disabling the motor. This
  avoids shifs during recovery.
- In uvlo_tiny, instead of moving up indefinitely, adjust Z just
  once using the smallest move possible (new def UVLO_TINY_Z_AXIS_SHIFT)
- Perform all the uvlo/recovery processing in physical coordinates
  and MBL off: there should be no automatic Z movement!
- Disable heaters in both handlers to conserve more power.
- Add timing information to uvlo_tiny too.
- During recovery, to switch between physical and logical positioning
  introduce a new "PRUSA MBL" gcode as most of the procedure is
  enqueued, and no existing gcode was available.
2020-01-26 17:46:50 +01:00
Yuri D'Elia
11a0e95f60 Re-enable the code that moves the extruder during PP
There is frequently plenty of power left during a PP. Take advantage of
it by moving the extruder to either side of the axis to detach
completely the nozzle from the print.

Re-enable Z during this move to avoid losing the current step.
2020-01-26 17:46:50 +01:00
Yuri D'Elia
0702e0de6e Use world2machine instead of repeating code 2020-01-26 17:46:50 +01:00
Yuri D'Elia
ec5cbf73b9 During PP keep the watchdog waiting for longer
When the printer is connected to a USB host during a PP (and the host
does not lose power), the rambo can linger for longer, sometimes for
long enough to recover the print state. Drain some more power.
2020-01-26 17:46:50 +01:00
Yuri D'Elia
ec8b5aaa34 Do not attempt to "zero-phase" the microstep counter
If the motors are off-phase, this is more likely to "bump" them to an
incorrect/reverse full-step, doing worse.

We need to ensure the motors are already positioned on a fullstep
during power panic instead.

Remove the PSU_DELTA exception: Z _always_ needs to be powered here.
2020-01-26 17:46:26 +01:00
Yuri D'Elia
5310181970 Cancel a recovering print when using the LCD "Stop"
Also clear the UVLO flag when using lcd_print_stop. This prevents an
aborted print which has been cancelled while unparking (just prior to
recover) to come back again at the next startup.
2020-01-26 17:45:47 +01:00
Alex Voinea
4055977a95
Do not clear axis known position when Z is set to silent
Also removed unused (forgotten) variable.
2020-01-25 11:41:27 +02:00
Alex Voinea
2e50954710
Merge branch 'MK3' into MK3_fix_selftest_Z_crash2 2020-01-22 14:56:54 +02:00
MRprusa3d
73527d6069 selfTest workflow optimalization 2020-01-22 04:45:13 +01:00
Yuri D'Elia
7f3d4a8491 Restore the last E axis position correctly after powerpanic
- Initially restore the last E position from the eeprom in any case, not
  just when using absolute mode (although unnecessary: since it will be
  reset later), fixing a possible unitialized position and crash during
  recovery (thanks to @leptun)
- Remove useless extra calls to put the extruder in relative mode:
  the extruder already starts in relative mode and is later switched to
  absolute.
- Replace incorrect calls to STRINGIFY with sprintf_P
- Retract after pressure has been restored in uvlo_tiny, to be
  consistent with a regular uvlo (remove the bogus double unretract
  as a result).
- Set the real E position prior to the panic *after* the retraction,
  using the now-fixed G92.
2020-01-21 17:41:43 +01:00
Yuri D'Elia
4c8f1e8b89 Use eeprom_update_word instead of EEPROM_save_B 2020-01-21 16:36:34 +01:00
Yuri D'Elia
9ac80f73f2 Remove an useless/duplicate Z move
Likely a result of a merge
2020-01-21 16:34:09 +01:00
Yuri D'Elia
8437630122 Inhibit serial processing in uvlo_
Do not process serial commands when re-enabling the global isr.
While printing via USB and a power panic is triggered, *any* extra
command should be ignored.

Abuse the "saved_printing" variable to inhibit serial processing.
2020-01-21 16:29:12 +01:00
Yuri D'Elia
e8f05d0668 Heat both nozzle/bed together while recovering a print 2020-01-21 16:26:16 +01:00
Yuri D'Elia
67decb466d Avoid another call to st_get_position_mm
current_position is already filled by planner_abort_hard.
2020-01-21 16:24:19 +01:00
Alex Voinea
e6ba9e633c
Adjusted hotend, bed and Ambient mintemp values 2020-01-21 14:50:53 +02:00
DRracer
95a2ad533d Version changed (3.9.0 build 3175) 2020-01-16 16:03:34 +01:00
Alex Voinea
1d17a37250
all axis -> all axes 2020-01-16 09:15:44 +02:00
leptun
ccd3885d84
rephrase G28 W 2020-01-15 23:01:09 +02:00
Alex Voinea
6a1eb63a52
Add @todo to M999 2020-01-15 22:41:02 +02:00