You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/os-development/macos.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
# OS Development on MacOS
2
2
3
-
Most users can just use a pre-built binary from the [releases page](https://github.com/MicroPythonOS/MicroPythonOS/releases) and install it manually or using the [web installer](https://install.MicroPythonOS.com).
3
+
If you're looking to install MicroPythonOS on a supported device, you can probably just use a pre-built binary from the [releases page](https://github.com/MicroPythonOS/MicroPythonOS/releases) and install it on the device, either manually or with the [web installer](https://install.MicroPythonOS.com).
4
4
5
5
But if for some reason that one doesn't work, or you really want to modify things under the hood, you're in the right place here!
1. Make sure you have the `local_filesystem/` folder
4
4
5
-
Either you built your own [on MacOS](../os-development/macos.md) or [Linux](../os-development/linux.md) or you can download a pre-built executable binary (e.g., `MicroPythonOS_amd64_Linux`, `MicroPythonOS_amd64_MacOS`) from the [releases page](https://github.com/MicroPythonOS/MicroPythonOS/releases).
6
-
7
-
Give it executable permissions:
8
-
9
-
```
10
-
chmod +x /path/to/MicroPythonOS_executable_binary
11
-
```
12
-
13
-
2. Make sure you have the `local_filesystem/` folder
14
-
15
-
You probably already have a local clone that contains the [internal_filesystem](https://github.com/MicroPythonOS/MicroPythonOS/tree/main/internal_filesystem).
16
-
17
-
If not, then clone it now:
5
+
Make a local clone that contains the [internal_filesystem](https://github.com/MicroPythonOS/MicroPythonOS/tree/main/internal_filesystem) with:
18
6
19
7
<pre>
20
8
```
@@ -23,52 +11,33 @@
23
11
```
24
12
</pre>
25
13
26
-
3. Start it from the local_filesystem/ folder:
14
+
2. Make sure you have the software
15
+
16
+
Either you built your own [on MacOS](../os-development/macos.md) or [Linux](../os-development/linux.md) or you can download a pre-built executable binary (e.g., `MicroPythonOS_amd64_Linux_0.7.1.elf`, `MicroPythonOS_amd64_MacOS_0.7.1.bin`) from the [releases page](https://github.com/MicroPythonOS/MicroPythonOS/releases).
17
+
18
+
If you downloaded a pre-built binary (for example to /Users/yourname/MicroPythonOS_amd64_MacOS_0.7.1.bin) then put it in the right location, with execution rights:
27
19
28
20
<pre>
29
21
```
30
-
cd internal_filesystem/ # make sure you're in the right place to find the filesystem
The `install.sh` script copies files from `internal_filesystem/` to the device's storage partition over USB/serial.
40
+
There's no need to run `./scripts/install.sh` when testing on desktop - that script is only for deploying everything from internal_filesystem/ to physical hardware.
72
41
73
42
### Modifying Files
74
43
@@ -83,7 +52,22 @@ This results in a very quick coding cycle - no compilation or installation neede
83
52
3. Open the About app
84
53
4. See your changes immediately!
85
54
86
-
**When you DO need to rebuild:**
55
+
56
+
## Development on Hardware
57
+
58
+
Once you've tested your changes on desktop and they work correctly, or you're doing things you can't test on desktop, then you can deploy to physical hardware.
59
+
60
+
This assumes your device was already flashed with MicroPythonOS or at least MicroPython, using something like https://install.MicroPythonOS.com/
61
+
62
+
The `install.sh` script copies files from `internal_filesystem/` to the device's storage partition over USB/serial:
63
+
64
+
```bash
65
+
./scripts/install.sh
66
+
```
67
+
68
+
On MacOS, you need this for the install.sh script: `brew install --cask serial`
69
+
70
+
**When you DO need to rebuild and flash the MicroPythonOS firmware:**
87
71
88
72
You only need to run `./scripts/build_mpos.sh` when:
89
73
@@ -92,4 +76,4 @@ You only need to run `./scripts/build_mpos.sh` when:
92
76
- Testing the frozen filesystem for production releases
93
77
- Creating firmware for distribution
94
78
95
-
For **all Python code development**, just edit files in `internal_filesystem/` and run `./scripts/run_desktop.sh`.
79
+
For **all Python code development**, just edit files in `internal_filesystem/` and run `./scripts/run_desktop.sh` (to run on desktop) or `./scripts/install.sh` to copy your files to a device.
0 commit comments