diff --git a/.gitignore b/.gitignore index df902c9..d019926 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ /files /sources -/tmp \ No newline at end of file +/tmp +.idea/ \ No newline at end of file diff --git a/README.md b/README.md index fbf9504..8244817 100644 --- a/README.md +++ b/README.md @@ -23,6 +23,15 @@ These are the data sources currently used. - STM32Cube database: describes all MCUs, with useful stuff like GPIO AF mappings, DMA stream mappings, pinouts... - stm32-rs SVDs: register blocks. YAMLs are extracted and manually cleaned up. +## Install pre-requisites + +In order to run the generator, you will need to install the following tools: + +* `wget` +* `git` +* `jq` +* `svd` – `pip3 install svdtools` + ## Generating the YAMLs - Run `./d download_all` diff --git a/d b/d index c16baf0..698e128 100755 --- a/d +++ b/d @@ -3,6 +3,12 @@ set -e cd $(dirname $0) +die() { echo "$*" 1>&2; exit 1; } + +for i in jq wget svd git; do + command -v "$i" &>/dev/null || die "Missing the command line tool '$i'" +done + case "$1" in download_all) ./d download_mcufinder