Guðni Már Gilbert
d5b666d260
Add LCD_STR_SOLID_BLOCK to represent \xFF
2022-02-05 19:53:42 +00:00
Guðni Már Gilbert
976c8c4902
Change message from .c to .cpp
...
The allows us to include lcd.h and replace hardcoded value with define LCD_STR_REFRESH
Also deleted a #define for bool which does not seem to be used.
2022-02-05 18:57:18 +00:00
Guðni Már Gilbert
e62bc4686f
Replace hardcoded values and optimise strings
...
This commit saves 64 bytes of flash memory on my end
2022-02-05 18:28:17 +00:00
Guðni Már Gilbert
158877e736
Remove one space from Support -> Temperatures menu
...
Saves 2 bytes of flash memory
2021-08-01 11:20:29 +00:00
Guðni Már Gilbert
da2c802440
Add two defines and use LCD_STR_DEGREE with consistency
...
This saves 12 bytes of flash and 2 bytes of SRAM
2021-08-01 11:10:03 +00:00
Guðni Már Gilbert
6afc87d3c8
Reduce unnecessary LCD CGRAM writes
2021-07-30 23:53:57 +00:00
Guðni Már Gilbert
400f673fe0
Remove redundant extern variable lcd_encoder from menu.cpp
...
This extern variable is included from lcd.h
2021-07-20 09:12:14 +02:00
Guðni Már Gilbert
d087973e00
Remove redundant extern variable is_usb_printing from tmc2130.cpp
...
This extern variable is included from Marlin.h
2021-07-20 09:12:14 +02:00
Guðni Már Gilbert
6aee17b4ca
lcd_change_fil_state has two extern's in Marlin.h, only one needed.
2021-07-20 09:12:14 +02:00
Guðni Már Gilbert
3cfd706fff
Remove useless extern in cmdqueue.cpp
2021-07-20 09:12:14 +02:00
Guðni Már Gilbert
31c8e4bc4c
* Remove redundant externs already included with temperature.h
...
* Add ifdefs in Dcodes.cpp when using extern variables
2021-07-20 09:12:14 +02:00
Guðni Már Gilbert
eb9c8c8c20
Improve mc_arc() parameters
...
- Make the mc_arc() function declaration consistent with the definition
- isclockwise is supposed to be bool type, given how it is used.
2021-07-20 09:03:50 +02:00
Guðni Már Gilbert
538ce06bf0
Remove unused function lcd_choose_color()
2021-07-20 08:55:49 +02:00
Guðni Már Gilbert
bbe62b136a
Remove unused Sound_Save() function declaration
2021-07-20 08:51:57 +02:00
Yuri D'Elia
d04ea859fb
Consolidate "Unknown X-Code" to save 16 bytes
2021-07-20 08:19:19 +02:00
Yuri D'Elia
47b1e6ccef
Remove spourious trailing whitespace in errors
2021-07-20 08:19:19 +02:00
Yuri D'Elia
1888c783cb
Print an error on unknown D-codes
...
This follows the same convention of M/G codes, so that the user knowns
that the D-code has been either handled or ignored.
2021-07-20 08:19:19 +02:00
Guðni Már Gilbert
d853c19a21
Use fabs() instead of abs() when using floats
...
This saves 514 bytes of flash memory
2021-07-20 08:16:18 +02:00
Yuri D'Elia
31b913cddb
Correct the C implementation for MultiU16X8toH16
...
The comment behind the ASM MultiU16X8toH16 was misleading.
It actually computes ((a<<8)*b)>>16, or (a*b)>>8.
Correct the comment and C reference implementation accordingly.
2021-07-20 08:10:36 +02:00
Guðni Már Gilbert
710852a1f2
Change nrFiles from int16_t to uint16_t
2021-07-20 08:10:07 +02:00
Guðni Már Gilbert
16602f4003
change boolean to bool
2021-07-20 08:03:17 +02:00
Yuri D'Elia
1279a6cf4b
Correctly read FW_VERSION_NR array from progmem
...
In PR #3093 the progmem array FW_VERSION_NR was introduced to store the
version components, however the code didn't read it properly using the
pgm_read_* functions, making version comparisons fail.
Fix the existing/unused is_provided_version_newer() and reuse it in
show_upgrade_dialog_if_version_newer().
Similarly also read/update correctly the version in the eeprom.
2021-06-28 06:36:26 +02:00
Yuri D'Elia
56e531d40a
Improve/fix D23 for M2.5/S printers
...
- Move D23 into it's own function inside Dcodes
- Correctly include a break in the switch statement
- Show the dumper status (enabled/disabled) after toggling
- Allow to generate an immediate dump via g-code using D23 E for
symmetry with D20 E
2021-06-25 08:46:55 +02:00
Yuri D'Elia
380e34d481
Include "Dcodes.h" after "Marlin.h" for configuration
...
This is needed in order to get the function prototypes right according
to the actual enabled configuration.
2021-06-25 08:46:55 +02:00
Voinea Dragos
ecce6f865f
write_command() no line number handling
2021-06-25 08:12:30 +02:00
Yuri D'Elia
53fcd6fc8f
Work-around GCC LTO codegen bug in process_commands()
...
When building with GCC 4.9.2 (bundled with PF-build-env-1.0.6.*), -Os
and LTO enabled, PID_autotune gets automatically inlined into
process_commands().
Sadly, due to the massive size of process_commands(), it results in
codegen bug doing a partial stack overwrite in process_commands()
itself, manifesting as random behavior depending on the timing of
interrupts and the codepath taken inside the merged function.
Mark the function as noinline and add a note about the affected compiler
version in order to be checked again in the future.
2021-06-24 07:39:28 +02:00
Yuri D'Elia
66ee9a295f
Remove useless function EEPROM_read_st
2021-06-22 19:08:20 +02:00
Yuri D'Elia
8d11ad9d2d
xfdump: correctly erase all sectors in xfdump_erase
2021-06-22 19:07:49 +02:00
DRracer
8ff9b184c2
Merge pull request #3093 from DRracer/version-shave
...
Remove FW version parsing
2021-06-22 10:27:42 +02:00
D.R.racer
88074ac6c8
Remove FW version parsing
...
as it can be done at compile time. Code size dropped by >800 bytes.
2021-06-22 08:49:52 +02:00
DRracer
6188870c2e
Merge pull request #3157 from wavexx/improve_d2
...
Add extra debugging functions & crash analysis
2021-06-22 07:37:30 +02:00
DRracer
f36b9173da
Merge pull request #3191 from wavexx/fix_longpress_isr
...
Handle Long-Press in the main loop
2021-06-22 07:09:01 +02:00
Yuri D'Elia
79287ffb3d
Use uint8_t consistently for the block buffer's index
...
Instead of using a mixture of int8_t, unsigned char and (incorrectly)
int, use uint8_t consistently for indexing the current block.
This improves the performance of the wait loop in plan_buffer_line,
which currently expands all comparisons to a word for no reason.
This also extends the theoretical limit to 128 entries.
Add some static assertions to ensure BLOCK_BUFFER_SIZE is correct.
2021-06-22 06:59:57 +02:00
Yuri D'Elia
f4fcdae630
Fixup the DUMP_MAGIC constant
2021-06-22 00:04:39 +02:00
Yuri D'Elia
934b567e5a
Remove "bonus" exclamation points from the crash message
2021-06-21 22:37:28 +02:00
jfestrada
72be8f7be5
Fix spanish translation for MSG_UNLOAD_SUCCESSFUL ( #3185 )
...
Fix spanish transtalation for MSG_UNLOAD_SUCCESSFUL by: jfestrada <jfestrada@cloudhd.eu>
2021-06-21 12:42:56 +02:00
Yuri D'Elia
edde002cdc
Merge remote-tracking branch 'upstream/MK3' into fix_longpress_isr
2021-06-21 11:51:45 +02:00
Alex Voinea
30d9faef9d
Minor fixes to SD presence handling ( #3139 )
...
* Remove forgotten function protorypes
* Fix code indentation
* Fix double sorting if SD card is inserted during setup()
* Correctly handle SD removal during sorting
2021-06-21 07:30:47 +02:00
Voinea Dragos
0cbc759d8b
Second attempt at retrieving the SN from the 32u2 IC
2021-06-21 07:24:41 +02:00
Alex Voinea
6d25345fc4
optiboot_xflash comment about w25x20cl messages
...
Mention supported ICs
2021-06-21 07:21:40 +02:00
Yuri D'Elia
a92c0278fe
Use LCD_WIDTH instead of hardcoding 20
2021-06-21 07:21:10 +02:00
metacollin
8a7dd08116
Fixed C++ bug
2021-06-21 07:05:17 +02:00
Yuri D'Elia
09e935d27b
Fix two new explicit case fallthru warnings
2021-06-21 06:52:52 +02:00
Yuri D'Elia
d727a949dd
Silence explicit case-fallthru
2021-06-21 06:52:52 +02:00
Yuri D'Elia
c096462aab
Clarify statement by adding extra braces
2021-06-21 06:52:52 +02:00
Yuri D'Elia
051f03119b
Fix misleading indentation warnings by expanding tabs
2021-06-21 06:52:52 +02:00
Yuri D'Elia
f2fe57bfc0
Fix unused static declaration warnings
...
Guard declarations using the appropriate defines
2021-06-21 06:52:52 +02:00
Jonas Meyer
7bd43b77d7
Remove unnecessary assignment
2021-06-21 06:47:59 +02:00
Yuri D'Elia
eafdf6c216
Also move host_keepalive to manage_inactivity()
...
This avoids the "busy" output interleaving with regular output in very
rare scenarios.
We should focus in finding which calls are not using manage_inactivity()
properly instead of working it around.
2021-06-21 06:46:24 +02:00
Yuri D'Elia
29322d4bf3
Move host_autoreport() to manage_inactivity()
...
This makes autoreport work more consistently.
2021-06-21 06:46:24 +02:00