Commit Graph

1995 Commits

Author SHA1 Message Date
Yuri D'Elia 334bfe4d29 build: Set all version data based on git tags
Drop the ALPHA/BETA/custom version handling. Set the version string and
firmware date based on the current tree description which has all the
required details.

Allow to override the repository information via cmake.

Use a truncated commit hash to set the internal commit number for
compatibility.

Rebase and fix issues
2023-09-04 08:35:15 -04:00
3d-gussner 77a4b99f5e Fix Calibration menu shown during resuming 2023-09-01 16:18:57 +02:00
Yuri D'Elia 2bfd56cd30 lang/mmu: Translate MMU menu strings within caller
This fixes the undefined _T(label) reference, at the expense of a few
extra bytes.

I would argue this is worth the cost for the ability to check
translation references for the future. The warning happens because
`lang-check` cannot check a reference which is not _directly_ a catalog
entry.

We could introduce a method to suppress this warning (either a new macro
or some ///IGNORE comment), but that would mean that the additional
translation check is completely bypassed, defeating the purpose.
2023-08-30 18:54:57 +02:00
3d-gussner 0bbec5626c Update and fix translations 2023-08-21 16:28:36 +02:00
Guðni Már Gilbert 5bf9bf7507 optimisation: reduce code size in MMU filament menus
Change in memory:
Flash: -156 bytes
SRAM: 0 bytes
2023-08-21 07:29:43 +02:00
Guðni Már Gilbert 1881c5f086 Fix filament actions not cleared properly
We can't clear eFilamentAction in every case in mFilamentItem()

mFilamentItem() can trigger a call to M701 and M702 e.g. for Autoloading
and eFilamentAction must be cleared by the gcode to prevent
the user from triggering another Autoload (which will crashe the FW)

The same applies to submenus. Now the MMU submenus clear eFilamentAction
only when the action is done.

For MMU Unload Filament item, eFilamentAction is only cleared after
the unload_filament() call is done running. This fixes an issue where
the menu item can be selected again while the first unload is still
running.
2023-08-21 07:29:43 +02:00
sarusani c4c26050d3 Fix screen update after PFW-1531 2023-08-21 06:36:25 +02:00
sarusani 0d097d5a62 Fix TEMP_HYSTERESIS calculation 2023-08-21 06:35:32 +02:00
Guðni Már Gilbert 0e469c054f Fix disappearing menu items when Filament Action completes
An example is when Unloading filament with MMU.

After the unload completes successfully, some menu items disappeared.
Because mFilamentBack() was not called

Change in memory:
Flash: -56 bytes
SRAM: 0 bytes
2023-08-16 08:22:03 +02:00
Guðni Már Gilbert 1bf33bd1aa Fix a bug where Load filament menu disappears
Kudos to @3d-gussner for finding the issue

Steps to reproduce:
1. reset printer
2. select Load filament
3. go back to main
4. LCD menu is very limited
5. To get all menus back select 6. Preheat
7. back to main

This commit is my proposed fix.

When eFilamentAction is equal to
FilamentAction::Load we must reset it to FilamentAction::None
when the Back button in Load Filament is selected

Change in memory:
Flash: -26 bytes
SRAM: 0 bytes
2023-08-16 08:22:03 +02:00
VintagePC ea5bcc5eea Implement #2089 2023-08-05 12:19:51 -04:00
Guðni Már Gilbert 95d8711469 PFW-1531 Fix #4300
No change in memory
2023-08-04 17:02:03 +00:00
3d-gussner b1da06859c
Merge pull request #3494 from wavexx/lcd_temperature_jumping
Jump to PLA temps in LCD temperature settings when starting from zero
2023-08-02 14:21:53 +02:00
Yuri D'Elia 92202249d9 Make temperature jumping configurable in the variant file
Use this new feature in the Settings -> Temperature menus.
2023-07-31 16:04:33 +02:00
Guðni Már Gilbert 7e025894d1 Echo the result onto serial
Example:
MMU2:1111111111111110011
1 means filament present (solid block)
0 means otherwise (dash)

Change in memory:
Flash: +94 bytes
SRAM: 0 bytes
2023-07-27 16:44:34 +00:00
Guðni Már Gilbert 940e626f3a Previously we called cleared the LCD, no need to change that
Change in memory:
Flash: -6 bytes
SRAM: 0 bytes
2023-07-27 16:44:34 +00:00
Guðni Már Gilbert 28f6cebfd2 PFW-1504 Cleanup
Only set cursor with lcd_status_message_idx where the variable
is used.

No change in memory
2023-07-27 16:44:34 +00:00
Guðni Már Gilbert 63775dfabb PFW-1504 fix conflicting UI issues
Proposal to fix some of the issues with the initial implementation
it is safer to use the status line code to print the message so
there aren't any conflicts in the LCD cursor position.

Allow inserting a byte into any position in the LCD status message

Also, add a variable to control from which index in the array
should the message start printing. This is very useful for progress
bars and messages which continually update. I think we can save some
memory by applying this to Mesh Bed Leveling later.

Change in memory:
Flash: +106 bytes
SRAM: +1 byte
2023-07-27 16:44:34 +00:00
vintagepc a2eafc587a
Merge branch 'MK3' into 2477-redux 2023-07-26 12:34:38 -04:00
3d-gussner ce141a2fa1
Merge pull request #3564 from wavexx/fil_loading_state
Filament loading state fixes
2023-07-26 16:38:29 +02:00
3d-gussner 78ed427166 Rename `TempModel` to `ThermalModel` 2023-07-25 17:13:07 +02:00
3d-gussner 44ae8033eb Rename upper case `TEMP_MODEL` to `THERMAL_MODEL` 2023-07-25 17:13:07 +02:00
3d-gussner dac07d11ba Rename lower case `temp_model` to `thermal_model` 2023-07-25 17:13:07 +02:00
Guðni Már Gilbert 21faa52aab Rename axis_steps_per_unit to axis_steps_per_mm 2023-07-25 17:10:44 +02:00
Guðni Már Gilbert 7029af05fa optimisation: reduce code size in pid_extruder()
Author: leptun

Change in memory:
Flash: -14 bytes
SRAM: 0 bytes
2023-07-25 15:02:49 +00:00
Guðni Már Gilbert 5288d615f8 optimisation: lcd avoid streams
Author: leptun

Change in memory:
Flash: -124 bytes
SRAM: 0 bytes
2023-07-25 15:02:49 +00:00
Yuri D'Elia 074b5d380f Consistently replace loading_flag with eFilamentAction
Remove loading_flag and check for eFilamentAction instead which already
flags both load/unload (in addition to mmu actions).

Correctly transition from AutoLoad to Load as soon as the operation
cannot be cancelled anymore as opposed to resetting it.
2023-07-25 14:30:20 +00:00
Yuri D'Elia 05b536947b Refuse to start a SD print until filament loading is complete
Do not blidnly clear the loading_flag, check for it!

Just disallowing the SD menu while loading is being performed is not
sufficient, since the menu can be entered also by inserting card while
loading is taking place.

This is also nicer in behavior, as we allow to navigate the SD card
while loading.
2023-07-25 14:28:46 +00:00
Yuri D'Elia e3fd6a4902 Do not allow filament actions while an existing one is taking place 2023-07-25 14:28:45 +00:00
Yuri D'Elia 170dddfd71 Set/clear loading_flag also during unload 2023-07-25 14:28:13 +00:00
Yuri D'Elia dece5d268f Consider any lcd_custom_command to be "ACTIVE"
All custom commands are transitory and eventually switch back to Idle
state by themselves.

It doesn't make any sense to explicitly check for Layer1Cal: any
non-idle state is active by design.

Fix this check in the main menu. This is probably incomplete (Layer1Cal
is incorrectly used in several other places).
2023-07-25 14:27:00 +00:00
Guðni Már Gilbert c067318427 cleanup language menu
Change in memory:
Flash: -50 bytes
SRAM: 0 bytes
2023-07-25 08:58:52 +02:00
Guðni Már Gilbert 57d780ccf9 PFW-1519 Hide Preload to MMU menu item if filament is detected
This is by far the simplest solution to prevent the user from sending
a Load command to the MMU when the FINDA or Filament sensor
is detecting a filament. This may even happen if the sensors are poorly positioned.

Either way a Load in this scenario will make the MMU seem to hang as the
state machine will reject the command.

We could add a full screen message to let the use know
but it would require some memory resources.

For now, just hide the menu item.

Change in memory:
Flash: +16 bytes
SRAM: 0 bytes
2023-07-24 08:05:50 +02:00
Guðni Már Gilbert 6784c6919b cleanup: remove TMC2130 ifdef in lcd_selfcheck_axis
This function is no longer included in the firmware
when using TMC2130

Also removed commented code
2023-07-13 10:06:21 +02:00
Guðni Már Gilbert 9cc9af14bd Remove unnecessary la10compat include 2023-07-13 09:57:52 +02:00
3d-gussner 56dd8f09e7 Fix too long message `MSG_BABYSTEPPING_Z`from c=15 to c=13
Had to remove `:` and update NL translation to fit
2023-05-26 08:17:02 +02:00
3d-gussner 3c678122f6
Merge pull request #4222 from 3d-gussner/PFW1520-pofiles
PFW-1520: Add new message `Preload to MMU` to po files
2023-05-24 06:57:48 +02:00
3d-gussner 135247c3b7
Merge pull request #4214 from 3d-gussner/MK3_Fix_MMU_IRsensor
Fix IRsensor with MMU
2023-05-24 06:57:05 +02:00
3d-gussner 9b4c8e9c9d Thanks to @gudnimg 2023-05-23 10:39:05 +02:00
3d-gussner f43451f80b Update `MSG_EJECT_FILAMENT` and `MSG_CUT_FILAMENT` to `c=16`
Had to shorten SK translation
2023-05-23 09:50:27 +02:00
3d-gussner a37bcbfd8c Fix `Load filament` to c=16 2023-05-23 09:45:07 +02:00
Guðni Már Gilbert 467158eb49 MMU: Fix 0°C target temperature when loading to nozzle
bFilamentAction variable is never reset, even after
disabling the heaters.

Steps to reproduce:
1. Boot-up printer
2. Select Load to Nozzle.
3. Select PLA (215°C) target
4. Select Filament 1
5. Wait for load to be successful
6. Go to Preheat submenu and select Cooldown (last menu item)
7. Observe target temperature on the status screen is now 0°C
8. Select Load to Nozzle again.
9. Select Filament 2.
* Expected behavior target temperature IS NOT 0°C
* Actual behavior target temperature IS 0°C

Change in memory:
Flash: -26 bytes
SRAM: 0 bytes
2023-05-22 22:00:00 +00:00
Guðni Már Gilbert 9d5453a41e PFW-1520 Rename Load Filament menu to Preload to MMU
Change in memory:
Flash: +18 bytes
SRAM: 0 bytes
2023-05-22 07:53:26 +02:00
3d-gussner 91a23e27e1 Fix IRsensor with MMU
saves 38bytes
2023-05-19 13:35:28 +02:00
3d-gussner 0c453b53cd
Merge pull request #4193 from gudnimg/unload-sequence-improvements
Fix unload sequence for users without MMU
2023-05-10 07:29:16 +02:00
Guðni Már Gilbert 3c79e77220 Create define for two hardcoded values 2023-05-08 19:50:51 +00:00
Guðni Már Gilbert e24c2200f1 Set FILAMENTCHANGE_FINALRETRACT instead of hardcoded 0 2023-05-08 19:33:42 +00:00
3d-gussner 8d1abf772d
Merge pull request #4192 from gudnimg/PFW-1506
PFW-1506 Load to nozzle: Fix too short purge distance
2023-05-08 13:14:47 +02:00
Guðni Már Gilbert d781dae35b Combine two moves since they have the same feedrate
Change in memory:
Flash: -60 bytes
SRAM: 0 bytes
2023-05-06 15:24:54 +00:00
Guðni Már Gilbert 8556336185 Fix unload sequence for users without MMU
Restores 3.12 sequence which was working well before.

M600 "L" parameter now works like M702 "U" parameter.

Removed a lot of the unused parameters which were copied
from Marlin 2.

Change in memory:
Flash: +96 bytes
2023-05-06 15:24:54 +00:00