Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Various fixes: missed code uses, other updates #27711

Open
wants to merge 18 commits into
base: bugfix-2.1.x
Choose a base branch
from

Conversation

classicrocker883
Copy link
Contributor

@classicrocker883 classicrocker883 commented Feb 24, 2025

Description

  • Add FLIP() to missed opportunity placement
  • Remove ; typo from PlatformIO/scripts/STM32F1_create_variant.py
  • Delete redundant share/scripts/languageUtil.py and moved contents into share/scripts/languageExport.py
  • Follow up to 🩹 Even more Z input shaper followup #27119, we have forgot to add ProUI definition for Input Shaping - ICON_ShapingZ
    • Added test option including Input Shaping X/Y/Z for ProUI in STM32F103RE_creality
  • Fixes errors and improve on code. for example: added import ... to prevent error of it missing in a .py file.
  • in utility.h IAXIS_CHAR + iaxis_codes is only used in M907-M910.cpp when HAS_MOTOR_CURRENT_(I2C|DAC|SPI)
    • this change is probably not that significant, maybe just revert it?? but if it saves bytes...


- Other changes and good things

- fix this same error in share/scripts/g29_auto.py:

"None" is not iterable
  "__iter__" method not defined

    while len(gcode) > i:
-       try:
-           z, i = find_z(gcode, i + 1)
-       except TypeError:
-           break

    while len(gcode) > i:
+       result = find_z(gcode, i + 1)

+       if result is None:
+           break

+       z, i = result
-start, end = get_lines(gcode, min_g1)

+layer_range = get_lines(gcode, min_g1)

+if layer_range is None:
+   print("Error: Unable to determine layer range. Exiting.")
+   exit(1)

+start, end = layer_range

#doesnt have to say "Error: Unable to determine layer range. Exiting." per say, or to exit, but its suggested


also, near the end of this file, you will see

out_file = open(output_file, 'w')
in_file = open(input_file, 'r')

# other code ....

file.close()
out_file.close()

#file.close() should be in_file.close(), but the code has since been improved differently.


- Add FLIP() to missed opportunity placement

in module/tempurature.cpp

- if ((do_buttons ^= true)) ui.update_buttons();

+ if (FLIP(do_buttons)) ui.update_buttons();

Requirements

Benefits

Configurations

Related Issues

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant