Commit Graph

6979 Commits

Author SHA1 Message Date
gudnimg 940f5b7214 Add executable permission for update-po.py and update-pot.py on Linux 2023-02-20 17:53:41 +00:00
Guðni Már Gilbert 526e02a041 Fix an issue with using --file argument
The following command did not work in the lang folder:
python .\update-po.py --file ./po/Firmware_cs.po

To resolve this we just extract the filename from
the path and use the constant PO_DIR to make
sure the path is always the same.
2023-02-18 10:30:18 +00:00
Guðni Már Gilbert b6ef8ea32c Add a backup of po files 2023-02-18 10:13:34 +00:00
gudnimg 280a904799 ubuntu: subprocess does not allow extended glob
It's my understanding that we cannot use extended globbing
on Linux because
of the way I am invoking the lang-extract
script.  the python script is not run through bash/shell.

We would need to perhaps use Shell = True in check_call() but
then the all the input arguments needs to be one string.

This commit was tested on Ubuntu 22.04.1 LTS
2023-02-18 09:53:57 +00:00
Guðni Már Gilbert 327254d091 Expand glob in update-pot on Windows only 2023-02-18 09:53:57 +00:00
Guðni Már Gilbert 62c87a1fe5 Adjust module docstring 2023-02-18 09:53:57 +00:00
Guðni Már Gilbert b14f3780d4 Add mutually exclusive arguments --file and --all
Only one of these arguments must be supplied, or argparse raises an error.
2023-02-18 09:53:57 +00:00
Guðni Már Gilbert 4a93288353 Update README 2023-02-18 09:53:57 +00:00
Guðni Már Gilbert d90859e6a6 Add requirements.txt 2023-02-18 09:53:57 +00:00
Guðni Már Gilbert 7966633c1a Allow languages to be updated from any directory
Now these commands will work:
python .\lang\update-po.py
python .\lang\update-pot.py

When current working directory is
.\Prusa-Firmware\

Previously, you'd need to call the
script within the lang folder.
2023-02-18 09:53:56 +00:00
Guðni Már Gilbert 53ced0cb21 languages: Add new script update-pot.py 2023-02-18 09:53:56 +00:00
Guðni Már Gilbert 65d7605623 languages: update lang-extract.py
Fix an issue where it does not run on Windows.
When the input argument is regex, we must first search for the files
using said regex pattern and then creating a list of files.
When opening the files, the encoding needs to be utf-8.
2023-02-18 09:53:56 +00:00
Guðni Már Gilbert 12123d6d52 languages: create new script update_po.py
The script should do the same work as when one run update_po.sh
The Python script can be run on Windows too.
2023-02-18 09:53:56 +00:00
3d-gussner 3381bf2f7e
Merge pull request #2201 from vintagepc/2091_2153_sheet_Mcode
Add M850 code for setting sheet label and offsets
2023-02-17 15:12:22 +01:00
Yuri D'Elia 1b3fa8bfe9 TM: Move headers to support the legacy build system 2023-02-17 15:01:59 +01:00
Yuri D'Elia a8f219259a TM: Split default model parameters into a separate header
Preparation to support multiple default model parameter sets
2023-02-17 15:01:59 +01:00
Yuri D'Elia d1ff728e4f TM: future-proofing for incompatible model upgrades
Introduce a model version. This is initialized at "1" and doesn't
require any upgrade/downgrade checks since it's currently
retro-compatible.
2023-02-17 15:01:59 +01:00
Yuri D'Elia 9bd03cedb9 TM: Fix UV identity 2023-02-17 15:01:59 +01:00
Yuri D'Elia ddf5147f9f TM: Optimize temp_model_set_lag
Save about 20 bytes by rewriting the sample count check
2023-02-17 15:01:59 +01:00
Yuri D'Elia b676d395e3 TM: Handle L/TEMP_MODEL_LAG 2023-02-17 15:01:59 +01:00
Yuri D'Elia 0bf6a5bc4b TM: Handle UV (PTC loss)
Model UV as power-invariant, so that scaling P doesn't change the
intercept location (that is, the zero point remains at the same
temperature even for more powerful heaters).

NOTE: It's not clear to me whether this is generally true (couldn't
find a datasheet from the same heater in diffent power variants
showing the efficiency loss)
2023-02-17 15:01:59 +01:00
Yuri D'Elia ba96c8d457 TM: Handle D/TEMP_MODEL_fS 2023-02-17 15:01:59 +01:00
Yuri D'Elia eb88b720ac TM: Handle UVDL set/load/report/upgrade
- Expose TEMP_MODEL_fS and TEMP_MODEL_LAG as D and L respectively,
  initializing the default values based on the previous hard-coded
  values.
- Always round L to the effective sample lag to future-proof model
  upgrades or changes (the stored value _is_ the effective value).
- Introduce UV as a new linear term for PTC heaters, defaulting
  to an identity for model backward-compatibility.
2023-02-17 15:01:59 +01:00
Yuri D'Elia 38b1e64687 TM: Allocate new eeprom parameters for PTC handling 2023-02-17 15:01:59 +01:00
vintagepc 235ce62cd3
Update Marlin_main.cpp
Remove more stale code
2023-02-17 08:58:17 -05:00
vintagepc 032d5ebe5b
Update Marlin_main.cpp
Fix use of removed function
2023-02-17 08:31:27 -05:00
Guðni Már Gilbert d0e0b51497 Optimisation: lcd_commands "M702 C" should be "M702"
Change in memory:
Flash: -2 bytes
SRAM: 0 bytes
2023-02-17 14:30:20 +01:00
Giles Bathgate 952b1af60b Consistent use of noinline attribute 2023-02-17 14:30:20 +01:00
Giles Bathgate 754b2d03c3 Remove extraneous line added during merge conflict resolution 2023-02-17 14:30:20 +01:00
Giles Bathgate 25f9728e09 Add noinline attribute to count_e 2023-02-17 14:30:20 +01:00
Giles Bathgate 620b19bbab Roll up lay1cal_square loops 2023-02-17 14:30:20 +01:00
Giles Bathgate f92d2279d5 Re-use duplicated strings 2023-02-17 14:30:20 +01:00
Giles Bathgate 8129a14f19 Move layer calibration finish commands into first_layer_cal.cpp 2023-02-17 14:30:20 +01:00
Giles Bathgate 39160bc4ae Free up some progmem 2023-02-17 14:30:20 +01:00
Giles Bathgate 568eec5ee0 Implement first layer cal with calculated extrusion widths 2023-02-17 14:30:20 +01:00
vintagepc 20eef890a6
Merge branch 'MK3' into 2091_2153_sheet_Mcode 2023-02-17 08:24:49 -05:00
D.R.racer 9b64d122dc Disable MMU2S by default
On printers without the MMU no error screen should occur and no attempts of communication with the MMU should be performed -> EEPROM_MMU_ENABLED should default to 0.

PFW-1418
2023-02-17 12:53:07 +01:00
Guðni Már Gilbert 6745b2c766 Shorten Reset MMU button to fit LCD
Button strings are limited to 8 characters
2023-02-13 07:08:54 +01:00
Guðni Már Gilbert b63f5433df Don't show Pause/Stop menus while processing T-codes
PFW-1449

Change in memory:
Flash: +18 bytes
SRAM: +1 bytes
2023-02-12 15:58:07 +01:00
Guðni Már Gilbert 504099bd6c optimisation: reduce code size in rendering cursor
Change in memory:
Flash: -62 bytes
SRAM: 0 bytes
2023-02-11 19:06:14 +01:00
Guðni Már Gilbert c51aa10087 optimisation: spooljoin: use new eeprom init method
Change in memory:
Flash: -40 bytes
SRAM: -1 byte
2023-02-11 15:58:07 +01:00
Guðni Már Gilbert 982b1bb4bd optimisation: backlight: use new eeprom_init function
Change in memory:
Flash: -56 bytes
SRAM: 0 bytes
2023-02-11 15:56:46 +01:00
Guðni Már Gilbert c2a952cee5 optimisation: sound: use new eeprom_init function
Change in memory:
Flash: -18 bytes
SRAM: 0 bytes
2023-02-11 15:56:46 +01:00
Guðni Már Gilbert 8794ab2f71 respect Once sound mode
Change in memory:
Flash: +4 bytes
SRAM: 0 bytes
2023-02-11 15:54:33 +01:00
Guðni Már Gilbert 96fc90c80b Revert a change in the MMU error screen logic
We can pull this code into a common function in a separate PR
2023-02-11 15:54:33 +01:00
Guðni Már Gilbert 5b4bc8bcdb Tune louder beeps to match previous M600 behavior 2023-02-11 15:54:33 +01:00
Guðni Már Gilbert b4f9f6d0b5 fixup: make sure to start the timer
Change in memory:
Flash: +10 bytes
SRAM: 0 bytes
2023-02-11 15:54:33 +01:00
Guðni Már Gilbert 8db2fbc97f Improve sound handling for MMU error screen
Change in memory:
Flash: -174 bytes
SRAM: +4 bytes
2023-02-11 15:54:33 +01:00
Guðni Már Gilbert e34faee389 optimisation: don't inline Sound_MakeCustom
Change in memory:
Flash: -32 bytes
SRAM: 0 bytes
2023-02-11 12:42:47 +01:00
Guðni Már Gilbert 7799853a05 optimisation: remove duplicate code
Sound_MakeCustom should play the sound
if critical = true OR the sound is not Silent

Change in memory:
Flash: -16 bytes
SRAM:  0 bytes
2023-02-11 12:42:47 +01:00