Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/Duet3D/RepRapFirmware.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/src/DuetM
diff options
context:
space:
mode:
authorDavid Crocker <dcrocker@eschertech.com>2019-12-09 22:47:33 +0300
committerDavid Crocker <dcrocker@eschertech.com>2019-12-09 22:47:33 +0300
commit14db90f06f74494ee811cf1ae4f12190756ed2ca (patch)
treec5c8332e39db09a5df8c4475cfc03e184ed46016 /src/DuetM
parentbf7be88b40ee5b48aacd4d78917cfaa94f7aa3d2 (diff)
Support loading IAP in RAM
Support loading IAP in RAM instead of flash, to make more flash memory available for the main firmware
Diffstat (limited to 'src/DuetM')
-rw-r--r--src/DuetM/Pins_DuetM.h20
1 files changed, 15 insertions, 5 deletions
diff --git a/src/DuetM/Pins_DuetM.h b/src/DuetM/Pins_DuetM.h
index 234d761f..8215914e 100644
--- a/src/DuetM/Pins_DuetM.h
+++ b/src/DuetM/Pins_DuetM.h
@@ -12,7 +12,21 @@
#define DEFAULT_BOARD_TYPE BoardType::DuetM_10
constexpr size_t NumFirmwareUpdateModules = 1; // 1 module
#define IAP_FIRMWARE_FILE "DuetMaestroFirmware.bin"
-#define IAP_UPDATE_FILE "iap4s.bin"
+
+#define IAP_IN_RAM 1
+
+#if IAP_IN_RAM
+
+# define IAP_UPDATE_FILE "DuetMaestroIAP.bin"
+constexpr uint32_t IAP_IMAGE_START = 0x20010000;
+
+#else
+
+# define IAP_UPDATE_FILE "iap4s.bin"
+constexpr uint32_t IAP_IMAGE_START = 0x00470000;
+constexpr uint32_t IAP_IMAGE_END = 0x0047FFFF; // we allow a full 64K on the SAM4
+
+#endif
// Features definition
#define HAS_LWIP_NETWORKING 0
@@ -259,10 +273,6 @@ constexpr const char *DefaultZProbePinNames = "^zprobe.in+zprobe.mod";
constexpr const char *DefaultFanPinNames[] = { "fan0", "fan1", "fan2" };
constexpr PwmFrequency DefaultFanPwmFrequencies[] = { DefaultFanPwmFreq };
-// SAM4S Flash locations (may be expanded in the future)
-constexpr uint32_t IAP_FLASH_START = 0x00470000;
-constexpr uint32_t IAP_FLASH_END = 0x0047FFFF; // we allow a full 64K on the SAM4
-
// Duet pin numbers to control the W5500 interface
constexpr Pin W5500ResetPin = PortCPin(13); // Low on this in holds the W5500 in reset
constexpr Pin W5500SsPin = PortAPin(11); // SPI NPCS pin to W5500