Skip to content

async API for Env? #685

@antonok-edm

Description

@antonok-edm

Hi! I'm working on a project using the RTIC framework on an STM32F4 microcontroller, and I'm interested in porting OpenSK to that architecture if at all possible.

RTIC leans heavily on Rust's async with interrupts for resource sharing and task scheduling. Right now it looks like the current definition of traits required by Env exclusively use blocking function calls. After a first review for my use-case it looks like HidConnection::send_and_maybe_recv, AttestationStore::{get,set}, Storage::{read_slice,write_slice,erase_page}, and UserPresence would all need to access some kind of shared I/O peripherals. Under RTIC, non-blocking implementations of these traits would be awkward at best (and maybe highly unsafe at worst).

Before I go down this route, I wanted to check in with the maintainers - is this something you'd be willing to merge if a PR was provided? Any other thoughts?

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions