blackcat-cubesat / n2o4 Goto Github PK
View Code? Open in Web Editor NEWSafe, idiomatic bindings to cFE and OSAL APIs for Rust
Home Page: https://blackcat-cubesat.github.io/n2o4/
License: Apache License 2.0
Safe, idiomatic bindings to cFE and OSAL APIs for Rust
Home Page: https://blackcat-cubesat.github.io/n2o4/
License: Apache License 2.0
Right now, we run Cargo with --jobs 1
(see #14), as there doesn't seem to be a way to expose the Make jobserver to the cargo
invocation from CMake. It would be nice to enable such exposure to be able to exploit concurrency within a Cargo build in a controllable manner.
Maybe alter the cFS CMake framework so that you can use Ninja?
Issue BlackCAT-CubeSat/printf-wrap#1 should make the printf-wrap
crate unconditionally #[no_std]
on Rust ≥1.64.0 and remove the dependency on the libc
crate. Once that comes out, we should propagate those changes to n2o4
and cfs-sys
.
Relevant bits include Cargo.toml as well as stuff scattered throughout the Rust source (idea: change NullString
arguments to be AsRef<CStr>
instead?).
It came up today that USING.md
does not include information about some of the dependencies needed for n2o4
to work. We should fix that.
Currently, n2o4
has no bindings to the Table Services APIs; that should be fixed.
Assigning to myself, as I'm currently working on this.
As a crate which isn't being released on crates.io currently, we don't just get online docs for free from docs.rs. Hand-maintaining generation is tedious and prone to errors of omission; as such, we should probably set up a GitHub workflow for building the docs upon an update of the main
branch, generating the HTML and pushing it onto the gh-pages
branch.
Right now, with the use of printf-wrap
, n2o4
has decent support for printf(3)
-type formatting with syslog entries and events. However, Rust has its own string-formatting system. It would be good to support using that instead when making syslog entries or events for a more Rustic experience.
Some things that may come in handy when creating that:
core::write
core::fmt::Write
core::format_args
In particular, implementing Write
for a "[u8; N]
plus index-into-buffer" type would allow all this to be done without heap allocations.
It would be good to be able to use features for, e.g., conditional compilation.
When writing tests for an app, it became clear that it would be convenient if there were Cmp
and Eq
impls for OSTime
and OSTimeInterval
.
Having continuous integration available for catching mistakes in pull requests, etc. would be good to have.
Currently, the n2o4
and cfs-sys
crates only support a specific version of cFE and OSAL:
v7.0.0-rc4
v6.0.0-rc4
As these are the versions of the respective libraries we're using in the BlackCAT flight software, this has been OK for development so far. However, n2o4
should ideally be usable on as wide a range of setups as possible, and that means being able to support other versions of cFE and OSAL.
Right now, it's not clear to me how to modify the current system to support multiple library versions. cfs-sys
just tries to bindgen
everything it can (with some manual additions), with no awareness of what versions of cFE and OSAL it's working with. n2o4
does no version detection whatsoever, and manually trying to track which APIs are available in which versions of {cFE, OSAL} (and with which signatures) sounds like it would be tedious and error-prone.
So, are there good ways to automate or semi-automate this?
It would be nice to be able to test code using n2o4
using Rust's unit-testing framework. This means figuring out the best way to handle the case of #[cfg(test)]
.
Each Rust-based cFS app is compiled separately. Often, they have many of the same dependencies (n2o4
, bindgen
, etc.), and it would be nice to leverage that to speed up compilation.
Need to find out how to do that safely.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.