Verified Commit 4bd7a362 authored by Paul Szczepanek's avatar Paul Szczepanek Committed by Vincent Coubard
Browse files

Add new switches and AMI deps to the readme


Signed-off-by: default avatarPaul Szczepanek <paul.szczepanek@arm.com>
Signed-off-by: Vincent Coubard's avatarVincent Coubard <vincent.coubard@arm.com>
parent bf2563d9
......@@ -94,12 +94,16 @@ ssh -i "MyKeyPair.pem" ubuntu@<instance ip address>
To update the application, a set of scripts is included to setup the environment,
build applications, run them and test them. These scripts must be executed in the AVH AMI.
### Connect
Open your favorite terminal program or linux shell application and connect to the AVH AMI instance:
```sh
ssh ubuntu@<your-ec2-instance>
```
### Prepare environment
Clone the repository in the AMI:
```sh
......@@ -115,34 +119,68 @@ Synchronize git submodules, setup ML and apply required patches:
Install additional python dependencies required to run tests and sign binaries:
```sh
pip3 install click imgtool pytest cbor intelhex
export PATH=$PATH:/home/ubuntu/.local/bin
sudo apt install python3.8-venv
```
Update cmake:
```sh
python3.8 -m pip install imgtool cbor2
```
```sh
sudo snap refresh cmake --channel=latest/stable
python3.9 -m pip install imgtool cffi intelhex cbor2 cbor pytest click
```
Make python user packages visible in the shell.
```sh
export PATH=$PATH:/home/ubuntu/.local/bin
```
### Build
There are currently two applications available: `blink` and `kws`.
The `ats.sh` scripts takes the command `bootstrap`, `build` or `run` as first parameter.
The second parameter is the name of the application to build or run.
Below we use `kws` as the name of the application, replace it with `blinky` to build that instead.
Build the kws application:
```sh
./ats.sh build kws
```
This will by default build the application in the `build` directory for the `Corstone-300` target using the `FreeRTOS` OS. This is equivalent to:
```sh
./ats.sh build kws --target Corstone-300 --rtos FREERTOS --path build
```
To build for Corstone-310 use `--target Corstone-310`. To build using the RTX RTOS implementation use `--rtos RTX`.
You can have multiple builds with different parameters side by side by changing the `--path` parameter to something unique to each build configuration. This speed up the re-build process when working with multiple targets and RTOS.
### Run
Run the kws application:
```sh
./ats.sh run kws
```
The `run` command can take the `--path` switch to run a particular build. It uses `build` directory by default.
This is equivalent to:
```sh
./ats.sh run kws --path build
```
### Integration tests
Launch the kws integration tests:
```sh
pytest -s kws/tests/test_ml.py
```
To build, run and launch a test of the blinky application, replace `kws` by `blinky`.
## Updating audio data
The audio data streamed into the Arm Virtual Hardware is read from the file `test.wav` located at the root of the repository. It can be replaced with another audio file with the following configuration:
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment