The Prusa Mk2 firmware has several requirements which must be met in order to successfully compile and deploy to your printer. This script will download the required files and make the necessary modifications for a complete Arduino development environment on your Windows system.
The resulting development environment will be portable and will not change or impact existing Arduino IDE installations.
This script utilizes PowerShell version 5, installed by default on Windows 10 and available for download from Microsoft for earlier Windows versions.
Double-click on the .cmd file and it will call the PowerShell script to deploy the development environment into a subfolder named "Prusa-Firmware". After deployment the IDE will be opened and shortcuts will be created for later use.
Make some modifications to the firmware.
For example, edit the Configuration_prusa.h
file and edit (at your own risk):
- Extruder PID tuning:
DEFAULT_Kp
,DEFAULT_Ki
andDEFAULT_Kd
values - Bed PID tuning:
DEFAULT_bedKp
,DEFAULT_bedKi
,DEFAULT_bedKd
values - Extruder fan noise: reduce
EXTRUDER_AUTO_FAN_SPEED
from255
to96
(experiment a bit)
You can now build the firmware:
- Compile* the firmware with
Sketch -> Build (CTRL-R)
. - Export the compiled binary with
Sketch -> Export compiled sketch (CTRL-ALT-S)
.
The compiled firmware will be exported to Prusa-Firmware-MK2\Firmware\Firmware.ino.with_bootloader.rambo.hex
*Note: The current Prusa codebase will throw some warnings during compilation. Don't be alarmed if you see errors like "WARNING: Category '' in library Wire is not valid[...]
or Warning: platform.txt from core 'Marlin AVR Boards' contains deprecated[...] "
. These are normal for the current codebase and won't prevent you from compiling or using the firmware.
Follow Prusa's official firmware upgrade guide here.
The script and this document were largely copied from this excellent guide posted by GitHub user pboschi.