Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/katyo/uctl-rs
Generic control library for low-end hardware
https://github.com/katyo/uctl-rs
Last synced: 16 days ago
JSON representation
Generic control library for low-end hardware
- Host: GitHub
- URL: https://github.com/katyo/uctl-rs
- Owner: katyo
- Created: 2019-10-19T14:39:48.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2021-02-07T08:40:12.000Z (almost 4 years ago)
- Last Synced: 2024-09-16T06:18:08.302Z (4 months ago)
- Language: Rust
- Size: 113 KB
- Stars: 2
- Watchers: 4
- Forks: 0
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Generic control library for low-end hadrware
[![License: MIT](https://img.shields.io/badge/License-MIT-brightgreen.svg)](https://opensource.org/licenses/MIT)
[![Travis-CI Build Status](https://travis-ci.com/katyo/uctl-rs.svg?branch=master)](https://travis-ci.com/katyo/uctl-rs)
[![Crates.io Package](https://img.shields.io/crates/v/uctl.svg?style=popout)](https://crates.io/crates/uctl)
[![Docs.rs API Documentation](https://docs.rs/uctl/badge.svg)](https://docs.rs/uctl)This library intended to simplify developing control algorithms for bare-metal low-end hardware such as
microcontrollers.## Current status
Currently Rust is quite restricted in using constants as a type parameters. To get the original ideas works well it requires support for floating-point operations at type level which implement only the languages with fullfeatured compile-time expression evaluation like D and C++ (with restrictions and quirks).
Due to reasons above the development currently focussed on [uctl-d](https://github.com/katyo/uctl-d).## Overview
This library consist of several independent components which grouped to filters, regulators and convertors.
Also it includes some useful utilities, such as clampers, scalers and etc.The filters and regulators can be configured in a human-friendly way without using obscure artifical coefficients.
All components can operate both with floating point and fixed point values.
### Optimization techniques
When you targeted to FPU-less hardware in order to get best possible performance and reduce firmware size you should use only binary fixed point arithmetic because internally it operates with integers.
Also you should avoid exceeding platform word size when it is possible without lossing required precision.### Safe usage
Fixed point arithmetic has well known problems with overflowing especially on multiplication.
Also it has well known problems with precision loss on division.## Links
* [ufix crate](https://crates.io/crates/ufix)
* [ufix API](https://docs.rs/ufix)
* [uctl crate](https://crates.io/crates/uctl)
* [uctl API](https://docs.rs/uctl)