Skip to content

Commit

Permalink
Readme: Refactored commands into code blocks
Browse files Browse the repository at this point in the history
  • Loading branch information
SteelPh0enix committed Oct 20, 2023
1 parent 565f83f commit 0b9a3a5
Showing 1 changed file with 35 additions and 13 deletions.
48 changes: 35 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,25 +30,43 @@ The repository structure is as follows:

## Building

aerugo requires nightly, make sure you have it installed: \
`rustup toolchain install nightly`
aerugo requires nightly, make sure you have it installed:

For the Cortex-M7 platform you first need to install that target via `rustup`: \
`rustup target add thumbv7em-none-eabihf`
```sh
rustup toolchain install nightly
```

For the Cortex-M7 platform you first need to install that target via `rustup`:

Then to build the system run: \
`cargo build -p aerugo --features=use-aerugo-cortex-m --target=thumbv7em-none-eabihf`
```sh
rustup target add thumbv7em-none-eabihf
```

x86 target is also supported for development purposes: \
`cargo build -p aerugo --features=use-aerugo-x86 --target=x86_64-unknown-linux-gnu`
Then to build the system run:

```sh
cargo build -p aerugo --features=use-aerugo-cortex-m --target=thumbv7em-none-eabihf
```

x86 target is also supported for development purposes:

```sh
cargo build -p aerugo --features=use-aerugo-x86 --target=x86_64-unknown-linux-gnu
```

## Tests

Tests can be built and run using a bash script. For all tests run: \
`./scripts/run_tests.sh`
Tests can be built and run using a bash script. For all tests run:

```sh
./scripts/run_tests.sh
```

or for specific package run for example:

or for specific package run for example: \
`./scripts/run_tests.sh aerugo_x86`
```sh
./scripts/run_tests.sh aerugo_x86
```

Tests can also be run using `cargo test` with `--features` and `--target` flags.

Expand Down Expand Up @@ -82,7 +100,11 @@ You can either run each test manually, by invoking `./tests/requirements/test/te
python ./tests/requirements/test/test_hal_watchdog.py
```

Or you can run them all at once, via `./scripts/run_tests.sh aerugo_v71` command.
Or you can run them all at once, with

```sh
./scripts/run_tests.sh aerugo_v71
```

**Warning: If running test via `cargo` for the first time, be aware that their build time will be contained in test execution time, which can potentially cause a timeout. It's recommended to build (or run) all test binaries manually for the first time.**
Test binaries can be built either by running [`./scripts/build_hal_tests.sh`](./scripts/build_hal_tests.sh), or by invoking `cargo build` in test's project directory (in [`testbins`](./testbins/))!
Expand Down

0 comments on commit 0b9a3a5

Please sign in to comment.