From da91b3a3e120151bc5abcff01395c6fb72d0445b Mon Sep 17 00:00:00 2001 From: Bjoern Kerler Date: Mon, 18 Dec 2023 17:54:40 +0100 Subject: [PATCH 1/7] Fix serialprintPGM parameter from mac to mac_buffer --- src/marlin_stubs/host/M46.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/marlin_stubs/host/M46.cpp b/src/marlin_stubs/host/M46.cpp index f04d36700b..c8462e4b38 100644 --- a/src/marlin_stubs/host/M46.cpp +++ b/src/marlin_stubs/host/M46.cpp @@ -15,6 +15,6 @@ void GcodeSuite::M46() { char mac_buffer[19] = { 0 }; get_MAC_address(&mac, netdev_get_active_id()); snprintf(mac_buffer, sizeof(mac_buffer), "%s\n", mac); - serialprintPGM(mac); + serialprintPGM(mac_buffer); } } From 245e7e32c8282d338fb08fd3e4ccce0a95ef15d8 Mon Sep 17 00:00:00 2001 From: "D.R.racer" Date: Wed, 15 Nov 2023 11:03:54 +0100 Subject: [PATCH 2/7] Update bug_report.md text --- .github/ISSUE_TEMPLATE/bug_report.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md index 5aeac8ea77..3a3b2c8bdc 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.md +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -9,7 +9,7 @@ assignees: '' Please, before you create a new bug report, please make sure you searched in open and closed issues and couldn't find anything that matches. -**Printer type** - [MINI] +**Printer type** - [MINI, MK4, XL] **Printer firmware version** - [e.g. 4.0.5, ...] @@ -33,7 +33,9 @@ Please, before you create a new bug report, please make sure you searched in ope Please attach the G-code you had trouble with. This will make it easier for us to replicate the error. **Crash dump file** - Please attach the crash dump file. This will make it easier for us to investigate the bug. + Please send the crash dump file to Prusa by emailing it to reports@prusa3d.com. Sharing this file is important and helps us investigate the bug. + + Do not share the file publicly, as the crash dump contains a raw snapshot of the printer's memory and may include unencrypted sensitive information. **Video** Please attach a video. It usually helps to solve the problem. From eff8298fbf83e994851ffef352ba22a24e4a1a88 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Luk=C3=A1=C5=A1=20Hr=C3=A1zk=C3=BD?= Date: Wed, 8 Nov 2023 12:39:56 +0100 Subject: [PATCH 3/7] doc: Add contributing.md A carbon copy of the relevant part of Developer Guidelines from wiki. --- doc/contributing.md | 58 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) create mode 100644 doc/contributing.md diff --git a/doc/contributing.md b/doc/contributing.md new file mode 100644 index 0000000000..0a318b596f --- /dev/null +++ b/doc/contributing.md @@ -0,0 +1,58 @@ +## Git + +### Merging: Use rebase whenever possible + +The goal is to have a simple and linear git history. +It is not always possible; for example when merging master into private. +In such cases, it is ok to use git-merge. + +### Commit: Atomicity + +A commit should be a single complete unit of work. +Every commit should be buildable and follow the rules in this document. + +### Commit: Message + +- Commit message comprises a subject and a body (separated by an empty line). +- Commit message is written in English. +- Subject uses the imperative mood. +- Subject starts with a capital letter and does not end with a period. +- When a commit is relevant to some subset/module of the project (most of the time), use it as a prefix of the subject as follows: + ``` + metrics: Add support for syslog + ``` + , or + ``` + gui: Add touch support + ``` +- Write the module in lowercase +- Limit the subject to 72 letters. +- Wrap the body to 72 letters per line. +- Do not put Jira references in the subject line. Put it at the end of the body. + +## Formatting & Code Organization + +### Files: Include Guards +Use the `#pragma once` as a file guard. +Do not use the `#ifdef FILE_X`, `#define FILE_X`, `#endif` pattern. + +### Files: Author & Copyright + +Do not add file headers with author/creation time/copyright, etc. +Those data are already stored in the commit, and we don't want to duplicate them. + +This does not apply to 3rd party code in our repository. + +### Formatting: pre-commit + +The project contains a pre-commit configuration (see pre-commit.com and .pre-commit-config.yaml). +Make sure you have installed pre-commit in your clone of the repository. +The pre-commit will run before every commit you make, ensuring the code is formatted correctly. + +### Code Style: C/C++ Naming Conventions + +- Types & Classes are in `PascalCase`. +- Global constants in `SCREAMING_CASE` +- Variables (local, class, etc), methods ands namespaces are in `snake_case`. +- File names are in `snake_case.cpp` (even if the only thing the file contains is a class named in PascalCase). +- Types never end with a '_t'. From d9ba9182d39ed21efb8a8f93fdde4de8dc7e73cc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Luk=C3=A1=C5=A1=20Hr=C3=A1zk=C3=BD?= Date: Wed, 8 Nov 2023 12:48:03 +0100 Subject: [PATCH 4/7] doc: Minor fixes to contributing.md --- doc/contributing.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/doc/contributing.md b/doc/contributing.md index 0a318b596f..f4cc6c6b85 100644 --- a/doc/contributing.md +++ b/doc/contributing.md @@ -21,14 +21,14 @@ Every commit should be buildable and follow the rules in this document. ``` metrics: Add support for syslog ``` - , or + or ``` gui: Add touch support ``` - Write the module in lowercase - Limit the subject to 72 letters. - Wrap the body to 72 letters per line. -- Do not put Jira references in the subject line. Put it at the end of the body. +- Put an issue tracker reference (BFW-xxxx) at the end of the body if you have one. Do not put it in the subject line. ## Formatting & Code Organization @@ -45,7 +45,7 @@ This does not apply to 3rd party code in our repository. ### Formatting: pre-commit -The project contains a pre-commit configuration (see pre-commit.com and .pre-commit-config.yaml). +The project contains a pre-commit configuration (see [pre-commit.com](https://pre-commit.com) and `.pre-commit-config.yaml`). Make sure you have installed pre-commit in your clone of the repository. The pre-commit will run before every commit you make, ensuring the code is formatted correctly. @@ -53,6 +53,6 @@ The pre-commit will run before every commit you make, ensuring the code is forma - Types & Classes are in `PascalCase`. - Global constants in `SCREAMING_CASE` -- Variables (local, class, etc), methods ands namespaces are in `snake_case`. -- File names are in `snake_case.cpp` (even if the only thing the file contains is a class named in PascalCase). -- Types never end with a '_t'. +- Variables (local, class, etc), methods and namespaces are in `snake_case`. +- File names are in `snake_case.cpp` (even if the only thing the file contains is a class named in `PascalCase`). +- Types never end with a `'_t'`. From fa7141c5bb58b5369a0b7ad3b15c0d15920e434c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Luk=C3=A1=C5=A1=20Hr=C3=A1zk=C3=BD?= Date: Wed, 8 Nov 2023 13:04:49 +0100 Subject: [PATCH 5/7] doc: Define style to use for class-level constants and enum class items --- doc/contributing.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/contributing.md b/doc/contributing.md index f4cc6c6b85..77cd370d2b 100644 --- a/doc/contributing.md +++ b/doc/contributing.md @@ -53,6 +53,6 @@ The pre-commit will run before every commit you make, ensuring the code is forma - Types & Classes are in `PascalCase`. - Global constants in `SCREAMING_CASE` -- Variables (local, class, etc), methods and namespaces are in `snake_case`. +- Variables (local, class, etc), class-level constants, `enum class` items, methods and namespaces are in `snake_case`. - File names are in `snake_case.cpp` (even if the only thing the file contains is a class named in `PascalCase`). - Types never end with a `'_t'`. From e8faab94df6532280bac7b4514f9e08216d092ea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Luk=C3=A1=C5=A1=20Hr=C3=A1zk=C3=BD?= Date: Thu, 9 Nov 2023 10:46:33 +0100 Subject: [PATCH 6/7] doc: Link doc/contributing from README.md, deduplicate information --- README.md | 10 ++-------- doc/contributing.md | 18 ++++++++++++------ 2 files changed, 14 insertions(+), 14 deletions(-) diff --git a/README.md b/README.md index 286d69bc5b..3b118a00d5 100644 --- a/README.md +++ b/README.md @@ -59,15 +59,9 @@ The build process of this project is driven by CMake and `build.py` is just a hi - [Eclipse, STM32CubeIDE](doc/editor/stm32cubeide.md) - [Other LSP-based IDEs (Atom, Sublime Text, ...)](doc/editor/lsp-based-ides.md) -#### Formatting +#### Contributing -All the source code in this repository is automatically formatted: - -- C/C++ files using [clang-format](https://clang.llvm.org/docs/ClangFormat.html), -- Python files using [yapf](https://github.com/google/yapf), -- and CMake files using [cmake-format](https://github.com/cheshirekow/cmake_format). - -If you want to contribute, make sure to install [pre-commit](https://pre-commit.com) and then run `pre-commit install` within the repository. This makes sure that all your future commits will be formatted appropriately. Our build server automatically rejects improperly formatted pull requests. +If you want to contribute to the codebase, please read the [Contribution Guidelines](doc/contributing.md). #### XL and Puppies diff --git a/doc/contributing.md b/doc/contributing.md index 77cd370d2b..56850ee770 100644 --- a/doc/contributing.md +++ b/doc/contributing.md @@ -1,3 +1,5 @@ +# Contribution Guidelines + ## Git ### Merging: Use rebase whenever possible @@ -32,6 +34,16 @@ Every commit should be buildable and follow the rules in this document. ## Formatting & Code Organization +### Formatting + +All the source code in this repository is automatically formatted: + +- C/C++ files using [clang-format](https://clang.llvm.org/docs/ClangFormat.html), +- Python files using [yapf](https://github.com/google/yapf), +- and CMake files using [cmake-format](https://github.com/cheshirekow/cmake_format). + +If you want to contribute, make sure to install [pre-commit](https://pre-commit.com) and then run `pre-commit install` within the repository. This makes sure that all your future commits will be formatted appropriately. Our build server automatically rejects improperly formatted pull requests. + ### Files: Include Guards Use the `#pragma once` as a file guard. Do not use the `#ifdef FILE_X`, `#define FILE_X`, `#endif` pattern. @@ -43,12 +55,6 @@ Those data are already stored in the commit, and we don't want to duplicate them This does not apply to 3rd party code in our repository. -### Formatting: pre-commit - -The project contains a pre-commit configuration (see [pre-commit.com](https://pre-commit.com) and `.pre-commit-config.yaml`). -Make sure you have installed pre-commit in your clone of the repository. -The pre-commit will run before every commit you make, ensuring the code is formatted correctly. - ### Code Style: C/C++ Naming Conventions - Types & Classes are in `PascalCase`. From 53ae4e76b44a6ca9bccaeed451288a2fc09ab8ea Mon Sep 17 00:00:00 2001 From: Jakub Dolezal <31956337+JakoobCZ@users.noreply.github.com> Date: Wed, 19 Apr 2023 17:01:58 +0200 Subject: [PATCH 7/7] Update README.md Add MINI+ and MK3.9 to the list of supported models. --- README.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 3b118a00d5..6198040515 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,8 @@ This repository includes source code and firmware releases for the Original Prusa 3D printers based on the 32-bit ARM microcontrollers. The currently supported models are: -- Original Prusa MINI +- Original Prusa MINI/MINI+ +- Original Prusa MK3.9 - Original Prusa MK4 - Original Prusa XL