My Marlin configs for Fabrikator Mini and CTC i3 Pro B
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

openblt.py 601B

12345678910111213141516171819
  1. #
  2. # Convert the ELF to an SREC file suitable for some bootloaders
  3. #
  4. import pioutil
  5. if pioutil.is_pio_build():
  6. from os.path import join
  7. Import("env")
  8. board = env.BoardConfig()
  9. board_keys = board.get("build").keys()
  10. if 'encode' in board_keys:
  11. env.AddPostAction(
  12. join("$BUILD_DIR", "${PROGNAME}.bin"),
  13. env.VerboseAction(" ".join([
  14. "$OBJCOPY", "-O", "srec",
  15. "\"$BUILD_DIR/${PROGNAME}.elf\"", "\"" + join("$BUILD_DIR", board.get("build.encode")) + "\""
  16. ]), "Building " + board.get("build.encode"))
  17. )