Skip to main content

Appendix D: Using the Zephyr4Microchip Repo

The Zephyr4Microchip repo is a fork of the main Zephyr repository that contains support for the latest Microchip dev boards. These contributions will eventually be mainlined to the main Zephyr repo. For more information, take a look at the Zephyr4Microchip website.

Using the Zephyr4Microchip repo before running west init

Instead of running west init to download the main Zephyr repo, it is possible to directly download the Microchip4Zephyr repo. Go to the folder for your zephyr project and run the following in your terminal:

$ source ~/zephyrproject/.venv/bin/activate
(.venv) $ west init -m https://github.com/Zephyr4Microchip/zephyr.git --mr mchp_pic32cxbz_v420
(.venv) $ west blobs fetch hal_microchip

Switching to the Zephyr4Microchip Repo after running west init

If you already ran west init and downloaded the regular Zephyr repo, you need to change the git remote and run west update. Run the following commands from your Zephyr project directory:

$ git -C zephyr remote set-url origin https://github.com/Zephyr4Microchip/zephyr
$ git -C zephyr fetch
$ git -C zephyr checkout mchp_pic32cxbz_v420
$ source .venv/bin/activate
(.venv) $ west update
(.venv) $ west blobs fetch hal_microchip