summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
-rw-r--r--esp8266/modules/_boot.py3
-rw-r--r--esp8266/scripts/inisetup.py2
2 files changed, 5 insertions, 0 deletions
diff --git a/esp8266/modules/_boot.py b/esp8266/modules/_boot.py
index c950de6758..2cacb56760 100644
--- a/esp8266/modules/_boot.py
+++ b/esp8266/modules/_boot.py
@@ -1,3 +1,4 @@
+import gc
import uos
from flashbdev import bdev
@@ -7,3 +8,5 @@ try:
except OSError:
import inisetup
vfs = inisetup.setup()
+
+gc.collect()
diff --git a/esp8266/scripts/inisetup.py b/esp8266/scripts/inisetup.py
index 461690b162..7d8f6fa0a8 100644
--- a/esp8266/scripts/inisetup.py
+++ b/esp8266/scripts/inisetup.py
@@ -40,7 +40,9 @@ def setup():
with open("/boot.py", "w") as f:
f.write("""\
# This file is executed on every boot (including wake-boot from deepsleep)
+import gc
#import webrepl
#webrepl.start()
+gc.collect()
""")
return vfs