diff --git a/.editorconfig b/.editorconfig index 7d13ba2..a3ef04c 100644 --- a/.editorconfig +++ b/.editorconfig @@ -15,7 +15,7 @@ indent_size = unset [*.lock] indent_style = unset -[*.{adoc,envrc,nix,nu,yaml,yml}] +[*.{adoc,envrc,lock,nix,nu,yaml,yml}] max_line_length = off [{justfile,.justfile,*.just,*.rs}] diff --git a/.justfile b/.justfile index b780703..4585444 100644 --- a/.justfile +++ b/.justfile @@ -24,7 +24,7 @@ build board="attiny85" profile="dev": alias fmt := format format: - treefmt + treefmt-nix alias f := run alias flash := run @@ -78,8 +78,8 @@ update: nix run ".#update-nixos-release" nix flake update cd "{{ justfile_directory() }}/boards/attiny85" - cargo update + cargo update --verbose cd "{{ justfile_directory() }}/boards/pico" - cargo update + cargo update --verbose cd "{{ justfile_directory() }}/boards/qt-py-ch32v203" - cargo update + cargo update --verbose diff --git a/boards/attiny85/.justfile b/boards/attiny85/.justfile index 7c9f9dd..87207a5 100644 --- a/boards/attiny85/.justfile +++ b/boards/attiny85/.justfile @@ -26,4 +26,4 @@ alias up := update update: nix flake update - cargo update + cargo update --verbose diff --git a/boards/attiny85/Cargo.lock b/boards/attiny85/Cargo.lock index 1c241f6..5a90c0b 100644 --- a/boards/attiny85/Cargo.lock +++ b/boards/attiny85/Cargo.lock @@ -66,9 +66,9 @@ checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" [[package]] name = "critical-section" -version = "1.1.3" +version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f64009896348fc5af4222e9cf7d7d82a95a256c634ebcf61c53e4ea461422242" +checksum = "790eea4361631c5e7d22598ecd5723ff611904e3344ce8720784c93e3d83d40b" [[package]] name = "embedded-hal" @@ -119,9 +119,9 @@ checksum = "8d5439c4ad607c3c23abf66de8c8bf57ba8adcd1f129e699851a6e43935d339d" [[package]] name = "panic-halt" -version = "0.2.0" +version = "1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "de96540e0ebde571dc55c73d60ef407c653844e6f9a1e2fdbd40c07b9252d812" +checksum = "a513e167849a384b7f9b746e517604398518590a9142f4846a32e3c2a4de7b11" [[package]] name = "paste" @@ -162,9 +162,9 @@ dependencies = [ [[package]] name = "rustversion" -version = "1.0.17" +version = "1.0.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "955d28af4278de8121b7ebeb796b6a45735dc01436d898801014aced2773a3d6" +checksum = "0e819f2bc632f285be6d7cd36e25940d45b2391dd6d9b939e79de557f7014248" [[package]] name = "syn" @@ -206,9 +206,9 @@ checksum = "e87a2ed6b42ec5e28cc3b94c09982969e9227600b2e3dcbc1db927a84c06bd69" [[package]] name = "unicode-ident" -version = "1.0.13" +version = "1.0.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e91b56cd4cadaeb79bbf1a5645f6b4f8dc5bde8834ad5894a8db35fda9efa1fe" +checksum = "adb9e6ca4f869e1180728b7950e35922a7fc6397f7b641499e8f3ef06e50dc83" [[package]] name = "unwrap-infallible" diff --git a/boards/attiny85/Cargo.toml b/boards/attiny85/Cargo.toml index 134b650..7a3edb1 100644 --- a/boards/attiny85/Cargo.toml +++ b/boards/attiny85/Cargo.toml @@ -7,15 +7,16 @@ homepage = "https://github.com/jwillikers/pwm-fan-controller" description = "A simple PWM fan controller for microcontrollers" license = "MIT OR Apache-2.0" repository = "https://github.com/jwillikers/pwm-fan-controller.git" +# autobin = false [dependencies] -embedded-hal = "1.0.0" -nb = "1.1.0" -panic-halt = "0.2.0" -ufmt = "0.2.0" +embedded-hal = "1.0" +nb = "1.1" +panic-halt = "1.0" +ufmt = "0.2" #[dependencies.avr-device] -#version = "0.4.0" +#version = "0.6.0" #features = ["attiny85"] [dependencies.avr-hal-generic] diff --git a/boards/attiny85/rust-toolchain.toml b/boards/attiny85/rust-toolchain.toml index 63f11f2..a73301d 100644 --- a/boards/attiny85/rust-toolchain.toml +++ b/boards/attiny85/rust-toolchain.toml @@ -1,5 +1,6 @@ [toolchain] channel = "nightly-2024-03-22" +# channel = "nightly" components = ["llvm-tools-preview", "rust-src"] profile = "minimal" targets = ["avr-unknown-none-attiny85.json"] diff --git a/boards/pico/.justfile b/boards/pico/.justfile index 6e7e02b..24dc209 100644 --- a/boards/pico/.justfile +++ b/boards/pico/.justfile @@ -50,4 +50,4 @@ alias up := package update: nix flake update - cargo update + cargo update --verbose diff --git a/boards/qt-py-ch32v203/.justfile b/boards/qt-py-ch32v203/.justfile index aeda550..83c8c01 100644 --- a/boards/qt-py-ch32v203/.justfile +++ b/boards/qt-py-ch32v203/.justfile @@ -37,4 +37,4 @@ alias up := package update: nix flake update - cargo update + cargo update --verbose diff --git a/flake.nix b/flake.nix index ad94ead..d1d59ad 100644 --- a/flake.nix +++ b/flake.nix @@ -92,7 +92,7 @@ p: (p.rust-bin.fromRustupToolchainFile ./boards/attiny85/rust-toolchain.toml).override { # Remove the avr-unknown-none-attiny85.json file from the list of targets for the Rust toolchain. - # Nix doesn't really support target JSON files specified in the toolchain and even if it did, it won't be ablet to build a toolchain for AVR. + # Nix doesn't really support target JSON files specified in the toolchain and even if it did, it won't be able to build a toolchain for AVR. # The AVR toolchain is unstable and does not include std. targets = [ p.stdenv.hostPlatform.rust.rustcTarget ]; }; @@ -140,6 +140,7 @@ # will avoid IFD entirely but will require manually keeping the file # up to date! "${rustToolchain.passthru.availableComponents.rust-src}/lib/rustlib/src/rust/Cargo.lock" + # "${rustToolchain.passthru.availableComponents.rust-src}/lib/rustlib/src/rust/library/Cargo.lock" ]; }; cargoExtraArgs = "--target avr-unknown-none-attiny85.json -Z build-std=core"; @@ -147,8 +148,9 @@ extraDummyScript = '' cp --archive ${./boards/attiny85/avr-unknown-none-attiny85.json} $out/avr-unknown-none-attiny85.json - rm --force --recursive $out/src/bin/crane-dummy-* + (shopt -s globstar; rm --force --recursive $out/**/src/bin/crane-dummy-*) ''; + # # rm --force --recursive $out/src/bin/crane-dummy-* }; cargoArtifacts = craneLib.buildDepsOnly commonArgs;