Yuri D'Elia
68c04ca2f6
Switch a few pointers that don't manipute strings to const
2022-08-06 23:08:03 +02:00
Alex Voinea
f25bddce35
Simplify GETPC()
2022-02-02 21:06:58 +01: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
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
Yuri D'Elia
700825ff76
serial_dump: include hex prefix
2021-06-19 13:57:40 +02:00
Yuri D'Elia
dd8c6c064c
xfdump: simplify stack debugging (sample pc+sp)
...
Instead of having to guess the PC where the SP was sampled, always take
both. This allows "seamless" stack decoding for both serial and xflash
dumps, since we don't have to guess which function generated the dump.
Make the core functions (doing the sampling) be ``noinline`` as well,
so that they always have valid frame.
2021-06-17 01:29:25 +02:00
Yuri D'Elia
a614268c94
serial_dump_and_reset: do not call manage_heater with interrupts disabled
...
Do not call manage_heater() in print_mem() if interrupts are already
disabled. This means we're running inside the crash handler.
2021-06-15 18:44:44 +02:00
Yuri D'Elia
d193d0f7ac
serial_dump: manipulate WDT just once
2021-06-15 16:21:56 +02:00
Yuri D'Elia
928c7211ad
emergency handlers: always save SP _at_ the crash location
...
Save SP which is closest to the crash location, which simplifies
debugging. For serial_dump, write SP just before the dump.
For xfdump, save SP in the dump header.
This makes xfdump_dump and xfdump_full_dump_and_reset() equivalent for
stack debugging.
2021-06-15 11:47:27 +02:00
Yuri D'Elia
7db667ca86
serial_dump_and_reset: turn on print fan while dumping
...
To avoid scorching the sheet while dumping close to the bed.
2021-06-13 22:28:28 +02:00
Yuri D'Elia
ea51d65137
serial_dump_and_reset: do not completely disable WDT
...
Set it to 8s which is long enough to complete the dump.
2021-06-12 15:39:37 +02:00
Yuri D'Elia
bd57e00448
Implement an online crash dumper for MK2.5 boards
...
When XFLASH is not available, allow users to request _online_ crash
dumps by using D23 (since these require active user cooperation).
Once enabled, instead of just rebooting, dump memory directly to
the serial.
As similarly done with EMERGENCY_DUMP, we have two features that can be
enabled:
EMERGENCY_SERIAL_DUMP: enables dumping on crash after being requested
MENU_SERIAL_DUMP: allow triggering the same manually through the support
menu.
2021-06-12 13:37:20 +02:00
Yuri D'Elia
f7dc8dcaef
Fix usage of RAMEND
...
RAMEND is the last valid address, not one-past as I expected it to be...
2021-06-12 13:16:12 +02:00
Voinea Dragos
0a77f2c02d
Dump header as well
2021-06-10 11:58:46 +03:00
Voinea Dragos
094c577e9d
Fix XFLASH_DUMP print_mem
2021-06-09 14:10:20 +03:00
Voinea Dragos
8c3d76f85f
Fix millis reference
2021-06-09 12:44:28 +03:00
Yuri D'Elia
378f239ff0
dcode_code: fix inverted define to print larger types
2021-06-08 18:57:16 +02:00
Yuri D'Elia
c072fbbf02
Dcodes: fix daddr_t type when only XFLASH_DUMP is enabled
2021-06-08 18:14:49 +02:00
Yuri D'Elia
c331c07b16
xfdump: reuse standard definitions for SRAM size/offset
2021-06-08 17:53:06 +02:00
Yuri D'Elia
30402e0404
Dcodes: add D20/D21/D22 to generate/read/clear dumps
2021-06-08 15:34:39 +02:00
Yuri D'Elia
6dfef76346
xfdump: implement dump-to-xflash functionality
...
Update xflash_layout to include information about the dump, which sits
at the end of xflash.
2021-06-08 15:28:02 +02:00
Yuri D'Elia
5ae8bad0ba
Introduce "xflash_layout" to organize XFLASH's content
...
Update the language code to use the new LANG_OFFSET definition
and remove hard-coded flash sizes.
2021-06-08 15:22:37 +02:00
Yuri D'Elia
af636c7f2a
Move "xflash" include inside the conditional
2021-06-08 15:18:33 +02:00
Yuri D'Elia
0fcdada579
D6: add documentation
2021-06-07 19:58:18 +02:00
Yuri D'Elia
ed9f52dd85
D6: also hide declaration behind conditional
2021-06-07 18:50:45 +02:00
Yuri D'Elia
db096557d4
D[236]: remove "busy" messages while dumping, avoid WDT
2021-06-07 16:41:25 +02:00
Yuri D'Elia
12e124324f
Remove PROGMEM handling from print_mem until D5 uses dcode_core
...
Handling PROGMEM also requires a 32bit address type.
2021-06-07 16:41:25 +02:00
Yuri D'Elia
f9371146d0
Implement reading XFLASH with D6
...
This requires expanding the dcode_core address type to 32bit type,
thus enlarges the D2/D3 implementation as a result.
Still allow to save all the original space if D6 is disabled, for now.
2021-06-07 16:41:25 +02:00
Yuri D'Elia
915f5a7692
Unify D2 and D3 handling
...
Handle reading/writing memory using the same base functions
in order to save space.
2021-06-07 16:41:25 +02:00
Yuri D'Elia
2d25a5705f
Fix D2 to read the entire SRAM content
...
Allow to read up to 0x21ff, which is the last byte of SRAM. Set default
starting address to 0x200, which is the first true byte.
0x0-200 is mapped to register/io space and could cause issues when read
from bi-directional registers.
2021-06-07 16:37:34 +02:00
Yuri D'Elia
62f496e1d6
Allow D2 to be enabled selectively
2021-06-07 16:37:34 +02:00
Alex Voinea
c951bea627
Remove unused/broken bootapp code
2021-03-03 16:31:30 +02:00
Voinea Dragos
da21916473
Change printf_P without format arguments and NL to puts_P only
2021-01-22 18:56:05 +02:00
D.R.racer
c710253cca
Code cleanup and size reduction and RAM optimization
...
Replase single character strings with single characters when calling
lcd_print
2021-01-22 17:11:51 +01:00
Alex Voinea
8d9dc73d1b
Fix compile error
...
fix compile
Fix compile error
2020-08-12 17:25:49 +03:00
Alex Voinea
5530b99882
Reboot after factory reset
2020-08-12 12:46:35 +03:00
DRracer
c8f67f2279
Merge pull request #2568 from 3d-gussner/MK3_Dcodes_move
...
D- codes move
2020-04-03 11:12:30 +02:00
3d-gussner
a1b8ee67b3
Fix missing (hex) in D5 code ( #2560 )
...
* Fix missing (hex) in D5 code
* Make ALL D-codes available for DEBUG mode
until now D3 and D5 needed to be defined separately
* Forgot to modify Marlin_main
2020-04-02 14:56:19 +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
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
2ceec597a5
Fix typo
2020-03-26 14:08:35 +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
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
3d-gussner
17e23693eb
Fixed stuipid copy paste error
2019-12-04 14:21:43 +01:00
3d-gussner
0ce7c51c1d
Added more D-codes to RR Wiki and doxygen
...
D-1, D80, D81, D106
2019-12-03 20:02:58 +01:00