Skip to content

Commit 4826994

Browse files
authored
Merge pull request #1802 from adafruit/revert-1779-nrf-nvm-2
Revert "nrf nvm: touchups to nickzoic PR #1768"
2 parents 22889ca + 254d0a5 commit 4826994

File tree

12 files changed

+78
-308
lines changed

12 files changed

+78
-308
lines changed

ports/nrf/Makefile

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,6 @@ SRC_C += \
177177
peripherals/nrf/clocks.c \
178178
peripherals/nrf/$(MCU_CHIP)/pins.c \
179179
peripherals/nrf/$(MCU_CHIP)/power.c \
180-
peripherals/nrf/nvm.c \
181180
peripherals/nrf/timers.c \
182181
sd_mutex.c \
183182
supervisor/shared/memory.c

ports/nrf/boards/adafruit_nrf52840_s140_v6.ld

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111

1212
0x000ED000..0x000F3FFF (28KB ) Private Config Data (Bonding, Keys, etc.)
1313
0x000AD000..0x000ECFFF (256KB) User Filesystem
14+
1415
0x00026000..0x000ACFFF (540KB) Application Code (including ISR vector)
1516
0x00001000..0x00025FFF (148KB) SoftDevice
1617
0x00000000..0x00000FFF (4KB) Master Boot Record

ports/nrf/boards/feather_nrf52840_express/mpconfigboard.h

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,6 @@
3333
#define MICROPY_HW_MCU_NAME "nRF52840"
3434
#define MICROPY_PY_SYS_PLATFORM "Feather52840Express"
3535

36-
#define FLASH_SIZE (0x100000)
37-
#define FLASH_PAGE_SIZE (4096)
38-
3936
#define MICROPY_HW_NEOPIXEL (&pin_P0_16)
4037

4138
#define MICROPY_HW_LED_STATUS (&pin_P1_15)
@@ -58,7 +55,7 @@
5855

5956
#define CIRCUITPY_AUTORELOAD_DELAY_MS 500
6057

61-
#define CIRCUITPY_INTERNAL_NVM_SIZE (4096)
58+
// TODO #define CIRCUITPY_INTERNAL_NVM_SIZE 8192
6259

6360
#define BOARD_FLASH_SIZE (FLASH_SIZE - 0x4000 - CIRCUITPY_INTERNAL_NVM_SIZE)
6461

ports/nrf/common-hal/microcontroller/__init__.c

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -24,14 +24,9 @@
2424
* THE SOFTWARE.
2525
*/
2626

27-
#include "py/mphal.h"
28-
#include "py/obj.h"
29-
#include "py/runtime.h"
30-
3127
#include "common-hal/microcontroller/Pin.h"
3228
#include "common-hal/microcontroller/Processor.h"
3329

34-
#include "shared-bindings/nvm/ByteArray.h"
3530
#include "shared-bindings/microcontroller/__init__.h"
3631
#include "shared-bindings/microcontroller/Pin.h"
3732
#include "shared-bindings/microcontroller/Processor.h"
@@ -68,16 +63,6 @@ const mcu_processor_obj_t common_hal_mcu_processor_obj = {
6863
},
6964
};
7065

71-
#if CIRCUITPY_INTERNAL_NVM_SIZE > 0
72-
// The singleton nvm.ByteArray object.
73-
const nvm_bytearray_obj_t common_hal_mcu_nvm_obj = {
74-
.base = {
75-
.type = &nvm_bytearray_type,
76-
},
77-
.len = CIRCUITPY_INTERNAL_NVM_SIZE,
78-
.start_address = (uint8_t*) (FLASH_SIZE - CIRCUITPY_INTERNAL_NVM_SIZE),
79-
};
80-
#endif
8166

8267
STATIC const mp_rom_map_elem_t mcu_pin_globals_table[] = {
8368
{ MP_ROM_QSTR(MP_QSTR_P0_00), MP_ROM_PTR(&pin_P0_00) },

ports/nrf/common-hal/nvm/ByteArray.c

Lines changed: 0 additions & 77 deletions
This file was deleted.

ports/nrf/common-hal/nvm/ByteArray.h

Lines changed: 0 additions & 38 deletions
This file was deleted.

ports/nrf/common-hal/nvm/__init__.c

Lines changed: 0 additions & 27 deletions
This file was deleted.

ports/nrf/mpconfigport.mk

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@ CIRCUITPY_AUDIOBUSIO = 0
1919
# No I2CSlave implementation
2020
CIRCUITPY_I2CSLAVE = 0
2121

22-
# enable NVM
23-
CIRCUITPY_NVM = 1
22+
# nvm not yet implemented
23+
CIRCUITPY_NVM = 0
2424

2525
# enable RTC
2626
CIRCUITPY_RTC = 1

ports/nrf/peripherals/nrf/nvm.c

Lines changed: 0 additions & 95 deletions
This file was deleted.

ports/nrf/peripherals/nrf/nvm.h

Lines changed: 0 additions & 34 deletions
This file was deleted.

0 commit comments

Comments
 (0)