Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/katyo/zephyr-rtos.nix
Battle-tested nix env for Zephyr RTOS developers
https://github.com/katyo/zephyr-rtos.nix
Last synced: 2 months ago
JSON representation
Battle-tested nix env for Zephyr RTOS developers
- Host: GitHub
- URL: https://github.com/katyo/zephyr-rtos.nix
- Owner: katyo
- Created: 2022-10-05T10:29:33.000Z (about 2 years ago)
- Default Branch: master
- Last Pushed: 2024-02-03T06:35:05.000Z (11 months ago)
- Last Synced: 2024-04-14T05:25:26.501Z (9 months ago)
- Language: Nix
- Size: 108 KB
- Stars: 11
- Watchers: 5
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Zephyr Project - Development Environment
This Nix Flake allows use of Zephyr SDK by applications in a reproducible way. It offers following
features:* Selection of toolchains to install, reducing the download size.
* Allow addition of extra packages inside the development shell.
* Provide a fully reproducible Python environment with Zephyr SDK requirements.## Quickstart
To use the development shell, you can use a flake such as:
```nix
{
inputs.nixpkgs.url = "nixpkgs/release-23.11";inputs.zephyr-rtos = {
url = "github:katyo/zephyr-rtos.nix";
inputs.nixpkgs.follows = "nixpkgs";
};outputs = { nixpkgs, zephyr-rtos, ... }:
let
supportedSystems = [ "x86_64-linux" "x86_64-darwin" "aarch64-linux" "aarch64-darwin" ];
forAllSystems = nixpkgs.lib.genAttrs supportedSystems;
nixpkgsFor = forAllSystems (system: import nixpkgs {
inherit system;
overlays = [ zephyr-rtos.overlays.default ];
});
in
{
devShells = forAllSystems (system: {
default = nixpkgsFor.${system}.mkZephyrSdk { };
});
};
}
```Once this is done, the `nix develop` command will get you under a development shell ready for Zephyr
Project development.## Templates
- `all-toolchains`: using all supported toolchains
- `arm`: using arm toolchain## Packages
- `openocd-svd`
- `openocd-zephyr`
- `uncrustify_0_72`
- `zephyr-sdk`