Commit Graph

6127 Commits

Author SHA1 Message Date
Yuri D'Elia 16b9acf8bc Decouple temperature ISR from ADC readings
Read from ADC as fast as possible using the ADC interrupt to get
more accurate instantaneous readings.

Decouple the temperature_isr from the adc reading interval, so that
the two can run independently for future use.
2022-07-25 17:30:21 +02:00
Yuri D'Elia e87188e7e3 Ensure ADC and thermistor tables use the same oversampling
The current code assumes that values are directly comparable
2022-07-25 17:30:21 +02:00
Yuri D'Elia 2535d072c4 Do not recursively enter temperature_isr
Disable the interrupt source instead, which avoids the added latency of
reentering the isr in the first place.
2022-07-25 17:30:21 +02:00
Yuri D'Elia 82e221e3c7 Remove ADC pullup checks
Setting pullups on the ADC should trigger the model-based check, making
this redundant and wasteful.

Keep the DEBUG_PULLUP_CRASH menu so that we can verify this behavior in
the future.
2022-07-25 17:30:21 +02:00
Yuri D'Elia 306f77ccbd Disable IR_SENSOR due to the injected ADC read for now
This is already reimplemented in the newer fsensor implementation
2022-07-25 17:30:21 +02:00
Yuri D'Elia 13163e9fbf Move millis_nc to system_timer.h 2022-07-18 17:53:27 +02:00
Yuri D'Elia f8de274db3 Split fan checks out of temperature.cpp 2022-07-18 17:53:27 +02:00
Alex Voinea 8e72470afc
Merge pull request #3435 from leptun/MK3_variant_hotend_name
Use correct filament type in variant files
2022-07-15 15:57:53 +03:00
Alex Voinea 46a9cf6239
Merge pull request #3529 from leptun/sd_menu_fixes
SD menu fixes
2022-07-15 15:55:26 +03:00
Alex Voinea 510c874619 Fix scrolling timing issue when the menu is rendering very slowly 2022-07-15 15:46:01 +03:00
Alex Voinea 8bb451129d Remove compiler bug workaround
These lines had to be done like that because gcc 5.4.0 would throw a segmentation fault when linking. With gcc 7.3.0, this is no longer an issue
2022-07-15 15:46:01 +03:00
Alex Voinea ae1815dc52 When over the SD limit, continue from the last sorted file
This gives a significant speed boost when just above the sorting limit, while only costing 2 bytes of ram
2022-07-15 15:46:01 +03:00
Alex Voinea a96e60c241 Do not call lcd_update after presorting 2022-07-15 15:45:34 +03:00
Alex Voinea 3a5bc0462a Do not call lcd_update recursively when running presort with many files 2022-07-15 15:45:34 +03:00
Alex Voinea 3c579bf738 Fix fullscreen message lcd_update handling 2022-07-15 15:45:34 +03:00
Alex Voinea 2059e40596
Merge pull request #3054 from espr14/insert_sort
File: use insert sort
2022-07-15 15:44:04 +03:00
Alex Voinea 49fb27bb28
Merge pull request #3504 from gudnimg/gudni_printer_smodel_check
Simplify `printer_smodel_check()`
2022-07-12 21:53:23 +03:00
Alex Voinea 39dfa96167
Merge pull request #3542 from wavexx/default_beep_freq_2
M300: do not set a default frequency if S is not set
2022-07-12 20:39:31 +03:00
3d-gussner 15bac09594 Fix typo 2022-07-12 11:24:35 +02:00
Alex Voinea 3ed3f87db6 Prevent beeps when P is 0 2022-07-12 09:57:56 +03:00
3d-gussner 3a77ef3ce7 Sync PF-build.sh and MK404-build.sh with MK3_3.11.1 branch 2022-07-12 08:48:22 +02:00
Yuri D'Elia 2a9869ce2d M300: do not set a default frequency if S is not set
Fallback to use the default HIGH value if a frequency has not been
specified.

This makes the tone of "M300" and "M300 P<x>" identical as a result.

Supersedes #3339
2022-07-11 15:18:56 +02:00
3d-gussner 1db9735654
Merge pull request #3520 from 3d-gussner/MK3_build_v108
Use PF-build-env 1.0.8
2022-07-05 17:21:04 +02:00
Alex Voinea 56bc2f1a0c
Merge pull request #3495 from wavexx/extrude_min_temp
Replace EXTRUDE_MINTEMP with the configurable extrude_min_temp
2022-07-05 12:02:26 +02:00
Alex Voinea 9466945532
Merge pull request #3461 from wavexx/fan_selfcheck_test
Fix/optimize fan selftest
2022-07-05 11:32:57 +02:00
Alex Voinea 19b494a554 Make the fan thresholds configurable 2022-07-05 09:02:47 +02:00
3d-gussner 4903270ffa Use PF-build-env 1.0.8 2022-07-04 20:46:46 +02:00
Yuri D'Elia a8244dc2bd
Merge pull request #3455 from wavexx/stop_raise_higher
Stop raise higher
2022-07-04 20:05:23 +02:00
3d-gussner 6271f17340
Merge pull request #3442 from gudnimg/fix-M701-doc
Add documentation for M701, M203, M201 parameters
2022-07-04 18:51:31 +02:00
Alex Voinea 253b14def1 Clamp Z movements to machine limits 2022-07-04 18:26:14 +02:00
Yuri D'Elia 44fce0696b Make the stop raising distance configurable (Z_CANCEL_LIFT) 2022-07-04 18:21:59 +02:00
Yuri D'Elia 2c41857cb5 Raise Z 5cm after stopping
Check if Z axis has been homed and, if so, raise Z at least 5cm after
stopping so that the steel sheet can be comfortably removed.
2022-07-04 18:21:59 +02:00
Alex Voinea 61b8dbbab5 Disable sorting speedtest 2022-07-04 18:06:54 +02:00
Alex Voinea e79e15b12f Use the sd cache for positions even when not sorting 2022-07-04 18:06:54 +02:00
Alex Voinea d9d3d68217 Remove postponed sorting of elements
Now that the position is a uint16_t instead of uint32_t, it is simpler to just sort the positions in place without using the uint8_t indices. Also, this approach is considerably lighter on the stack usage and it also removes a delay after the sorting happens
2022-07-04 18:06:54 +02:00
Alex Voinea c100df7ba3 Remove quicksort, shellsort and add performance benchmark 2022-07-04 18:06:54 +02:00
Alex Voinea cac2b9ae40 Implement timer elapsed function
also fix build
2022-07-04 18:05:49 +02:00
Alex Voinea 490754a0f0 Fix build 2022-07-04 18:05:49 +02:00
espr14 02ca9496e8 File: use insert sort 2022-07-04 18:05:49 +02:00
Alex Voinea 65e19f6b0b
Merge pull request #3530 from wavexx/py_no_ex_dataerr
tools: Do not use os.EX_DATAERR due to unavailability on windows
2022-07-04 17:52:21 +02:00
Alex Voinea e435ef4bab Fix one more EX_DATAERR after sync with 3.11.1 2022-07-04 17:48:11 +02:00
Yuri D'Elia e68ded37fe tools: Do not use os.EX_DATAERR due to unavailability on windows
Just return a plain exit code...
2022-07-04 17:45:11 +02:00
Yuri D'Elia 0e7f2b33cf
Merge pull request #3531 from wavexx/mk311_sync
Synchronize MK3 with MK3_3.11.1
2022-07-04 17:23:14 +02:00
Yuri D'Elia e37435b53f Merge remote-tracking branch 'upstream/MK3_3.11.1' into mk311_sync 2022-07-04 16:14:23 +02:00
Alex Voinea 3ff2b04801 M701 Alias T for E parameter 2022-07-04 15:01:41 +02:00
Alex Voinea fd702c8a21
Merge pull request #3527 from gudnimg/fix-cmdbuffer-debug-crash
Fix a crash during file check when `CMDBUFFER_DEBUG` is defined
2022-07-04 12:02:51 +02:00
Alex Voinea 7c108c9420
Merge pull request #3528 from leptun/fix_some_gcc7.3.0_warnings
Fix gnu++17 register warning
2022-07-04 10:17:30 +02:00
Alex Voinea d5fc2a28f2
Merge pull request #3014 from Panayiotis-git/MK3_ButtonLongPress_Fix
Ignore button long-press event, if not allowed
2022-07-04 09:46:08 +02:00
Alex Voinea 29159a5bf3
Merge pull request #3475 from gudnimg/custom_message_m601
Make M117 message persistent on LCD when used with M601 or G4
2022-07-04 09:42:23 +02:00
Alex Voinea 61151251ff
Merge pull request #3485 from wavexx/ambient_raw_temps
Fix AMBIENT_RAW_*_TEMP define names
2022-07-04 09:38:05 +02:00