|
1 | | -# fprime-zephyr-reference project |
2 | | -This project is an implementation of F` on Zephyr RTOS. |
| 1 | +# Proves Core Reference Project |
3 | 2 |
|
4 | | -<!-- Not sure if this will be true in the future --> |
5 | | -<!-- > [!Note] |
6 | | -> This deployment by default builds for the Teensy 4.1 development board and has been verified on macOS and on Windows 11 using WSL (Ubuntu 22.04 LTS). |
7 | | -> --> |
| 3 | +This is a reference software implementation for the [Proves Kit](https://docs.proveskit.space/en/latest/). |
8 | 4 |
|
9 | 5 | ## System Requirements |
10 | 6 | - F Prime System Requirements listed [here](https://fprime.jpl.nasa.gov/latest/docs/getting-started/installing-fprime/#system-requirements) |
11 | | -- Zephyr dependencies listed [here](https://docs.zephyrproject.org/latest/develop/getting_started/index.html#install-dependencies) |
12 | | -- Minimum required **CMake version: 3.27.0** |
13 | | - |
14 | | -## Prerequisites |
15 | | -1. Follow the [Hello World Tutorial](https://fprime.jpl.nasa.gov/latest/tutorials-hello-world/docs/hello-world/) |
16 | | -2. Follow the [Zephyr Getting Started Guide](https://docs.zephyrproject.org/latest/develop/getting_started/index.html). Ensure that the Zephyr's dependencies and SDK have been installed |
17 | | -3. If you are using WSL, make sure to refer to the [WSL Notes][wsl-notes] docs |
18 | | - |
19 | | -## Table of Contents |
20 | | -1. [Initial Project Setup][initial-setup] |
21 | | -2. [Building, Flashing, and Running the Deployment][build-flash-run] |
22 | | - |
23 | | -## Additional Resources |
24 | | -- [Using a Custom Board Configuration][custom-board] |
25 | | -- [Tested Board List][board-list] |
26 | | -- [Troubleshooting][troubleshooting] |
27 | | -- [WSL Notes][wsl-notes] |
28 | | - |
29 | | -<!-- Links --> |
30 | | -[initial-setup]: ./docs/main-content/initial-setup.md |
31 | | -[board-dependencies]: ./docs/main-content/board-dependencies.md |
32 | | -[build-flash-run]: ./docs/main-content/build-flash-run.md |
33 | | -[custom-board]: ./docs/additional-resources/specifying-board-configuration.md |
34 | | -[board-list]: ./docs/additional-resources/board-list.md |
35 | | -[troubleshooting]: ./docs/additional-resources/troubleshooting.md |
36 | | -[wsl-notes]: ./docs/additional-resources/wsl-notes.md |
| 7 | +- Zephyr dependencies listed [here](https://docs.zephyrproject.org/latest/develop/getting_started/index.html#install-dependencies) (NOTE: Only complete the install dependencies step, as we run through the rest of the steps in this readme.) |
| 8 | + |
| 9 | +## Installation |
| 10 | + |
| 11 | +> [!TIP] |
| 12 | +> Always source the virtual environment when building by running `. fprime-venv/bin/activate` in the `proves-core-reference` directory, |
| 13 | +
|
| 14 | +First, clone the Proves Core Reference repository and ensure all submodules are properly checked-out. |
| 15 | + |
| 16 | +``` |
| 17 | +fprime-bootstrap clone https://github.com/Open-Source-Space-Foundation/proves-core-reference |
| 18 | +``` |
| 19 | + |
| 20 | +By using `fprime-bootstrap` the following several tasks are accomplished: |
| 21 | + |
| 22 | +- The repository and submodules are cloned |
| 23 | +- A virtual environment is created and depenencies are installed |
| 24 | + |
| 25 | +Next update Zephyr modules. This will take a long time. |
| 26 | + |
| 27 | +``` |
| 28 | +cd proves-core-reference/lib/zephyr-workspace |
| 29 | +west update |
| 30 | +``` |
| 31 | + |
| 32 | +Export a Zephyr CMake package. This allows CMake to automatically load boilerplate code required for building Zephyr applications. |
| 33 | + |
| 34 | +``` |
| 35 | +west zephyr-export |
| 36 | +``` |
| 37 | + |
| 38 | +The Zephyr west extension command, west packages can be used to install Python dependencies. |
| 39 | + |
| 40 | +``` |
| 41 | +west packages pip --install |
| 42 | +``` |
| 43 | + |
| 44 | +Finally, install the Zephyr SDK. |
| 45 | + |
| 46 | +``` |
| 47 | +west sdk install |
| 48 | +``` |
| 49 | + |
| 50 | +## Running the code |
| 51 | + |
| 52 | +if its the first time or you are updating and adding components and ports, run generate from the `proves-core-reference` directory. When you regenerate append a -f, this will purge the previous deployment |
| 53 | +``` |
| 54 | +fprime-util generate |
| 55 | +``` |
| 56 | + |
| 57 | +Then, and everytime you change code, run |
| 58 | + |
| 59 | +``` |
| 60 | +fprime-util build |
| 61 | +``` |
| 62 | + |
| 63 | +Next, plug in your board! You want to find the location of the board on your computer. It should be called something like RP2350 but you want to find the path to to |
| 64 | + |
| 65 | +For Mac: |
| 66 | +``` |
| 67 | +ls -lah /Volumes |
| 68 | +``` |
| 69 | + |
| 70 | + |
| 71 | +For Windows: |
| 72 | +Check the letter said to be the mount (ex D) |
| 73 | + |
| 74 | +For Linux: |
| 75 | +``` |
| 76 | +findmnt |
| 77 | +``` |
| 78 | + |
| 79 | + |
| 80 | +Now you want to copy the code from the deployment we just made. Before you run this command you have to make this board writable by pressing the two buttons in succesion |
| 81 | +``` |
| 82 | +cp build-fprime-automatic-zephyr/zephyr/zephyr.uf2 [path-to-your-board] |
| 83 | +``` |
| 84 | + |
| 85 | +Finally, run the fprime-gds. You dont have to start and trop it everytime you |
| 86 | +``` |
| 87 | +fprime-gds -n -–dictionary ./build-fprime-automatic-zephyr/FPrimeZephyrReference/ReferenceDeployment/Top/ReferenceDeploymentTopologyDictionary.json -–communication-selection uart –-uart-baud 115200 |
| 88 | +``` |
| 89 | + |
0 commit comments