From a8470a76d9f3420f1daa1ecaf3eda80732bb857c Mon Sep 17 00:00:00 2001 From: Martin Williams Date: Thu, 15 Aug 2024 14:57:04 +0100 Subject: [PATCH 1/4] Allow log full FUL to be written to last byte (#438) Fixes #406 --- source/FSCache.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/FSCache.cpp b/source/FSCache.cpp index e0e8fc64..d5352a93 100644 --- a/source/FSCache.cpp +++ b/source/FSCache.cpp @@ -84,7 +84,7 @@ int FSCache::read(uint32_t address, const void *data, int len) int bytesCopied = 0; // Ensure that the operation is within the limits of the device - if (address < flash.getFlashStart() || address + len >= flash.getFlashEnd()) + if (address < flash.getFlashStart() || address + len > flash.getFlashEnd()) return DEVICE_INVALID_PARAMETER; // Read operation may span multiple cache boundaries... so we iterate over blocks as necessary. @@ -116,7 +116,7 @@ int FSCache::write(uint32_t address, const void *data, int len) int bytesCopied = 0; // Ensure that the operation is within the limits of the device - if (address < flash.getFlashStart() || address + len >= flash.getFlashEnd()) + if (address < flash.getFlashStart() || address + len > flash.getFlashEnd()) return DEVICE_INVALID_PARAMETER; #ifdef CODAL_FS_CACHE_VALIDATE From 4dcbe1212e900262380b1d4022c87435586b8028 Mon Sep 17 00:00:00 2001 From: Carlos Pereira Atencio Date: Thu, 5 Sep 2024 21:26:45 +0100 Subject: [PATCH 2/4] Temporarily set CODAL_VERSION back to "unknown". (#445) This is to workaround an issue in the iOS app as described in: https://github.com/microsoft/pxt-microbit/issues/5913 --- target-locked.json | 1 + target.json | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/target-locked.json b/target-locked.json index d6594c54..2d6ef2b8 100644 --- a/target-locked.json +++ b/target-locked.json @@ -11,6 +11,7 @@ "CODAL_PROVIDE_PRINTF": 1, "CODAL_TIMER_32BIT": 1, "CODAL_TIMESTAMP": "uint64_t", + "CODAL_VERSION": "\"unknown\"", "CONFIG_GPIO_AS_PINRESET": 1, "CONFIG_NFCT_PINS_AS_GPIOS": 1, "DEVICE_BLE": 1, diff --git a/target.json b/target.json index 32981b8b..23cc9073 100644 --- a/target.json +++ b/target.json @@ -7,7 +7,6 @@ "generate_bin":true, "generate_hex":true, "config":{ - "MBED_CONF_NORDIC_NRF_LF_CLOCK_SRC": "NRF_LF_SRC_XTAL", "CONFIG_GPIO_AS_PINRESET": 1, "CONFIG_NFCT_PINS_AS_GPIOS": 1, @@ -42,7 +41,8 @@ "CAPTOUCH_DEFAULT_CALIBRATION" : 3500, "HARDWARE_NEOPIXEL": 1, "CODAL_TIMER_32BIT": 1, - "DEVICE_BLE": 1 + "DEVICE_BLE": 1, + "CODAL_VERSION": "unknown" }, "definitions":"-DAPP_TIMER_V2 -DAPP_TIMER_V2_RTC1_ENABLED -DNRF_DFU_TRANSPORT_BLE=1 -DNRF52833_XXAA -DNRF52833 -DTARGET_MCU_NRF52833 -DNRF5 -DNRF52833 -D__CORTEX_M4 -DS113 -DTOOLCHAIN_GCC -D__START=target_start", From bd446c49f5501584e2cef3b5f53ebb826928e47b Mon Sep 17 00:00:00 2001 From: Carlos Pereira Atencio Date: Thu, 5 Sep 2024 21:29:23 +0100 Subject: [PATCH 3/4] Snapshot v0.2.68 --- target-locked.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/target-locked.json b/target-locked.json index 2d6ef2b8..283ca267 100644 --- a/target-locked.json +++ b/target-locked.json @@ -72,6 +72,6 @@ "linker_flags": "-Wl,--no-wchar-size-warning -Wl,--gc-sections -Wl,--wrap,atexit -mcpu=cortex-m4 -mthumb -mfpu=fpv4-sp-d16 -mfloat-abi=softfp -Wl,--start-group -lstdc++ -lsupc++ -lm -lc -lgcc -lnosys -Wl,--end-group", "post_process": "", "processor": "NRF52833", - "snapshot_version": "v0.2.67", + "snapshot_version": "v0.2.68", "toolchain": "ARM_GCC" } \ No newline at end of file From e88ca61bbd1fcad76d20fb9e02f9e5c86e381262 Mon Sep 17 00:00:00 2001 From: Carlos Pereira Atencio Date: Fri, 13 Sep 2024 17:50:31 +0100 Subject: [PATCH 4/4] Fix CODAL_VERSION config value defined in target.json --- target.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/target.json b/target.json index 23cc9073..dce155d4 100644 --- a/target.json +++ b/target.json @@ -42,7 +42,7 @@ "HARDWARE_NEOPIXEL": 1, "CODAL_TIMER_32BIT": 1, "DEVICE_BLE": 1, - "CODAL_VERSION": "unknown" + "CODAL_VERSION": "\"unknown\"" }, "definitions":"-DAPP_TIMER_V2 -DAPP_TIMER_V2_RTC1_ENABLED -DNRF_DFU_TRANSPORT_BLE=1 -DNRF52833_XXAA -DNRF52833 -DTARGET_MCU_NRF52833 -DNRF5 -DNRF52833 -D__CORTEX_M4 -DS113 -DTOOLCHAIN_GCC -D__START=target_start",