Skip to content

✨ Add Driver Class traits #154

@rneswold

Description

@rneswold

There should be a drmem-driver-api crate that driver writers can use to make it easier to write them. Driver is the fundamental trait and has the 3 API methods to implement. But we could define other supertraits that guide the developer to create a proper, standardized driver. For instance, there could be a Light state that defines the register_devices() method. In this case, it would create a boolean state device. A DimmableLight could be a supertrait and add a brightness device. ColorLight enhances it further by adding a color device, etc.

This enforces a standard set of device endpoints for classes of hardware.

Metadata

Metadata

Assignees

Labels

designFormalize specification(s)driverIssue is about a driverenhancementNew feature or request

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions