From 6a93466a3fb5e3026e255fae5643a6a83508cbde Mon Sep 17 00:00:00 2001 From: gijsio <67470426+gijsio@users.noreply.github.com> Date: Wed, 12 Aug 2020 17:38:50 +0200 Subject: [PATCH] Update frozen.md update pybytes --- content/advance/frozen.md | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/content/advance/frozen.md b/content/advance/frozen.md index 317a834..ce04e77 100644 --- a/content/advance/frozen.md +++ b/content/advance/frozen.md @@ -12,7 +12,12 @@ What we call `Frozen` code, relates to a principle in MicroPython where you can 3. You can find the `_main.py` and `_boot.py` files in the `frozen/Base/` folder. These are similar to `main.py` and `boot.py` files you can build into the source code, with the exception that `_boot.py` will also run in safeboot mode. Moreover can only change the behaviour by rebuilding and reflashing the firmware. > Note that if you plan to make changes in the `_boot.py`, keep the code already in the file, as that enables the output to REPL. - > When building firmware with `VARIANT=PYBYTES`, you can find the `_boot.py` and `_main.py` in the `frozen/Pybytes/` folder and the files in `Base` will **NOT** be used + > When building firmware with `VARIANT=PYBYTES`, you need to use the `frozen/Pybytes/_boot.py` and `frozen/Pybytes/_main.py`, and the files in `Base` will **NOT** be used. If you then enable Pybytes on boot with the following flag: + >```python + >import pycom; pycom.pybytes_on_boot(True) + >``` + > Not the `Pybytes/_main.py`, but the `Pybytes/_pybytes_main.py` will be used. + 4. For example, add to the `_main.py`: ```python