mirror of
https://github.com/micropython/micropython.git
synced 2026-01-05 11:40:18 +01:00
esp8266/modules/flashbdev: Add RESERVED_SECS before the filesystem.
Starting at esp.flash_user_start(), the reserved sectors are for general purpose use, for example for native code generation. There is currently one sector reserved as such.
This commit is contained in:
@@ -3,8 +3,9 @@ import esp
|
||||
class FlashBdev:
|
||||
|
||||
SEC_SIZE = 4096
|
||||
START_SEC = esp.flash_user_start() // SEC_SIZE
|
||||
NUM_BLK = 0x6b
|
||||
RESERVED_SECS = 1
|
||||
START_SEC = esp.flash_user_start() // SEC_SIZE + RESERVED_SECS
|
||||
NUM_BLK = 0x6b - RESERVED_SECS
|
||||
|
||||
def __init__(self, blocks=NUM_BLK):
|
||||
self.blocks = blocks
|
||||
|
||||
Reference in New Issue
Block a user