Ivan's Blog
项目实践

ups120

Rust embedded firmware + libraries for an “UPS120” device, with supporting docs, scripts, and structured submodules for chip drivers/components. Evidence: README.md, firmware/, libs/, rust-toolchain.toml.

  • Device mono-repo
  • DC fan speed control

目录

技术栈

运行与交付

CI 工作流
  • check.yml
  • dev-release.yml
  • release.yml
能力标记
  • github_actions
  • package_json
  • package_lock
JSON

Basics

Rust embedded firmware + libraries for an “UPS120” device, with supporting docs, scripts, and structured submodules for chip drivers/components. Evidence: README.md, firmware/, libs/, rust-toolchain.toml.

Taxonomy

  • Tags: Device mono-repo, DC fan speed control

Architecture

  • Firmware-centric mono-repo with multiple component directories (device-level firmware + chip drivers + shared libs). Evidence: firmware/, libs/, bq76920/, sc8815/.
  • Uses Embassy async ecosystem for embedded runtime. Evidence: embassy/, Cargo.toml within firmware/libs.
  • Adds a two-wire fan control path using RT9043GB with PWM->RC->FB voltage control and EN gating for linear DC speed regulation. Evidence: firmware/ups-main/docs/fan_control_spec.md.

Conventions

  • Pinned toolchain + formatting config for consistent builds. Evidence: rust-toolchain.toml, rustfmt.toml.
  • Hook-based hygiene for commits/formatting. Evidence: lefthook.yml, commitlint.config.cjs.

Taste notes

This repo is a good “device firmware as a product” example: clear docs, structured components, and disciplined tooling reduce the usual embedded chaos.